Animation curve editor?

Started by joiecito, July 01, 2009, 01:43:02 PM

Previous topic - Next topic

joiecito

OK I've found a mel wich is able to export .chan files and terragen2 is able to import them right away. The mel also imports .chan files, but I don't know how to export them from terragen2..., Is terragen1 able to export .chan files?, if yes, I can't find it.

Please enlight me ;)

Matt

Quote from: joiecito on July 02, 2009, 07:10:22 AM
Tested, Terragen can't load .mov files the same way as .chan files..., Another option?.

Can you send me the .mov file that you tested with? I'd like to find out why Terragen can't load it.

The "Import chan file" button on the camera node should be able to read a Maya .mov file, Houdini chan file or Nuke chan file.

If file has extension ".chan" then:


  • It is assumed to be a Houdini chan file (7 channels) or Nuke chan file (8 channels)
  • Lines with 7 columns are assumed to be from a Houdini chan file without a frame number
  • Lines with 8 columns are assumed to be from a Nuke chan file with the first value being the frame number
  • The last column (7th or 8th) is interpreted as vertical FOV
  • The last 7 columns are interpreted as camera coordinates in Houdini coordinate space(*)

If the file does not have the extension ".chan" then:


  • It is assumed to be a Maya .mov file (which is identical to a Houdini .chan file if number of columns is 7)
  • The 7th column is interpreted as vertical FOV if it exists
  • The 8th column is not used
  • The last 7 columns are interpreted as camera coordinates in Houdini coordinate space(*)

(*) Here's what I mean by "Houdini coordinate space". The 7 fields following the frame number are:

X (as TG2)
Y (up, as TG2)
Z (out of screen, negative to TG2)
Rotate X (pitch upwards, as TG2)
Rotate Y (anti-clockwise** heading, negative to TG2)
Rotate Z (bank left, negative to TG2)
Vertical Field of View

(**) I only call it anti-clockwise as viewed as a heading on a map, but it's actually clockwise as viewed along the Y axis in its positive direction.

Matt
Just because milk is white doesn't mean that clouds are made of milk.

Matt

It's not currently possible to export animation files, only import, sorry.

Matt
Just because milk is white doesn't mean that clouds are made of milk.

joiecito

Well, if I export the .mov file directly from MAYA, terragen doesn't understand it, but if I export it with the mel, it does it perfect.

So I can't export animation (publicity says it can by the way), but can I export a mesh from the terrain or something I can use for reference (an .obj or something)?.

Thank's in advance.

Matt

Quote from: joiecito on July 03, 2009, 05:03:05 AM
Well, if I export the .mov file directly from MAYA, terragen doesn't understand it, but if I export it with the mel, it does it perfect.

Any chance you can send me the .mov and the .chan please? I would like to test the .mov and compare with the .chan. My email address is matt at planetside.co.uk

Quote
So I can't export animation (publicity says it can by the way), but can I export a mesh from the terrain or something I can use for reference (an .obj or something)?.
Thank's in advance.

If there are any false claims on our website I apologise. I hope there aren't! I'll correct any mistake if you show me where.

You can export the terrain in a couple of different ways, depending on your needs. Both export Lightwave objects (.lwo) but you should be able to import those into Maya.

1) If your terrain is just a single heightfield, then you can export that by creating a "Heightfield Export LWO" operator. This will create a pretty large/dense mesh, but it's broken up into multiple pieces.

2) Alternatively - and this works for any procedural terrain, not just a single heightfield - you can use the LWO Micro Exporter. It will export a view-dependent mesh of the terrain and you can control the resolution. It works by rendering an image and exporting all of the micro-triangles that are generated during the render, within the view of the camera. Put the camera wherever you want to control what part of the terrain is exported. There are some limits to how detailed the export render can be. It's best to try with very low detail first (e.g. 0.1). More information here:

http://forums.planetside.co.uk/index.php?topic=6346.0
http://forums.planetside.co.uk/index.php?topic=1910.msg18752#msg18752

Matt
Just because milk is white doesn't mean that clouds are made of milk.

joiecito

OK, now I'm able to export a lws with my terrain. My terrain is procedural, so I made what you said and connected the terrain to a heightfield generator wich is connected to a lwo exporter. But I can't find the way to control what section I want to extract because I don't know wich part of my terrain is generating the heightfield generator..., Could you point me or made an idiot-proof tutorial on this?.

Thank's in advance.

P.D.: Sorry but the last .mov was deleted and now is working as espected, so I can't recreate that .mov situation anymore.

joiecito

Another question:

If I'm not be able to export any animatoin data from Terragen, then I guess I can just copy the translation and rotation values of the came in the first and last frame and continue animating in MAYA (since I can import that animation in Terragen).

But the camera doesn't match the one on terragen. So I guess MAYA doesn't share the same 3d axis as Terragen. Wich are the differences between Terragen and MAYA space coordinates so I can match them?.

Thank's in advance.

Hetzen

I've got say that I've not managed to work out how to get camera data into TG with a 100% success rate, hence my earlier comment. I've had some camera track from cloud height over a scene, which seemed to have not got the camera rotation correctly. I've not really had much time to investigate why. So any tips I pick up on in this thread will be usefull, like for example the curvature of the planet over altitude. Thanks Matt.

Matt

#23
Here's how to copy camera coordinates from TG2 to Maya:

First, in Maya set the camera's Rotate Order = zxy. The final rotation will be wrong if you don't do this. The default rotation of xyz is OK only if your z rotation (bank) is 0. In all other cases you need to use zxy.

Translate: copy the Position XYZ values from Terragen, but negate the Z (3rd) coordinate
Rotate: copy the Rotation XYZ values from Terragen, but negate the Y (2nd) and Z (3rd) values

Angle of View: copy the Field of view from Terragen, but in some cases you may need to set Terragen to use vertical instead of horizontal to be able to match it.

Matt
Just because milk is white doesn't mean that clouds are made of milk.

Matt

#24
If you're using Shader -> Heightfield Generate -> Heightfield LWO Export, look on the "Use shader" tab of the Heightfield Generate node. It allows you to set the position of the heightfield in space as it reads the shader, in X and Z coordinates. You can specify either the centre or the lower left corner of the heightfield. The size of the heightfield is the pair of values near the top labeled "Size in metres".

The other set of values to the right of the "New heightfield" checkbox specify the resolution of the heightfield. Use this to change the detail of your exported geometry.

(If you were to apply this heightfield back onto the planet for rendering, you would enter the same position settings in the Heightfield Shader to make it line up with the shader that generated it.)

Matt
Just because milk is white doesn't mean that clouds are made of milk.

Matt

There may potentially be line-up issues if you're using the Shader -> Heightfield Generate -> Heightfield LWO Export trick, if the heightfield is very large or far from the origin. That's because the Heightfield LWO Export doesn't know about the planet curvature. In that case use the Micro Exporter method, as it is the most geometrically accurate.

Matt
Just because milk is white doesn't mean that clouds are made of milk.

joiecito

I can attach two file I've exported from MAYA, a .mov and a .chan.

The .mov is exported directly from MAYA and TG2 doesn't open it right, it imports 375 frames, but all are the same.

The .chan is exported with a mel and TG2 imports it right.

Do you want to test them out?

Matt

Yes, please attach them here, or email them to me.

Matt
Just because milk is white doesn't mean that clouds are made of milk.

joiecito

Here are the files, if you can find where the problem was, please tell me :)

joiecito

Any news on this?, Did you find the problem?.