Chan file issues

Started by old_blaggard, September 13, 2007, 01:00:41 am

Previous topic - Next topic

old_blaggard

I'm having issues getting a chan file to work in TG2.  I've attached it, and if anyone wants to take a peek and tell me why it won't import correctly, that would be great.  It's really late, so if you need more information, just ask, and I'll respond tomorrow.
http://www.terragen.org - A great Terragen resource with models, contests, galleries, and forums.

bigben

I'll have a play tonight... Are you on a Mac or PC? If PC you could try my conversion utility which allows for tweaking data to be compatible with TG2 http://forums.planetside.co.uk/index.php?topic=1841.0. (Hope to have a Mac version by the end of the year if I can get a Mac for development at work).  What sort of issues are you having?

old_blaggard

I'm on a Mac.  For some reason, even though there are several hundred frames, it only imports 127 of them.  The frames that it imports then have coordinates for the camera that don't correspond at all to the coordinates in the file.
http://www.terragen.org - A great Terragen resource with models, contests, galleries, and forums.

Volker Harun

September 13, 2007, 10:13:20 am #3 Last Edit: September 13, 2007, 10:22:41 am by Volker Harun
Maybe you should upgrade to Burger King?

127 and starting with 0 this makes 128 = 2^7

I'll give it a try in a minute or two.

Edit:
Just a stupid question ... did you change the end frame number in your project settings to ~1381? Or isn't it important?

Volker Harun

I think that the alert window that tells you about only 127 got imported is just a bug.
When setting the project's length to 1381 frames, it plays the preview more than 127 frames. ;-)

old_blaggard

While it does indeed import all 1381 frames, if you compare the camera position and rotation values on frame one to those values within the animation file, there is a pretty huge discrepancy.

Oh, and I dunno... I like Mac's fries better ;).
http://www.terragen.org - A great Terragen resource with models, contests, galleries, and forums.

Volker Harun

September 13, 2007, 10:49:54 am #6 Last Edit: September 13, 2007, 10:52:04 am by Volker Harun
Agree with the fries ...

First thing I noticed is that I cannot import the .chan regulary, it gives me the error that Maya should have 6 or 7 coloumns. Yours has 8.
So I imported it to the camera-position only, that 127 frames alert appeared.

Now you tell me something about rotation ... hmmmm ... that does not fit at all.

old_blaggard

I got my information for creating the chan file from here:
http://forums.planetside.co.uk/index.php?topic=1409.msg14025#msg14025

I can try playing around with getting rid of parameters later, though.
http://www.terragen.org - A great Terragen resource with models, contests, galleries, and forums.

Volker Harun

Kill the first column that gives the frame numbers. That is the error #1.
Doing this I have a nice, turning view into the sky.

Volker Harun

I can only delete these values by hand, as in the german spreadsheets a ',' is used instead of '.' when using floating point numbers. So I cannot import the file correctly :-(

bigben

Quote from: Volker Harun on September 13, 2007, 10:58:36 am
Kill the first column that gives the frame numbers. That is the error #1.
Doing this I have a nice, turning view into the sky.


Yep, frame numbers are the problem. Reading the linked post more carefully the problem may be just your file name. If you rename it from .txt to .chan TG2 will see that there are 8 columns and assume that the first column is the frame number. With .txt, TG2 will only use the first 7 columns and discard the 8th.

Quote from: Matt on April 25, 2007, 11:19:12 am
An excerpt from some comments I added to my .chan reader in TG2:

   Reads 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
   }
   else:
   {
     It is assumed to be a Maya .mov file (which is identical to a Houdini .chan file if numchannels == 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
   }




old_blaggard

Thanks, guys.  I managed to figure it out :).  Now I just have to tweak my conversion script to make sure that everything works.  I'll make it available once I get the rest of the bugs ironed out.
http://www.terragen.org - A great Terragen resource with models, contests, galleries, and forums.