Search DLab 1.0

Showing posts with label Python. Show all posts
Showing posts with label Python. Show all posts

Sunday, August 29, 2010

Python scripting for Blender

Belle has also succeeded in trying out a python script that can align any objects that are placed randomly.This could be helpful in learning the scripting language.

The objects on the screen are randomly placed


But once the script has been executed, it aligns all the objects/ or chosen objects.

import Blender


Here is our script:

import Blender
myObject = Blender.Object.Get(‘Cube’)

selectionList = Blender.Object.GetSelected()

for i in selectionList:

i.LocY = myObject.LocY

Blender.Redraw()

Saturday, August 28, 2010

Blender Python Scripting / movement explorations

Ajarn Moe ka, this is the tutorial that I have been working on for a long time now, its rather useful because it talks about linking the movement of one object to another using a tool called driver. Basically, you can add the driver to an object and the driving force is another object. Here is the video.



Below are a series of python scripting tutorial in Blenders that me and Tony are working on also, and will probably be working on tomorrow as well.