[MPlayer-dev-eng] [PATCH] Review please: support sub_pos in libass

Rafał Miłecki zajec5 at gmail.com
Wed Dec 24 18:16:15 CET 2008


2008/12/24 Evgeniy Stepanov <eugeni.stepanov at gmail.com>:
> On Wednesday 24 December 2008 14:45:59 Rafał Miłecki wrote:
>> > You'd better give it a name, like VALIGN_PERCENTPOS, and keep that "else"
>> > branch for traditional ASS subtitles (VALIGN_SUB). Less likely to break
>> > something this way.
>>
>> Now I wonder if this is good idea to use this new invalid value. Maybe
>> I just should add new variable tracking if Alignment was got from
>> subtitles file? Something like:
>>
>> int Respect_sub_pos;
>> style->Respect_sub_pos = 1;
>>
>> and in case of finding alignment in subtitle:
>> {
>> style->Alignment = new_alignment_value;
>> style->Respect_sub_pos = 0;
>> }
>
> It's not invalid, we can call it an mplayer extension of SSA/ASS. What you are
> suggesting is to add one more variable to ass_style_t without real benefits.

OK, thanks for evaluating. I don't know MPlayer enought yet, to decide
which solution is better :)


>> >> One possibility would be to add an alignment type that reads the exact
>> >> position from another variable in the struct,
>> >
>> > Probably percentage of image height, not the exact pixel position.
>>
>> Sorry, I don't understand that. What do you mean by adding "alignment
>> type"? Some new struct? On field in existing struct?
>
> VALIGN_PERCENTPOS constant. And a variable ass_style_t.percent_pos, storing
> the value of sub_pos.

Thanks again.


I'm sending reworked patch in few minutes.

-- 
Rafał Miłecki


More information about the MPlayer-dev-eng mailing list