Anim8or Community

Please login or register.

Login with username, password and session length
Advanced search  

News:

Ian Ross has just released a book on Anim8or. It's perect for a beginner and a good reference for experienced users. It contains detailed chapters on every aspect, with many examples. Get your own copy here: "Anim8or Tutorial Book"

Pages: 1 [2] 3

Author Topic: A Matter of Proportion?  (Read 24055 times)

selden

  • Full Member
  • ***
  • Posts: 222
    • View Profile
    • Modelling for Celestia
Re: A Matter of Proportion?
« Reply #15 on: October 20, 2015, 06:51:44 pm »

Here's a Celestia SSC catalog which defines three hammerheads using the same model. (If you want them to have different livery, you'll need to create separate models referencing different surface texture images.) The orbital parameters of HH_001 are identical to the ones used for the ISS in Celestia, with a slightly different MeanAnomaly so they're chasing it. The positions of HH_002 and HH_003 are defined relative to HH_001.
Code: [Select]
# three hammerheads chasing the ISS

"HH_001:hammerhead" "Sol/Earth"
{
Class "spacecraft"
Mesh "hammerhead-lwobin.cmod"
Radius 0.00625                  # length: 11.5 m, wingspan 12.5m

    EllipticalOrbit {
        Period          0.064176392
        SemiMajorAxis   6767
        Eccentricity    0.0016886
        Inclination      51.5684
        AscendingNode   343.1518
        ArgOfPericenter 346.2476
#        MeanAnomaly      13.8216
        MeanAnomaly      13.821
        Epoch           2452028.18381755
    }

    BodyFrame {BodyFixed { Center "Sol/Earth/ISS"}}
    FixedRotation {
      MeridianAngle 90
  Inclination -90
  }
   
    Albedo       0.10
}

# place other spacecraft at fixed positions relative to first

"HH_002" "Sol/Earth/HH_001"
{
Class "spacecraft"
Mesh "hammerhead-lwobin.cmod"
Radius 0.00625                  # length: 11.5 m, wingspan 12.5m

# location
    OrbitFrame { BodyFixed { Center "Sol/Earth/HH_001" }}
    FixedPosition [ -0.015 -0.015 0 ]

# rotation
    BodyFrame { BodyFixed { Center "Sol/Earth/HH_001" }}
    FixedRotation {}


Albedo       0.10
}


"HH_003" "Sol/Earth/HH_001"
{
Class "spacecraft"
Mesh "hammerhead-lwobin.cmod"
Radius 0.00625                  # length: 11.5 m, wingspan 12.5m

# location
    OrbitFrame { BodyFixed { Center "Sol/Earth/HH_001" }}
    FixedPosition [ 0.015 -0.015 0 ]

# rotation
    BodyFrame { BodyFixed { Center "Sol/Earth/HH_001" }}
    FixedRotation {}


Albedo       0.10
}

Unfortunately, there's no CMOD importer for Anim8or. You'll have to learn how to use the CMOD exporter. I tried to make the instructions on the modeling page as explicit as I could. Just follow them "to the letter". Briefly: specify the location of your Anim8or script(s), select the cmod exporter in Anim8or's export menu, concatenate the file's two pieces, place it in Celestia's "models" subdirectory.

Alternatively, you could try cutting the Hammerhead model into several pieces (in Anim8or) so each component mesh is smaller than the 3DS 64K limit. Then you could export them as a single model from Anim8or in the 3DS format. The pilot model looks relatively complex, so maybe making the cockpit separate (as it was in the TV show) would be sufficient.

