asobostudio / gltf-blender-io-msfs Goto Github PK
View Code? Open in Web Editor NEWLicense: Apache License 2.0
License: Apache License 2.0
Simple Shape Collision gizmos are exported with incorrect coordinate
Wrong
"extensions" : {
"ASOBO_gizmo_object" : {
"gizmo_objects" : [
{
"translation" : [
0,
21.90847396850586,
4.967909812927246
],
"type" : "box",
"params" : {
"length" : 5.940423488616943,
"width" : 21.49878692626953,
"height" : 5.114718914031982
},
"extensions" : {
"ASOBO_tags" : {
"tags" : [
"Collision"
]
}
}
}
]
}
Good
"ASOBO_gizmo_object" : {
"gizmo_objects" : [
{
"translation" : [
0,
0,
-21.49878692626953,
],
"type" : "box",
"params" : {
"length" : 42.996,
"width" : 5.940423488616943,
"height" : 5.114718914031982
},
"extensions" : {
"ASOBO_tags" : {
"tags" : [
"Collision"
]
}
}
}
]
}
add a simple shape collision, export, compile and look at it in the sim
- OS: win 10
- Blender: 3.0.1
- glTF-Blender-IO-MSFS: 1.0.5 (this is the release indicated in the releases page
"https://github.com/AsoboStudio/glTF-Blender-IO-MSFS/releases/tag/v1.0.5"
but is still indicated has 1.0.4 in the python files,
-- i'm not a github user so could be totally wrong here!!--
I.e. https://github.com/KhronosGroup/glTF-Blender-IO . I wonder if that project would accept patches to export/import the MSFS flavour of glTF? Or is the MSFS glTF so different that having support for it in the official glTF 2.0 exporter-importer would lead to a horrible mess?
missing ASOBO_detail_map in windshield texture slots. (main branch test)
commit 547df62
After the update to version 1.1.5 I tried to apply the windshield material and it worked. But when I added the comp, norm, etc. it suddenly went pink in MSFS, as if the textures were missing (which they don't).
Windshield material also working when adding scratches, etc.
Create new windshield material with correct settings --> works
Add the textures and shaders from the DA62 (exactly the same way as in the DA62, verified with FBW im-/exporter) --> broken
- OS:Win10
- Blender: 3.1
- glTF-Blender-IO-MSFS: 1.1.5
Setting a texture to Base Color causes error. - not shown
to add texture to texture node
Open model
migrate standard texture (has standard texture already) will not carry over.
set the texture to the required texture get error.
Traceback (most recent call last):
File "C:\Users\Ron\AppData\Roaming\Blender Foundation\Blender\3.1\scripts\addons\io_scene_gltf2_msfs\blender\msfs_material_prop_update.py", line 128, in update_base_color_texture
msfs.setBaseColorTex(self.msfs_base_color_texture)
AttributeError: 'NoneType' object has no attribute 'setBaseColorTex'
File "C:\Users\Ron\AppData\Roaming\Blender Foundation\Blender\3.1\scripts\addons\io_scene_gltf2_msfs\blender\msfs_material_prop_update.py", line 123, in update_base_color_texture
Traceback (most recent call last):
File "C:\Users\Ron\AppData\Roaming\Blender Foundation\Blender\3.1\scripts\addons\io_scene_gltf2_msfs\blender\msfs_material_prop_update.py", line 128, in update_base_color_texture
msfs.setBaseColorTex(self.msfs_base_color_texture)
AttributeError: 'NoneType' object has no attribute 'setBaseColorTex'
File "C:\Users\Ron\AppData\Roaming\Blender Foundation\Blender\3.1\scripts\addons\io_scene_gltf2_msfs\blender\msfs_material_prop_update.py", line 123, in update_base_color_texture
- OS:win 10
- Blender:3.1
- glTF-Blender-IO-MSFS:1.1.2
No response
LOD lines are ASC by the min size
in this order the more detailed models are not loading.
i exported with grouped collections
- OS: win 10
- Blender: 3.1
- glTF-Blender-IO-MSFS: main branch 21.03.2022
No response
the uri for the texture file names is "funny"
{
"mimeType" : "image/png",
"name" : "testplanepanel_normal",
"uri" : "../texture/testplanepanel_normal.png"
},
why the ../texture - as this is the export folder name that the textures goes into - should not be part of the file name - I get this warning in sim build.
I've created three collision boxes (with Road collider settings off) and exported them in the SIM but there is no collision detected
The collision boxes should work in the SIM as standard scenery objects
Just export a collision box in the SIM and test it
- OS: Windows 10
- Blender:3.1
- glTF-Blender-IO-MSFS: 1.1.2
No response
Currently, we have no enforced code formatting. This thread will be used to discuss which style is best. My recommendation is the following:
Black Formater (https://github.com/psf/black)
pylint (https://github.com/PyCQA/pylint)
When selecting export folder,
If the export folder Is the same of the .blend
in the textbox appears "//"
Exporting throws errors in Blender
When selecting a folder, the full path name must be provided to avoid erros
Select as export folder the same folder where the .blend file Is located and click accept
- OS:win.10 ita
- Blender: 3.0.1
- glTF-Blender-IO-MSFS: 1.0.5
No response
Hello,
The exporter appeared to work fine in exports, but after using 'Build and Export' inside MSFS, the materials were broken. Most all became pink. Rebooting the sim and rebooting the computer did not fix it. Repeated external exports fixed some of the exterior textures, but some textures inside the plane remained pink.
I then went back to the previous version exporter and materials were immediately fixed.
Bill
Lionheart Creations
With the last build V1.1.2 pbr material are not correctly displayed in MSFS (Comp is missing), and normal map is nto correctly rendered in the Blender Viewport.
Have a correct render in MSFS, and it's secondary but better if it's solved, a correct normal map aspect in Blender viewport.
- OS:Win10
- Blender:3.1.0
- glTF-Blender-IO-MSFS:1.1.2
MSFS Rendered:
Albedo Channel:
Comp, channel Metallic:
Comp, channel Roughness:
Comp, channel AO:
Normal channel:
Blender shading tab:
Blender Normal map viewport :
Added Spot and area lights do not export. They all export fine with Blender2MSFS and Blender 2.9. I noticed this with my airport scenery so I decided to create a small scene containing 2 cubes (one cube has been divided to take 3 faces with glass texturing), 2 spots, and 1 icosphere (with emission).
When I export using 1.1.3 when I load it in the sim all lights are not there, however the emission on the icosphere is good.
When I export the exact same blend file from Blender 2.9 using Blender2MSFS, everything shows up in the sim.
I opened both glTF files in Notepad++ and noticed that the one (made a text file of the gltf called....TestBlock.txt) from Blender2MSFS exporter has the lights but the Asobo exporter glTF (made a text file of the gltf called...TestBlockX.txt) does not
TestBlock.txt
TestBlockX.txt
.
All added lights should be turned on based on the settings for day/night. I have some lights on all the time and some set to day/night.
- OS: Window 10 Pro
- Blender: 3.1
- glTF-Blender-IO-MSFS: 1.1.3
I tried to attach the .blend file here but it would not allow it.
migrate does not use metallic, roughness, emissive and alpha from legacy bsdf
Use those values and update new scale nodes
click migrate on bsfd colr materials
- OS:win 10
- Blender:3.1
- glTF-Blender-IO-MSFS:1.1.2
No response
Emissive is set to 1,1,1 when you migrate textures.
"materials" : [
{
"alphaMode" : "BLEND",
"emissiveFactor" : [
1,
1,
1
],
"name" : "Prop_Blur_Back",
"pbrMetallicRoughness" : {
"baseColorTexture" : {
"index" : 0
}
}
},
"materials" : [
{
"alphaMode" : "BLEND",
"emissiveFactor" : [
0,
0,
0
],
"name" : "Prop_Blur_Back",
"pbrMetallicRoughness" : {
"baseColorTexture" : {
"index" : 0
}
}
},
or removed.
open legacy blend file - migrate textures - in blender looks good, build in sim and all textures are emissive.
- OS:windows 10
- Blender:3.1
- glTF-Blender-IO-MSFS:1.1.1 build f1c717a
No response
seems a duplicate or two nodes are on top of each other.
self.nodeDetailNormal = self.addNode(
"ShaderNodeTexImage",
{
"name": MSFS_ShaderNodes.detailNormalTex.value,
"location": (-500, -1300.0),
},
)
............
self.nodeDetailNormalTex = self.addNode(
"ShaderNodeTexImage",
{
"name": MSFS_ShaderNodes.detailNormalTex.value,
"location": (-500, -1300.0),
},
)
file ismsfs_material_function lines 282 on.
no dupe?
look at code
- OS:win 10
- Blender: 3.1
- glTF-Blender-IO-MSFS:March 16
No response
draw order is set to zero
Draw order set to legacy value
make windhsield material with draw order in order to stop flashing of two windhiled materials side by side , example interior windshield material next to exterior windshield material.
- OS:10
- Blender:3.1.2
- glTF-Blender-IO-MSFS:1.1.5
No response
getting the following error on export of test plane
14:48:47 | WARNING: More than one shader node tex image used for a texture. The resulting glTF sampler will behave like the first shader node tex image.
gather_material_hook fails on <io_scene_gltf2_msfs.glTF2ExportUserExtension object at 0x000001C6AA43D370>
gather_texture_info() missing 1 required positional argument: 'export_settings'
if you start and add a material and after that set the msfs material to for example default the Emissive Scale slider is at 1.00
but if you look into the shader editor the node has a value of 0.00
maybe "Emissive Strength" would be a better wording? :)
There are some more sliders with the same effect:
The Emissive RGB Node (grayish) and the Emissive Color (black) in the properties panel is also not in sync when loading a material.
the same is with Base Color RGB Node (grayish) and the Base Color (white).
node value 1.00
- OS: Win 10
- Blender: 3.1
- glTF-Blender-IO-MSFS: main-branch - from 21.03.22
No response
The alpha values for windshield material is not being carried over in windshield migration.. it remains as 1.0
Carry over the alpha value from the Legacy exporter albedo_tint node. (base color)
open a model with windshield material - migrate windshield - see that the windshield shows all the textures - no transparency.
- OS:10
- Blender:3.1
- glTF-Blender-IO-MSFS:1.1.4
after:
The Anisotropic and Anisotropic Rotation in the principled bsdf are not connected when we choose and put a texture on Anisotropic Direction (Material: Anisotropic).
create and connect correct nodes
- OS: win10
- Blender: 3.0.1
- glTF-Blender-IO-MSFS: 1.0.5
I'm in the process to debug this for the MSFSToolkit as this is the same issue
The blend factors are set to zero, while they should reflect the current blend factors in the panel data. and custom values panel.
reflect the values found in custom panel for blend factors.
use legacy exporte with decal material, set blend factors to 1.0 open this model in ASOBO 1.1.5 exporter and migrate decal msfs material. See that blend factors are set to zero.
- OS:10
- Blender:3.1.2
- glTF-Blender-IO-MSFS:1.1.5
Getting the following error on export of Testplane
14:49:04 | WARNING: Image '<bpy_struct, Image("testplanefroma_metallic.png") at 0x000001C6AF26F208>' has no color channels and cannot be exported.
missing msfs_env_occluder and msfs_invisible not showing
change legacy name msfs_env_occluder from msfs_environment_occluder
example legacy occluder
- OS:10
- Blender:3.1
- glTF-Blender-IO-MSFS:1.1.2
No response
the texture for Details Scratches, ics, fingerprints is not carried over for windshield material.
Carry over the texture.
add windshield material with textures as required
- OS:10
- Blender:3.1
- glTF-Blender-IO-MSFS:1.1.2
When exporting multiple lods, the file naming in the section is wrong (only the last lod name is used)
<LODS> <LOD minSize="100" ModelFile="x2_bigOjbect.gltf"/> <LOD minSize="50" ModelFile="x2_bigOjbect.gltf"/> <LOD minSize="20" ModelFile="x2_bigOjbect.gltf"/> </LODS>
<LODS> <LOD minSize="100" ModelFile="x0_bigOjbect.gltf"/> <LOD minSize="50" ModelFile="x1_bigOjbect.gltf"/> <LOD minSize="20" ModelFile="x2_bigOjbect.gltf"/> </LODS>
create any multi lod in Blender and export
- OS:win10
- Blender:3.1.0
- glTF-Blender-IO-MSFS:1.1.2
Hello,
I made some cube in 2 different collection "LOD00" , "LOD01"
I have a Env collection which contain a sun and a camera'
I click on the Multi-Export Panel, and I click on Reload LODs but it takes all my object even those who are invisible in the viewport.
I have the error 'Cube' Can't be selected because it is not in View Layer 'ViewLayer' when I click the 'Export' button
Can you clarify what the correct workflow is for exporting an object with 2 (or more) LODS, including generating the xml, please?
Hello Team,
I was just curious when this SDK pack might be ready for testing in Blender 3.2?
Blender 3.2 availability
Load and run and install this SDK into Blender 3.2 for functionality check.
- OS:Win 10
- Blender:3.2
- glTF-Blender-IO-MSFS:
No response
the color space of this node is currently set to srgb this is resulting in too shiny materials.
if it is set to "non-color" the result is way better
- OS: win 10
- Blender: 3.1
- glTF-Blender-IO-MSFS: main branch from 21.03.2022
No response
when you make a object with a spotlight and export it the exporter is adding this extension: KHR_lights_punctual
because of this you get this message from the compiler:
It looks like the rotation / orientation of the spot is exported with the wrong extension.
"extensionsUsed" : [ "ASOBO_normal_map_convention", "KHR_lights_punctual", "ASOBO_macro_light" ], "extensionsRequired" : [ "KHR_lights_punctual" ], "extensions" : { "KHR_lights_punctual" : { "lights" : [ { "color" : [ 1, 0.9425290822982788, 0.854992687702179 ], "intensity" : 150, "spot" : { "innerConeAngle" : 0.8901179370451118, "outerConeAngle" : 1.0471975803375244 }, "type" : "spot", "name" : "Spot" } ] } }, "scene" : 0, "scenes" : [ { "name" : "Scene", "nodes" : [ 0, 2 ] } ], "nodes" : [ { "mesh" : 0, "name" : "x01_Main.001", "translation" : [ 0.8182962536811829, 1.0000004768371582, 0.9419757723808289 ] }, { "extensions" : { "KHR_lights_punctual" : { "light" : 0 } }, "name" : "Spot_Orientation", "rotation" : [ -0.7071067690849304, 0, 0, 0.7071067690849304 ] }, { "children" : [ 1 ], "extensions" : { "ASOBO_macro_light" : { "color" : [ 1, 0.9425290822982788, 0.854992687702179 ], "intensity" : 150, "cone_angle" : 120.00000333930423, "has_symmetry" : false, "flash_frequency" : 0, "flash_duration" : 0, "flash_phase" : 0, "rotation_speed" : 0, "day_night_cycle" : true } }, "name" : "Spot", "translation" : [ -6.666948318481445, 2.705559730529785, 13.863369941711426 ] } ],
something like this:
"extensionsUsed" : [ "ASOBO_normal_map_convention", "ASOBO_macro_light" ], "scene" : 0, "scenes" : [ { "name" : "Scene", "nodes" : [ 0, 1, 2, 3, 4 ] } ], "nodes" : [ { "mesh" : 0, "name" : "Cube" }, { "mesh" : 1, "name" : "Cube.001", "scale" : [ 0.20000000298023224, 0.02600245177745819, 0.20000000298023224 ], "translation" : [ 11.680688858032227, 4.844680309295654, 8.398731231689453 ] }, { "extensions" : { "ASOBO_macro_light" : { "color" : [ 1, 0.7716997265815735, 0.6500170826911926 ], "intensity" : 80, "cone_angle" : 120.00000333930423, "has_simmetry" : false, "flash_frequency" : 0, "flash_duration" : 0, "flash_phase" : 0, "rotation_speed" : 0, "day_night_cycle" : true } }, "name" : "Spot", "rotation" : [ 0.7071067690849304, 0, 0, 0.7071068286895752 ], "translation" : [ 11.690343856811523, 4.592289924621582, 8.399174690246582 ] },
- OS: Win 10
- Blender: 3.1
- glTF-Blender-IO-MSFS: 1.1.2
No response
Background: I have hangar doors animated, but I would like to export them static in a partially open position. I move playback to a specific frame and export with "current frame" enabled in the exporter settings. This works with normal Transform (Both rotation and Location). Delta transform makes it so much easier to animate and reposition than absolute transform.
Delta transform works if I activate the animation as autoplay in the xml, but not for static "Current Frame" export.
Issue: "Current frame" exporter setting ignores "Delta Transform".
Delta transform works when the animation is playing, so I would expect it to also work when exporting a static "Current Frame".
Green box in attached screenshot and blender file:
Make an animation on an object from 1-101 with location or rotation transform and make NLA track.
Select a frame in the playback, tick the "Current Frame" checkbox in the exporter settings.
Observe in MSFS that the object is positioned correctly according to the playback frame in Blender.
Red box in attached screenshot and blender file:
Make an animation on an object from 1-101 with Delta Transform location or rotation and make NLA track.
Select a frame in the playback, tick the "Current Frame" checkbox in the exporter settings.
Observe in MSFS that the object is positioned as frame 0, no animation applied
.
- OS:Windows 10
- Blender: 3.1.0
- glTF-Blender-IO-MSFS:
Example Blender file:
BlendfileanimationtestDelta.zip
Texture are exported in root folder (the folder where the Blender file Is)
Texture should be exported to /texture folder
Otherwise gonna show Pink checker in msfs
Export with multiexporter
- OS: win 10 ita
- Blender: 3.0.1
- glTF-Blender-IO-MSFS: 1.0.5
No response
Currently, we store gizmos and empties as raw references to their Blender data, which if handled incorrectly crashes blender. We should rewrite this to use PointerProperties, which don't crash Blender.
An upcoming change to the Khronos exporter is changing the gather_gltf_hook
. Once that PR merges (KhronosGroup/glTF-Blender-IO#1571), we need to change the hook name to gather_gltf_extensions_hook
. Also on that note, we really shouldn't be modifying anything in this hook, as that's not what it was meant for.
They should scale uniformly, but currently scale independently.
Every time "Generate XML" is ran a brand new GUID is generated which is different from the GUID written to the "scene".xml. This cause your up dated object to be "Unknown" in the simulator. One would have to go into the .gltf file and copy the new GUID and paste it into the "LibraryObject name=" location for the updated object. A work around has been to only create the XML the first time you add an object to your scenery and then uncheck "Generate XML" for subsequent updates. However, the Blender2MSFS2 would do a check to see if the object already has a GUID, and if it does it would not generate a GUID. This saved a lot of time as you did not have to check the xmls for matching GUIDs.
Exporter needs to check to see if a GUID has been generated already and if so, do not generate a new GUID.....use the previous one.
- OS: windows 10 pro
- Blender: 3.1
- glTF-Blender-IO-MSFS: 1.1.3
No response
having icing dirt finger prints etc cause error in blender export.
21:32:37 | WARNING: More than one shader node tex image used for a texture. The resulting glTF sampler will behave like the first shader node tex image.
gather_material_hook fails on <io_scene_gltf2_msfs.glTF2ExportUserExtension object at 0x0000023BD94B9BB0>
gather_texture_info() missing 1 required positional argument: 'export_settings'
Issue :Windshield materials do not work
Cause: the "extras" property is not placed in the material declaration within the glTF file
The exporter shall place the following declaration in the windshield type material
"extras" : {
"ASOBO_material_code" : "Windshield"
},
Inserting this code snipped causes the windshield material to work properly
- OS: Windows 10
- Blender: 3.1.0
- glTF-Blender-IO-MSFS: 1.13
No response
The texture file name includes the path of the texture. This should not be required. possible issue with sim, but not in all cases.
Now everybody has to change values when selecting a material like glass. You have to change the alpha of the base color, etc. I would be nice, if possible, to have the values be on a default value that works and then change them to your liking later. Thx
When a new material is created, the Material Properties sliders and controls do not reflect the actual default values of the nodes in the created material node tree. This appears to be a problem with initialization when a new material is created. A work-around is to manipulate the control slider/value once, and that will make the control/node values equal.
The parameters of relevant nodes created by the MSFS Standard Material should reflect the values set in the node tree of the instance created.
- OS: Windows 10 Home
- Blender:3.1
- glTF-Blender-IO-MSFS:1.1.3
Best guess as to the solution for this problem:
In the init portion of the material class instance constructor, there should be a segment that scans the visible default settings of the material properties controls to make the nodes reflect the visible settings. This problem is apparent in many of the control/node pairings.
Minor Consideration:
Controls like Metallic Factor, Roughness Factor, Normal Scale, Emissive RGB and the like should be defaulted to reasonable values if they are used in the material. The default set in the Principled BSDF Shader in Blender would be a reasonable set.
Summary comment:
I have been using this new exporter extensively for the past week, and I find it a very agreeable tool. I am currently recompiling many of my projects using it. My thanks to all the developers for this well-organized tool. I await the resolution of the order of LOD keys in the .xml file. Thank you all for the work on this tool.
I don't know if this is possible via the SDK limitations of the game (if it's not possible, maybe bring it up to Asobo), but is there a way to define via a toggle in 'Render' or 'Gameplay' parameters if an object is a Windsock or not?
I feel like this will cut the need for custom animations and just have this object rely on in-game weather for animations instead of exporting animations and the tedious process.
When we're using the Anisotropic material the textures are correctly exported, but it create an error to build the package.
it should not cause any error
- OS: Windows 10
- Blender: 3.1.0
- glTF-Blender-IO-MSFS:1.0.0
if you place a spotlight like this pointing away from the building:
in the simulator it is 90° rotatet on the blender z axis:
the light should point into the same direction like in blender.
- OS: Win 10
- Blender: 3.1
- glTF-Blender-IO-MSFS: 1.1.3
No response
When building an aircraft I like to separate each component (wings, elevator, panel etc) into an individual collection. This makes it easier to work with a large project which can have over a thousand parts. There doesn't seem to be any way to export these collections as a single model. The exporter forces each collection to be exported as a separate model which may be fine for working with scenery but is less than ideal for exporting aircraft.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.