Thanks, added to the TODO list
GLTF Import Export
- clintonman
- Captain
- Posts: 5432
- Joined: 21 May 2009, 21:08
- Type the number ten into the box: 0
- Location: California
- Contact:
- clintonman
- Captain
- Posts: 5432
- Joined: 21 May 2009, 21:08
- Type the number ten into the box: 0
- Location: California
- Contact:
Re: GLTF Import Export
Improved handling of the metallic value in the non-texture model shader
Left is before and right is after
Easiest to see the difference in the gold spheres 3rd column from the left. As it goes up the metal factor increases and the highlight color changes from white to gold and the reflection properties change.
This change also requires a change to the lights so they are bright enough to illuminate it. Using unofficial update lights the intensity before was 2 and in the after image it was something like 200.
Next the texture based model shader will need a similar fix.
Re: GLTF Import Export
Really love your Environment Lighting
Makes for some awesome Real time Gold material
Playing with the Roughness Scale .
- clintonman
- Captain
- Posts: 5432
- Joined: 21 May 2009, 21:08
- Type the number ten into the box: 0
- Location: California
- Contact:
Re: GLTF Import Export
Texture based model shader was updated and a new texture environment to go with it.
Re: GLTF Import Export
Here is a Wolf scene
Export does not export the Alpha Fur image
Import Fur is Solid Color
Export does not export the Alpha Fur image
Import Fur is Solid Color
- Attachments
-
- Wolf.RsScn
- (1.8 MiB) Downloaded 36 times
- clintonman
- Captain
- Posts: 5432
- Joined: 21 May 2009, 21:08
- Type the number ten into the box: 0
- Location: California
- Contact:
Re: GLTF Import Export
In gltf the alpha is a part of the color image. No color image so no alpha.
You can use the "solid color image" compositing node with a TextureShader to create a color image.
The final result will have alpha but it will be reversed because of the special TextureAlpha3. It has an internal reverse of the alpha values.
Re: GLTF Import Export
Tried a different Alpha Shader and a Black Color Textureclintonman wrote: ↑18 Nov 2023, 18:14In gltf the alpha is a part of the color image. No color image so no alpha.
ColorToColorImage.jpg
You can use the "solid color image" compositing node with a TextureShader to create a color image.
The final result will have alpha but it will be reversed because of the special TextureAlpha3. It has an internal reverse of the alpha values.
GLTFWolfAlphaReversed.jpg
Results: .
The imported Alpha Image is Inverted
Re: GLTF Import Export
I changed the Wolf materials to Compiled Textures
I get much better results with Exporting and then Importing into trueSpace
Except it is Imported with Shinny textures
But the Alpha Fur is as expected .
FYI:
I discovered that trueSpace's TextureBumpAlphaMetal & TexxtureBumpAlpha compiled textures does not show the AlphaTest & AlphaTestValue attributes
And you can get Transparent Shadows .
Modifications
Expose:
AlphaTest
AlphaTestValue
AlphaTest = Enabled
AlphaTestValue = 0.100 'Transparent Shadows'
AlphaTestValue = 1.000 'No Transparent Shadows'
I get much better results with Exporting and then Importing into trueSpace
Except it is Imported with Shinny textures
But the Alpha Fur is as expected .
FYI:
I discovered that trueSpace's TextureBumpAlphaMetal & TexxtureBumpAlpha compiled textures does not show the AlphaTest & AlphaTestValue attributes
And you can get Transparent Shadows .
Modifications
Expose:
AlphaTest
AlphaTestValue
AlphaTest = Enabled
AlphaTestValue = 0.100 'Transparent Shadows'
AlphaTestValue = 1.000 'No Transparent Shadows'
Re: GLTF Import Export
Something odd about the Imported Spotlights with No Shadow
- clintonman
- Captain
- Posts: 5432
- Joined: 21 May 2009, 21:08
- Type the number ten into the box: 0
- Location: California
- Contact:
Re: GLTF Import Export
steps:
add cube to default scene
export gltf
import gltf
set light intensity to brighten it up
disable shadow on spotlight
see the problem
temporary workaround for now: change ThresholdAttenuation from 0.05 to 0.005
TODO: light export needs to look at the attenuation values to adjust the exported intensity and tinygltf won't load gltf with empty buffer, if empty remove from the file