28th February 2005, 04:12 AM | #1 |
Junior Member
Junior member
Join Date: Feb 2005
Posts: 4
|
Manipulating a random matrix in AC3D
I'm updating my ShortHike space settlement exporter to AC3D 5. One of the requirements of the simulation is the ability to place and export game data relating to "ports" on the modules. I would need a way to manipulate a position and orientation for these "ports". In other applications I use standard animation bones for the purpose.
What's the best strategy for creating these "ports"? Do named objects have a local transformation matrix I could use for this? Can I get it with scaling factors set to 1? One strategy I have in mind was a "Add port" command that would add a specific port object with data stored to mark it as a port. Then at export time I could just grab those matrices and export them as bones that can be used later in the process. Am I on the right track here? Oh, and where can I find the SDK for 5.0? |
28th February 2005, 06:14 AM | #2 |
Administrator
Professional user
Join Date: Jun 2003
Posts: 4,565
|
Everything internally is stored in global/world coordinates. Your port objects will have to have at least one vertex for them to hang around and be manipulated in AC3D. You will be able to set the string data with your info and define the position (loc in Tools->object-property-editor).
I'll email you the latest headers... Andy |
28th February 2005, 12:45 PM | #3 |
Junior Member
Junior member
Join Date: Feb 2005
Posts: 4
|
I can see how to get the position if I have a single point. But how do I get the orientation? I need four points in space to do this reliably. If I create these "handle" objects, is the point order stable. Ie. if I create them in the sequence A, B, C, D can I be assured (user tampering excluded) that they are in that order after saving and reloading?
|
28th February 2005, 02:57 PM | #4 |
Administrator
Professional user
Join Date: Jun 2003
Posts: 4,565
|
Well the order of the vertices in an object may change but the vertex order in a surface won't.
Andy |
1st March 2005, 05:19 AM | #5 |
Junior Member
Junior member
Join Date: Feb 2005
Posts: 4
|
But the surface vertices need to be planar don't they? Maybe use two surfaces .. Hmm.. I used to do this with only 3 points but then I had problems with right and left handed coordinate system ..
Can you think of any other ways of extracting orientation information from the editor? |
1st March 2005, 10:42 AM | #6 |
Administrator
Professional user
Join Date: Jun 2003
Posts: 4,565
|
I think your best bet would be to add a text comment in the object data.
Andy |
28th May 2005, 01:29 PM | #7 |
Junior Member
Junior member
Join Date: Feb 2005
Posts: 4
|
I just wanted to resurface this as I never managed to solve it. The real issue I'm having is for the AC3D user to be able to manipulate an object with just a position and an orientation (Quaternion or Matrix). In other modeling tools these are called NULL objects and they are abundant in games and simulations to mark mount points and similar for the engine.
NULL objects need AC3D support for manipulating the position and orientation. Usually they are displayed in the scene with three lines colored the same as the XYZ axis. In renderings they are invisible. Andy, I was looking at your light manipulation and you could grab that code, add rotation and have a decent null object. The object data field can be used for all the details. This is a showstopper feature for me. AC3D is perfect for our current needs, and I've been sending practically all my modders here for almost three years. However, I've spent tens of hours and modders hundreds to work around this limitation. It's just a bit too much effort. But I can't do this with the SDK. This requires internal AC3D support. All my hope rests with you Andy.. |
|
|