@zephyr3d/device 0.2.1 → 0.2.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/gpuobject.js CHANGED
@@ -1754,6 +1754,48 @@ const vertexAttribFormatMap = {
1754
1754
  'u32',
1755
1755
  4
1756
1756
  ],
1757
+ blendweights_f16x1: [
1758
+ VERTEX_ATTRIB_BLEND_WEIGHT,
1759
+ PBPrimitiveType.F16,
1760
+ 2,
1761
+ 'f16',
1762
+ 1
1763
+ ],
1764
+ blendweights_f32x1: [
1765
+ VERTEX_ATTRIB_BLEND_WEIGHT,
1766
+ PBPrimitiveType.F32,
1767
+ 4,
1768
+ 'f32',
1769
+ 1
1770
+ ],
1771
+ blendweights_f16x2: [
1772
+ VERTEX_ATTRIB_BLEND_WEIGHT,
1773
+ PBPrimitiveType.F16VEC2,
1774
+ 4,
1775
+ 'f16',
1776
+ 2
1777
+ ],
1778
+ blendweights_f32x2: [
1779
+ VERTEX_ATTRIB_BLEND_WEIGHT,
1780
+ PBPrimitiveType.F32VEC2,
1781
+ 8,
1782
+ 'f32',
1783
+ 2
1784
+ ],
1785
+ blendweights_f16x3: [
1786
+ VERTEX_ATTRIB_BLEND_WEIGHT,
1787
+ PBPrimitiveType.F16VEC3,
1788
+ 6,
1789
+ 'f16',
1790
+ 3
1791
+ ],
1792
+ blendweights_f32x3: [
1793
+ VERTEX_ATTRIB_BLEND_WEIGHT,
1794
+ PBPrimitiveType.F32VEC3,
1795
+ 12,
1796
+ 'f32',
1797
+ 3
1798
+ ],
1757
1799
  blendweights_f16x4: [
1758
1800
  VERTEX_ATTRIB_BLEND_WEIGHT,
1759
1801
  PBPrimitiveType.F16VEC4,
@@ -1768,6 +1810,90 @@ const vertexAttribFormatMap = {
1768
1810
  'f32',
1769
1811
  4
1770
1812
  ],
1813
+ blendindices_u16x1: [
1814
+ VERTEX_ATTRIB_BLEND_INDICES,
1815
+ PBPrimitiveType.U16,
1816
+ 2,
1817
+ 'u16',
1818
+ 1
1819
+ ],
1820
+ blendindices_f16x1: [
1821
+ VERTEX_ATTRIB_BLEND_INDICES,
1822
+ PBPrimitiveType.F16,
1823
+ 2,
1824
+ 'f16',
1825
+ 1
1826
+ ],
1827
+ blendindices_f32x1: [
1828
+ VERTEX_ATTRIB_BLEND_INDICES,
1829
+ PBPrimitiveType.F32,
1830
+ 4,
1831
+ 'f32',
1832
+ 1
1833
+ ],
1834
+ blendindices_u32x1: [
1835
+ VERTEX_ATTRIB_BLEND_INDICES,
1836
+ PBPrimitiveType.U32,
1837
+ 4,
1838
+ 'u32',
1839
+ 1
1840
+ ],
1841
+ blendindices_u16x2: [
1842
+ VERTEX_ATTRIB_BLEND_INDICES,
1843
+ PBPrimitiveType.U16VEC2,
1844
+ 4,
1845
+ 'u16',
1846
+ 2
1847
+ ],
1848
+ blendindices_f16x2: [
1849
+ VERTEX_ATTRIB_BLEND_INDICES,
1850
+ PBPrimitiveType.F16VEC2,
1851
+ 4,
1852
+ 'f16',
1853
+ 2
1854
+ ],
1855
+ blendindices_f32x2: [
1856
+ VERTEX_ATTRIB_BLEND_INDICES,
1857
+ PBPrimitiveType.F32VEC2,
1858
+ 8,
1859
+ 'f32',
1860
+ 2
1861
+ ],
1862
+ blendindices_u32x2: [
1863
+ VERTEX_ATTRIB_BLEND_INDICES,
1864
+ PBPrimitiveType.U32VEC2,
1865
+ 8,
1866
+ 'u32',
1867
+ 2
1868
+ ],
1869
+ blendindices_u16x3: [
1870
+ VERTEX_ATTRIB_BLEND_INDICES,
1871
+ PBPrimitiveType.U16VEC3,
1872
+ 6,
1873
+ 'u16',
1874
+ 3
1875
+ ],
1876
+ blendindices_f16x3: [
1877
+ VERTEX_ATTRIB_BLEND_INDICES,
1878
+ PBPrimitiveType.F16VEC3,
1879
+ 6,
1880
+ 'f16',
1881
+ 3
1882
+ ],
1883
+ blendindices_f32x3: [
1884
+ VERTEX_ATTRIB_BLEND_INDICES,
1885
+ PBPrimitiveType.F32VEC3,
1886
+ 12,
1887
+ 'f32',
1888
+ 3
1889
+ ],
1890
+ blendindices_u32x3: [
1891
+ VERTEX_ATTRIB_BLEND_INDICES,
1892
+ PBPrimitiveType.U32VEC3,
1893
+ 12,
1894
+ 'u32',
1895
+ 3
1896
+ ],
1771
1897
  blendindices_u16x4: [
1772
1898
  VERTEX_ATTRIB_BLEND_INDICES,
1773
1899
  PBPrimitiveType.U16VEC4,
@@ -1846,22 +1972,28 @@ var GPUResourceUsageFlags;
1846
1972
  })(GPUResourceUsageFlags || (GPUResourceUsageFlags = {}));
