-
Notifications
You must be signed in to change notification settings - Fork 271
Buffer interpolators
x3dom extends the standard interpolators with an option to use a binary data file, the buffer. This extension is based on how gltf uses binary data, and in fact the gltf inline function takes advantage of this extension. A few addtional fields for the interpolator nodes facilitate.
The buffer field defines the url to the binary data file. Accessor fields nodes define key and keyValue pointers into the buffer and an additional offset for a view into the buffer. They also define size and data type for key and keyValue.
Here a glTF explanation of the terms: https://github.com/KhronosGroup/glTF-Tutorials/blob/master/gltfTutorial/gltfTutorial_005_BuffersBufferViewsAccessors.md
The url to the binary file, that contains the binary buffer data. [ could be MFString to be consistent with Urls in x3d which have fallback options ].
A list of BufferAccessor nodes. One of bufferType "SAMPLER_INPUT" is intended for the key, and one of bufferType "SAMPLER_OUTPUT" for the keyValue.
The node has these fields:
Specifies if the accessor’s elements are scalars, vectors, or matrices, or sampler input or output. Use "SAMPLER_INPUT" for key, and "SAMPLER_OUTPUT" for keyValue.
The related buffer view. Id of a BufferView.
The buffer byteOffset. The offset from the beginning of the referenced view in bytes.
The buffer byteStride. not used.
The buffer components. not used.
The buffer component type. The type of numerical representation as GL enum.
The buffer element count. The count times the number of bytes defined by the component type is used to determine the size of the data in the buffer.
X3DOM wiki