mirror of
https://github.com/mpv-player/mpv
synced 2024-11-14 22:48:35 +01:00
ass_process_chunk: Use llrint, not lrint
libass's ass_process_chunk expects long long int for the timecode and durations arguments, thus should use llrint instead of lrint. This does not cause any problems on most platforms, but on cygwin, it causes strange subtitle behaviour, like subtitles not showing, getting stuck or old subtitles showing at the same time as new subtitles.
This commit is contained in:
parent
af0a8d7478
commit
da0bf27930
@ -270,8 +270,8 @@ static void decode(struct sd *sd, struct demux_packet *packet)
|
||||
// Note that for this packet format, libass has an internal mechanism
|
||||
// for discarding duplicate (already seen) packets.
|
||||
ass_process_chunk(track, packet->buffer, packet->len,
|
||||
lrint(packet->pts * 1000),
|
||||
lrint(packet->duration * 1000));
|
||||
llrint(packet->pts * 1000),
|
||||
llrint(packet->duration * 1000));
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user