forked from KhronosGroup/glTF
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathaccessor.schema.json
60 lines (60 loc) · 2.45 KB
/
accessor.schema.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
{
"$schema" : "http://json-schema.org/draft-03/schema",
"title" : "accessor",
"type" : "object",
"description" : "A typed accessor into a buffer-view.",
"extends" : { "$ref" : "glTFChildOfRootProperty.schema.json" },
"properties" : {
"bufferView" : {
"extends" : { "$ref" : "glTFid.schema.json" },
"description" : "The id (JSON property name) of the buffer-view.",
"required" : true
},
"byteOffset" : {
"type" : "integer",
"description" : "The offset relative to the buffer-view in bytes. Must be a multiple of the size of the data type. WebGL: see vertexAttribPointer() offset parameter.",
"minimum" : 0,
"required" : true
},
"byteStride" : {
"type" : "integer",
"description" : "The stride, in bytes, between attributes referenced by this accessor. When 0, the attributes are tightly packed. WebGL: see vertexAttribPointer() stride parameter.",
"minimum" : 0,
"maximum" : 255,
"default" : 0
},
"componentType" : {
"type" : "integer",
"description" : "Valid values are BYTE (5120), UNSIGNED_BYTE (5121), SHORT (5122), UNSIGNED_SHORT (5123), FLOAT (5126). Corresponding typed arrays: Int8Array, Uint8Array, Int16Array, Uint16Array, and Float32Array.",
"enum" : [5120, 5121, 5122, 5123, 5126],
"required" : true
},
"count" : {
"type" : "integer",
"description" : "The number of attributes referenced by this accessor, not to be confused with the number of bytes or number of components.",
"minimum" : 1,
"required" : true
},
"type" : {
"type" : "string",
"description" : "Specifies if the attribute is a scale, vector, or matrix.",
"enum" : ["SCALAR", "VEC2", "VEC3", "VEC4", "MAT2", "MAT3", "MAT4"],
"required" : true
},
"max" : {
"type" : "array",
"description" : "Maximum value of each component in this attribute.",
"items" : {
"type" : "number"
}
},
"min" : {
"type" : "array",
"description" : "Minimum value of each component in this attribute.",
"items" : {
"type" : "number"
}
}
},
"additionalProperties" : false
}