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.
This commit is contained in:
@@ -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++;
|
||||
|
Reference in New Issue
Block a user