GL: use dupmsg instead of dupb

parent d9d6fb61
......@@ -195,8 +195,8 @@ static void ogl_display_set_yuv(struct opengles_display* gldisp, mblk_t *yuv, en
}
ms_mutex_lock(&gldisp->yuv_mutex);
if (gldisp->yuv[type])
freeb(gldisp->yuv[type]);
gldisp->yuv[type] = dupb(yuv);
freemsg(gldisp->yuv[type]);
gldisp->yuv[type] = dupmsg(yuv);
gldisp->new_yuv_image[type] = TRUE;
ms_mutex_unlock(&gldisp->yuv_mutex);
}
......
......@@ -187,7 +187,7 @@ static void choose_display_name(VideoStream *stream){
stream->display_name=ms_strdup("MSAndroidDisplay");
#elif __APPLE__ && !defined(__ios)
stream->display_name=ms_strdup("MSOSXGLDisplay");
#elif defined (HAVE_X11_EXTENSIONS_XV_H)
#elif defined (HAVE_XV) || defined (HAVE_GL)
stream->display_name=ms_strdup("MSX11Video");
#elif defined(__ios)
stream->display_name=ms_strdup("IOSDisplay");
......
......@@ -418,7 +418,7 @@ static void x11video_process(MSFilter *f){
}
if (f->inputs[1]!=NULL && (inm=ms_queue_peek_last(f->inputs[1]))!=0) {
if (ms_yuv_buf_init_from_mblk(&src,inm)==0){
ogl_display_set_yuv_preview_to_display(obj->glhelper, inm);
ogl_display_set_preview_yuv_to_display(obj->glhelper, inm);
}
}
......
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