Commit 700fe6be authored by smorlat's avatar smorlat

fix crash during video resizing on SDL/linux.



git-svn-id: svn+ssh://svn.savannah.nongnu.org/linphone/trunk@455 3f6dc0c8-ddfe-455d-9043-3cd528dc4637
parent 714edd3f
mediastreamer-2.2.4:
* fix crash during video window resizing on windows
* improve documentation
* various little improvements
mediastreamer-2.2.3: 21, January 2009
* rfc3984 support improved
* webcam support on windows largely improved (vfw mode)
......
......@@ -129,18 +129,18 @@ static int enc_set_br(MSFilter *f, void*data){
if (br>=1024000){
vsize.width = MS_VIDEO_SIZE_4CIF_W;
vsize.height = MS_VIDEO_SIZE_4CIF_H;
s->tinfo.quality=32;
fps=15;
s->tinfo.quality=15;
fps=30;
}else if (br>=512000){
vsize.width = MS_VIDEO_SIZE_CIF_W;
vsize.height = MS_VIDEO_SIZE_CIF_H;
s->tinfo.quality=32;
s->tinfo.quality=15;
fps=15;
}else if (br>=256000){
vsize.width = MS_VIDEO_SIZE_CIF_W;
vsize.height = MS_VIDEO_SIZE_CIF_H;
s->tinfo.quality=5;
fps=12;
fps=15;
}else if(br>=128000){
vsize.width=MS_VIDEO_SIZE_QCIF_W;
vsize.height=MS_VIDEO_SIZE_QCIF_H;
......
......@@ -137,6 +137,7 @@ static bool_t sdl_display_init(MSDisplay *obj, MSPicture *fbuf){
sdl_initialized=TRUE;
ms_mutex_init(&sdl_mutex,NULL);
}
ms_mutex_lock(&sdl_mutex);
if (obj->data!=NULL){
SDL_FreeYUVOverlay((SDL_Overlay*)obj->data);
}
......@@ -156,8 +157,10 @@ static bool_t sdl_display_init(MSDisplay *obj, MSPicture *fbuf){
obj->data=lay;
sdl_show_window(TRUE);
obj->window_id=sdl_get_native_window_id();
ms_mutex_unlock(&sdl_mutex);
return TRUE;
}
ms_mutex_unlock(&sdl_mutex);
return FALSE;
}
......
......@@ -189,9 +189,8 @@ int main(int argc, char * argv[])
}else if (strcmp(argv[i],"--ec")==0){
ec=TRUE;
}
}
run_media_streams(localport,ip,remoteport,payload,fmtp,jitter,ec,bitrate,vs);
return 0;
}
......
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