mirror of https://code.videolan.org/videolan/vlc
xcb/render: assume the video area is the same as the "original" area
This commit is contained in:
parent
df71e59703
commit
5b65b93eb1
|
@ -172,15 +172,13 @@ static void RenderRegion(vout_display_t *vd, const vlc_render_subpicture *subpic
|
|||
sys->picture.subpic_crop, alpha_color,
|
||||
ARRAY_SIZE(rects), rects);
|
||||
|
||||
const float scale_w = (float)(place->width ) / (subpic->i_original_picture_width );
|
||||
const float scale_h = (float)(place->height) / (subpic->i_original_picture_height);
|
||||
/* Mask in the original alpha channel then renver over the scaled pixmap.
|
||||
* Mask (pre)multiplies RGB channels and restores the alpha channel.
|
||||
*/
|
||||
int_fast16_t dx = place->x + reg->place.x * scale_w;
|
||||
int_fast16_t dy = place->y + reg->place.y * scale_h;
|
||||
uint_fast16_t dw = (reg->place.width) * scale_w;
|
||||
uint_fast16_t dh = (reg->place.height) * scale_h;
|
||||
int_fast16_t dx = place->x + reg->place.x;
|
||||
int_fast16_t dy = place->y + reg->place.y;
|
||||
uint_fast16_t dw = reg->place.width;
|
||||
uint_fast16_t dh = reg->place.height;
|
||||
|
||||
xcb_render_transform_t transform = {
|
||||
0, 0, 0,
|
||||
|
|
Loading…
Reference in New Issue