Graphics Reference
In-Depth Information
”animation 0” :
{
”channels” :[ {
”sampler” : ”animation 0 translation sampler” ,
”target” :
{
”id” : ”node
box” ,
”path” : ”translation”
cam01
],
”count” : 901,
”parameters” :
}
{
”TIME” :
{
”bufferView” : ”bufferView 4509” ,
”byteOffset” :0,
”count” : 901,
”type” : ”FLOAT”
} ,
”translation” : {
”bufferView” : ”bufferView 4509” ,
”byteOffset” : 3604,
”count” : 901,
”type” : ”FLOAT VEC3”
}
} ,
”samplers” : {
”animation 0 translation sampler” :
{
”input” : ”TIME” ,
”interpolation” : ”LINEAR” ,
”output” : ”translation”
}
}
}
Listing 2.1. Animation listing.
glTF targets GL APIs by creating structures that can be sent directly to a
runtime engine built with WebGL, OpenGL ES, or OpenGL. glTF consists of
a set of files that are directly compatible with web technology—a JSON file,
binary files, GLSL shaders, and images. COLLADA2GLTF is the open-source
converter from COLLADA to glTF. As shown in Figure 2.7, it can be used as-is,
be incorporated into a content pipeline, or serve as a reference implementation
for other converters.
2.9.1 COLLADA2GLTF
COLLADA2GLTF content processing incorporates several stages that progres-
sively transform the content into the data structure accepted by GL APIs:
Triangulate: Geometry is transformed into primitives accepted by GL. The
most common one is TRIANGLES .
Single index: Only one index per vertex attribute can reference all the
attributes associated. Modelers often use one index per attribute, which
Search WWH ::




Custom Search