Page 1 of 1

Moho Camera Importer

Posted: Wed Aug 16, 2006 3:52 am
by 7feet
I was just reminded of this companion to my MohoCam camera exporter script that I completely spaced on posting.

It works the same as th MohoCam script, but in reverse. So you would also be able import cameras from various different 3D apps into Moho. One thing to keep in mind is that, since you can't save keyframe interpolation types, the exporter saves exact camera positions for every frame. So when you import, you'll get keyframes on all the camera channels at all frames for the length of the camera move. It's a lot of keyframes, but the only way to really get the exact camera move.

So, ImportCam v1.0

Sorry 'bout the delay.

Thanks a lot 7feet.

Posted: Wed Aug 16, 2006 8:37 am
by Aldrik
Too cool! I don't think the extra keys are a issue at all, but I'm sure it wouldn't be to hard to make the script remove the redundant ones (may give it a try if I get time/bord).

Just to let everyone know there is a Maya CC exporter (& probably importer too) for blender being make over at the blender artists forums.

PS. Hi all, just found out about Moho the other day & it looks like a very powerful/fun program (will be picking at your brains very soon)! I'm off to play now, thanks again 7feet! :D

MohoCam update...

Posted: Wed Aug 16, 2006 8:39 pm
by Aldrik
I've updated both your import and export scripts 7feet.

ExportCam 1.4 changes
1) Fixed a typo that exported the cameras Y position to Z
2) Fixed it so the first frame now gets exported (frame 0)

ImportCam 1.1 changes
1) Removes repeated/redundant frames
2) Now supports files with a negative frame numbers
3) Imports frames at current timeline position

It is possible to work out the interpolation and remove more frames, I may add linear but I'm to lazzy to do the others. :evil:

Image
(Dont have any space of my own at the mo, a mirror would be good :wink:)

PS. 7feet, the Importer code I added is a bit messy (soz), never used lua before & don't have time to check docs.

Posted: Thu Aug 17, 2006 5:47 am
by 7feet
Cool, Aldrick. I try not to be too messy myself, or a few months down the line when I want to change something I'll be completely screwed, I'm okay while I'm doing it but it doesn't really "stick". But as long as it works.

Where was the typo? I was looking at the one on my machine and I can't find it, but that doesn't necessarily it ain't in the one I uploaded. Usually when I'm writing something it's in a bit of a frenzy, and I can get a wee bit sloppy on the versioning. I'm terrible like that.

Posted: Thu Aug 17, 2006 6:00 am
by heyvern
7feet wrote:... and I can get a wee bit sloppy on the versioning. I'm terrible like that.
Phew! Not just me then... ;)

On that topic... any descriptions online how exactly to do "versioning" of something like this?

Is it just... a free for all? make it up?

How do you know if something should be...
... v2.0 v1.5 or v1.5b or 1.5.9 or 1.4.6046r0003?

I was always clueless about it...

-vern

Posted: Thu Aug 17, 2006 6:22 am
by 7feet
What I've usually tried to do, say after the dreaded "1.0", is to add a full tick after the decimal if I've added a new feature (or just made it actually work), going to 1.1, 1.2, etc. If it's pretty much a minor tweak or bug fix because I did something bone stupid, it would be more like 1.01. Or I might just want to confuse the hell out of everyone and make the new version equalto PI, or a kabbalistic interpretation of my dogs name, factorial. But usually the first bits suffice.

My problem is that I just forget to note it at all. So as I still have every version of Moho 5 from the 1st beta still installed separately on my machine, sometimes I've found myself fishing around through some of my scripts from different places that have the same version number, but seem to do different things. And that's just, y'know, stupid. You get caught up in the moment, and then the next morning... Jeez.

Posted: Thu Aug 17, 2006 6:44 am
by heyvern
Thanks for the reply... it really made my evening. I laughed out loud (I try to avoid that in the middle of the night... scares the neighbors.)
You get caught up in the moment, and then the next morning... Jeez.
This could apply to... well... life in general actually. ;)

-vern

Posted: Thu Aug 17, 2006 9:42 am
by Aldrik
7feet wrote:Where was the typo?
I'm sure you must have already fixed for your self... :wink:

sf_MohoCamV1.3.lua

Code: Select all

line210			string.format("%.4f",tostring((position.x * self.positionScaling) * 10))..tabs..
line211			string.format("%.4f",tostring((position.y * self.positionScaling) * 10))..tabs..
line212			string.format("%.4f",tostring((position.y * self.positionScaling) * 10))..tabs..

Posted: Tue Nov 07, 2006 12:37 am
by BA
Does anyone know where to find a script that exports camera info from 3DstudioMAX?

Posted: Wed Nov 08, 2006 12:23 am
by Ovjeh
It's here http://www.motionblur.it search for Camera converter.

Posted: Wed Nov 08, 2006 12:28 am
by 7feet
Go to http://www.Motionblur.it and get the Camera Converter scripts. That's the format I based the Moho importer and exporter on, and there's a 3DSMax exporter in there.

Ack, Ovjeh, ya beat me to it...