Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  1. You can use the GET API with UUID to get the details of the tile to which you have assigned the source to be cropped.

    GET: http://192.168.10.131/api/5.0/tiles/config/ecc27aff-a5a2-471e-b9e6-1e0c5086c1e0/.json
    Response

Expand
titleRESPONSE
  1. Code Block
    languagejson
    {
        "data": {
            "uuid": "ecc27aff-a5a2-471e-b9e6-1e0c5086c1e0",
            "label": "tile_beforecrop",
            "version": 0,
            "created": "2024-02-02T11:07:17.691Z",
            "modified": "2024-02-02T11:07:41.959Z",
            "content_type": "Channel",
            "min_width": 32,
            "min_height": 32,
            "default_width": 300,
            "default_height": 200,
            "description": "",
            "objects": [
                {
                    "type": "Video",
                    "left": {
                        "pixels": 0,
                        "percentage": 10
                    },
                    "right": {
                        "pixels": 0,
                        "percentage": 10
                    },
                    "top": {
                        "pixels": 0,
                        "percentage": 10
                    },
                    "bottom": {
                        "pixels": 0,
                        "percentage": 10
                    },
                    "max_width": {
                        "pixels": null,
                        "percentage": 100
                    },
                    "max_height": {
                        "pixels": null,
                        "percentage": 100
                    },
                    "alignment": "Top Left",
                    "index": 1,
                    "crop": {
                        "left": {
                            "percentage": 0
                        },
                        "right": {
                            "percentage": 0
                        },
                        "top": {
                            "percentage": 0
                        },
                        "bottom": {
                            "percentage": 0
                        }
                    }
                }
            ]
        },
        "metadata": {
            "config_version": 1706857250569938
        }
    }

View the source before cropping on Output encoder

...

  1. In POSTMAN under the BODY section, edit the percentage under the crop section shown below using PUT command. Please note that all percentage values must be in integers, decimal values are not supported currently.

    PUT http://192.168.10.131/api/5.0/tiles/config/ecc27aff-a5a2-471e-b9e6-1e0c5086c1e0/.json

...

Expand
titleBODY
Code Block
languagejson
{
    "data": {
        "label": "tile_aftercrop",
        "version": 0,
        "content_type": "Channel",
        "min_width": 32,
        "min_height": 32,
        "default_width": 300,
        "default_height": 200,
        "description": "",
        "objects": [
            {
                "type": "Video",
                "left": {
                    "pixels": 0,
                    "percentage": 10
                },
                "right": {
                    "pixels": 0,
                    "percentage": 10
                },
                "top": {
                    "pixels": 0,
                    "percentage": 10
                },
                "bottom": {
                    "pixels": 0,
                    "percentage": 10
                },
                "max_width": {
                    "pixels": null,
                    "percentage": 100
                },
                "max_height": {
                    "pixels": null,
                    "percentage": 100
                },
                "alignment": "Top Left",
                "index": 1,
                "crop": {
                    "left": {
                        "percentage": 30
                    },
                    "right": {
                        "percentage": 40
                    },
                    "top": {
                        "percentage": 35
                    },
                    "bottom": {
                        "percentage": 20
                    }
                }
            }
        ]
    },
    "metadata": {
        "config_version": 1706857250569938
    }
}

Expand
title
Response
RESPONSE
Code Block
languagejson
{
    "data": {
        "uuid": "ecc27aff-a5a2-471e-b9e6-1e0c5086c1e0",
        "label": "tile_aftercrop",
        "version": 0,
        "created": "2024-02-02T11:07:17.691Z",
        "modified": "2024-02-02T11:25:15.914Z",
        "content_type": "Channel",
        "min_width": 32,
        "min_height": 32,
        "default_width": 300,
        "default_height": 200,
        "description": "",
        "objects": [
            {
                "type": "Video",
                "left": {
                    "pixels": 0,
                    "percentage": 10
                },
                "right": {
                    "pixels": 0,
                    "percentage": 10
                },
                "top": {
                    "pixels": 0,
                    "percentage": 10
                },
                "bottom": {
                    "pixels": 0,
                    "percentage": 10
                },
                "max_width": {
                    "pixels": null,
                    "percentage": 100
                },
                "max_height": {
                    "pixels": null,
                    "percentage": 100
                },
                "alignment": "Top Left",
                "index": 1,
                "crop": {
                    "left": {
                        "percentage": 30
                    },
                    "right": {
                        "percentage": 40
                    },
                    "top": {
                        "percentage": 35
                    },
                    "bottom": {
                        "percentage": 20
                    }
                }
            }
        ]
    },
    "metadata": {
        "config_version": 1706857250569938
    }
}
image-20240202-113240.pngImage Modified