Old feature request: undo system now restores images without reloading.

Was surprisingly easy to add, compiant with file reading and undo code.

Currently only the Image->ibuf gets restored, and its opengl binding, so
for realtime texture it works nicely. Also texture images are not freed
inbetween undo steps

Notes:
- Painting textures will just keep the painted image, there's no undo
  yet for that
- If this works satisfying, I'll extend it to compositing previews

TEST IT WELL PLEASE! :)
This commit is contained in:
2006-11-10 10:17:04 +00:00
parent a54bd4993f
commit 9a14548104
4 changed files with 69 additions and 7 deletions

View File

@@ -474,7 +474,7 @@ void free_realtime_image(Image *ima)
glDeleteTextures(ima->totbind, (GLuint *)ima->repbind);
MEM_freeN(ima->repbind);
ima->repbind= 0;
ima->repbind= NULL;
}
}