tiler icon indicating copy to clipboard operation
tiler copied to clipboard

Conteiner bounds overflow

Open Shpakovich opened this issue 3 years ago • 0 comments

If you create a tiler with parameters where toCount is greater than colCount and rowCount:

{ // draw area params for tiler
     "fromCount": 30,
      "toCount": 40,
      "colCount": 7,
      "rowCount": 5,
      "margin": 4,
      "forceAspectRatio": 1.7777777777777777
}

In this case, the overflow check will not work and tiler compose() will return a grid with video slots not included in the area, instead of cutting off extra videos:

{ // returned slot example
    "height": 170,
    "width": 303,
    "top": 1017,
    "left": 1233,
    "stream": {
        "id": "local",
        "objectFit": "cover",
        "kind": "",
        "title": {
            "label": "Denis Shmakov",
            "padding": 2,
            "margin": 8,
            "position": "bottom right"
        },
        "area": 1,
        "muted": false
    }
}

for example 39-s video element, where top + height > area size. Screenshot of what it looks:

Снимок экрана 2022-04-22 в 12 09 10

I am attaching logs with what was sent and returned from tiler compose() compose_log_input.log compose_log_output.log

Shpakovich avatar Apr 22 '22 12:04 Shpakovich