Modeling for Ardupilot SITL

ceu.gomez

New member
Hi guys,
So, I'm having a touch of trouble getting custom 3d-models into realflight. We have been developing autopilots through ardupilot for a while, and are trying to build a simulator for our airframes in RealFlight 9 with ardupilot's native FlightAxis link SITL integration. We have custom 3d-models of our plane in both 3DSMax 2019 and Blender, but implementing them into the game hasn't worked so far.

Brief rundown of the steps I've taken so far (I can elaborate if necessary):

- Imported our STLs into both blender and 3DSMax
- Assigned the naming conventions detailed in KnifeEdge's aircraft development guide and parented all parts to the fuselage
- Created a ~CS_SPINNER and a ~CS_ENGINE part at the motor mount hub, parented to fuselage
- Applied a solid grey 32x32 TGA texture to all parts with the UVMap Editor, located in the same directory as the model
- exported from 3DSMax as a .3DS file (in the same directory)
- called with recommended export settings
- Ran 3ds2kex, both the beta and non-beta versions available for download from knifeEdge's site, on the file. I get the license & terms of use output in the command prompt, but no output file. The converters work on the supplied samples in the folder.

I'm kind of not sure what to do next! All the 3ds plugins available are for legacy versions of the software, which Autodesk no longer supports. Do you guys have any suggestions for possible ways to go from here? We are running Windows 10 x64.

Thanks! you guys are doing some awesome stuff here.
-jake :)
 
That feels like it should work, but RealFlight throws an error right at the end of the export dialogue box:
'Error: Cannot locate path to texture file within KEX file. Corrupted KEX file?'

The only tga I'm using is in the same directory as the .FBX that I'm trying to import. Is there a subdirectory I should place it in so RealFlight picks it up after it does the KEX conversion, or something? Or is there a way to edit that path into a KEX file?

-jake
 
Are you sure the texture is applied, to all the parts that use it? I'm just throwing things out there.
 
So, I went through and remapped all the textures to the .TGA (2048x2048) in 3DSMax, with one material created with the bitmap attached. RF9 still doesn't want to import it directly as an FBX, citing unable to find texture in the generated KEX, but the converter now at least tries to parse it and outputs 'The model uses too few bitmap materials. Please reconfigure the model to use exactly one bitmap.' I can see the materials rendered on each segment in the 3DS viewport; how should I set up the materials so it doesn't throw this error?

Thanks for your help :p 2 minds are better than one regardless

-jake
 
Yeah, I have lol. I'm sure I'm just doing something small wrong in the import/export process that's throwing off the Knife Edge conversion engine, but it does seem that their software library for content creators would benefit from a bit of an update :p

Thanks for your help, I'll update this thread if I make any significant progress!
 
Got it! took a while, but the models import straight from the 3dsMAX 2019 FBX exporter.

If anyone was running up against a similar issue, the fix was to:

- strip paths from all assets and manually place them in the same folder as the 3d model.

-THEN set the paths to textures within asset tracking, make them relative to project folder, export as FBX, and import to RF9
 
Wondering if you (or anyone else) have been able to export fbx files from blender that don't generate the RF path error. I can import objects into RF from Wings3D (3ds files converted to fbx with the Autodesk fbx converter) but I always get the path error on files exported from blender.

RF does some weird things with my object colors and I was hoping that being able to export fbx files directly from blender might solve that problem.

I just started learning blender a few days ago and I think they named it that because trying to understand it makes you feel like your brain is in a blender!
 
I looked into it, but the FBX exporter in Blender is Very limited [read: it sucks].
You can try playing with the blender tutorials given by KnifeEdge (in the downloads section of this site), but if you have the capability to acquire a student or trial license of 3dsMax, i strongly recommend using that, if just as an export tool.

