Bake an animation.
Instead of having this "live" via drivers, a handler, etc, etc, can bake the animation of another object to match the path of chosen particle.
Could say this is somewhat similar to the particle systems baked cache in that If the particle system is changed, will need to run script again.
Get particle location using python
This script assigns first particle location to another object(In this case Empty). you can parent camera to this object for further manipulation.
ob = bpy.context.scene.objects["Cube"]
target = bpy.context.scene.objects["Empty"]
def my_handler(scene, depsgraph):
eval_ob = ob.evaluated_get(depsgraph)
particle_system = ...
Hello fellow Linux user!
For taking advantage of your Nvidia RTX card, it is recommended to install the non-free Nvidia driver. I also have an RTX (a smaller one, the 2060) and it works fine with Blender 2.8x, renders in minutes and never crashes.
I answered my self when I posted this question :D
The scripted expression is working in radians by default and is auto converted to degrees in the spotlight object. So what I did was: var - 5 and got my range just in the sweetspot.
Now it goes approximately from 1 to 172 deg.
I'm not sure for the precise math behind it, but it is working for me. If you need ...
Noise module is in the driver namespace
For our convenience the mathutils.noise module is added to the driver namespace by default. As have all members of mathutils and most of math module.
There are a number of options for randoms, for a simple range (-1.0, 1.0) can type #2 * ...
It's a bit hacky but you can use the python hash method to generate a "random" number, for example using the name of each object since they must be different from each other.
The caveat is it isn't by default in the driver namespace, but you can very easily add it in. You can choose to permanently add it to the driver namespace for all sessions or ...