Hello. Weirdness in image.update, maybe it’s the way I’m doing things.
I have an image, used by a texture slot of the material of an object displayed in the view 3d screen.
I take the pixels (cache = image.pixels[:]), do some filtering, then i put the pixels back (image.pixels[:] = cache) and:
- update the image with image.update().
This updates the image in the image editor area but not in the texture slot
- call image.update() followed by image.gl_load()
This updates the image in the image editor and in the texture slot but not in the view 3d
- do a very fishy thing:
image.gl_free()
image.pixels[:] = cache
image.update()
for i in range(0, 100): image.gl_load()
This updates everything, even when gl_load() fails 100 times in a row.
So the question is: should I call an exorcist for my PC, am I doing something wrong, is there some other way to update an image after the pixel buffer has been changed?
Thanks.