[Bf-codereview] MovieCache implementation (issue 5283049)

brechtvanlommel at gmail.com brechtvanlommel at gmail.com
Sat Oct 15 19:55:32 CEST 2011


There's something wrong with the new files, they don't diff correctly
and inline comments don't work there, maybe because this was uploaded
from a git checkout? Anyway, here are some comments:


BKE_moviecache.h:

I'd put this code in the imbuf/ module as IMB_moviecache.h. It doesn't
really depend on anything in blenkernel.
There are also functions IMB_cache_limiter_* in imbuf but they seem to
be unused, might be good to remove that system now.

Typo: stroting => storing


moviecache.c:

if(ibuf->rect_float)
     channel_size= sizeof(float);

This should also be += ?

} else if(cache) {

This if(cache) isn't needed.

MEM_freeN(frames);

This should be moved outside the if(), it will leak with totseg 0.



http://codereview.appspot.com/5283049/diff/1/source/blender/blenkernel/intern/seqcache.c
File source/blender/blenkernel/intern/seqcache.c (right):

http://codereview.appspot.com/5283049/diff/1/source/blender/blenkernel/intern/seqcache.c#newcode51
source/blender/blenkernel/intern/seqcache.c:51: struct MovieCache
*moviecache = NULL;
Suggest to make this static, better not have this in global namespace.

http://codereview.appspot.com/5283049/


More information about the Bf-codereview mailing list