UNPKG

@animech-public/playcanvas

Version:
2 lines (1 loc) 2.09 kB
import{DEVICETYPE_NULL as t,PIXELFORMAT_RGBA8 as e}from"../constants.js";import{GraphicsDevice as s}from"../graphics-device.js";import{NullIndexBuffer as r}from"./null-index-buffer.js";import{NullRenderTarget as i}from"./null-render-target.js";import{NullShader as a}from"./null-shader.js";import{NullTexture as o}from"./null-texture.js";import{NullVertexBuffer as p}from"./null-vertex-buffer.js";class n extends s{constructor(e,s={}){super(e,s),s=this.initOptions,this.isNull=!0,this._deviceType=t,this.samples=1}destroy(){super.destroy()}initDeviceCaps(){this.disableParticleSystem=!0,this.precision="highp",this.maxPrecision="highp",this.maxSamples=4,this.maxTextures=16,this.maxTextureSize=4096,this.maxCubeMapSize=4096,this.maxVolumeSize=4096,this.maxColorAttachments=8,this.maxPixelRatio=1,this.maxAnisotropy=16,this.supportsInstancing=!0,this.supportsUniformBuffers=!1,this.supportsVolumeTextures=!0,this.supportsBoneTextures=!0,this.supportsMorphTargetTexturesCore=!0,this.supportsAreaLights=!0,this.supportsDepthShadow=!0,this.supportsGpuParticles=!1,this.supportsMrt=!0,this.extUintElement=!0,this.extTextureFloat=!0,this.textureFloatRenderable=!0,this.extTextureHalfFloat=!0,this.textureHalfFloatRenderable=!0,this.textureHalfFloatUpdatable=!0,this.boneLimit=1024,this.supportsImageBitmap=!0,this.extStandardDerivatives=!0,this.extBlendMinmax=!0,this.areaLightLutFormat=e,this.supportsTextureFetch=!0}postInit(){super.postInit()}frameStart(){super.frameStart()}frameEnd(){super.frameEnd()}updateBegin(){}updateEnd(){}readPixels(t,e,s,r,i){}createVertexBufferImpl(t,e){return new p(t,e)}createIndexBufferImpl(t){return new r(t)}createShaderImpl(t){return new a(t)}createTextureImpl(t){return new o(t)}createRenderTargetImpl(t){return new i(t)}draw(t,e=1,s){}setShader(t,e=!1){}setBlendState(t){}setDepthState(t){}setStencilState(t,e){}setBlendColor(t,e,s,r){}setCullMode(t){}setAlphaToCoverage(t){}initializeContextCaches(){super.initializeContextCaches()}clear(t){}setViewport(t,e,s,r){}setScissor(t,e,s,r){}copyRenderTarget(t,e,s,r){return!0}}export{n as NullGraphicsDevice};