[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [15939] trunk/blender/source/blender/imbuf /intern/anim.c: == FFMPEG ==
Peter Schlaile
peter at schlaile.de
Sun Aug 3 18:11:58 CEST 2008
Revision: 15939
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=15939
Author: schlaile
Date: 2008-08-03 18:11:57 +0200 (Sun, 03 Aug 2008)
Log Message:
-----------
== FFMPEG ==
This fixes:
[#16655] Blender crashes when Fraps videos are added to the sequencer
(sorry, color conversion is not supported by swscaler for some reason,
so currently, only the crash is fixed)
Modified Paths:
--------------
trunk/blender/source/blender/imbuf/intern/anim.c
Modified: trunk/blender/source/blender/imbuf/intern/anim.c
===================================================================
--- trunk/blender/source/blender/imbuf/intern/anim.c 2008-08-03 16:02:56 UTC (rev 15938)
+++ trunk/blender/source/blender/imbuf/intern/anim.c 2008-08-03 16:11:57 UTC (rev 15939)
@@ -612,6 +612,7 @@
av_free(anim->pFrameRGB);
av_free(anim->pFrameDeinterlaced);
av_free(anim->pFrame);
+ anim->pCodecCtx = NULL;
return -1;
}
@@ -639,7 +640,19 @@
PIX_FMT_BGR32,
SWS_FAST_BILINEAR | SWS_PRINT_INFO,
NULL, NULL, NULL);
-
+
+ if (!anim->img_convert_ctx) {
+ fprintf (stderr,
+ "Can't transform color space??? Bailing out...\n");
+ avcodec_close(anim->pCodecCtx);
+ av_close_input_file(anim->pFormatCtx);
+ av_free(anim->pFrameRGB);
+ av_free(anim->pFrameDeinterlaced);
+ av_free(anim->pFrame);
+ anim->pCodecCtx = NULL;
+ return -1;
+ }
+
return (0);
}
More information about the Bf-blender-cvs
mailing list