Commit 4d4f72b8 authored by Derk-Jan Hartman's avatar Derk-Jan Hartman

* forwardport the mjpeg fix and the dvbsub color fixes

parent 267b66c8
...@@ -419,8 +419,8 @@ static void default_clut_init( decoder_t *p_dec ) ...@@ -419,8 +419,8 @@ static void default_clut_init( decoder_t *p_dec )
else R = G = B = 0x7F; else R = G = B = 0x7F;
p_sys->default_clut.c_2b[i].Y = RGB_TO_Y(R,G,B); p_sys->default_clut.c_2b[i].Y = RGB_TO_Y(R,G,B);
p_sys->default_clut.c_2b[i].Cr = RGB_TO_U(R,G,B);
p_sys->default_clut.c_2b[i].Cb = RGB_TO_V(R,G,B); p_sys->default_clut.c_2b[i].Cb = RGB_TO_V(R,G,B);
p_sys->default_clut.c_2b[i].Cr = RGB_TO_U(R,G,B);
p_sys->default_clut.c_2b[i].T = T; p_sys->default_clut.c_2b[i].T = T;
} }
...@@ -450,8 +450,8 @@ static void default_clut_init( decoder_t *p_dec ) ...@@ -450,8 +450,8 @@ static void default_clut_init( decoder_t *p_dec )
} }
p_sys->default_clut.c_4b[i].Y = RGB_TO_Y(R,G,B); p_sys->default_clut.c_4b[i].Y = RGB_TO_Y(R,G,B);
p_sys->default_clut.c_4b[i].Cr = RGB_TO_U(R,G,B); p_sys->default_clut.c_4b[i].Cr = RGB_TO_V(R,G,B);
p_sys->default_clut.c_4b[i].Cb = RGB_TO_V(R,G,B); p_sys->default_clut.c_4b[i].Cb = RGB_TO_U(R,G,B);
p_sys->default_clut.c_4b[i].T = T; p_sys->default_clut.c_4b[i].T = T;
} }
...@@ -1405,8 +1405,8 @@ static subpicture_t *render( decoder_t *p_dec ) ...@@ -1405,8 +1405,8 @@ static subpicture_t *render( decoder_t *p_dec )
for( j = 0; j < fmt.p_palette->i_entries; j++ ) for( j = 0; j < fmt.p_palette->i_entries; j++ )
{ {
fmt.p_palette->palette[j][0] = p_color[j].Y; fmt.p_palette->palette[j][0] = p_color[j].Y;
fmt.p_palette->palette[j][1] = p_color[j].Cr; fmt.p_palette->palette[j][1] = p_color[j].Cb; /* U == Cb */
fmt.p_palette->palette[j][2] = p_color[j].Cb; fmt.p_palette->palette[j][2] = p_color[j].Cr; /* V == Cr */
fmt.p_palette->palette[j][3] = 0xff - p_color[j].T; fmt.p_palette->palette[j][3] = 0xff - p_color[j].T;
} }
...@@ -1464,6 +1464,8 @@ static subpicture_t *render( decoder_t *p_dec ) ...@@ -1464,6 +1464,8 @@ static subpicture_t *render( decoder_t *p_dec )
p_spu->i_flags = p_sys->i_spu_position; p_spu->i_flags = p_sys->i_spu_position;
p_spu->i_x = p_sys->i_spu_x; p_spu->i_x = p_sys->i_spu_x;
p_spu->i_y = p_sys->i_spu_y; p_spu->i_y = p_sys->i_spu_y;
p_spu->i_original_picture_width = 720;
p_spu->i_original_picture_height = 576;
return p_spu; return p_spu;
} }
......
...@@ -202,7 +202,9 @@ static vlc_bool_t CheckMimeHeader( demux_t *p_demux, int *p_header_size ) ...@@ -202,7 +202,9 @@ static vlc_bool_t CheckMimeHeader( demux_t *p_demux, int *p_header_size )
*p_header_size = -3; *p_header_size = -3;
return VLC_FALSE; return VLC_FALSE;
} }
if( NULL == p_sys->psz_separator )
/* Read the separator and remember it if not yet stored */
if( p_sys->psz_separator == NULL )
{ {
p_sys->psz_separator = psz_line; p_sys->psz_separator = psz_line;
msg_Dbg( p_demux, "Multipart MIME detected, using separator: %s", msg_Dbg( p_demux, "Multipart MIME detected, using separator: %s",
...@@ -215,8 +217,9 @@ static vlc_bool_t CheckMimeHeader( demux_t *p_demux, int *p_header_size ) ...@@ -215,8 +217,9 @@ static vlc_bool_t CheckMimeHeader( demux_t *p_demux, int *p_header_size )
msg_Warn( p_demux, "separator %s does not match %s", psz_line, msg_Warn( p_demux, "separator %s does not match %s", psz_line,
p_sys->psz_separator ); p_sys->psz_separator );
} }
free( psz_line );
} }
free( psz_line );
psz_line = GetLine( p_demux, &i_pos ); psz_line = GetLine( p_demux, &i_pos );
while( psz_line && *psz_line ) while( psz_line && *psz_line )
{ {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment