changeset 36536:a2bf6994df8c

vo_bl: RGB output support. Patch by Stefan Schuermans [stefan blinkenarea org].
author reimar
date Sun, 19 Jan 2014 12:06:03 +0000
parents 9bd54104cdee
children 3b2228019b6a
files libvo/vo_bl.c
diffstat 1 files changed, 5 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/libvo/vo_bl.c	Sun Jan 19 12:06:02 2014 +0000
+++ b/libvo/vo_bl.c	Sun Jan 19 12:06:03 2014 +0000
@@ -213,7 +213,7 @@
 	h->fd = -1;
 }
 
-#define NO_BLS 3
+#define NO_BLS 4
 
 static const bl_properties_t bls[NO_BLS] = {
 	{ "hdl", IMGFMT_Y8, 1, 18, 8, 8,
@@ -224,6 +224,9 @@
 	&udp_init, &udp_send, &udp_close },
 	{ "grayscale", IMGFMT_Y8, 1, -1, -1, 8, /* use width and height of movie */
 	&bml_init, &bml_write_frame, &bml_close,
+	&udp_init, &udp_send, &udp_close },
+	{ "rgb", IMGFMT_RGB24, 3, -1, -1, 8, /* use width and height of movie */
+	&bml_init, &bml_write_frame, &bml_close,
 	&udp_init, &udp_send, &udp_close } };
 
 static int config(uint32_t width, uint32_t height, uint32_t d_width,
@@ -269,7 +272,7 @@
 	bl_packet->maxval = htons((1 << bl->bpc) - 1);
 
 	framenum = 0;
-	if (format != IMGFMT_Y8) {
+	if (format != bl->img_format) {
 		mp_msg(MSGT_VO, MSGL_ERR, "vo_bl called with wrong format");
 		goto err_out;
 	}