Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange
Join us in building a kind, collaborative learning community via our updated Code of Conduct.

Python is an object-oriented programming language. In Blender, it is used as a general purpose scripting language and to create add-ons to extend Blender's functionality.

0
votes
0answers
12 views

Multiple Modal Timers running continuously without the delay

I am new to blender and i need to visualise linear transformations. I am using this piece of code to create a timer. ...
0
votes
0answers
14 views

Boujou to blender, how to fix camera and dots

Hi Blender wizards out there! I am having a problem with my motion tracked data from boujou to blender. I know how to export from boujou and in to blender, but when the camera appears, first thing I ...
2
votes
0answers
25 views

Is there a way to have an object animated by keyframes (or otherwise) leave a perpetual trail behind it?

I am currently working on an orbital simulation program, and using Blender to render the paths that the various planetary bodies and satellites follow in the simulations. A feature I would like to add ...
0
votes
0answers
9 views

take a picture of a specific object with python

I've created a 2d object and applied a UV map on it. I would like to take a picture of that object using python scripting. I tried using openGL render but that takes a picture of the entire scene. I ...
0
votes
1answer
36 views

Blender scripting GPU acceleration

Is there any possible way to accelerate the python's script execution inside of blender using GPU ?
1
vote
0answers
31 views

Allow cyclic connections in custom node tree

I want to allow a cyclic connection in a custom node tree. Here is an example screenshot of a cyclic connection. From what I uderstand, the following happens: As soon as a link is inserted such that ...
3
votes
2answers
40 views

Align vertices along vector (Python)

I have a vector and vertices, and I'm trying to align the vertices to that vector using 'Translation Matrix', unfortunately multiplying the matrix with the vertices' coordinates do not change anything....
2
votes
1answer
20 views

Make python script to animate vertex points of any object

I am very new to blender and python . i want to make python script which can animate the vertex point of any object (let's example bpy.data.obajects['Cube']) ...
1
vote
0answers
25 views

Blender 2.79 and 2.78c crash on startup with Exception access violation error

I've been trying to install blender 2.79 on my windows 10 machine but it crashes on start up and shows the error bellow : I tried changing the sound properties but it did not work, I updated my ...
2
votes
1answer
26 views

Parsing xml file with animation nodes

I've an XML which includes position and rotation information and which I need to parse it in order to use it with animation nodes. This is something I already managed to do via python scripting but as ...
1
vote
1answer
21 views

How to render animation using different text each time?

I'm beginner in Blender and I don't even know if it is possible: I have an animation which I need to render multiple times with only difference in name of person used. (Like Hello, Mark next ...
1
vote
1answer
21 views

How to use antialiasing with bgl drawn elements?

When using a draw_handler to draw bgl elements to a screen as with GL_POLYGON or GL_LINE_LOOP, are there any bgl flags which can ...
0
votes
0answers
24 views

Draw informations in 3D_view

I'm trying to script a baking in network and it works but now I'd like to print informations for the user (clients whose are connected for example) I tried to print those informations in the 3D_view ...
2
votes
1answer
27 views

Why does an update function loop when string property is reset?

I have a string property, when it is updated it runs a function which runs an operator, the operator clears the string at the end to reset it. This makes the function (string_update) loop to infinite ...
0
votes
0answers
7 views

How can I package a game written in Python using the Blender Game Engine 2.79b?

How can I package a game written in Python using the Blender Game Engine 2.79b? I researched online and have found from the Python Packaging Authority some tutorials but I am not exactly sure how to ...
0
votes
1answer
25 views

Load camera track from an external file (by Python script)

what I need is to import a camera track from an external file and to do this in a Python script. The external track is a sequence of camera poses (location + rotation) in world coordinates. How to do ...
0
votes
0answers
30 views

Blender as Python module; link to the correct pythonXX.dll?

I am the maintainer of a blender as a python module 'bpy' on pip and github. https://github.com/TylerGubala/blenderpy I am able to build blender pretty successfully. I have wheels for multiple ...
0
votes
0answers
18 views

How get image material preview for PyQT item icon (QListWidget)?

Hello me need get a privew material image for PyQT. Thank. ...
2
votes
1answer
37 views

Animated GIFs in Dynamic Previews Enum

Is there any possibility to load animated gifs as a custom icon, which then would be viewed as animated sequence right in the preview? for now, it's just blank and no static preview generated For ...
0
votes
1answer
22 views

Multiple instances of blender (bpy) in single python script

I am trying to parallelize rendering using blender's python API, built as a python module. I'd like to use multiple instances of blender contained within their own classes. Currently, I can generate ...
0
votes
1answer
27 views

How to get Mirrored Vector by Plane on Python

How can I get mirrored vector(point) by Plane by using blender python modules? Plane will be defined as plane_normal : Vector plane_position : Vector I need to know function like ...
1
vote
0answers
13 views

Exporting to .ac file using io_scene_ac3d folder files

I'm trying to modify a Blender file object (aircraft instrument) then export to an .ac file for use in Flightgear. Error script follows below. I've enabled the ac3d folder contents in separate ...
1
vote
0answers
23 views

How to use bgl?

I want to render simple lines on the 3D viewport through a modal operator but not using glBegin/End because those commands are deprecated in opengl 3.3 and will not be avaliable on 2.8 leaving me ...
0
votes
0answers
20 views

How Does AnimationNodes Create This GUI Item?

I'm attaching the image of one GUI element which Animation Nodes can produce in the Nodes window. This does not seem to be from "context.window_manager.invoke_props_dialog()" (sorry, I'm not very good ...
0
votes
0answers
6 views

ui previews dynamic enum error

in the ui_previews_dynamic_enum.py from the templates script i have an error, the error happen when i load the path and remove the path and replace with the same path(the path that i previously ...
0
votes
1answer
22 views

invoke_props_dialog: callback during change?

While creating a custom pop-up (via invoke_props_dialog) with two integer values (in this case representing a start frame and stop frame) I find that the "execute()" method (upon clicking the "ok" ...
2
votes
1answer
19 views

Auto add keyframe at regular intervals?

Is there a way to automate adding keyframes at a regular intervals? I'm mimicking stop-motion movement by keyframing the animation manually adding inbetween keyframes every 4-5 frames setting ...
1
vote
1answer
27 views

Extrude in python

As in title, I'm trying to extrude mesh via python as I have ~1.5k objects to extrude and when I do it in editor it works perfectly but when I run it via python it always go wrong. It just move face ...
0
votes
0answers
10 views

How to get a layout element's x,y location?

Is it possible to get the location of a layout element (layout.prop, column.operator etc...)?
0
votes
1answer
38 views

Get an executable list of executed operators in python

What is it for: I’m writing an addon for blender which will have to store operators that have been executed since a custom button has been pressed, until another button is pressed. What do I need: If ...
1
vote
1answer
24 views

PYTHONPATH extension?

I am trying to write some scripts to test blender. I have developed some helper tasks that I would like to use from a common module. However when I move the task from the working script into a ...
1
vote
1answer
26 views

How to do a ray_cast from camera origin(position) to object in scene in such a way that ray would pas through a given pixel coordinate in camera view?

As question states, I want to "extract" global coordinates of 3D point that generated information in a specific pixel in camera view(rendered image). I have a pixel coordinate in a rendered image ...
0
votes
0answers
14 views

image deformation by UV mapping it on an object

I have an image of a person, and 2 .obj files of that person. The first object file depicts the person, and the second object is a deformation of that person (e.g. the same person but with a different ...
1
vote
1answer
18 views

How do I access the glTF Metallic roughness shader node with Python?

I am currently working on a little script that takes a bunch of obj, imports them into blender with their textures, plugs the textures in the right places of the GLTF Metallic Roughness shader group, ...
0
votes
0answers
19 views

Batch for a folder

I am not a developer. Few notions of Python, but insufficient. Let me explain: Although I have tried a "macro" recorder, it does not do what I want. The case is simple: I have a folder with xxx obj's, ...
1
vote
0answers
37 views

poll failed - context is incorrect

Goal Generate several scene from files (csv, yml with parameters) and thus, initialize the scene before loading a file. Bug In my code, I am creating a plane(object mode) and want to subdivide it (...
1
vote
0answers
40 views

Real time animation of a hand

I want to animate a model of a human hand in Real-Time using bending sensors to measure the movement of the fingers. Currently I have a model of a hand as a mesh and rigged it with bones and parented ...
0
votes
0answers
27 views

Blender and external files not working, giving error in numpy

I keep running into an issue with Blender, and files I create outside of blender that I then import into my blender file as a library. This seems like an issue with numpy, although i'm not 100 percent ...
0
votes
0answers
16 views

Is it possible to update a StringProperty on ui activation?

I'm working on some text editor tools. I need to be able to invoke a modal operator immediately after a StringProperty has been clicked via the ui (a button in the header or panel for example). This ...
1
vote
1answer
32 views

Program UI Slider

I would like to add a slider to my own panel. How can i do that and how can i then read the value from it and assign it to a variable? I already tried this: ...
2
votes
0answers
110 views

How do I create custom sub menus for MCprep Addon?

I'd like to do my own edit of an add-on so it covers everything I need, I need to create a new menu when doing Shift+A and a sub tab when selecting a mode like on the pictures below: You can ...
0
votes
0answers
4 views

Batch Mdd caches to separate files

At the studio we have a project with characters and almost 100 shots, I need to bake each piece to separate mdds (for example, character_1_eyes.mdd, character_1_body.mdd, etc.), this workflow is well ...
1
vote
0answers
33 views

How to change the active node tree data block using python?

I'm using animation nodes add-on. How can I switch between the node tree data blocks using python (as shown in the picture below)?
0
votes
0answers
21 views

Blender 2.8 modifier apply Python

has somebody an idea how to apply a modifier with Python in Blender 2.8 or is it just a bug and not an API / internal change? When I apply like this: ...
0
votes
1answer
16 views

Switching resolution wipes rendered layers?

If you render with the usual F12 render button, then any previously rendered layers get blanked out and re-rendered. If you are manually rendering via the button on nodes in the compositor, you can ...
0
votes
0answers
6 views

Create button and running order of execution

I am writing an add-on and I am new to coding. I want to create multiple buttons and each button execute different scripts in Blender Text. I write another script to "push the buttons" in Blender in ...
1
vote
0answers
24 views

Python: How to toggle an object visibility with a menu?

Hello everyone I was making a menu for my rig in python, so I was wondering how would I make a menu that can toggle visibility of certain objects according to the option I choose: For example, let’s ...
0
votes
1answer
8 views

obj.closest_point_on_mesh ValueError: too many values to unpack

I am trying to check if an imported obj file is colliding with others by trying tu use the closest_point_on_mesh function. Here is the loop: ...
0
votes
1answer
16 views

When “is_library_indirect” property of ID's could be set to True?

Every ID datablock in Blender has an is_library_indirect property ( https://docs.blender.org/api/2.79/bpy.types.ID.html#bpy.types.ID.is_library_indirect) I wanna know after what user actions it could ...
1
vote
1answer
24 views

Finding neighboring mesh faces

I'm quite new to Blender and I'm trying to write my first Blender/Python script. I'm implementing an algorithm that is looking for the lowest (z-value) laying neighboring face for each mesh face. I ...