comparison libswscale/swscale-test.c @ 30415:3f9c8b7320a2

Fix randomness of the swscale-test output. See the thread: Subject: [FFmpeg-devel] [RFC] Make swscale-test perform only one convertion Date: Fri, 29 Jan 2010 01:52:23 +0100
author stefano
date Sat, 30 Jan 2010 13:31:00 +0000
parents 3e858991e23d
children 1bd54aea2896
comparison
equal deleted inserted replaced
30414:e5abaf769020 30415:3f9c8b7320a2
104 104
105 /* Image buffers passed into libswscale can be allocated any way you 105 /* Image buffers passed into libswscale can be allocated any way you
106 * prefer, as long as they're aligned enough for the architecture, and 106 * prefer, as long as they're aligned enough for the architecture, and
107 * they're freed appropriately (such as using av_free for buffers 107 * they're freed appropriately (such as using av_free for buffers
108 * allocated with av_malloc). */ 108 * allocated with av_malloc). */
109 src[i]= av_malloc(srcStride[i]*srcH); 109 src[i]= av_mallocz(srcStride[i]*srcH);
110 dst[i]= av_malloc(dstStride[i]*dstH); 110 dst[i]= av_mallocz(dstStride[i]*dstH);
111 out[i]= av_malloc(refStride[i]*h); 111 out[i]= av_mallocz(refStride[i]*h);
112 if (!src[i] || !dst[i] || !out[i]) { 112 if (!src[i] || !dst[i] || !out[i]) {
113 perror("Malloc"); 113 perror("Malloc");
114 res = -1; 114 res = -1;
115 115
116 goto end; 116 goto end;