-
-
Notifications
You must be signed in to change notification settings - Fork 21.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
8 uvs for glTF2, URI decode and Vertex Custom api #52504
Conversation
Current status:
|
Updated the review with support for float based custom formats in SurfaceTool, EditorSceneImporterMesh and GLTFDocument. Future work: support importing uvs to half-based or unorm-based CUSTOM* channels; support half and unorm/snorm types in SurfaceTool::create_vertex_array_from_triangle_arrays and support exporting half and unorm/snorm types to TEXCOORD_ channels in gltf. Here's a shader program I use to test UVs. It shows 3 of the 4 channels based on screen quadrant: It does seem like CUSTOM0, CUSTOM1 and CUSTOM2 show the same data in the shader. I tried reordering the bufferviews such that it should have guaranteed the custom channels are different, but I haven't entirely ruled out yet if the input data is bad. |
a01a601
to
0c73f9a
Compare
Demo Project and video. 2021-09-08_23-05-35.mp4 |
dd2cbd4
to
3254a13
Compare
d118a59
to
603e52c
Compare
Looks good to me, will merge later today or tomorrow if no one else objects. |
Add glTF2 uri decode for paths. Add vertex custom apis. Add scene importer api. Change Color to float; add support for float-based custom channels in SurfaceTool and EditorSceneImporterMesh Co-authored-by: darth negative hunter <thenegativehunter2@users.noreply.github.com>
Fixes: #44552
Fixes: godotengine/godot-proposals#2266
Based upon the work of thenegativehunter2.
Use https://github.com/KhronosGroup/glTF-Sample-Models/tree/master/2.0/MultiUVTest to test.
Use for import tests:
gltf_test_8_uvs.zip
Use for export tests:
https://github.com/thenegativehunter2/godot_custom_vertex_attribute_demo/blob/master/assets/meshes/DualSurfaceMesh.mesh:
gltf_uvbug01glb.zip