0
$\begingroup$

For my game, i need to render all chars from a mono type font, where all symbols are the same width and height. So, i think to type them in a long string against X axis, and move a camera over each symbol to get rendered frames. Later i will compile these frames with metadata to larger map. Well, can i execute a script, which will modify a scene by the render trigger or something ?

Thanks !

$\endgroup$
  • $\begingroup$ How about using keyframes? $\endgroup$ – Leander Jan 2 at 0:38
  • $\begingroup$ Seems the only way :) Just generated about thousand by the script $\endgroup$ – Oleg Skripnyak Jan 2 at 1:47
0
$\begingroup$

Implemented it by a script, which generates keyframes for a camera, thousand of them. Here is the blender file https://yadi.sk/d/6AXRNZDxEwAtDw

And here is the code, note these magic numbers - i was finding them for few hours, and still not sure if they are right, but close

import bpy
from mathutils import Vector

# useful shortcut
scene = bpy.context.scene

# this shows you all objects in scene
scene.objects.keys()
cam = bpy.data.objects["Camera"];
cam.location.x = 0
for frame in range(1073):
    scene.frame_set(frame)
    cam.location.x = frame * 0.35285 - 0.209;
    cam.keyframe_insert(data_path="location", index=-1)


| improve this answer | |
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.