It is 100% possible to model completely in blender, export to 3dsMax, assign materials in 3ds, and export an FBX from there (in fact, that's how i've been doing it. Autodesk's 3d tools leave something to be desired, IMO).
 
I looked into it, but the FBX exporter in Blender is Very limited [read: it sucks].
You can try playing with the blender tutorials given by KnifeEdge (in the downloads section of this site), but if you have the capability to acquire a student or trial license of 3dsMax, i strongly recommend using that, if just as an export tool.

It is 100% possible to model completely in blender, export to 3dsMax, assign materials in 3ds, and export an FBX from there (in fact, that's how i've been doing it. Autodesk's 3d tools leave something to be desired, IMO).

I like working in wings3d because I'm doing simple objects like shelters, fences, sheds, etc. - typical flying field stuff...no aircraft. But after hours of trying I just can't get the results I want. Even with mapping the entire model, the surfaces are super shiny when imported to RF.

I don't qualify for a Max educational license and I certainly can't afford to purchase it so I guess I'm stuck with what I have for now.

Thanks for the info.
 
Try making a "name"_s.tga . All black and nothing will be shiny. Make sire it is in the same folder as the original .tga
 
Try making a "name"_s.tga . All black and nothing will be shiny. Make sire it is in the same folder as the original .tga

Wow, you just made my day...week...maybe year! No more shiny grass runways or roof shingles!!

Thank you!
 
You can adjust the shine by lightening the areas you want to have reflections such as windows or chrome.
 
Wow, you just made my day...week...maybe year! No more shiny grass runways or roof shingles!!

Thank you!

You can adjust the shine by lightening the areas you want to have reflections such as windows or chrome.

In wings3d the shininess is reversed. 1.0 is no shine and 0.0 is max shine. when editing the material there should be a slider with the range above
 
In wings3d the shininess is reversed. 1.0 is no shine and 0.0 is max shine. when editing the material there should be a slider with the range above

I have seen the shininess slider on tutorials but my version 2.2.4 doesn't have it.
It does have a Metallic slider setting. See attachment. Could that be it?
 

Attachments

  • materials window.jpg
    materials window.jpg
    92.6 KB · Views: 14
I have seen the shininess slider on tutorials but my version 2.2.4 doesn't have it.
It does have a Metallic slider setting. See attachment. Could that be it?

I am using Wings 2.1.5 and it looks like wings 2.2.4 is using/defaults to metalness instead of what rf 9 and earlier uses (diffuse ambient specular) which may be why colors are getting distorted with the converter that people are using to skip using 3dsmax
 

Attachments

  • 2019-12-20 17_17_43-Window.jpg
    2019-12-20 17_17_43-Window.jpg
    24.3 KB · Views: 12
I am using Wings 2.1.5 and it looks like wings 2.2.4 is using/defaults to metalness instead of what rf 9 and earlier uses (diffuse ambient specular) which may be why colors are getting distorted with the converter that people are using to skip using 3dsmax

Yeah that's the window I've seen on the tutorials.

On a wire fence I made, there were green metal posts with the top 6 inches mapped in white. Most of the time they look transparent rather than white but it depends on the angle, etc.

I also have problems with projected images. They have streaky color bands around the outside of the image. So, I just import them as scenery, set them to conform to ground, adjust the Z coordinate, and turn off collision.

I've tried using different planes including image planes but no luck finding the magic formula yet.

Having said all that, I suspect you are right that the FBX converter is the problem. I think I read where RF recommends the FBX 2014/2015 version but the Autodesk converter I have has nothing later than the 2013 version.

I hope to eventually get Max. I know that's the ultimate answer.
 
Yeah that's the window I've seen on the tutorials.

On a wire fence I made, there were green metal posts with the top 6 inches mapped in white. Most of the time they look transparent rather than white but it depends on the angle, etc.

I also have problems with projected images. They have streaky color bands around the outside of the image. So, I just import them as scenery, set them to conform to ground, adjust the Z coordinate, and turn off collision.

I've tried using different planes including image planes but no luck finding the magic formula yet.

Having said all that, I suspect you are right that the FBX converter is the problem. I think I read where RF recommends the FBX 2014/2015 version but the Autodesk converter I have has nothing later than the 2013 version.

I hope to eventually get Max. I know that's the ultimate answer.

looking transperent rather than white at certain angle is probobly the the shiny values acting as a mirror

the streaky color band sounds like the face(s) needs hard edges

The only thing I have ever used an image plane for is a cross section or 3views for airplane building
 
Back
Top