Working on some tools for Blender and Pipmak
Status: Alpha
Brought to you by:
cwalther
From: rivenwanderer <riv...@ya...> - 2008-11-04 06:56:03
|
I'm working on making some tools for getting Pipmak environments together as quickly and easily as possible. The first is a Blender Python script made from the Panorama Maker tool at http://www.alienhelpdesk.com/python_scripts/old_scripts . The tool renders panoramas for all selected cameras in a Blender scene, placing them into node subfolders where the names are taken from the names of the camera objects in Blender. The standalone auto-handle-placer doodad (needs a better name ;) ) is being written in Python for now. It first takes a list of the names of the cameras and the points where the cameras were. Here's an example, where the two cameras are named "1" and "2". 1:0.0,0.999999940395,4.0 2:0.0,0.999999940395,-10.0 This can be automatically exported from Blender with a simple script (which I'm including in the batch pano tool for now), and hopefully from most other 3D programs also. The coordinates should be like that in the diagram in Fig. 2 (page 11) of the Pipmak reference. Then it takes a file specifying which cameras are connected to which other cameras, with the assumption that it's bidirectional. For example, camera 1 connected to cameras 2, 3, and 4 would be represented as "1:2,3,4". Then, for each camera, it computes the elevation and azimuth to all the connected cameras and adds appropriate handles to the node.lua file in the subdirectory with the same name as the camera (creating the node file if it doesn't exist yet). The tool won't check for overlapping handles or anything, and not all handles will be exactly what one would want for a game, but they can be adjusted later. The two tools together should mean that I can take a modeled environment in Blender and (1) place cameras in arbitrary locations where I want nodes to be rendered from, (2) hit a button and wait for all panos to render, (3) spend a couple minutes writing down which nodes connect to which, and (4) run a script from the commandline, then be able to fully navigate the project in Pipmak. This streamlined process for the "normal" nodes (as opposed to typing out the handles in every node.lua or editing hotspots with a graphics program) should leave me with more time for working on the more complex programming parts of my games. I've got the Blender tool in a working (though still rough around the edges) state, and am hoping to get the standalone tool working in the next few days. I'll be sure to post the python code (on the wiki? or would somewhere else be preferred?) once they're in a state that's usable for people besides just me. I'm not at a point where I could write this stuff in Lua yet, but hopefully the code will be readable enough for someone (me or someone else) to port it for inclusion in the Pipmak editor someday :) -- View this message in context: http://www.nabble.com/Working-on-some-tools-for-Blender-and-Pipmak-tp20317074p20317074.html Sent from the pipmak-users mailing list archive at Nabble.com. |