hilo3d 1.17.0 → 1.18.0

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hilo3d",
3
- "version": "1.17.0",
3
+ "version": "1.18.0",
4
4
  "description": "Hilo3d, a WebGL 3d engine.",
5
5
  "main": "build/Hilo3d.js",
6
6
  "types": "types/index.d.ts",
@@ -57,7 +57,7 @@
57
57
  "gulp": "^4.0.2",
58
58
  "gulp-concat": "^2.6.1",
59
59
  "gulp-replace": "^1.0.0",
60
- "gulp-uitest": "^1.0.0",
60
+ "gulp-uitest": "^13.0.0",
61
61
  "jsdoc": "^3.6.4",
62
62
  "mocha": "^5.2.0",
63
63
  "raw-loader": "^0.5.1",
package/types/index.d.ts CHANGED
@@ -1484,6 +1484,26 @@ namespace math {
1484
1484
  function nextPowerOfTwo(value: number): number;
1485
1485
  }
1486
1486
 
1487
+ /**
1488
+ */
1489
+ type AttachmentInfo = {
1490
+ attachmentType: 'TEXTURE' | 'RENDERBUFFER';
1491
+ framebufferTarget: GLenum;
1492
+ attachment: GLenum;
1493
+ samples: number;
1494
+ target: GLenum;
1495
+ internalFormat: GLenum;
1496
+ format: GLenum;
1497
+ type: GLenum;
1498
+ minFilter: GLenum;
1499
+ magFilter: GLenum;
1500
+ wrapS: GLenum;
1501
+ wrapT: GLenum;
1502
+ data: TypedArray;
1503
+ texture: Texture;
1504
+ renderbuffer: WebGLRenderbuffer;
1505
+ };
1506
+
1487
1507
  /**
1488
1508
  * @param mesh
1489
1509
  */
@@ -1582,8 +1602,10 @@ type EXTTextureFilterAnisotropic = any;
1582
1602
 
1583
1603
  type EXT_sRGB = any;
1584
1604
 
1605
+ type WEBGLDrawBuffers = any;
1606
+
1585
1607
  /**
1586
- * WebGL 扩展管理,默认开启的扩展有:ANGLE_instanced_arrays, OES_vertex_array_object, OES_texture_float, OES_element_index_uint, EXT_shader_texture_lod, EXT_texture_filter_anisotropic, WEBGL_lose_context
1608
+ * WebGL 扩展管理,默认开启的扩展有:ANGLE_instanced_arrays, OES_vertex_array_object, OES_texture_float, OES_element_index_uint, EXT_shader_texture_lod, EXT_texture_filter_anisotropic, WEBGL_lose_context, WEBGL_draw_buffers
1587
1609
  */
1588
1610
  namespace extensions {
1589
1611
  /**
@@ -1594,6 +1616,10 @@ namespace extensions {
1594
1616
  * OES_vertex_array_object扩展
1595
1617
  */
1596
1618
  var vao: OESVertexArrayObject;
1619
+ /**
1620
+ * WEBGL_draw_buffers扩展
1621
+ */
1622
+ var drawBuffers: WEBGLDrawBuffers;
1597
1623
  /**
1598
1624
  * OES_texture_float扩展
1599
1625
  */
@@ -3186,6 +3212,22 @@ class VertexArrayObject {
3186
3212
  destroy(): VertexArrayObject;
3187
3213
  }
3188
3214
 
3215
+ /**
3216
+ * Uniform Buffer Object
3217
+ */
3218
+ class UniformBuffer {
3219
+ className: string;
3220
+ isUniformBuffer: boolean;
3221
+ /**
3222
+ * is dirty
3223
+ */
3224
+ isDirty: boolean;
3225
+ /**
3226
+ * data
3227
+ */
3228
+ data: TypedArray | ArrayBuffer;
3229
+ }
3230
+
3189
3231
  /**
3190
3232
  * 渲染列表
3191
3233
  */
@@ -3302,6 +3344,10 @@ class Program {
3302
3344
  * uniform 集合
3303
3345
  */
3304
3346
  uniforms: any;
3347
+ /**
3348
+ * uniformBlock 集合
3349
+ */
3350
+ uniformBlocks: any;
3305
3351
  /**
3306
3352
  * program
3307
3353
  */
@@ -3388,6 +3434,10 @@ class Framebuffer {
3388
3434
  * bufferInternalFormat
3389
3435
  */
3390
3436
  bufferInternalFormat: GLenum;
3437
+ /**
3438
+ * framebufferTarget
3439
+ */
3440
+ framebufferTarget: GLenum;
3391
3441
  /**
3392
3442
  * texture target
3393
3443
  */
@@ -3452,6 +3502,14 @@ class Framebuffer {
3452
3502
  * framebuffer
3453
3503
  */
3454
3504
  framebuffer: WebGLFramebuffer;
3505
+ /**
3506
+ * colorAttachmentInfos
3507
+ */
3508
+ colorAttachmentInfos: AttachmentInfo[];
3509
+ /**
3510
+ * depthStencilAttachmentInfo
3511
+ */
3512
+ depthStencilAttachmentInfo: AttachmentInfo;
3455
3513
  /**
3456
3514
  * init
3457
3515
  */
@@ -3492,6 +3550,10 @@ class Framebuffer {
3492
3550
  * @param [height = 1]
3493
3551
  */
3494
3552
  readPixels(x: number, y: number, width?: number, height?: number): TypedArray;
3553
+ /**
3554
+ * copy framebuffer
3555
+ */
3556
+ copyFramebuffer(): void;
3495
3557
  /**
3496
3558
  * 销毁资源
3497
3559
  * @returns this
@@ -6203,6 +6265,10 @@ class Material {
6203
6265
  * 是否开启 texture lod
6204
6266
  */
6205
6267
  enableTextureLod: boolean;
6268
+ /**
6269
+ * 是否开启 drawBuffers
6270
+ */
6271
+ enableDrawBuffers: boolean;
6206
6272
  /**
6207
6273
  * 是否需要加基础 uniforms
6208
6274
  */