Comments (5)
I think you're just looking at the wrong part of the spec. From the byte stride definition:
The stride, in bytes, between vertex attributes. When this is not defined, data is tightly packed. When two or more accessors use the same bufferView, this field must be defined. Minimum value: 4.
"Between" attributes suggests to me that it does not include the size of the component, implying that a byteStride of 0 would also indicate densely-packed data, but the spec authors prefer to omit the value entirely in this case.
The current algorithm has worked on all the sample models we've tried, but I admit it's possible that we misinterpreted. I don't think any of them use interleaved attributes or anything with byteStride. I'll ask the spec group.
from unitygltf.
I just think it is ambiguous, if you read this statement:
Each accessor must fit its bufferView, i.e., accessor.byteOffset + STRIDE * (accessor.count - 1) + >SIZE_OF_ELEMENT must be less than or equal to bufferView.length.
Then it implies the stride is the total stride, not the padding.
from unitygltf.
Wrong button.
This statement implies that the stride is the total stride, not the padding
Each accessor must fit its bufferView, i.e., accessor.byteOffset + STRIDE * (accessor.count - 1) +
SIZE_OF_ELEMENT must be less than or equal to bufferView.length.
from unitygltf.
Well, it looks like you're right, though it took some digging. The byteStride definition references WebGL's vertexAttribPointer
's stride
parameter, which reads:
A GLsizei specifying the offset in bytes between the beginning of consecutive vertex attributes. Cannot be larger than 255.
That's unambiguous. I'll get this fixed soon.
from unitygltf.
Fixed in 019b1c6
from unitygltf.
Related Issues (20)
- 'Texture2D' does not contain a definition for 'isDataSRGB' HOT 10
- Encounter object export errors when using package HOT 5
- Timeline for implementing KHR_interactivity? HOT 1
- Creating animation on runtime, from scratch HOT 10
- ShaderGraph dependency problem for OpenUPM install HOT 5
- how to get progress (while loading) runtime.? HOT 2
- Incorrect material texture offset value on KTX2-based compressed GLB import HOT 2
- KtxTexture AssertionException HOT 5
- Textures are loading twice in memory causing doubled CPU spike and memory usage HOT 15
- Shaders don't mark any exposed properties as "Main Color" HOT 2
- Default range for imported punctual lights is too high. HOT 2
- KHR_materials_anisotropy support HOT 1
- Freeze frame during runtime loading in Android HOT 6
- Fix Suggenstion for HDRP
- Only 4 bone weights per vertex exported/imported when Unity supports up to 256 HOT 2
- Mesh with tangents has validation errors and breaking compression HOT 7
- How to load glb as byte[] or MemoryStream
- i build and run my unity project and i found only pink object. if someone know please help me. HOT 7
- Issues building for runtime loading HOT 2
- File Names are wrong HOT 1
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 unitygltf.