1847
1973
  /**
1848
1974
  * Get vertex attribute index by semantic
1849
- * @internal
1975
+ * @public
1850
1976
  */ function getVertexAttribByName(name) {
1851
1977
  return vertexAttribNameMap[name];
1852
1978
  }
1853
1979
  /**
1854
1980
  * Get vertex semantic by attribute index
1855
- * @internal
1981
+ * @public
1856
1982
  */ function getVertexAttribName(attrib) {
1857
1983
  return vertexAttribNameRevMap[attrib];
1858
1984
  }
1859
1985
  /**
1860
1986
  * Get byte size of specified vertex format
1861
- * @internal
1987
+ * @public
1862
1988
  */ function getVertexFormatSize(fmt) {
1863
1989
  return vertexAttribFormatMap[fmt][2];
1864
1990
  }
1991
+ /**
1992
+ * Get number of components of specified vertex format
1993
+ * @public
1994
+ */ function getVertexFormatComponentCount(fmt) {
1995
+ return vertexAttribFormatMap[fmt][4];
1996
+ }
1865
1997
  /**
1866
1998
  * Get vertex format by semantic and component type and component count
1867
1999
  * @param semantic - The vertex semantic
@@ -2043,5 +2175,5 @@ var GPUResourceUsageFlags;
2043
2175
  }
2044
2176
  }
2045
2177
 
2046
- export { GPUResourceUsageFlags, MAX_BINDING_GROUPS, MAX_TEXCOORD_INDEX_COUNT, MAX_VERTEX_ATTRIBUTES, VERTEX_ATTRIB_BLEND_INDICES, VERTEX_ATTRIB_BLEND_WEIGHT, VERTEX_ATTRIB_DIFFUSE, VERTEX_ATTRIB_NORMAL, VERTEX_ATTRIB_POSITION, VERTEX_ATTRIB_TANGENT, VERTEX_ATTRIB_TEXCOORD0, VERTEX_ATTRIB_TEXCOORD1, VERTEX_ATTRIB_TEXCOORD2, VERTEX_ATTRIB_TEXCOORD3, VERTEX_ATTRIB_TEXCOORD4, VERTEX_ATTRIB_TEXCOORD5, VERTEX_ATTRIB_TEXCOORD6, VERTEX_ATTRIB_TEXCOORD7, genDefaultName, getVertexAttribByName, getVertexAttribFormat, getVertexAttribName, getVertexBufferAttribType, getVertexBufferAttribTypeBySemantic, getVertexBufferLength, getVertexBufferStride, getVertexFormatSize, makeVertexBufferType, semanticList, semanticToAttrib };
2178
+ export { GPUResourceUsageFlags, MAX_BINDING_GROUPS, MAX_TEXCOORD_INDEX_COUNT, MAX_VERTEX_ATTRIBUTES, VERTEX_ATTRIB_BLEND_INDICES, VERTEX_ATTRIB_BLEND_WEIGHT, VERTEX_ATTRIB_DIFFUSE, VERTEX_ATTRIB_NORMAL, VERTEX_ATTRIB_POSITION, VERTEX_ATTRIB_TANGENT, VERTEX_ATTRIB_TEXCOORD0, VERTEX_ATTRIB_TEXCOORD1, VERTEX_ATTRIB_TEXCOORD2, VERTEX_ATTRIB_TEXCOORD3, VERTEX_ATTRIB_TEXCOORD4, VERTEX_ATTRIB_TEXCOORD5, VERTEX_ATTRIB_TEXCOORD6, VERTEX_ATTRIB_TEXCOORD7, genDefaultName, getVertexAttribByName, getVertexAttribFormat, getVertexAttribName, getVertexBufferAttribType, getVertexBufferAttribTypeBySemantic, getVertexBufferLength, getVertexBufferStride, getVertexFormatComponentCount, getVertexFormatSize, makeVertexBufferType, semanticList, semanticToAttrib };
2047
2179
  //# sourceMappingURL=gpuobject.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"gpuobject.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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