summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2021-03-01 21:36:36 +0100
committerCarl Hetherington <cth@carlh.net>2021-03-02 15:40:18 +0100
commit04e94f01295463f2c910ba2b4306c1b76e340a45 (patch)
tree4ea19f5000304a6966b5432de0161380d3e1e11f
parentb9cee5bab06b073cff91b8ca618a6452a354a45e (diff)
Rename some subtitle decoding / processing methods.
-rw-r--r--src/lib/ffmpeg_decoder.cc12
-rw-r--r--src/lib/ffmpeg_decoder.h6
2 files changed, 9 insertions, 9 deletions
diff --git a/src/lib/ffmpeg_decoder.cc b/src/lib/ffmpeg_decoder.cc
index 9b65e5639..30993f882 100644
--- a/src/lib/ffmpeg_decoder.cc
+++ b/src/lib/ffmpeg_decoder.cc
@@ -192,7 +192,7 @@ FFmpegDecoder::pass ()
if (_video_stream && si == _video_stream.get() && video && !video->ignore()) {
decode_video_packet (packet);
} else if (fc->subtitle_stream() && fc->subtitle_stream()->uses_index(_format_context, si) && !only_text()->ignore()) {
- decode_subtitle_packet (packet);
+ decode_and_process_subtitle_packet (packet);
} else {
decode_audio_packet (packet);
}
@@ -598,7 +598,7 @@ DCPOMATIC_ENABLE_WARNINGS
void
-FFmpegDecoder::decode_subtitle_packet (AVPacket* packet)
+FFmpegDecoder::decode_and_process_subtitle_packet (AVPacket* packet)
{
int got_subtitle;
AVSubtitle sub;
@@ -641,13 +641,13 @@ FFmpegDecoder::decode_subtitle_packet (AVPacket* packet)
case SUBTITLE_NONE:
break;
case SUBTITLE_BITMAP:
- decode_bitmap_subtitle (rect, from);
+ process_bitmap_subtitle (rect, from);
break;
case SUBTITLE_TEXT:
cout << "XXX: SUBTITLE_TEXT " << rect->text << "\n";
break;
case SUBTITLE_ASS:
- decode_ass_subtitle (rect->ass, from);
+ process_ass_subtitle (rect->ass, from);
break;
}
}
@@ -661,7 +661,7 @@ FFmpegDecoder::decode_subtitle_packet (AVPacket* packet)
void
-FFmpegDecoder::decode_bitmap_subtitle (AVSubtitleRect const * rect, ContentTime from)
+FFmpegDecoder::process_bitmap_subtitle (AVSubtitleRect const * rect, ContentTime from)
{
/* Note BGRA is expressed little-endian, so the first byte in the word is B, second
G, third R, fourth A.
@@ -749,7 +749,7 @@ FFmpegDecoder::decode_bitmap_subtitle (AVSubtitleRect const * rect, ContentTime
void
-FFmpegDecoder::decode_ass_subtitle (string ass, ContentTime from)
+FFmpegDecoder::process_ass_subtitle (string ass, ContentTime from)
{
/* We have no styles and no Format: line, so I'm assuming that FFmpeg
produces a single format of Dialogue: lines...
diff --git a/src/lib/ffmpeg_decoder.h b/src/lib/ffmpeg_decoder.h
index a0a93c9a0..bd35814df 100644
--- a/src/lib/ffmpeg_decoder.h
+++ b/src/lib/ffmpeg_decoder.h
@@ -62,10 +62,10 @@ private:
bool decode_video_packet (AVPacket* packet);
void decode_audio_packet (AVPacket* packet);
- void decode_subtitle_packet (AVPacket* packet);
+ void decode_and_process_subtitle_packet (AVPacket* packet);
- void decode_bitmap_subtitle (AVSubtitleRect const * rect, dcpomatic::ContentTime from);
- void decode_ass_subtitle (std::string ass, dcpomatic::ContentTime from);
+ void process_bitmap_subtitle (AVSubtitleRect const * rect, dcpomatic::ContentTime from);
+ void process_ass_subtitle (std::string ass, dcpomatic::ContentTime from);
void maybe_add_subtitle ();
std::shared_ptr<AudioBuffers> deinterleave_audio (std::shared_ptr<FFmpegAudioStream> stream) const;