View Single Post
Old 24th March 2023, 09:04   #11  |  Link
cubicibo
Registered User
 
Join Date: Feb 2022
Posts: 104
Thank you really much! So scrolling subtitles is easy (well…)

Changing subtitles will never refresh the display instantaneously with cropping. This is because the cropping operation is done on existing objects in the PG buffer (the object you see is defined only once in the stream). As you switch, you land in the middle of the epoch and there are no objects to crop, so all subsequent segments are ignored. If you want more frequent hooks, the stream needs to contain acquisition points. But then, the object must be decoded, copied and drawn again and this can take quite a few frames! If your scrolling has a pause, you can do it. If it does not, it is not possible without steutterred movement. Of course, with real subtitles, scrolling will last a handful of seconds, not 20. so there will be frequent hooks.

FFmpeg decoder checks that the displayed object is not larger than the dimensions declared in the PGS. Since 1150 > 1080, (image is 800x1150 I think) it aborts decoding and drops the data. I will try to send a patch to FFmpeg to implement cropping.

BTW, this is the maximum refreshable area when cropping is performed:
MaxArea = 32e6/(2*(fps/k))
For 24p, refreshing every frame (k=1) is limited to 666,500 pixels (e.g 815x815). If you want to update more area, you must scroll every other frames to increment the k factor.
The rule of thumb is 1/4 screen area of a 1920x1080p29.97.

I will try to add scrolling and cropping detection in the bdn.xml convert pipeline of SUPer. Hopefully in a few months.

Last edited by cubicibo; 24th March 2023 at 10:25.
cubicibo is offline   Reply With Quote