UNPKG

2.09 kBSource Map (JSON)View Raw
1{"version":3,"file":"ObjectRenderer.js","sources":["../../src/batch/ObjectRenderer.ts"],"sourcesContent":["import type { Renderer } from '../Renderer';\nimport type { ISystem } from '../system/ISystem';\n\n/**\n * Base for a common object renderer that can be used as a\n * system renderer plugin.\n * @memberof PIXI\n */\nexport class ObjectRenderer implements ISystem\n{\n /** The renderer this manager works for. */\n protected renderer: Renderer;\n\n /**\n * @param renderer - The renderer this manager works for.\n */\n constructor(renderer: Renderer)\n {\n this.renderer = renderer;\n }\n\n /** Stub method that should be used to empty the current batch by rendering objects now. */\n flush(): void\n {\n // flush!\n }\n\n /** Generic destruction method that frees all resources. This should be called by subclasses. */\n destroy(): void\n {\n this.renderer = null;\n }\n\n /**\n * Stub method that initializes any state required before\n * rendering starts. It is different from the `prerender`\n * signal, which occurs every frame, in that it is called\n * whenever an object requests _this_ renderer specifically.\n */\n start(): void\n {\n // set the shader..\n }\n\n /** Stops the renderer. It should free up any state and become dormant. */\n stop(): void\n {\n this.flush();\n }\n\n /**\n * Keeps the object to render. It doesn't have to be\n * rendered immediately.\n * @param {PIXI.DisplayObject} _object - The object to render.\n */\n render(_object: any): void // eslint-disable-line @typescript-eslint/explicit-module-boundary-types\n {\n // render the object\n }\n}\n"],"names":[],"mappings":";AAQO,MAAM,eACb;AAAA;AAAA;AAAA;AAAA,EAOI,YAAY,UACZ;AACI,SAAK,WAAW;AAAA,EACpB;AAAA;AAAA,EAGA,QACA;AAAA,EAEA;AAAA;AAAA,EAGA,UACA;AACI,SAAK,WAAW;AAAA,EACpB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAQA,QACA;AAAA,EAEA;AAAA;AAAA,EAGA,OACA;AACI,SAAK,MAAM;AAAA,EACf;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAOA,OAAO,SACP;AAAA,EAEA;AACJ;;"}
\No newline at end of file