diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2011-05-09 14:03:06 +0400 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2011-05-09 14:03:06 +0400 |
commit | 99ee18c684da65ba774175c0b57a086e8222464a (patch) | |
tree | eeb7da044f7e6ff248d76c7d23d0cfa37b482637 /source/blender/imbuf/intern/filter.c | |
parent | 4c71d9efb536b53e8f1f5fd4c950d32bfa29b363 (diff) |
Fix for memory leak caused by re-making mipmaps
Problem was caused by different limits for "last" mipmap: it was 1x1
for mkaing mipmaps and 2x2 for re-making.
2x2 should be enough for mipmap.
Diffstat (limited to 'source/blender/imbuf/intern/filter.c')
-rw-r--r-- | source/blender/imbuf/intern/filter.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/imbuf/intern/filter.c b/source/blender/imbuf/intern/filter.c index 2821ba2a361..16fb1fdf4aa 100644 --- a/source/blender/imbuf/intern/filter.c +++ b/source/blender/imbuf/intern/filter.c @@ -437,7 +437,7 @@ void IMB_makemipmap(ImBuf *ibuf, int use_filter) hbuf= ibuf->mipmap[curmap]; hbuf->miplevel= curmap+1; - if(!hbuf || (hbuf->x == 1 && hbuf->y == 1)) + if(!hbuf || (hbuf->x <= 2 && hbuf->y <= 2)) break; curmap++; |