@@ -217,10 +217,10 @@ class Texture {
217217 */
218218 constructor ( graphicsDevice , options = { } ) {
219219 this . device = graphicsDevice ;
220- Debug . assert ( this . device , " Texture constructor requires a graphicsDevice to be valid" ) ;
221- Debug . assert ( ! options . width || Number . isInteger ( options . width ) , " Texture width must be an integer number, got" , options ) ;
222- Debug . assert ( ! options . height || Number . isInteger ( options . height ) , " Texture height must be an integer number, got" , options ) ;
223- Debug . assert ( ! options . layers || Number . isInteger ( options . layers ) , " Texture layers must be an integer number, got" , options ) ;
220+ Debug . assert ( this . device , ' Texture constructor requires a graphicsDevice to be valid' ) ;
221+ Debug . assert ( ! options . width || Number . isInteger ( options . width ) , ' Texture width must be an integer number, got' , options ) ;
222+ Debug . assert ( ! options . height || Number . isInteger ( options . height ) , ' Texture height must be an integer number, got' , options ) ;
223+ Debug . assert ( ! options . layers || Number . isInteger ( options . layers ) , ' Texture layers must be an integer number, got' , options ) ;
224224
225225 this . name = options . name ?? '' ;
226226
@@ -234,7 +234,7 @@ class Texture {
234234
235235 this . _layers = Math . floor ( options . layers ?? ( this . _dimension === TEXTUREDIMENSION_CUBE ? 6 : 1 ) ) ;
236236
237- Debug . assert ( ( this . _dimension === TEXTUREDIMENSION_CUBE ? this . _layers === 6 : true ) , " Texture cube map must have 6 layers" ) ;
237+ Debug . assert ( ( this . _dimension === TEXTUREDIMENSION_CUBE ? this . _layers === 6 : true ) , ' Texture cube map must have 6 layers' ) ;
238238
239239 this . _format = options . format ?? PIXELFORMAT_RGBA8 ;
240240 this . _compressed = isCompressedPixelFormat ( this . _format ) ;
@@ -941,8 +941,9 @@ class Texture {
941941 if ( ! invalid ) {
942942 // mark levels as updated
943943 for ( let i = 0 ; i < this . _layers ; i ++ ) {
944- if ( this . _levels [ 0 ] [ i ] !== source [ i ] )
944+ if ( this . _levels [ 0 ] [ i ] !== source [ i ] ) {
945945 this . _levelsUpdated [ 0 ] [ i ] = true ;
946+ }
946947 }
947948 }
948949 } else {
@@ -953,8 +954,9 @@ class Texture {
953954
954955 if ( ! invalid ) {
955956 // mark level as updated
956- if ( source !== this . _levels [ 0 ] )
957+ if ( source !== this . _levels [ 0 ] ) {
957958 this . _levelsUpdated [ 0 ] = true ;
959+ }
958960
959961 width = source . width ;
960962 height = source . height ;
0 commit comments