Blender Git Commit Log

Git Commits -> Revision d73e312

Revision d73e312 by Campbell Barton (master)
December 13, 2005, 00:00 (GMT)

Added Image.GetCurrent()
Previously the only way to get the current image was flaky and relyd on the image being assigned to a mesh.

try:
me = Scene.GetCurrent().getAttiveObject().getData(mesh=1)
image = me.faces[me.activeFace].image
except:
image = None

...Can new be replaced by the following, and works even when there is no mesh.
image = Image.GetCurrent()

epydocs:
Get the currently displayed Image from Blenders UV/Image window.
When multiple images are displayed, the last active UV/Image windows image is used.

Commit Details:

Full Hash: d73e312f885b4deb89835582827887ceae111165
SVN Revision: 6092
Parent Commit: b72dc45
Lines Changed: +35, -9

2 Modified Paths:

/source/blender/python/api2_2x/doc/Image.py (+7, -0) (Diff)
/source/blender/python/api2_2x/Image.c (+28, -9) (Diff)
By: Miika HämäläinenLast update: Nov-07-2014 14:18MiikaHweb | 2003-2021