Fixes output for field_2

This commit is contained in:
Umang Jain 2015-02-27 20:47:50 +05:30
parent 0e803eba95
commit 9358978a61
3 changed files with 4 additions and 2 deletions

View File

@ -99,6 +99,7 @@ struct lib_cc_decode
enum ccx_output_format write_format; // 0=Raw, 1=srt, 2=SMI
struct ccx_boundary_time extraction_start, extraction_end; // Segment we actually process
void *wbout1;
void *wbout2;
LLONG subs_delay; // ms to delay (or advance) subs
};

View File

@ -538,7 +538,8 @@ void general_loop(struct lib_ccx_ctx *ctx, void *enc_ctx)
struct cc_subtitle dec_sub;
struct lib_cc_decode *dec_ctx = NULL;
dec_ctx = ctx->dec_ctx;
dec_ctx->wbout1 = (struct ccx_s_write*)&ctx->wbout1 ;
dec_ctx->wbout1 = (struct ccx_s_write*)&ctx->wbout1 ;
dec_ctx->wbout2 = (struct ccx_s_write*)&ctx->wbout2 ;
inbuf = 0; // No data yet
end_of_file = 0;

View File

@ -111,7 +111,7 @@ void printdata (struct lib_cc_decode *ctx, const unsigned char *data1, int lengt
struct ccx_decoder_608_context *field_2 = ctx->context_cc608_field_2;
struct ccx_s_write *wbout1 = ctx->wbout1;
field_1->out = ctx->wbout1 ;
field_2->out = ctx->wbout1 ;
field_2->out = ctx->wbout2 ;
if (ctx->write_format==CCX_OF_DVDRAW)
writeDVDraw (data1, length1, data2, length2, wbout1);
else /* Broadcast raw or any non-raw */