window.XenoGL=function(t){function e(i){if(_[i])return _[i].exports;var r=_[i]={i:i,l:!1,exports:{}};return t[i].call(r.exports,r,r.exports,e),r.l=!0,r.exports}var _={};return e.m=t,e.c=_,e.d=function(t,_,i){e.o(t,_)||Object.defineProperty(t,_,{configurable:!1,enumerable:!0,get:i})},e.n=function(t){var _=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(_,"a",_),_},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="",e(e.s=2)}([function(t,e,_){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.TIMEOUT_IGNORED=-1,e.ZERO=0,e.NO_ERROR=0,e.NONE=0,e.ONE=1,e.POINTS=0,e.SYNC_FLUSH_COMMANDS_BIT=1,e.DEPTH_BUFFER_BIT=256,e.STENCIL_BUFFER_BIT=1024,e.COLOR_BUFFER_BIT=16384,e.LINES=1,e.LINE_LOOP=2,e.LINE_STRIP=3,e.TRIANGLES=4,e.TRIANGLE_STRIP=5,e.TRIANGLE_FAN=6,e.NEVER=512,e.LESS=513,e.EQUAL=514,e.LEQUAL=515,e.GREATER=516,e.NOTEQUAL=517,e.GEQUAL=518,e.ALWAYS=519,e.SRC_COLOR=768,e.ONE_MINUS_SRC_COLOR=769,e.SRC_ALPHA=770,e.ONE_MINUS_SRC_ALPHA=771,e.DST_ALPHA=772,e.ONE_MINUS_DST_ALPHA=773,e.DST_COLOR=774,e.ONE_MINUS_DST_COLOR=775,e.SRC_ALPHA_SATURATE=776,e.FRONT=1028,e.BACK=1029,e.FRONT_AND_BACK=1032,e.INVALID_ENUM=1280,e.INVALID_VALUE=1281,e.INVALID_OPERATION=1282,e.OUT_OF_MEMORY=1285,e.INVALID_FRAMEBUFFER_OPERATION=1286,e.CW=2304,e.CCW=2305,e.LINE_WIDTH=2849,e.CULL_FACE=2884,e.CULL_FACE_MODE=2885,e.FRONT_FACE=2886,e.DEPTH_RANGE=2928,e.DEPTH_TEST=2929,e.DEPTH_WRITEMASK=2930,e.DEPTH_CLEAR_VALUE=2931,e.DEPTH_FUNC=2932,e.STENCIL_TEST=2960,e.STENCIL_CLEAR_VALUE=2961,e.STENCIL_FUNC=2962,e.STENCIL_VALUE_MASK=2963,e.STENCIL_FAIL=2964,e.STENCIL_PASS_DEPTH_FAIL=2965,e.STENCIL_PASS_DEPTH_PASS=2966,e.STENCIL_REF=2967,e.STENCIL_WRITEMASK=2968,e.VIEWPORT=2978,e.DITHER=3024,e.BLEND=3042,e.READ_BUFFER=3074,e.SCISSOR_BOX=3088,e.SCISSOR_TEST=3089,e.COLOR_CLEAR_VALUE=3106,e.COLOR_WRITEMASK=3107,e.UNPACK_ROW_LENGTH=3314,e.UNPACK_SKIP_ROWS=3315,e.UNPACK_SKIP_PIXELS=3316,e.UNPACK_ALIGNMENT=3317,e.PACK_ROW_LENGTH=3330,e.PACK_SKIP_ROWS=3331,e.PACK_SKIP_PIXELS=3332,e.PACK_ALIGNMENT=3333,e.MAX_TEXTURE_SIZE=3379,e.MAX_VIEWPORT_DIMS=3386,e.SUBPIXEL_BITS=3408,e.RED_BITS=3410,e.GREEN_BITS=3411,e.BLUE_BITS=3412,e.ALPHA_BITS=3413,e.DEPTH_BITS=3414,e.STENCIL_BITS=3415,e.TEXTURE_2D=3553,e.DONT_CARE=4352,e.FASTEST=4353,e.NICEST=4354,e.BYTE=5120,e.UNSIGNED_BYTE=5121,e.SHORT=5122,e.UNSIGNED_SHORT=5123,e.INT=5124,e.UNSIGNED_INT=5125,e.FLOAT=5126,e.HALF_FLOAT=5131,e.INVERT=5386,e.TEXTURE=5890,e.COLOR=6144,e.DEPTH=6145,e.STENCIL=6146,e.STENCIL_INDEX=6401,e.DEPTH_COMPONENT=6402,e.RED=6403,e.ALPHA=6406,e.RGB=6407,e.RGBA=6408,e.LUMINANCE=6409,e.LUMINANCE_ALPHA=6410,e.KEEP=7680,e.REPLACE=7681,e.INCR=7682,e.DECR=7683,e.VENDOR=7936,e.RENDERER=7937,e.VERSION=7938,e.NEAREST=9728,e.LINEAR=9729,e.NEAREST_MIPMAP_NEAREST=9984,e.LINEAR_MIPMAP_NEAREST=9985,e.NEAREST_MIPMAP_LINEAR=9986,e.LINEAR_MIPMAP_LINEAR=9987,e.TEXTURE_MAG_FILTER=10240,e.TEXTURE_MIN_FILTER=10241,e.TEXTURE_WRAP_S=10242,e.TEXTURE_WRAP_T=10243,e.REPEAT=10497,e.POLYGON_OFFSET_UNITS=10752,e.CONSTANT_COLOR=32769,e.ONE_MINUS_CONSTANT_COLOR=32770,e.CONSTANT_ALPHA=32771,e.ONE_MINUS_CONSTANT_ALPHA=32772,e.BLEND_COLOR=32773,e.FUNC_ADD=32774,e.MIN=32775,e.MAX=32776,e.BLEND_EQUATION=32777,e.BLEND_EQUATION_RGB=32777,e.FUNC_SUBSTRACT=32778,e.FUNC_REVERSE_SUBTRACT=32779,e.UNSIGNED_SHORT_4_4_4_4=32819,e.UNSIGNED_SHORT_5_5_5_1=32820,e.POLYGON_OFFSET_FILL=32823,e.POLYGON_OFFSET_FACTOR=32824,e.RGB8=32849,e.RGBA4=32854,e.RGB5_A1=32855,e.RGBA8=32856,e.RGB10_A2=32857,e.TEXTURE_BINDING_2D=32873,e.TEXTURE_BINDING_3D=32874,e.UNPACK_SKIP_IMAGES=32877,e.UNPACK_IMAGE_HEIGHT=32878,e.TEXTURE_3D=32879,e.TEXTURE_WRAP_R=32882,e.MAX_3D_TEXTURE_SIZE=32883,e.SAMPLE_ALPHA_TO_COVERAGE=32926,e.SAMPLE_COVERAGE=32928,e.SAMPLE_BUFFERS=32936,e.SAMPLES=32937,e.SAMPLE_COVERAGE_VALUE=32938,e.SAMPLE_COVERAGE_INVERT=32939,e.BLEND_DST_RGB=32968,e.BLEND_SRC_RGB=32969,e.BLEND_DST_ALPHA=32970,e.BLEND_SRC_ALPHA=32971,e.MAX_ELEMENTS_VERTICES=33e3,e.MAX_ELEMENTS_INDICES=33001,e.CLAMP_TO_EDGE=33071,e.TEXTURE_MIN_LOD=33082,e.TEXTURE_MAX_LOD=33083,e.TEXTURE_BASE_LEVEL=33084,e.TEXTURE_MAX_LEVEL=33085,e.GENERATE_MIPMAP_HINT=33170,e.DEPTH_COMPONENT16=33189,e.DEPTH_COMPONENT24=33190,e.FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING=33296,e.FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE=33297,e.FRAMEBUFFER_ATTACHMENT_RED_SIZE=33298,e.FRAMEBUFFER_ATTACHMENT_GREEN_SIZE=33299,e.FRAMEBUFFER_ATTACHMENT_BLUE_SIZE=33300,e.FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE=33301,e.FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE=33302,e.FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE=33303,e.FRAMEBUFFER_DEFAULT=33304,e.DEPTH_STENCIL_ATTACHMENT=33306,e.RG=33319,e.RG_INTEGER=33320,e.R8=33321,e.RG8=33323,e.R16F=33325,e.R32F=33326,e.RG16F=33327,e.RG32F=33328,e.R8I=33329,e.R8UI=33330,e.R16I=33331;e.R16UI=33332,e.R32I=33333,e.R32UI=33334,e.RG8I=33335,e.RG8UI=33336,e.RG16I=33337,e.RG16UI=33338,e.RG32I=33339,e.RG32UI=33340,e.TEXTURE_IMMUTABLE_LEVELS=33503,e.UNSIGNED_SHORT_5_6_5=33635,e.UNSIGNED_INT_2_10_10_10_REV=33640,e.MIRRORED_REPEAT=33648,e.ALIASED_POINT_SIZE_RANGE=33901,e.ALIASED_LINE_WIDTH_RANGE=33902,e.TEXTURE0=33984,e.TEXTURE1=33985,e.TEXTURE2=33986,e.TEXTURE3=33987,e.TEXTURE4=33988,e.TEXTURE5=33989,e.TEXTURE6=33990,e.TEXTURE7=33991,e.TEXTURE8=33992,e.TEXTURE9=33993,e.TEXTURE10=33994,e.TEXTURE11=33995,e.TEXTURE12=33996,e.TEXTURE13=33997,e.TEXTURE14=33998,e.TEXTURE15=33999,e.TEXTURE16=34e3,e.TEXTURE17=34001,e.TEXTURE18=34002,e.TEXTURE19=34003,e.TEXTURE20=34004,e.TEXTURE21=34005,e.TEXTURE22=34006,e.TEXTURE23=34007,e.TEXTURE24=34008,e.TEXTURE25=34009,e.TEXTURE26=34010,e.TEXTURE27=34011,e.TEXTURE28=34012,e.TEXTURE29=34013,e.TEXTURE30=34014,e.TEXTURE31=33999,e.ACTIVE_TEXTURE=34016,e.MAX_RENDERBUFFER_SIZE=34024,e.DEPTH_STENCIL=34041,e.UNSIGNED_INT_24_8=34042,e.MAX_TEXTURE_LOD_BIAS=34045,e.INCR_WRAP=34055,e.DECR_WRAP=34056,e.TEXTURE_CUBE_MAP=34067,e.TEXTURE_BINDING_CUBE_MAP=34068,e.TEXTURE_CUBE_MAP_POSITIVE_X=34069,e.TEXTURE_CUBE_MAP_NEGATIVE_X=34070,e.TEXTURE_CUBE_MAP_POSITIVE_Y=34071,e.TEXTURE_CUBE_MAP_NEGATIVE_Y=34072,e.TEXTURE_CUBE_MAP_POSITIVE_Z=34073,e.TEXTURE_CUBE_MAP_NEGATIVE_Z=34074,e.MAX_CUBE_MAP_TEXTURE_SIZE=34076,e.VERTEX_ARRAY_BINDING=34229,e.VERTEX_ATTRIB_ARRAY_ENABLED=34338,e.VERTEX_ATTRIB_ARRAY_SIZE=34339,e.VERTEX_ATTRIB_ARRAY_STRIDE=34340,e.VERTEX_ATTRIB_ARRAY_TYPE=34341,e.CURRENT_VERTEX_ATTRIB=34342,e.VERTEX_ATTRIB_ARRAY_POINTER=34373,e.COMPRESSED_TEXTURE_FORMATS=34467,e.BUFFER_SIZE=34660,e.BUFFER_USAGE=34661,e.STENCIL_BACK_FUNC=34816,e.STENCIL_BACK_FAIL=34817,e.STENCIL_BACK_PASS_DEPTH_FAIL=34818,e.STENCIL_BACK_PASS_DEPTH_PASS=34819,e.RGBA32F=34836,e.RGB32F=34837,e.RGBA16F=34842,e.RGB16F=34843,e.MAX_DRAW_BUFFERS=34852,e.DRAW_BUFFER0=34853,e.DRAW_BUFFER1=34854,e.DRAW_BUFFER2=34855,e.DRAW_BUFFER3=34856,e.DRAW_BUFFER4=34857,e.DRAW_BUFFER5=34858,e.DRAW_BUFFER6=34859,e.DRAW_BUFFER7=34860,e.DRAW_BUFFER8=34861,e.DRAW_BUFFER9=34862,e.DRAW_BUFFER10=34863,e.DRAW_BUFFER11=34864,e.DRAW_BUFFER12=34865,e.DRAW_BUFFER13=34866,e.DRAW_BUFFER14=34867,e.DRAW_BUFFER15=34868,e.BLEND_EQUATION_ALPHA=34877,e.TEXTURE_COMPARE_MODE=34892,e.TEXTURE_COMPARE_FUNC=34893,e.COMPARE_REF_TO_TEXTURE=34894,e.CURRENT_QUERY=34917,e.QUERY_RESULT=34918,e.QUERY_RESULT_AVAILABLE=34919,e.MAX_VERTEX_ATTRIBS=34921,e.VERTEX_ATTRIB_ARRAY_NORMALIZED=34922,e.MAX_TEXTURE_IMAGE_UNITS=34930,e.ARRAY_BUFFER=34962,e.ELEMENT_ARRAY_BUFFER=34963,e.ARRAY_BUFFER_BINDING=34964,e.ELEMENT_ARRAY_BUFFER_BINDING=34965,e.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING=34975,e.STREAM_DRAW=35040,e.STREAM_READ=35041,e.STREAM_COPY=35042,e.STATIC_DRAW=35044,e.STATIC_READ=35045,e.STATIC_COPY=35046,e.DYNAMIC_DRAW=35048,e.DYNAMIC_READ=35049,e.DYNAMIC_COPY=35050,e.PIXEL_PACK_BUFFER=35051,e.PIXEL_UNPACK_BUFFER=35052,e.PIXEL_PACK_BUFFER_BINDING=35053,e.PIXEL_UNPACK_BUFFER_BINDING=35055,e.DEPTH24_STENCIL8=35056,e.VERTEX_ATTRIB_ARRAY_INTEGER=35069,e.VERTEX_ATTRIB_ARRAY_DIVISOR=35070,e.MAX_ARRAY_TEXTURE_LAYERS=35071,e.MIN_PROGRAM_TEXEL_OFFSET=35076,e.MAX_PROGRAM_TEXEL_OFFSET=35077,e.SAMPLER_BINDING=35097,e.UNIFORM_BUFFER=35345,e.UNIFORM_BUFFER_BINDING=35368,e.UNIFORM_BUFFER_START=35369,e.UNIFORM_BUFFER_SIZE=35370,e.MAX_VERTEX_UNIFORM_BLOCKS=35371,e.MAX_FRAGMENT_UNIFORM_BLOCKS=35373,e.MAX_COMBINED_UNIFORM_BLOCKS=35374,e.MAX_UNIFORM_BUFFER_BINDINGS=35375,e.MAX_UNIFORM_BLOCK_SIZE=35376,e.MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS=35377,e.MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS=35379,e.UNIFORM_BUFFER_OFFSET_ALIGNMENT=35380,e.ACTIVE_UNIFORM_BLOCKS=35382,e.UNIFORM_TYPE=35383,e.UNIFORM_SIZE=35384,e.UNIFORM_BLOCK_INDEX=35386,e.UNIFORM_OFFSET=35387,e.UNIFORM_ARRAY_STRIDE=35388,e.UNIFORM_MATRIX_STRIDE=35389,e.UNIFORM_IS_ROW_MAJOR=35390,e.UNIFORM_BLOCK_BINDING=35391,e.UNIFORM_BLOCK_DATA_SIZE=35392,e.UNIFORM_BLOCK_ACTIVE_UNIFORMS=35394,e.UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES=35395,e.UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER=35396,e.UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER=35398,e.FRAGMENT_SHADER=35632,e.VERTEX_SHADER=35633,e.MAX_FRAGMENT_UNIFORM_COMPONENTS=35657,e.MAX_VERTEX_UNIFORM_COMPONENTS=35658,e.MAX_VARYING_COMPONENTS=35659,e.MAX_VERTEX_TEXTURE_IMAGE_UNITS=35660,e.MAX_COMBINED_TEXTURE_IMAGE_UNITS=35661,e.SHADER_TYPE=35663,e.FLOAT_VEC2=35664,e.FLOAT_VEC3=35665,e.FLOAT_VEC4=35666,e.INT_VEC2=35667,e.INT_VEC3=35668,e.INT_VEC4=35669,e.BOOL=35670,e.BOOL_VEC2=35671,e.BOOL_VEC3=35672,e.BOOL_VEC4=35673,e.FLOAT_MAT2=35674,e.FLOAT_MAT3=35675,e.FLOAT_MAT4=35676,e.SAMPLER_2D=35678,e.SAMPLER_3D=35679,e.SAMPLER_CUBE=35680,e.SAMPLER_2D_SHADOW=35682,e.FLOAT_MAT2x3=35685,e.FLOAT_MAT2x4=35686,e.FLOAT_MAT3x2=35687,e.FLOAT_MAT3x4=35688,e.FLOAT_MAT4x2=35689,e.FLOAT_MAT4x3=35690,e.DELETE_STATUS=35712,e.COMPILE_STATUS=35713,e.LINK_STATUS=35714,e.VALIDATE_STATUS=35715,e.ATTACHED_SHADERS=35717,e.ACTIVE_UNIFORMS=35718,e.ACTIVE_ATTRIBUTES=35721,e.FRAGMENT_SHADER_DERIVATIVE_HINT=35723,e.SHADING_LANGUAGE_VERSION=35724,e.CURRENT_PROGRAM=35725;e.IMPLEMENTATION_COLOR_READ_TYPE=35738,e.IMPLEMENTATION_COLOR_READ_FORMAT=35739,e.UNSIGNED_NORMALIZED=35863,e.TEXTURE_2D_ARRAY=35866,e.TEXTURE_BINDING_2D_ARRAY=35869,e.ANY_SAMPLES_PASSED=35887,e.R11F_G11F_B10F=35898,e.UNSIGNED_INT_10F_11F_11F_REV=35899,e.RGB9_E5=35901,e.UNSIGNED_INT_5_9_9_9_REV=35902,e.SRGB=35904,e.SRGB8=35905,e.SRGB8_ALPHA8=35907,e.TRANSFORM_FEEDBACK_BUFFER_MODE=35967,e.MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS=35968,e.TRANSFORM_FEEDBACK_VARYINGS=35971,e.TRANSFORM_FEEDBACK_BUFFER_START=35972,e.TRANSFORM_FEEDBACK_BUFFER_SIZE=35973,e.TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN=35976,e.RASTERIZER_DISCARD=35977,e.MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS=35978,e.MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS=35979,e.INTERLEAVED_ATTRIBS=35980,e.SEPARATE_ATTRIBS=35981,e.TRANSFORM_FEEDBACK_BUFFER=35982,e.TRANSFORM_FEEDBACK_BUFFER_BINDING=35983,e.STENCIL_BACK_REF=36003,e.STENCIL_BACK_VALUE_MASK=36004,e.STENCIL_BACK_WRITEMASK=36005,e.FRAMEBUFFER_BINDING=36006,e.DRAW_FRAMEBUFFER_BINDING=36006,e.RENDERBUFFER_BINDING=36007,e.READ_FRAMEBUFFER=36008,e.DRAW_FRAMEBUFFER=36009,e.READ_FRAMEBUFFER_BINDING=36010,e.RENDERBUFFER_SAMPLES=36011,e.DEPTH_COMPONENT32F=36012,e.DEPTH32F_STENCIL8=36013,e.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE=36048,e.FRAMEBUFFER_ATTACHMENT_OBJECT_NAME=36049,e.FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL=36050,e.FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE=36051,e.FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER=36052,e.FRAMEBUFFER_COMPLETE=36053,e.FRAMEBUFFER_INCOMPLETE_ATTACHMENT=36054,e.FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT=36055,e.FRAMEBUFFER_INCOMPLETE_DIMENSIONS=36057,e.FRAMEBUFFER_UNSUPPORTED=36061,e.MAX_COLOR_ATTACHMENTS=36063,e.COLOR_ATTACHMENT0=36064,e.COLOR_ATTACHMENT1=36065,e.COLOR_ATTACHMENT2=36066,e.COLOR_ATTACHMENT3=36067,e.COLOR_ATTACHMENT4=36068,e.COLOR_ATTACHMENT5=36069,e.COLOR_ATTACHMENT6=36070,e.COLOR_ATTACHMENT7=36071,e.COLOR_ATTACHMENT8=36072,e.COLOR_ATTACHMENT9=36073,e.COLOR_ATTACHMENT10=36074,e.COLOR_ATTACHMENT11=36075,e.COLOR_ATTACHMENT12=36076,e.COLOR_ATTACHMENT13=36077,e.COLOR_ATTACHMENT14=36078,e.COLOR_ATTACHMENT15=36079,e.DEPTH_ATTACHMENT=36096,e.STENCIL_ATTACHMENT=36128,e.FRAMEBUFFER=36160,e.RENDERBUFFER=36161,e.RENDERBUFFER_WIDTH=36162,e.RENDERBUFFER_HEIGHT=36163,e.RENDERBUFFER_INTERNAL_FORMAT=36164,e.STENCIL_INDEX8=36168,e.RENDERBUFFER_RED_SIZE=36176,e.RENDERBUFFER_GREEN_SIZE=36177,e.RENDERBUFFER_BLUE_SIZE=36178,e.RENDERBUFFER_ALPHA_SIZE=36179,e.RENDERBUFFER_DEPTH_SIZE=36180,e.RENDERBUFFER_STENCIL_SIZE=36181,e.FRAMEBUFFER_INCOMPLETE_MULTISAMPLE=36182,e.MAX_SAMPLES=36183,e.RGB565=36194,e.ANY_SAMPLES_PASSED_CONSERVATIVE=36202,e.MAX_ELEMENT_INDEX=36203,e.RGBA32UI=36208,e.RGB32UI=36209,e.RGBA16UI=36214,e.RGB16UI=36215,e.RGBA8UI=36220,e.RGB8UI=36221,e.RGBA32I=36226,e.RGB32I=36227,e.RGBA16I=36232,e.RGB16I=36233,e.RGBA8I=36238,e.RGB8I=36239,e.RED_INTEGER=36244,e.RGB_INTEGER=36248,e.RGBA_INTEGER=36249,e.INT_2_10_10_10_REV=36255,e.FLOAT_32_UNSIGNED_INT_24_8_REV=36269,e.SAMPLER_2D_ARRAY=36289,e.SAMPLER_2D_ARRAY_SHADOW=36292,e.SAMPLER_CUBE_SHADOW=36293,e.UNSIGNED_INT_VEC2=36294,e.UNSIGNED_INT_VEC3=36295,e.UNSIGNED_INT_VEC4=36296,e.INT_SAMPLER_2D=36298,e.INT_SAMPLER_3D=36299,e.INT_SAMPLER_CUBE=36300,e.INT_SAMPLER_2D_ARRAY=36303,e.UNSIGNED_INT_SAMPLER_2D=36306,e.UNSIGNED_INT_SAMPLER_3D=36307,e.UNSIGNED_INT_SAMPLER_CUBE=36308,e.UNSIGNED_INT_SAMPLER_2D_ARRAY=36311,e.LOW_FLOAT=36336,e.MEDIUM_FLOAT=36337,e.HIGH_FLOAT=36338,e.LOW_INT=36339,e.MEDIUM_INT=36340,e.HIGH_INT=36341,e.MAX_VERTEX_UNIFORM_VECTORS=36347,e.MAX_VARYING_VECTORS=36348,e.MAX_FRAGMENT_UNIFORM_VECTORS=36349,e.TRANSFORM_FEEDBACK=36386,e.TRANSFORM_FEEDBACK_PAUSED=36387,e.TRANSFORM_FEEDBACK_ACTIVE=36388,e.TRANSFORM_FEEDBACK_BINDING=36389,e.COPY_READ_BUFFER=36662,e.COPY_READ_BUFFER_BINDING=36662,e.COPY_WRITE_BUFFER=36663,e.COPY_WRITE_BUFFER_BINDING=36663,e.R8_SNORM=36756,e.RG8_SNORM=36757,e.RGB8_SNORM=36758,e.RGBA8_SNORM=36759,e.SIGNED_NORMALIZED=36764,e.RGB10_A2UI=36975,e.MAX_SERVER_WAIT_TIMEOUT=37137,e.OBJECT_TYPE=37138,e.SYNC_CONDITION=37139,e.SYNC_STATUS=37140,e.SYNC_FLAGS=37141,e.SYNC_FENCE=37142,e.SYNC_GPU_COMMANDS_COMPLETE=37143,e.UNSIGNALED=37144,e.SIGNALED=37145,e.ALREADY_SIGNALED=37146,e.TIMEOUT_EXPIRED=37147,e.CONDITION_SATISFIED=37148,e.WAIT_FAILED=37149,e.MAX_VERTEX_OUTPUT_COMPONENTS=37154,e.MAX_FRAGMENT_INPUT_COMPONENTS=37157,e.TEXTURE_IMMUTABLE_FORMAT=37167,e.UNPACK_FLIP_Y_WEBGL=37440,e.UNPACK_PREMULTIPLY_ALPHA_WEBGL=37441,e.CONTEXT_LOST_WEBGL=37442,e.UNPACK_COLORSPACE_CONVERSION_WEBGL=37443,e.BROWSER_DEFAULT_WEBGL=37444,e.MAX_CLIENT_WAIT_TIMEOUT_WEBGL=37447,e.INVALID_INDEX=4294967295},function(t,e,_){"use strict";var i=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var _ in e)e.hasOwnProperty(_)&&(t[_]=e[_])};return function(e,_){function i(){this.constructor=e}t(e,_),e.prototype=null===_?Object.create(_):(i.prototype=_.prototype,new i)}}();Object.defineProperty(e,"__esModule",{value:!0});var r=_(0),E=_(6),n=function(){function t(t,e){void 0===t&&(t={dataOrLength:null,attributes:[],dataType:r.FLOAT,usage:r.STATIC_DRAW}),this._glContext=null,this._glProgram=null,this._glBuffer=null,this._dataOrLength="dataOrLength"in t?t.dataOrLength:null,this._attributes="attributes"in t?t.attributes:[],this._enabledAttributes=this._attributes,this._attributeToLocation=new Map,this._dataType="dataType"in t?t.dataType:r.FLOAT,this._usage="usage"in t?t.usage:r.STATIC_DRAW,this._bufferType=e,this._isInitialized=!1,this._flushData=function(t,e){},this._totalAttributesSize=this._attributes.reduce(function(t,e){return t+e.size},0),this._data=null,null!==this._dataOrLength&&this.bufferData(this._dataOrLength)}return t.prototype.bufferData=function(t){var e=this;this._flushData=function(_,i){if(e._dataOrLength=t,_.bindBuffer(e._bufferType,i),"number"==typeof t){var r=t*E.getBytesPerElementByGlType(e._dataType);_.bufferData(e._bufferType,r,e._usage)}else _.bufferData(e._bufferType,t,e._usage),e._data=t;_.bindBuffer(e._bufferType,null)},this._flush()},t.prototype.activate=function(){this._enableAttributes()},t.prototype.deactivate=function(){this._disableAttributes()},t.prototype._flush=function(){null!==this._glContext&&null!==this._glBuffer&&this._flushData(this._glContext,this._glBuffer)},t.prototype._initAttributes=function(t,e,_){var i=this;void 0===_&&(_=null),this._enabledAttributes=this._attributes,null!==_&&(this._enabledAttributes=_),this._attributes.forEach(function(_){var r=t.getAttribLocation(e,_.name);i._attributeToLocation.set(_,r)});for(var r=E.getBytesPerElementByGlType(this._dataType),n=r*this._totalAttributesSize,T=0,o=this,R=0;R<this._attributes.length;R++)!function(e){var _=o._attributes[e],i=o._attributeToLocation.get(_);o._enabledAttributes.find(function(t){return t.equals(_)})&&(t.enableVertexAttribArray(i),t.vertexAttribPointer(i,_.size,o._dataType,!1,n,T)),T+=_.size*r}(R)},t.prototype._enableAttributes=function(){if(null!==this._glContext){var t=this._glContext,e=this._glProgram;t.bindBuffer(this.bufferType,this._glBuffer),this._initAttributes(t,e,this._enabledAttributes),t.bindBuffer(this.bufferType,null)}},t.prototype._disableAttributes=function(){var t=this;if(null!==this._glContext){var e=this._glContext;this._enabledAttributes.forEach(function(_){var i=t._attributeToLocation.get(_);e.disableVertexAttribArray(i)})}},t.prototype._init=function(t,e,_){void 0===e&&(e=null),void 0===_&&(_=null);var i=t.createBuffer();t.bindBuffer(this._bufferType,i),null!==e&&this._initAttributes(t,e,_),this._glContext=t,this._glProgram=e,this._glBuffer=i,this._flush(),t.bindBuffer(this._bufferType,null),this._isInitialized=!0},t.prototype._initOnce=function(t,e,_){void 0===e&&(e=null),void 0===_&&(_=null),this.isInitialized||this._init(t,e,_)},t.prototype._createWebGLVertexArrayObject=function(t,e,_){void 0===e&&(e=null),void 0===_&&(_=null);var i=this._glBuffer,r=t.createVertexArray();return t.bindVertexArray(r),t.bindBuffer(this._bufferType,i),null!==e&&this._initAttributes(t,e,_),null!==this._dataOrLength&&"number"==typeof this._dataOrLength?t.bufferData(this._bufferType,this._dataOrLength,this._usage):null!==this._dataOrLength&&t.bufferData(this._bufferType,this._dataOrLength,this._usage),t.bindBuffer(this._bufferType,null),t.bindVertexArray(null),r},Object.defineProperty(t.prototype,"data",{get:function(){return this._data},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"dataType",{get:function(){return this._dataType},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"dataCount",{get:function(){return null!==this.data?this.data.length/this._totalAttributesSize:0},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"usage",{get:function(){return this._usage},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"isInitialized",{get:function(){return this._isInitialized},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"totalAttributesSize",{get:function(){return this._totalAttributesSize},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"bufferType",{get:function(){return this._bufferType},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"glBuffer",{get:function(){if(this.isInitialized)return this._glBuffer;throw new Error("This buffer is not initialized yet.")},enumerable:!0,configurable:!0}),t}();e.BufferBase=n;var T=function(t){function e(e){return void 0===e&&(e={dataOrLength:null,attributes:[],dataType:r.FLOAT,usage:r.STATIC_DRAW}),t.call(this,e,r.ARRAY_BUFFER)||this}return i(e,t),e}(n);e.ArrayBuffer=T;var o=function(t){function e(e){return void 0===e&&(e={dataOrLength:null,attributes:[],dataType:r.UNSIGNED_SHORT,usage:r.STATIC_DRAW}),t.call(this,e,r.ELEMENT_ARRAY_BUFFER)||this}return i(e,t),e}(n);e.ElementArrayBuffer=o;var R=function(t){function e(e){return void 0===e&&(e={dataOrLength:null,dataType:r.UNSIGNED_SHORT,usage:r.STATIC_DRAW}),t.call(this,e,r.UNIFORM_BUFFER)||this}return i(e,t),e}(n);e.UniformBuffer=R},function(t,e,_){"use strict";function i(t){for(var _ in t)e.hasOwnProperty(_)||(e[_]=t[_])}Object.defineProperty(e,"__esModule",{value:!0}),i(_(0)),i(_(3)),i(_(4)),i(_(5)),i(_(1)),i(_(7)),i(_(8)),i(_(9)),i(_(10))},function(t,e,_){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=_(0),r=function(){function t(t){this._context=t.getContext("webgl2"),this._programs=[],this._activeProgram=null,this._transformFeedbacks=[],this._textures=[],this._activeTexture=null}return t.prototype.addProgram=function(t){t.isLinked||t._link(this._context),this._programs.push(t),null===this._activeProgram&&(this._activeProgram=t,this._context.useProgram(t.glProgram));var e=this._programs.length-1;return t.id=e,e},t.prototype.addTransformFeedback=function(t){this._transformFeedbacks.push(t),t._init(this._context)},t.prototype.addTexture=function(t){var e=this._textures.length;this._textures.push(t),t._init(this._context,e),null===this._activeTexture&&t.activate()},t.prototype.activateProgram=function(t){if(null===t.id)throw new Error("This program is not added to WebGL2 yet. Add it by using addProgram method.");this.activateProgramByID(t.id)},t.prototype.activateProgramByID=function(t){if(t>this._programs.length)throw new Error("ID "+t+" does not exist.");null!==this._activeProgram&&this._activeProgram.deactivate();var e=this._programs[t];this._context.useProgram(e.glProgram),e.activate(),this._activeProgram=e},t.prototype.useProgram=function(t){if(null===t.id)throw new Error("This program is not added to WebGL2 yet. Add it by using addProgram method.");this.useProgramByID(t.id)},t.prototype.useProgramByID=function(t){if(t>this._programs.length)throw new Error("ID "+t+" does not exist.");var e=this._programs[t];this._context.useProgram(e.glProgram),this._activeProgram=e},t.prototype.activateTexture=function(t){},t.prototype.deactivateProgram=function(t){t.deactivate()},t.prototype.draw=function(t,e){void 0===e&&(e=null),null!==this._activeProgram&&this._activeProgram.draw(t,e)},t.prototype.clear=function(t){void 0===t&&(t=i.COLOR_BUFFER_BIT),this._context.clear(t)},t.prototype.clearColor=function(t,e,_,i){this._context.clearColor(t,_,e,i)},t.prototype.enable=function(t){this._context.enable(t)},t.prototype.disable=function(t){this._context.disable(t)},t.prototype.viewport=function(t,e,_,i){this._context.viewport(t,e,_,i)},t}();e.WebGL2=r},function(t,e,_){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=_(0),r=function(){function t(t,e){this._name=t,this._size=e}return t.prototype.equals=function(t){return this.name===t.name&&this.size===t.size},Object.defineProperty(t.prototype,"name",{get:function(){return this._name},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"size",{get:function(){return this._size},enumerable:!0,configurable:!0}),t}();e.Attribute=r;var E=function(){function t(t){this._name=t,this._location=null,this._glContext=null,this._glProgram=null,this._flushData=function(t,e){}}return t.prototype.setValue=function(t,e){e===i.FLOAT?this._flushData=function(e,_){e.uniform1f(_,t)}:e===i.INT?this._flushData=function(e,_){e.uniform1i(_,t)}:e===i.UNSIGNED_INT&&(this._flushData=function(e,_){e.uniform1ui(_,t)}),this._flush()},t.prototype.setVector=function(t,e){var _=t.length;if(1===_)this.setVector1(t,e);else if(2===_)this.setVector2(t,e);else if(3===_)this.setVector3(t,e);else{if(4!==_)throw new Error("Length of value must be 1, 2, 3 or 4. Your value length is "+_);this.setVector4(t,e)}},t.prototype.setVector1=function(t,e){e===i.FLOAT?this._flushData=function(e,_){e.uniform1fv(_,t)}:e===i.INT?this._flushData=function(e,_){e.uniform1iv(_,t)}:e===i.UNSIGNED_INT&&(this._flushData=function(e,_){e.uniform1uiv(_,t)}),this._flush()},t.prototype.setVector2=function(t,e){e===i.FLOAT?this._flushData=function(e,_){e.uniform2fv(_,t)}:e===i.INT?this._flushData=function(e,_){e.uniform2iv(_,t)}:e===i.UNSIGNED_INT&&(this._flushData=function(e,_){e.uniform2uiv(_,t)}),this._flush()},t.prototype.setVector3=function(t,e){e===i.FLOAT?this._flushData=function(e,_){e.uniform3fv(_,t)}:e===i.INT?this._flushData=function(e,_){e.uniform3iv(_,t)}:e===i.UNSIGNED_INT&&(this._flushData=function(e,_){e.uniform3uiv(_,t)}),this._flush()},t.prototype.setVector4=function(t,e){e===i.FLOAT?this._flushData=function(e,_){e.uniform4fv(_,t)}:e===i.INT?this._flushData=function(e,_){e.uniform4iv(_,t)}:e===i.UNSIGNED_INT&&(this._flushData=function(e,_){e.uniform4uiv(_,t)}),this._flush()},t.prototype.setMatrix=function(t){var e=t.length;if(4===e)this.setMatrix2(t);else if(9===e)this.setMatrix3(t);else{if(16!==e)throw new Error("Failed to detect size of the matrix. If you use a non-square matrix, use setMatrixNxN instead.");this.setMatrix4(t)}},t.prototype.setMatrix2=function(t){this._flushData=function(e,_){e.uniformMatrix2fv(_,!1,t)},this._flush()},t.prototype.setMatrix3=function(t){this._flushData=function(e,_){e.uniformMatrix3fv(_,!1,t)},this._flush()},t.prototype.setMatrix4=function(t){this._flushData=function(e,_){e.uniformMatrix4fv(_,!1,t)},this._flush()},t.prototype._flush=function(){this.isLocated&&null!==this._glContext&&this._flushData(this._glContext,this._location)},t.prototype._init=function(t,e){this._location=t.getUniformLocation(e,this._name),this._glContext=t,this._glProgram=e,this._flush()},Object.defineProperty(t.prototype,"isLocated",{get:function(){return null!==this._location},enumerable:!0,configurable:!0}),t}();e.Uniform=E},function(t,e,_){"use strict";var i=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var _ in e)e.hasOwnProperty(_)&&(t[_]=e[_])};return function(e,_){function i(){this.constructor=e}t(e,_),e.prototype=null===_?Object.create(_):(i.prototype=_.prototype,new i)}}();Object.defineProperty(e,"__esModule",{value:!0});var r=_(0),E=function(){function t(t,e){this._source=t,this._glShader=null,this._isCompiled=!1,this._shaderType=e}return t.prototype._compile=function(t){var e=t.createShader(this._shaderType);if(t.shaderSource(e,this._source),t.compileShader(e),!t.getShaderParameter(e,t.COMPILE_STATUS)){var _=t.getShaderInfoLog(e);throw new Error(_)}return this._glShader=e,this._isCompiled=!0,e},Object.defineProperty(t.prototype,"isCompiled",{get:function(){return this._isCompiled},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"glShader",{get:function(){if(null===!this._glShader)throw new Error("This shader is not compiled yet.");return this._glShader},enumerable:!0,configurable:!0}),t}();e.ShaderBase=E;var n=function(t){function e(e){return t.call(this,e,r.VERTEX_SHADER)||this}return i(e,t),e}(E);e.VertexShader=n;var T=function(t){function e(e){return t.call(this,e,r.FRAGMENT_SHADER)||this}return i(e,t),e}(E);e.FragmentShader=T;var o=function(){function t(t){this._vertexShader=t.vertexShader,this._fragmentShader=t.fragmentShader,this._feedbackVaryings="feedbackVaryings"in t?t.feedbackVaryings:[],this._feedbackBufferMode="feedbackBufferMode"in t?t.feedbackBufferMode:r.INTERLEAVED_ATTRIBS,this._isLinked=!1,this._glContext=null,this._glProgram=null,this._initializedBuffers=[],this._uninitializedBuffers=[],this._initializedUniforms=[],this._uninitializedUniforms=[],this._initializedVertexArrayObjects=[],this._uninitializedVertexArrayObject=[],this._initializedUniformBufferObjects=[],this._uninitializedUniformBufferObjects=[],this._currentIndexBuffer=null,this._currentVertexArrayObject=null,this.id=null}return t.prototype.addBuffer=function(t){t.bufferType===r.ELEMENT_ARRAY_BUFFER&&(this._currentIndexBuffer=t),this.isLinked?(t._initOnce(this._glContext,this._glProgram),t.bufferType===r.ELEMENT_ARRAY_BUFFER&&null!==this._glContext&&this._glContext.bindBuffer(r.ELEMENT_ARRAY_BUFFER,t.glBuffer),this._initializedBuffers.push(t)):t.isInitialized?this._initializedBuffers.push(t):this._uninitializedBuffers.push(t)},t.prototype.activateElementArrayBuffer=function(t){this._currentIndexBuffer=t,this.isLinked&&null!==this._glContext&&this._glContext.bindBuffer(r.ELEMENT_ARRAY_BUFFER,t.glBuffer)},t.prototype.addUniform=function(t){this.isLinked?(t._init(this._glContext,this._glProgram),this._initializedUniforms.push(t)):this._uninitializedUniforms.push(t)},t.prototype.addVertexArrayObject=function(t){this.isLinked?(t._init(this._glContext,this._glProgram),this._initializedVertexArrayObjects.push(t),this._initializedBuffers.push(t.buffer)):this._uninitializedVertexArrayObject.push(t)},t.prototype.activateVertexArrayObject=function(t){if(this._currentVertexArrayObject=t,this.isLinked){this._glContext.bindVertexArray(t.glVertexArrayObject)}},t.prototype.addUniformBufferObject=function(t){if(this.isLinked){var e=this._initializedUniformBufferObjects.length;t._init(this._glContext,this._glProgram,e),this._initializedUniformBufferObjects.push(t)}else this._uninitializedUniformBufferObjects.push(t)},t.prototype.draw=function(t,e){if(void 0===e&&(e=null),null!==this._glContext)if(null!==this._currentIndexBuffer&&null!==this._currentIndexBuffer.data)this._glContext.drawElements(t,this._currentIndexBuffer.data.length,this._currentIndexBuffer.dataType,0);else if(this._initializedBuffers.length>0){var _=null!==e?e:this._initializedBuffers[0].dataCount;this._glContext.drawArrays(t,0,_)}},t.prototype.activate=function(){this._initializedBuffers.forEach(function(t){return t.activate()})},t.prototype.deactivate=function(){this._initializedBuffers.forEach(function(t){return t.deactivate()})},t.prototype._link=function(t){this._vertexShader._compile(t),this._fragmentShader._compile(t);var e=t.createProgram();if(t.attachShader(e,this._vertexShader.glShader),t.attachShader(e,this._fragmentShader.glShader),this._feedbackVaryings.length>0&&t.transformFeedbackVaryings(e,this._feedbackVaryings,this._feedbackBufferMode),t.linkProgram(e),!t.getProgramParameter(e,t.LINK_STATUS)){var _=t.getProgramInfoLog(e);throw new Error(_)}this._glContext=t,this._glProgram=e,this._isLinked=!0;for(var i=null;i=this._uninitializedBuffers.shift();)i._init(t,e),i.bufferType===r.ELEMENT_ARRAY_BUFFER&&null===this._currentIndexBuffer&&(this._currentIndexBuffer=i),this._initializedBuffers.push(i);null!==this._currentIndexBuffer&&t.bindBuffer(r.ELEMENT_ARRAY_BUFFER,this._currentIndexBuffer);for(var E=null;E=this._uninitializedUniforms.shift();)E._init(t,e),this._initializedUniforms.push(E);for(var n=null;n=this._uninitializedVertexArrayObject.shift();)n._init(t,e),this._initializedVertexArrayObjects.push(n),this._initializedBuffers.push(n.buffer);null!==this._currentVertexArrayObject&&t.bindVertexArray(this._currentVertexArrayObject.glVertexArrayObject);for(var T=null;T=this._uninitializedUniformBufferObjects.shift();){var o=this._initializedUniformBufferObjects.length;T._init(t,e,o),this._initializedUniformBufferObjects.push(T)}},Object.defineProperty(t.prototype,"isLinked",{get:function(){return this._isLinked},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"glProgram",{get:function(){if(null===this._glProgram)throw new Error("This program is not linked yet.");return this._glProgram},enumerable:!0,configurable:!0}),t}();e.Program=o},function(t,e,_){"use strict";function i(t){return t===r.FLOAT?4:t===r.BYTE||t===r.UNSIGNED_BYTE?1:t===r.SHORT||t===r.UNSIGNED_SHORT||t===r.HALF_FLOAT?2:null}Object.defineProperty(e,"__esModule",{value:!0});var r=_(0);e.getBytesPerElementByGlType=i},function(t,e,_){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=function(){function t(t,e){void 0===e&&(e={}),this._buffer=t,this._glContext=null,this._glVertexArrayObject=null,this._enabledAttributes="attributes"in e?e.attributes:null,this._mustWriteData="dataOrLength"in e,this._mustWriteData&&(this._dataOrLength=e.dataOrLength),this._isInitialized=!1}return t.prototype._init=function(t,e){this._mustWriteData&&this._buffer.bufferData(this._dataOrLength),this._buffer._initOnce(t,e,this._enabledAttributes);var _=this._buffer._createWebGLVertexArrayObject(t,e,this._enabledAttributes);this._glContext=t,this._glVertexArrayObject=_,this._isInitialized=!0},Object.defineProperty(t.prototype,"buffer",{get:function(){return this._buffer},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"glVertexArrayObject",{get:function(){if(this._isInitialized)return this._glVertexArrayObject;throw new Error("This vertex array object is not added to any program yet.")},enumerable:!0,configurable:!0}),t}();e.VertexArrayObject=i},function(t,e,_){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=_(1),r=_(0),E=function(){function t(t,e){void 0===e&&(e={dataOrLength:null,dataType:r.FLOAT,usage:r.STATIC_DRAW}),this._blockName=t,this._blockIndex=null,this._javascriptIndex=null,this._isInitialized=!1,e instanceof i.UniformBuffer?this._buffer=e:this._buffer=new i.UniformBuffer(e)}return t.prototype._init=function(t,e,_){this._blockIndex=t.getUniformBlockIndex(e,this._blockName),this._javascriptIndex=_,t.uniformBlockBinding(e,this._blockIndex,_),this._buffer._initOnce(t,e),t.bindBufferBase(r.UNIFORM_BUFFER,_,this._buffer.glBuffer)},t}();e.UniformBufferObject=E},function(t,e,_){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=_(0),r=function(){function t(){this._glContext=null,this._glTransformFeedback=null}return t.prototype.feedback=function(t){if(null===this._glContext)throw new Error("This transform feedback is not added to any WebGL2 yet.");for(var e=0;e<t.targetBuffers.length;e++)this._glContext.bindBufferBase(i.TRANSFORM_FEEDBACK_BUFFER,e,t.targetBuffers[e].glBuffer);this._glContext.beginTransformFeedback(t.mode),this._glContext.drawArrays(t.mode,0,t.count),this._glContext.endTransformFeedback();for(var e=0;e<t.targetBuffers.length;e++)this._glContext.bindBufferBase(i.TRANSFORM_FEEDBACK_BUFFER,e,null)},t.prototype._init=function(t){this._glContext=t,this._glTransformFeedback=t.createTransformFeedback(),t.bindTransformFeedback(i.TRANSFORM_FEEDBACK,this._glTransformFeedback)},t}();e.TransformFeedback=r},function(t,e,_){"use strict";var i=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var _ in e)e.hasOwnProperty(_)&&(t[_]=e[_])};return function(e,_){function i(){this.constructor=e}t(e,_),e.prototype=null===_?Object.create(_):(i.prototype=_.prototype,new i)}}();Object.defineProperty(e,"__esModule",{value:!0});var r=_(0),E=function(){function t(){}return t.prototype._getTextureIdFromNumber=function(t){return r.TEXTURE0+t},t}();e.TextureBase=E;var n=function(t){function e(e,_){void 0===_&&(_={});var i=t.call(this)||this;return i._source=e,i._glContext=null,i._glTexture=null,i._textureID=null,i._target="target"in _?_.target:r.TEXTURE_2D,i._mipmapLevel="mipmapLevel"in _?_.mipmapLevel:0,i._internalFormat="internalFormat"in _?_.internalFormat:r.RGBA,i._format="format"in _?_.mipmapLevel:r.RGBA,i._dataType="dataType"in _?_.mipmapLevel:r.UNSIGNED_BYTE,i._width="width"in _?_.width:void 0,i._height="height"in _?_.height:void 0,i._flushData=function(){},i}return i(e,t),e.prototype.activate=function(){var t=this;this._flushData=function(e){e.activeTexture(t._textureID)}},e.prototype._init=function(t,e){this._glContext=t,this._textureID=this._getTextureIdFromNumber(e),t.activeTexture(this._textureID),this._glTexture=t.createTexture(),t.bindTexture(this._target,this._glTexture),void 0===this._width||void 0===this._height?t.texImage2D(this._target,this._mipmapLevel,this._internalFormat,this._format,this._dataType,this._source):t.texImage2D(this._target,this._mipmapLevel,this._internalFormat,this._width,this._height,0,this._format,this._dataType,this._source),t.generateMipmap(this._target),this._flush()},e.prototype._flush=function(){null!==this._glContext&&(this._flushData(this._glContext),this._flushData=function(){})},e}(E);e.Texture2D=n}]);