Below is a screengrab showing the Hammerheads chasing the ISS. Note how dark they are. This is because the model's materials definitions all explicitly specify a base color of 50% grey. To change this, you'd have to modify them all. It might be easier to edit the OBJ .mtl file appropriately (it's just a text file), so I'll zip the obj model and include it below. You'll also have to change the locations of the texture files that're specified in the .mtl file, since you won't have them in the same directory that I have them in.
Logged
Selden

selden

  • Full Member
  • ***
  • Posts: 222
    • View Profile
    • Modelling for Celestia
Re: A Matter of Proportion?
« Reply #16 on: October 20, 2015, 08:04:37 pm »

Yup, I was right. Cutting the hammerhead model (roughly) in half allows Anim8or to export it in 3DS format. The forward part of the fuselage is a relatively simple tube, so it was easy to break it in two.

Unfortunately, 3DS models use a different coordinate system when imported to Celestia, resulting in different positions and orientations. *shrug*

Below are a screengrab and  hammerhead-pieces.zip, which contains the sliced .AN8 model, the exported 3DS model and a revised SSC. (No textures are included.)


 
Logged
Selden

argo34116

  • Jr. Member
  • **
  • Posts: 83
    • View Profile
Re: A Matter of Proportion?
« Reply #17 on: October 21, 2015, 01:07:51 am »

Isn't there a way to have a model in anim8or and copy and paste to create a group of three then export it and add it to celestia? I have done this before with a battlestar galactica colonial viper with success. Where can I get instructions on how to add the cability to export to cmod with anim8or? I have a program to convert 3ds to cmod. It seems that it would be less complicated to copy and paste in anim8or to create a group then use that model in celestia versus all the extra steps to modify the ssc file.
Logged

argo34116

  • Jr. Member
  • **
  • Posts: 83
    • View Profile
Re: A Matter of Proportion?
« Reply #18 on: October 21, 2015, 07:32:38 am »

The fact is that adding the ability to export in anim8or as cmod seems above my understanding and capabilities. I am very much a newbie when it comes to the world of 3d modeling and I do not feel comfortable with it.

If someone could provide me with a model of three ships in formation in a cmod format (Copy and paste to create the two others in anim8or,then export as a cmod for use in celestia) That would be great. I can then create a ssc file of my own and place them as I want in celestia.

Thank you for your patience and assistance from a novice 3d modeler still learning.
Logged

selden

  • Full Member
  • ***
  • Posts: 222
    • View Profile
    • Modelling for Celestia
Re: A Matter of Proportion?
« Reply #19 on: October 21, 2015, 08:16:09 am »

The only way you're going to get comfortable with modeling is to do it. Don't be afraid to try things. You won't break anything. "Undo" is your friend. (Ctrl-Z).

The commands to copy-and-paste models and their components in Anim8or are the same as for text editors in Windows:
Ctrl-A = select all
Ctrl-C = copy to clipboard
Ctrl-V = paste to window
Then you can drag them wherever you want.

 The CMOD export script and the instructions for installing and using it are at the URL I posted previously:
http://www.classe.cornell.edu/~seb/celestia/modelling.html#4.1

Unfortunately, the combined model of the formation of three spacecraft is too large for me to upload.

The advantages of describing spacecraft in an SSC catalog instead of making a model containing several of them are
a) the resulting "Addon" is that much smaller, making it easier to share with others (e.g. I couldn't upload it to this forum)
b) when using the smaller model, Celestia is smaller and runs faster, and
c) when you use SSC catalogs, you can specify as many as you want in whatever formations you want, and make them do different things, e.g. fly in formation for a while, then separate on different missions
Logged
Selden

argo34116

  • Jr. Member
  • **
  • Posts: 83
    • View Profile
Re: A Matter of Proportion?
« Reply #20 on: October 21, 2015, 04:22:34 pm »

ok. I followed your link. I assume that is the script that is required to get anim8or to export .cmod. I understand that I have to click on file, then select configure. What is the deal though with the page that the link led me to? Do I have to copy and paste using a editor like Notepad ++ ? Then what do I save it as? What file extension do I use? How do I set it up so that I can click file then configure in anim8or? or is there something different I need to do? I wish that anim8or had this built in so there is no need to do this in such a roundabout way. Perhaps this can be done in a later release of anim8or? So models can be exported as .cmod? It seems like .cmod is used frequently and this should be built into it. Maybe someone can come up with a way to provide a installer that would add this to anim8or?
Logged

