comparison libvo/vo_bl.c @ 15952:7a33ae1f8e6d

--Patch by Stefan '1stein' Schuermans <1stein@schuermans.info>: the bugfix of the "grayscale" output scheme introduced a bug in the header writer for the stream output, this patch corrects that
author rik
date Sun, 10 Jul 2005 12:35:43 +0000
parents 05aa13cdf92f
children fd51fd1ff231
comparison
equal deleted inserted replaced
15951:137f825e58c2 15952:7a33ae1f8e6d
218 { 218 {
219 void * ptr; 219 void * ptr;
220 220
221 /* adapt size of Blinkenlights UDP stream to size of movie */ 221 /* adapt size of Blinkenlights UDP stream to size of movie */
222 if (bl->width < 0 || bl->height < 0) { 222 if (bl->width < 0 || bl->height < 0) {
223 if (bl->width < 0) /* use width of movie */ 223 if (bl->width < 0) { /* use width of movie */
224 bl->width = width; 224 bl->width = width;
225 if (bl->height < 0) /* use height of movie */ 225 bl_packet->width = htons(bl->width);
226 }
227 if (bl->height < 0) { /* use height of movie */
226 bl->height = height; 228 bl->height = height;
229 bl_packet->height = htons(bl->height);
230 }
227 /* check for maximum size of UDP packet */ 231 /* check for maximum size of UDP packet */
228 if (12 + bl->width*bl->height*bl->channels > 65507) { 232 if (12 + bl->width*bl->height*bl->channels > 65507) {
229 mp_msg(MSGT_VO, MSGL_ERR, "bl: %dx%d-%d does not fit into an UDP packet\n", 233 mp_msg(MSGT_VO, MSGL_ERR, "bl: %dx%d-%d does not fit into an UDP packet\n",
230 bl->width, bl->height, bl->channels); 234 bl->width, bl->height, bl->channels);
231 return 1; 235 return 1;