@@ -145,7 +145,7 @@ var CanvasRenderer = new Class({
145145
146146 /**
147147 * Details about the currently scheduled snapshot.
148- *
148+ *
149149 * If a non-null `callback` is set in this object, a snapshot of the canvas will be taken after the current frame is fully rendered.
150150 *
151151 * @name Phaser.Renderer.Canvas.CanvasRenderer#snapshotState
@@ -489,9 +489,9 @@ var CanvasRenderer = new Class({
489489
490490 /**
491491 * Takes a snapshot of the given area of the given canvas.
492- *
492+ *
493493 * Unlike the other snapshot methods, this one is processed immediately and doesn't wait for the next render.
494- *
494+ *
495495 * Snapshots work by creating an Image object from the canvas data, this is a blocking process, which gets
496496 * more expensive the larger the canvas size gets, so please be careful how you employ this in your game.
497497 *
@@ -529,12 +529,12 @@ var CanvasRenderer = new Class({
529529
530530 /**
531531 * Schedules a snapshot of the entire game viewport to be taken after the current frame is rendered.
532- *
532+ *
533533 * To capture a specific area see the `snapshotArea` method. To capture a specific pixel, see `snapshotPixel`.
534- *
534+ *
535535 * Only one snapshot can be active _per frame_. If you have already called `snapshotPixel`, for example, then
536536 * calling this method will override it.
537- *
537+ *
538538 * Snapshots work by creating an Image object from the canvas data, this is a blocking process, which gets
539539 * more expensive the larger the canvas size gets, so please be careful how you employ this in your game.
540540 *
@@ -554,12 +554,12 @@ var CanvasRenderer = new Class({
554554
555555 /**
556556 * Schedules a snapshot of the given area of the game viewport to be taken after the current frame is rendered.
557- *
557+ *
558558 * To capture the whole game viewport see the `snapshot` method. To capture a specific pixel, see `snapshotPixel`.
559- *
559+ *
560560 * Only one snapshot can be active _per frame_. If you have already called `snapshotPixel`, for example, then
561561 * calling this method will override it.
562- *
562+ *
563563 * Snapshots work by creating an Image object from the canvas data, this is a blocking process, which gets
564564 * more expensive the larger the canvas size gets, so please be careful how you employ this in your game.
565565 *
@@ -594,12 +594,12 @@ var CanvasRenderer = new Class({
594594
595595 /**
596596 * Schedules a snapshot of the given pixel from the game viewport to be taken after the current frame is rendered.
597- *
597+ *
598598 * To capture the whole game viewport see the `snapshot` method. To capture a specific area, see `snapshotArea`.
599- *
599+ *
600600 * Only one snapshot can be active _per frame_. If you have already called `snapshotArea`, for example, then
601601 * calling this method will override it.
602- *
602+ *
603603 * Unlike the other two snapshot methods, this one will return a `Color` object containing the color data for
604604 * the requested pixel. It doesn't need to create an internal Canvas or Image object, so is a lot faster to execute,
605605 * using less memory.
@@ -642,7 +642,7 @@ var CanvasRenderer = new Class({
642642 // Nothing to see, so abort early
643643 return ;
644644 }
645-
645+
646646 var ctx = this . currentContext ;
647647
648648 var camMatrix = this . _tempMatrix1 ;
@@ -676,7 +676,7 @@ var CanvasRenderer = new Class({
676676
677677 frameWidth = crop . cw ;
678678 frameHeight = crop . ch ;
679-
679+
680680 frameX = crop . cx ;
681681 frameY = crop . cy ;
682682
@@ -694,7 +694,7 @@ var CanvasRenderer = new Class({
694694 x = ( Math . abs ( x ) - frameWidth ) ;
695695 }
696696 }
697-
697+
698698 if ( sprite . flipY )
699699 {
700700 if ( y >= 0 )
@@ -752,31 +752,33 @@ var CanvasRenderer = new Class({
752752 {
753753 spriteMatrix . e -= camera . scrollX * sprite . scrollFactorX ;
754754 spriteMatrix . f -= camera . scrollY * sprite . scrollFactorY ;
755-
755+
756756 // Multiply by the Sprite matrix, store result in calcMatrix
757757 camMatrix . multiply ( spriteMatrix , calcMatrix ) ;
758758 }
759759
760760 ctx . save ( ) ;
761-
761+
762762 calcMatrix . setToContext ( ctx ) ;
763763
764764 ctx . globalCompositeOperation = this . blendModes [ sprite . blendMode ] ;
765765
766766 ctx . globalAlpha = alpha ;
767767
768768 ctx . imageSmoothingEnabled = ! ( ! this . antialias || frame . source . scaleMode ) ;
769-
770- if ( sprite . mask ) {
769+
770+ if ( sprite . mask )
771+ {
771772 sprite . mask . preRenderCanvas ( this , sprite , camera ) ;
772773 }
773774
774775 ctx . drawImage ( frame . source . image , frameX , frameY , frameWidth , frameHeight , x , y , frameWidth / res , frameHeight / res ) ;
775776
776- if ( sprite . mask ) {
777+ if ( sprite . mask )
778+ {
777779 sprite . mask . postRenderCanvas ( this , sprite , camera ) ;
778780 }
779-
781+
780782 ctx . restore ( ) ;
781783 } ,
782784
0 commit comments