@@ -192,63 +192,84 @@ var Camera = new Class({
192192 */
193193 this . _follow = null ;
194194
195+ /**
196+ * Is this Camera rendering directly or to a texture?
197+ *
198+ * @name Phaser.Cameras.Scene2D.Camera#renderToTexture
199+ * @type {boolean }
200+ * @default false
201+ * @private
202+ * @since 3.12.0-EXPERIMENTAL
203+ */
195204 this . renderToTexture = false ;
196205
197206 /**
198- * The HTML Canvas Element that the Render Texture is drawing to.
207+ * The HTML Canvas Element that the Camera is drawing to if rendering to a texture .
199208 * This is only populated if Phaser is running with the Canvas Renderer.
200209 *
201- * @name Phaser.GameObjects.RenderTexture #canvas
210+ * @name Phaser.Cameras.Scene2D.Camera #canvas
202211 * @type {HTMLCanvasElement }
203- * @since 3.12.0
212+ * @private
213+ * @since 3.12.0-EXPERIMENTAL
204214 */
205215 this . canvas = null ;
206216
207217 /**
208- * A reference to the Rendering Context belonging to the Canvas Element this Render Texture is drawing to.
218+ * A reference to the Rendering Context belonging to the Canvas Element this Camera is rendering to a texture .
209219 *
210- * @name Phaser.GameObjects.RenderTexture #context
220+ * @name Phaser.Cameras.Scene2D.Camera #context
211221 * @type {CanvasRenderingContext2D }
212- * @since 3.12.0
222+ * @private
223+ * @since 3.12.0-EXPERIMENTAL
213224 */
214225 this . context = null ;
215226
216227 /**
217- * A reference to the GL Frame Buffer this Render Texture is drawing to.
228+ * A reference to the GL Frame Buffer this Camera ia drawing to if rendering to a texture .
218229 * This is only set if Phaser is running with the WebGL Renderer.
219230 *
220- * @name Phaser.GameObjects.RenderTexture #framebuffer
231+ * @name Phaser.Cameras.Scene2D.Camera #framebuffer
221232 * @type {?WebGLFramebuffer }
222- * @since 3.12.0
233+ * @private
234+ * @since 3.12.0-EXPERIMENTAL
223235 */
224236 this . glTexture = null ;
225237
226238 /**
227- * A reference to the GL Frame Buffer this Render Texture is drawing to.
239+ * A reference to the GL Frame Buffer this Camera is drawing to if rendering to a texture .
228240 * This is only set if Phaser is running with the WebGL Renderer.
229241 *
230- * @name Phaser.GameObjects.RenderTexture #framebuffer
242+ * @name Phaser.Cameras.Scene2D.Camera #framebuffer
231243 * @type {?WebGLFramebuffer }
232- * @since 3.12.0
244+ * @private
245+ * @since 3.12.0-EXPERIMENTAL
233246 */
234247 this . framebuffer = null ;
235248
249+ /**
250+ * A reference to the GL Frame Buffer this Render Texture is drawing to.
251+ * This is only set if Phaser is running with the WebGL Renderer.
252+ *
253+ * @name Phaser.Cameras.Scene2D.Camera#pipeline
254+ * @type {any }
255+ * @private
256+ * @since 3.12.0-EXPERIMENTAL
257+ */
236258 this . pipeline = null ;
237-
238- // this.flipX = false;
239- // this.flipY = false;
240- // this.tintFill = 0;
241- // this._isTinted = false;
242- // this._tintTL = 0xffffff;
243- // this._tintTR = 0xffffff;
244- // this._tintBL = 0xffffff;
245- // this._tintBR = 0xffffff;
246- // this._alphaTL = 1;
247- // this._alphaTR = 1;
248- // this._alphaBL = 1;
249- // this._alphaBR = 1;
250259 } ,
251260
261+ /**
262+ * Sets the Camera to render to a texture instead of to the main display.
263+ *
264+ * This is an experimental feature and should be expected to change in the future.
265+ *
266+ * @method Phaser.Cameras.Scene2D.Camera#setRenderToTexture
267+ * @since 3.12.0-EXPERIMENTAL
268+ *
269+ * @param {any } [pipeline] - An optional WebGL Pipeline to render with.
270+ *
271+ * @return {Phaser.Cameras.Scene2D.Camera } This Camera instance.
272+ */
252273 setRenderToTexture : function ( pipeline )
253274 {
254275 var renderer = this . scene . sys . game . renderer ;
0 commit comments