subpicture: init the position of the PIP region

It's positioned at the center of the display by default as the PIP doesn't set any
alignment or set the absolute flag.

It was the value set by the calloc before 4f0d7e7731.
This commit is contained in:
Steve Lhomme 2024-03-26 14:13:03 +01:00
parent dc6eb5e78e
commit b92c25d085
1 changed files with 3 additions and 0 deletions

View File

@ -164,6 +164,9 @@ subpicture_t *subpicture_NewFromPicture( vlc_object_t *p_obj,
p_region->fmt.i_sar_num =
p_region->fmt.i_sar_den = 0;
// margin to the center or to the top/left if the subpicture is absolute
p_region->i_x = 0;
p_region->i_y = 0;
vlc_spu_regions_push( &p_subpic->regions, p_region );
return p_subpic;