- /* Margin shifts all subpictures */
- /* NOTE We have margin only for subtitles, so we don't really need this here
- if( i_margin_y != 0 )
- i_y -= i_margin_y;*/
-
- /* Clamp offset to not go out of the screen (when possible) */
- /* NOTE Again, useful only for subtitles, otherwise goes against the alignment logic above
- const int i_error_x = (i_x + p_region->fmt.i_width) - p_subpic->i_original_picture_width;
- if( i_error_x > 0 )
- i_x -= i_error_x;
- if( i_x < 0 )
- i_x = 0;
-
- const int i_error_y = (i_y + p_region->fmt.i_height) - p_subpic->i_original_picture_height;
- if( i_error_y > 0 )
- i_y -= i_error_y;
- if( i_y < 0 )
- i_y = 0;*/
-