Comments (14)
The assets from my side were done in Blender and exported to a proprietary asset format and finally exported again to glTF 2.0.
I suggest to provide the Blender files, as sooner or later we will have a Blender to glTF 2.0 exporter.
from gltf-sample-models.
As soon as the glTF 2.0 Blender exporter has made some progress and major changes will not occur anymore, I will upload the Blender files depending on the provided PBR metal roughness cycles node:
https://github.com/KhronosGroup/glTF-Blender-Exporter
from gltf-sample-models.
The models that are listed as "Simple models for testing individual features" in the README, namely
- AdvancedMaterial
- AnimatedTriangle
- Cameras
- SimpleMaterial
- SimpleMeshes
- SimpleOpacity
- SimpleSkin
- SimpleTexture
- Triangle
- TriangleWithoutIndices
are indeed created manually. They orginally had been created for the glTF tutorial, tweaking e.g. the order of the top level dictionaries/arrays to "group" them sensibly, and roughly match the descriptions in the tutorial. So there is no "source model" for those.
from gltf-sample-models.
@lasalvavida All of the models I added are sourced from FBX's with separate textures for each map specifically made for Unity's standard PBR materials. I can add these source files as well, but I'm not sure how useful they will be. Let me know if you want them anyways.
from gltf-sample-models.
@bghgary, if you could add them anyway, that would be terrific!
from gltf-sample-models.
For MetalRoughSpheres and NormalTangentTest, I do have COLLADA models with geometry/normals/UVs, but all of my texturemap names were hand-edited into the glTF. I notice that some of the other sample models seem to be using COLLADA's profile_COMMON
with diffuse and specular channels, but my models need basecolor, occlusionRoughnessMetalness, and normal. How can I produce a COLLADA model that contains an occlusionRoughnessMetalness map in it?
from gltf-sample-models.
My approach for this may not be perfect, but it seems to pretty accurately reflect the mapping in models for which I have both a COLLADA profile_COMMON
and a glTF PBR variant.
Using MetalRoughSpheres as an example, our PBR material is:
{
"pbrMetallicRoughness": {
"baseColorFactor": [
1,
1,
1,
1
],
"baseColorTexture": {
"index": 0
},
"metallicRoughnessTexture": {
"index": 1
}
}
}
You can get this out of COLLADA2GLTF-2.0 with the following COLLADA profile_COMMON
by putting baseColor as diffuse:
<profile_COMMON>
<newparam sid="baseColorTexture-surface">
<surface type="2D">
<init_from>baseColorTexture-image</init_from>
<format>A8R8G8B8</format>
</surface>
</newparam>
<newparam sid="baseColorTexture-sampler">
<sampler2D>
<source>baseColorTexture-surface</source>
<minfilter>LINEAR_MIPMAP_LINEAR</minfilter>
<magfilter>LINEAR</magfilter>
</sampler2D>
</newparam>
<technique sid="common">
<phong>
<diffuse>
<texture texture="baseColorTexture-sampler" texcoord="Texture" />
</diffuse>
</phong>
</technique>
</profile_COMMON>
And by specifying the --metallicRoughnessTexture
flag on the command line pointing to your metallic roughness texture. If you include this texture as ${MODEL_NAME}_metallicRoughness.png
my python conversion script will pick it up for you automatically. Looking now, it looks like I forgot to include those in sourceModels
when I did the move, so I'll have that fixed in the 2.0 PR shortly.
For NormalTangentTest, put occlusion in ambient and normal in bump.
from gltf-sample-models.
@McNopper, adding the blender files would be ideal
from gltf-sample-models.
And by specifying the --metallicRoughnessTexture flag on the command line pointing to your metallic roughness texture.
It may be a good idea to separate metallic and roughness as inputs, and combine in the tool.
from gltf-sample-models.
Note that a model can contain multiple materials, and each material can have its own roughnessMetallic texture, separate from other materials.
Maybe there could be a commandline flag to indicate that some other channel, such as the specular color channel, contains a reference to a roughnessMetallic texture (or even an occlusionRoughnessMetallic texture) instead of an actual specular map. This way, each material could specify its own map.
from gltf-sample-models.
a model can contain multiple materials
In the short term, my solution to this will probably be --metallicRoughnessTexture[_index]
with the optional index
being the effect
index in library_effects
.
from gltf-sample-models.
@lasalvavida The SmileFace.dae contains vertex color problems, I think that improvement is necessary.
This model has vertex colors all zero.
@bghgary Do you know the correct data source for the model?
Related: mrdoob/three.js#11264
from gltf-sample-models.
CC @sbtron
The source model, similar to the PBR models, started with an FBX. This particular model had a bug where
the vertex colors were all zeroes. I think the root of this issue is that it was authored incorrectly.
from gltf-sample-models.
Closing this issue. Not every sample glTF model here will have some other "source" format that automatically converts exactly to the sample presented here. Many of these samples test edge cases or experimental features using hand-crafted modifications. Some of these glTF files are entirely hand-crafted in glTF from scratch (eg, SimpleSkin).
from gltf-sample-models.
Related Issues (20)
- RecursiveSkeletons is not a valid glTF file HOT 2
- Errors in Fox model
- BoxTextured and BoxTexturedNonPowerOfTwo have different texture brightness HOT 8
- Buggy model doesn't follow the 4 bytes alignment requirement of the spec for indices HOT 2
- Blender GLTF fails the gLTF validation HOT 2
- Normal texture TestMap_blur.png does not conform to the glTF 2.0 spec HOT 4
- Please rename default branch from 'master' to 'main' per Khronos policy HOT 3
- Missing license for VertexColorTest HOT 1
- Missing license for BoxVertexColors HOT 1
- Many models missing AO channel HOT 9
- stainedGlassLamp/glTF-JPG-PNG alpha is 0.5 HOT 4
- π₯π₯π₯convert obj 3d model to gltf model on server side HOT 1
- Sponza gltf materials wrong? HOT 1
- It would be great if someone can convert these PBR research models into glTF HOT 5
- Mask / Stencil shader HOT 1
- InterpolationTest oddities HOT 4
- InterpolationTest translation animations loop badly HOT 7
- Iridescence test model? HOT 6
- Anisotropy test model? HOT 6
- Directory structure issues HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gltf-sample-models.