Ticket #53325: patch-0001-avwrapper-avframealloc-fix.diff
File patch-0001-avwrapper-avframealloc-fix.diff, 1.0 KB (added by kencu (Ken), 8 years ago) |
---|
-
./hedgewars/avwrapper/avwrapper.c
old new 158 158 else 159 159 g_NumSamples = g_pAudio->frame_size; 160 160 g_pSamples = (int16_t*)av_malloc(g_NumSamples*g_Channels*sizeof(int16_t)); 161 g_pAFrame = av codec_alloc_frame();161 g_pAFrame = av_frame_alloc(); 162 162 if (!g_pAFrame) 163 163 { 164 164 Log("Could not allocate frame\n"); … … 241 241 g_pVideo->time_base.den = g_Framerate.num; 242 242 g_pVideo->time_base.num = g_Framerate.den; 243 243 //g_pVideo->gop_size = 12; /* emit one intra frame every twelve frames at most */ 244 g_pVideo->pix_fmt = PIX_FMT_YUV420P;244 g_pVideo->pix_fmt = AV_PIX_FMT_YUV420P; 245 245 246 246 // set quality 247 247 if (g_VQuality > 100) … … 299 299 #endif 300 300 return FatalError("Could not open video codec %s", g_pVCodec->long_name); 301 301 302 g_pVFrame = av codec_alloc_frame();302 g_pVFrame = av_frame_alloc(); 303 303 if (!g_pVFrame) 304 304 return FatalError("Could not allocate frame"); 305 305