Hi!
I got Blender 228 from CVS to build using the MSVC project files.
I still can't get past Blender.getCurrentScene() in most ( all ) of the scripts I test. Noticing in scene.py there is a 'GetCurrent()', I tried it, but still no luck. I started with Blender.py, but noticing the Blender module, placed that in my Python 2.23 site-packages directory and tried it.
Anyone want to point me towards getting started?
Bruce Williams
Just getting started :-)
Moderators: jesterKing, stiv
try this

Code: Select all
# get selected objects
objs = Object.GetSelected()
# get meshes from selected objects
for obj in objs:
if( obj.getType() == "Mesh" ):
print "mesh"
else:
print "not mesh"
-
- Posts: 180
- Joined: Wed Oct 16, 2002 7:27 pm
- Location: Somewhere below the rivers in Holland (but not Limburg)
Re: Just getting started :-)
Hi,midnightcoder wrote:Hi!
I got Blender 228 from CVS to build using the MSVC project files.
I still can't get past Blender.getCurrentScene() in most ( all ) of the scripts I test. Noticing in scene.py there is a 'GetCurrent()', I tried it, but still no luck. I started with Blender.py, but noticing the Blender module, placed that in my Python 2.23 site-packages directory and tried it.
Anyone want to point me towards getting started?
Bruce Williams
have you read the API documentation? You can read the documentation here or download it here.
There's no Blender.getCurrentScene() function. This is probably what you want:
Code: Select all
import Blender
sc = Blender.Scene.GetCurrent()
Michel
You can have one of two things: Progress or Progress Reports.
-
- Posts: 0
- Joined: Wed Sep 03, 2003 5:10 pm