I am new to blender, and am trying to generate some random trajectories on a landscape (from A.N.T plugin) to create a synthetic dataset. Let's move on to the problem.

In 3D view, I can use grease pencil "draw" option with data source being set to the "object" and stroke placement being set the "surface", then draw a path on my already added landscape and the path gets projected on the landscape surface. But I could not figure it out how to do this programmatically, with simulating some random mouse movements with the settings I have mentioned.

I have found samples that make strokes using gpencil like this one: How to add points to a grease pencil stroke (or make new one) with python script? But I could not set the data source and stroke placement so the stroke can be projected on my landscape.

I will appreciate any help with this. Let me know if providing any further sample or information is needed.



You must log in to answer this question.

Browse other questions tagged .