1 |
- {"ast":null,"code":"import { VertexBuffer } from \"../Buffers/buffer.js\";\nimport { Observable } from \"../Misc/observable.js\";\n/**\n * PostProcessManager is used to manage one or more post processes or post process pipelines\n * See https://doc.babylonjs.com/features/featuresDeepDive/postProcesses/usePostProcesses\n */\nexport class PostProcessManager {\n /**\n * Creates a new instance PostProcess\n * @param scene The scene that the post process is associated with.\n */\n constructor(scene) {\n this._vertexBuffers = {};\n this.onBeforeRenderObservable = new Observable();\n this._scene = scene;\n }\n _prepareBuffers() {\n if (this._vertexBuffers[VertexBuffer.PositionKind]) {\n return;\n }\n // VBO\n const vertices = [];\n vertices.push(1, 1);\n vertices.push(-1, 1);\n vertices.push(-1, -1);\n vertices.push(1, -1);\n this._vertexBuffers[VertexBuffer.PositionKind] = new VertexBuffer(this._scene.getEngine(), vertices, VertexBuffer.PositionKind, false, false, 2);\n this._buildIndexBuffer();\n }\n _buildIndexBuffer() {\n // Indices\n const indices = [];\n indices.push(0);\n indices.push(1);\n indices.push(2);\n indices.push(0);\n indices.push(2);\n indices.push(3);\n this._indexBuffer = this._scene.getEngine().createIndexBuffer(indices);\n }\n /**\n * Rebuilds the vertex buffers of the manager.\n * @internal\n */\n _rebuild() {\n const vb = this._vertexBuffers[VertexBuffer.PositionKind];\n if (!vb) {\n return;\n }\n vb._rebuild();\n this._buildIndexBuffer();\n }\n // Methods\n /**\n * Prepares a frame to be run through a post process.\n * @param sourceTexture The input texture to the post processes. (default: null)\n * @param postProcesses An array of post processes to be run. (default: null)\n * @returns True if the post processes were able to be run.\n * @internal\n */\n _prepareFrame(sourceTexture = null, postProcesses = null) {\n const camera = this._scene.activeCamera;\n if (!camera) {\n return false;\n }\n postProcesses = postProcesses || camera._postProcesses.filter(pp => {\n return pp != null;\n });\n if (!postProcesses || postProcesses.length === 0 || !this._scene.postProcessesEnabled) {\n return false;\n }\n postProcesses[0].activate(camera, sourceTexture, postProcesses !== null && postProcesses !== undefined);\n return true;\n }\n /**\n * Manually render a set of post processes to a texture.\n * Please note, the frame buffer won't be unbound after the call in case you have more render to do.\n * @param postProcesses An array of post processes to be run.\n * @param targetTexture The render target wrapper to render to.\n * @param forceFullscreenViewport force gl.viewport to be full screen eg. 0,0,textureWidth,textureHeight\n * @param faceIndex defines the face to render to if a cubemap is defined as the target\n * @param lodLevel defines which lod of the texture to render to\n * @param doNotBindFrambuffer If set to true, assumes that the framebuffer has been bound previously\n */\n directRender(postProcesses, targetTexture = null, forceFullscreenViewport = false, faceIndex = 0, lodLevel = 0, doNotBindFrambuffer = false) {\n const engine = this._scene.getEngine();\n for (let index = 0; index < postProcesses.length; index++) {\n if (index < postProcesses.length - 1) {\n postProcesses[index + 1].activate(this._scene.activeCamera, targetTexture === null || targetTexture === void 0 ? void 0 : targetTexture.texture);\n } else {\n var _engine$_debugInsertM;\n if (targetTexture) {\n engine.bindFramebuffer(targetTexture, faceIndex, undefined, undefined, forceFullscreenViewport, lodLevel);\n } else if (!doNotBindFrambuffer) {\n engine.restoreDefaultFramebuffer();\n }\n (_engine$_debugInsertM = engine._debugInsertMarker) === null || _engine$_debugInsertM === void 0 || _engine$_debugInsertM.call(engine, `post process ${postProcesses[index].name} output`);\n }\n const pp = postProcesses[index];\n const effect = pp.apply();\n if (effect) {\n pp.onBeforeRenderObservable.notifyObservers(effect);\n // VBOs\n this._prepareBuffers();\n engine.bindBuffers(this._vertexBuffers, this._indexBuffer, effect);\n // Draw order\n engine.drawElementsType(0, 0, 6);\n pp.onAfterRenderObservable.notifyObservers(effect);\n }\n }\n // Restore depth buffer\n engine.setDepthBuffer(true);\n engine.setDepthWrite(true);\n }\n /**\n * Finalize the result of the output of the postprocesses.\n * @param doNotPresent If true the result will not be displayed to the screen.\n * @param targetTexture The render target wrapper to render to.\n * @param faceIndex The index of the face to bind the target texture to.\n * @param postProcesses The array of post processes to render.\n * @param forceFullscreenViewport force gl.viewport to be full screen eg. 0,0,textureWidth,textureHeight (default: false)\n * @internal\n */\n _finalizeFrame(doNotPresent, targetTexture, faceIndex, postProcesses, forceFullscreenViewport = false) {\n const camera = this._scene.activeCamera;\n if (!camera) {\n return;\n }\n this.onBeforeRenderObservable.notifyObservers(this);\n postProcesses = postProcesses || camera._postProcesses.filter(pp => {\n return pp != null;\n });\n if (postProcesses.length === 0 || !this._scene.postProcessesEnabled) {\n return;\n }\n const engine = this._scene.getEngine();\n for (let index = 0, len = postProcesses.length; index < len; index++) {\n const pp = postProcesses[index];\n if (index < len - 1) {\n pp._outputTexture = postProcesses[index + 1].activate(camera, targetTexture === null || targetTexture === void 0 ? void 0 : targetTexture.texture);\n } else {\n var _engine$_debugInsertM2;\n if (targetTexture) {\n engine.bindFramebuffer(targetTexture, faceIndex, undefined, undefined, forceFullscreenViewport);\n pp._outputTexture = targetTexture;\n } else {\n engine.restoreDefaultFramebuffer();\n pp._outputTexture = null;\n }\n (_engine$_debugInsertM2 = engine._debugInsertMarker) === null || _engine$_debugInsertM2 === void 0 || _engine$_debugInsertM2.call(engine, `post process ${postProcesses[index].name} output`);\n }\n if (doNotPresent) {\n break;\n }\n const effect = pp.apply();\n if (effect) {\n pp.onBeforeRenderObservable.notifyObservers(effect);\n // VBOs\n this._prepareBuffers();\n engine.bindBuffers(this._vertexBuffers, this._indexBuffer, effect);\n // Draw order\n engine.drawElementsType(0, 0, 6);\n pp.onAfterRenderObservable.notifyObservers(effect);\n }\n }\n // Restore states\n engine.setDepthBuffer(true);\n engine.setDepthWrite(true);\n engine.setAlphaMode(0);\n }\n /**\n * Disposes of the post process manager.\n */\n dispose() {\n const buffer = this._vertexBuffers[VertexBuffer.PositionKind];\n if (buffer) {\n buffer.dispose();\n this._vertexBuffers[VertexBuffer.PositionKind] = null;\n }\n if (this._indexBuffer) {\n this._scene.getEngine()._releaseBuffer(this._indexBuffer);\n this._indexBuffer = null;\n }\n }\n}","map":{"version":3,"names":["VertexBuffer","Observable","PostProcessManager","constructor","scene","_vertexBuffers","onBeforeRenderObservable","_scene","_prepareBuffers","PositionKind","vertices","push","getEngine","_buildIndexBuffer","indices","_indexBuffer","createIndexBuffer","_rebuild","vb","_prepareFrame","sourceTexture","postProcesses","camera","activeCamera","_postProcesses","filter","pp","length","postProcessesEnabled","activate","undefined","directRender","targetTexture","forceFullscreenViewport","faceIndex","lodLevel","doNotBindFrambuffer","engine","index","texture","_engine$_debugInsertM","bindFramebuffer","restoreDefaultFramebuffer","_debugInsertMarker","call","name","effect","apply","notifyObservers","bindBuffers","drawElementsType","onAfterRenderObservable","setDepthBuffer","setDepthWrite","_finalizeFrame","doNotPresent","len","_outputTexture","_engine$_debugInsertM2","setAlphaMode","dispose","buffer","_releaseBuffer"],"sources":["F:/workspace/202226701027/huinongbao-app/node_modules/@babylonjs/core/PostProcesses/postProcessManager.js"],"sourcesContent":["import { VertexBuffer } from \"../Buffers/buffer.js\";\n\nimport { Observable } from \"../Misc/observable.js\";\n/**\n * PostProcessManager is used to manage one or more post processes or post process pipelines\n * See https://doc.babylonjs.com/features/featuresDeepDive/postProcesses/usePostProcesses\n */\nexport class PostProcessManager {\n /**\n * Creates a new instance PostProcess\n * @param scene The scene that the post process is associated with.\n */\n constructor(scene) {\n this._vertexBuffers = {};\n this.onBeforeRenderObservable = new Observable();\n this._scene = scene;\n }\n _prepareBuffers() {\n if (this._vertexBuffers[VertexBuffer.PositionKind]) {\n return;\n }\n // VBO\n const vertices = [];\n vertices.push(1, 1);\n vertices.push(-1, 1);\n vertices.push(-1, -1);\n vertices.push(1, -1);\n this._vertexBuffers[VertexBuffer.PositionKind] = new VertexBuffer(this._scene.getEngine(), vertices, VertexBuffer.PositionKind, false, false, 2);\n this._buildIndexBuffer();\n }\n _buildIndexBuffer() {\n // Indices\n const indices = [];\n indices.push(0);\n indices.push(1);\n indices.push(2);\n indices.push(0);\n indices.push(2);\n indices.push(3);\n this._indexBuffer = this._scene.getEngine().createIndexBuffer(indices);\n }\n /**\n * Rebuilds the vertex buffers of the manager.\n * @internal\n */\n _rebuild() {\n const vb = this._vertexBuffers[VertexBuffer.PositionKind];\n if (!vb) {\n return;\n }\n vb._rebuild();\n this._buildIndexBuffer();\n }\n // Methods\n /**\n * Prepares a frame to be run through a post process.\n * @param sourceTexture The input texture to the post processes. (default: null)\n * @param postProcesses An array of post processes to be run. (default: null)\n * @returns True if the post processes were able to be run.\n * @internal\n */\n _prepareFrame(sourceTexture = null, postProcesses = null) {\n const camera = this._scene.activeCamera;\n if (!camera) {\n return false;\n }\n postProcesses = postProcesses || camera._postProcesses.filter((pp) => {\n return pp != null;\n });\n if (!postProcesses || postProcesses.length === 0 || !this._scene.postProcessesEnabled) {\n return false;\n }\n postProcesses[0].activate(camera, sourceTexture, postProcesses !== null && postProcesses !== undefined);\n return true;\n }\n /**\n * Manually render a set of post processes to a texture.\n * Please note, the frame buffer won't be unbound after the call in case you have more render to do.\n * @param postProcesses An array of post processes to be run.\n * @param targetTexture The render target wrapper to render to.\n * @param forceFullscreenViewport force gl.viewport to be full screen eg. 0,0,textureWidth,textureHeight\n * @param faceIndex defines the face to render to if a cubemap is defined as the target\n * @param lodLevel defines which lod of the texture to render to\n * @param doNotBindFrambuffer If set to true, assumes that the framebuffer has been bound previously\n */\n directRender(postProcesses, targetTexture = null, forceFullscreenViewport = false, faceIndex = 0, lodLevel = 0, doNotBindFrambuffer = false) {\n const engine = this._scene.getEngine();\n for (let index = 0; index < postProcesses.length; index++) {\n if (index < postProcesses.length - 1) {\n postProcesses[index + 1].activate(this._scene.activeCamera, targetTexture?.texture);\n }\n else {\n if (targetTexture) {\n engine.bindFramebuffer(targetTexture, faceIndex, undefined, undefined, forceFullscreenViewport, lodLevel);\n }\n else if (!doNotBindFrambuffer) {\n engine.restoreDefaultFramebuffer();\n }\n engine._debugInsertMarker?.(`post process ${postProcesses[index].name} output`);\n }\n const pp = postProcesses[index];\n const effect = pp.apply();\n if (effect) {\n pp.onBeforeRenderObservable.notifyObservers(effect);\n // VBOs\n this._prepareBuffers();\n engine.bindBuffers(this._vertexBuffers, this._indexBuffer, effect);\n // Draw order\n engine.drawElementsType(0, 0, 6);\n pp.onAfterRenderObservable.notifyObservers(effect);\n }\n }\n // Restore depth buffer\n engine.setDepthBuffer(true);\n engine.setDepthWrite(true);\n }\n /**\n * Finalize the result of the output of the postprocesses.\n * @param doNotPresent If true the result will not be displayed to the screen.\n * @param targetTexture The render target wrapper to render to.\n * @param faceIndex The index of the face to bind the target texture to.\n * @param postProcesses The array of post processes to render.\n * @param forceFullscreenViewport force gl.viewport to be full screen eg. 0,0,textureWidth,textureHeight (default: false)\n * @internal\n */\n _finalizeFrame(doNotPresent, targetTexture, faceIndex, postProcesses, forceFullscreenViewport = false) {\n const camera = this._scene.activeCamera;\n if (!camera) {\n return;\n }\n this.onBeforeRenderObservable.notifyObservers(this);\n postProcesses = postProcesses || camera._postProcesses.filter((pp) => {\n return pp != null;\n });\n if (postProcesses.length === 0 || !this._scene.postProcessesEnabled) {\n return;\n }\n const engine = this._scene.getEngine();\n for (let index = 0, len = postProcesses.length; index < len; index++) {\n const pp = postProcesses[index];\n if (index < len - 1) {\n pp._outputTexture = postProcesses[index + 1].activate(camera, targetTexture?.texture);\n }\n else {\n if (targetTexture) {\n engine.bindFramebuffer(targetTexture, faceIndex, undefined, undefined, forceFullscreenViewport);\n pp._outputTexture = targetTexture;\n }\n else {\n engine.restoreDefaultFramebuffer();\n pp._outputTexture = null;\n }\n engine._debugInsertMarker?.(`post process ${postProcesses[index].name} output`);\n }\n if (doNotPresent) {\n break;\n }\n const effect = pp.apply();\n if (effect) {\n pp.onBeforeRenderObservable.notifyObservers(effect);\n // VBOs\n this._prepareBuffers();\n engine.bindBuffers(this._vertexBuffers, this._indexBuffer, effect);\n // Draw order\n engine.drawElementsType(0, 0, 6);\n pp.onAfterRenderObservable.notifyObservers(effect);\n }\n }\n // Restore states\n engine.setDepthBuffer(true);\n engine.setDepthWrite(true);\n engine.setAlphaMode(0);\n }\n /**\n * Disposes of the post process manager.\n */\n dispose() {\n const buffer = this._vertexBuffers[VertexBuffer.PositionKind];\n if (buffer) {\n buffer.dispose();\n this._vertexBuffers[VertexBuffer.PositionKind] = null;\n }\n if (this._indexBuffer) {\n this._scene.getEngine()._releaseBuffer(this._indexBuffer);\n this._indexBuffer = null;\n }\n }\n}\n"],"mappings":"AAAA,SAASA,YAAY,QAAQ,sBAAsB;AAEnD,SAASC,UAAU,QAAQ,uBAAuB;AAClD;AACA;AACA;AACA;AACA,OAAO,MAAMC,kBAAkB,CAAC;EAC5B;AACJ;AACA;AACA;EACIC,WAAWA,CAACC,KAAK,EAAE;IACf,IAAI,CAACC,cAAc,GAAG,CAAC,CAAC;IACxB,IAAI,CAACC,wBAAwB,GAAG,IAAIL,UAAU,CAAC,CAAC;IAChD,IAAI,CAACM,MAAM,GAAGH,KAAK;EACvB;EACAI,eAAeA,CAAA,EAAG;IACd,IAAI,IAAI,CAACH,cAAc,CAACL,YAAY,CAACS,YAAY,CAAC,EAAE;MAChD;IACJ;IACA;IACA,MAAMC,QAAQ,GAAG,EAAE;IACnBA,QAAQ,CAACC,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC;IACnBD,QAAQ,CAACC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC;IACpBD,QAAQ,CAACC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;IACrBD,QAAQ,CAACC,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;IACpB,IAAI,CAACN,cAAc,CAACL,YAAY,CAACS,YAAY,CAAC,GAAG,IAAIT,YAAY,CAAC,IAAI,CAACO,MAAM,CAACK,SAAS,CAAC,CAAC,EAAEF,QAAQ,EAAEV,YAAY,CAACS,YAAY,EAAE,KAAK,EAAE,KAAK,EAAE,CAAC,CAAC;IAChJ,IAAI,CAACI,iBAAiB,CAAC,CAAC;EAC5B;EACAA,iBAAiBA,CAAA,EAAG;IAChB;IACA,MAAMC,OAAO,GAAG,EAAE;IAClBA,OAAO,CAACH,IAAI,CAAC,CAAC,CAAC;IACfG,OAAO,CAACH,IAAI,CAAC,CAAC,C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