LinkedInTwitterFacebook

Blender 3D – script to show python code under console.

To run this script yo need to select the render to Cycles Render.
Then go to Compositing from Screen layout ( in the top of the screen) and select Use Nodes from Material.
This will make a default material with a Diffuse BSDF .
The next step is to select Scripting from Screen layout.
This will allow you to make a script.
Create a new text and add this source code:

Press keys Alt+P or run the script from Text – Run Script.
When you click on tabs or select something the print function will print the python code into Console output area.
This can be used to see parts of python code from addons or Blender API.
Example with Archimesh addon :
You need to have this addon install and press the books button.
The result of this source code is show into console output and can be used with console shell to add books into your Scene: