mirror of
https://github.com/CCExtractor/ccextractor.git
synced 2026-07-08 18:06:30 +00:00
spupng subtitle offset set according to dvb spec
This commit is contained in:
@@ -794,6 +794,7 @@ static void save_display_set(DVBSubContext *ctx)
|
||||
|
||||
filename = get_spupng_filename(sp);
|
||||
inc_spupng_fileindex(sp);
|
||||
set_spupng_offset(sp,y_pos,x_pos);
|
||||
|
||||
pbuf = (uint8_t*) malloc(width * height);
|
||||
memset(pbuf, 0x0, width * height);
|
||||
@@ -1768,10 +1769,6 @@ static void dvbsub_parse_page_segment(void *dvb_ctx, const uint8_t *buf,
|
||||
delete_objects(ctx);
|
||||
delete_cluts(ctx);
|
||||
}
|
||||
else if(page_state == 0)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
tmp_display_list = ctx->display_list;
|
||||
ctx->display_list = NULL;
|
||||
|
||||
@@ -326,4 +326,10 @@ void inc_spupng_fileindex(void *ctx)
|
||||
struct spupng_t *sp = (struct spupng_t *)ctx;
|
||||
sp->fileIndex++;
|
||||
}
|
||||
void set_spupng_offset(void *ctx,int x,int y)
|
||||
{
|
||||
struct spupng_t *sp = (struct spupng_t *)ctx;
|
||||
sp->xOffset = x;
|
||||
sp->yOffset = y;
|
||||
}
|
||||
|
||||
|
||||
@@ -31,4 +31,5 @@ void write_sputag(struct spupng_t *sp,LLONG ms_start,LLONG ms_end);
|
||||
void write_spucomment(struct spupng_t *sp,const char *str);
|
||||
char* get_spupng_filename(void *ctx);
|
||||
void inc_spupng_fileindex(void *ctx);
|
||||
void set_spupng_offset(void *ctx,int x,int y);
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user