Skip to content

Commit a81d1ce

Browse files
movemanewong-harmonicincprateekmediacfsmp3
authored andcommitted
Handle row_count decrease (CCExtractor#1702)
Co-authored-by: ewong <Edmond.Wong@harmonicinc.com> Co-authored-by: Prateek Sunal <prtksunal@gmail.com> Co-authored-by: Carlos Fernandez Sanz <carlos@ccextractor.org>
1 parent 4cc0177 commit a81d1ce

File tree

2 files changed

+13
-0
lines changed

2 files changed

+13
-0
lines changed

docs/CHANGES.TXT

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@
5353
- Fix: Resolve compile-time error about implicit declarations (#1646)
5454
- Fix: fatal out of memory error extracting from a VOB PS
5555
- Fix: Unit Test Rust failing due to changes in Rust Version 1.86.0
56+
- Fix: handle row_count decrease in CEA-708 C decoder
5657
- Fix: Support for MINGW-w64 cross compiling
5758
- Fix: Build with ENABLE_FFMPEG to support ffmpeg 5
5859

src/lib_ccx/ccx_decoders_708.c

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1025,6 +1025,18 @@ void dtvcc_handle_DFx_DefineWindow(dtvcc_service_decoder *decoder, int window_id
10251025
if (anchor_horizontal > CCX_DTVCC_SCREENGRID_COLUMNS - col_count)
10261026
anchor_horizontal = CCX_DTVCC_SCREENGRID_COLUMNS - col_count;
10271027

1028+
if (window->is_defined)
1029+
{
1030+
if (row_count < window->row_count)
1031+
{
1032+
// Remove the oldest row if the row count is reduced
1033+
for (int i = row_count; i < window->row_count; i++)
1034+
{
1035+
dtvcc_window_rollup(decoder, window);
1036+
}
1037+
}
1038+
}
1039+
10281040
window->priority = priority;
10291041
window->col_lock = col_lock;
10301042
window->row_lock = row_lock;

0 commit comments

Comments
 (0)