Mercurial > mplayer.hg
comparison sub/sub.c @ 35275:317eee237d0f
Support subpos values > 100 that allow the subtitles
to be clipped a bit.
author | reimar |
---|---|
date | Thu, 08 Nov 2012 18:26:13 +0000 |
parents | 349f03d4c033 |
children | 19e0fc815a0e |
comparison
equal
deleted
inserted
replaced
35274:4f4a90b80a9a | 35275:317eee237d0f |
---|---|
977 else | 977 else |
978 obj->y = dys * sub_pos / 100; | 978 obj->y = dys * sub_pos / 100; |
979 | 979 |
980 if (obj->y < 0) | 980 if (obj->y < 0) |
981 obj->y = 0; | 981 obj->y = 0; |
982 if (sub_pos <= 100 && obj->y > dys - h) | |
983 obj->y = FFMAX(dys - h, 0); | |
982 if (obj->y > dys - h) | 984 if (obj->y > dys - h) |
983 obj->y = dys - h; | 985 h = FFMAX(dys - obj->y, 0); |
984 | 986 |
985 obj->bbox.y2 = obj->y + h; | 987 obj->bbox.y2 = obj->y + h; |
986 | 988 |
987 // calculate bbox: | 989 // calculate bbox: |
988 if (sub_justify) xmin = 10; | 990 if (sub_justify) xmin = 10; |