Claude

  • Sr. Member
  • ****
  • Posts: 285
    • View Profile
Re: A Matter of Proportion?
« Reply #21 on: October 21, 2015, 09:18:03 pm »

selden

I was wondering why you were not going
twice through all the shapes.
The first time to extract all the materials.
The second  time to extract all the meshes.

Maybe I'm missing something.

Claude
Logged

selden

  • Full Member
  • ***
  • Posts: 222
    • View Profile
    • Modelling for Celestia
Re: A Matter of Proportion?
« Reply #22 on: October 21, 2015, 10:47:16 pm »

Claude,

I didn't do that *because* it would have required two passes, and wasn't obvious to me how to reinitialize the shape pointers to get back to the start. Concatenating the files is relatively easy, so I've never bothered to figure that out.
Logged
Selden

argo34116

  • Jr. Member
  • **
  • Posts: 83
    • View Profile
Re: A Matter of Proportion?
« Reply #23 on: October 22, 2015, 01:40:03 am »

Here is a group of three hammerheads that I created in anim8or. Just need to figure out how to convert to .cmod I have included it here as HHS
Logged

selden

  • Full Member
  • ***
  • Posts: 222
    • View Profile
    • Modelling for Celestia
Re: A Matter of Proportion?
« Reply #24 on: October 22, 2015, 03:25:43 pm »

None of them have any surface textures associated with them. Is that the way you want them to be?
Logged
Selden

argo34116

  • Jr. Member
  • **
  • Posts: 83
    • View Profile
Re: A Matter of Proportion?
« Reply #25 on: October 23, 2015, 01:51:31 am »

Use surface textures from other posts, but here it is again. Thank you for your help
Logged

selden

  • Full Member
  • ***
  • Posts: 222
    • View Profile
    • Modelling for Celestia
Re: A Matter of Proportion?
« Reply #26 on: October 23, 2015, 06:25:16 am »

herewith.
Logged
Selden

argo34116

  • Jr. Member
  • **
  • Posts: 83
    • View Profile
Re: A Matter of Proportion?
« Reply #27 on: October 25, 2015, 01:55:36 am »

Thank you soooooo much Selden. They look great. I have another question though. I have a add on for Celestia that displays the battlestar galactica viper mkII. I copied the ssc file "hammerheads chasing the ISS" and modified it to make a group of three Viper MkII and placed them in orbit around Rigel with the craft from the Galactica TOS add on. It worked great, but the models exhibit a jumpy motion when displayed. What is causing this? Can it be fixed. Otherwise they look great. I have included the file below with both the original and the revised ssc.
Logged

selden

  • Full Member
  • ***
  • Posts: 222
    • View Profile
    • Modelling for Celestia
Re: A Matter of Proportion?
« Reply #28 on: October 25, 2015, 11:56:53 am »

It's because you've got them on an orbit which is very tiny, orbiting rapidly, and inside the star.  An orbit which is appropriate for going around the Earth doesn't work well for going around a star. If you specify a larger orbit, one which places the spacecraft outside the star, they won't jump around.  e.g.

    EllipticalOrbit {
    Period 1
    SemiMajorAxis 1
    }

This is just an example to make it display well. A period of 1 (year) at a distance of 1 (AU) is only correct for orbits around our own Sun.  Rigel is a much more massive star, so orbits around it have much shorter orbital periods for orbits with a given semimajor axis.  If you want it to be more realistic, you'll need to do some research and a little algebra to define an orbit which has more appropriate parameters for this star (at a larger SMA so the pilots don't cook, for example :) ) and with the correct period for that SMA.

However, this isn't a topic directly related to Anim8or, so it might be more appropriate to discuss it in a PM (Private Message).
« Last Edit: October 25, 2015, 12:01:34 pm by selden »
Logged
Selden

argo34116

  • Jr. Member
  • **
  • Posts: 83
    • View Profile
Re: A Matter of Proportion?
« Reply #29 on: October 26, 2015, 05:28:05 am »

Sorry. Thank you though. That did the trick
Logged
Pages: 1 [2] 3