From d43eab44aff7d7543ff51ac15ae8fa869724901a Mon Sep 17 00:00:00 2001 From: Joseph Cloutier Date: Sun, 7 May 2023 15:39:50 -0400 Subject: [PATCH] Fix rest of `WebGL2RenderContext` indentation. This all could have been one big change, but the diff view would be very hard to read. Breaking it up like this allows Git to highlight the whitespace changes for you. Otherwise, it would show that 1245 lines were removed and replaced by 1245 new lines, not recognizing that any of those lines match. --- src/lime/graphics/WebGL2RenderContext.hx | 316 +++++++++++------------ 1 file changed, 158 insertions(+), 158 deletions(-) diff --git a/src/lime/graphics/WebGL2RenderContext.hx b/src/lime/graphics/WebGL2RenderContext.hx index 0590c3984..3fdc91364 100644 --- a/src/lime/graphics/WebGL2RenderContext.hx +++ b/src/lime/graphics/WebGL2RenderContext.hx @@ -4815,206 +4815,206 @@ abstract WebGL2RenderContext(Dynamic) from Dynamic to Dynamic } #if !lime_webgl - public function uniformMatrix3fv(location:GLUniformLocation, transpose:Bool, - v:Float32Array, srcOffset:Int = 0, ?srcLength:Int):Void + public function uniformMatrix3fv(location:GLUniformLocation, transpose:Bool, + v:Float32Array, srcOffset:Int = 0, ?srcLength:Int):Void #else - public inline function uniformMatrix3fv(location:GLUniformLocation, transpose:Bool, - v:Dynamic, ?srcOffset:Int, ?srcLength:Int):Void + public inline function uniformMatrix3fv(location:GLUniformLocation, transpose:Bool, + v:Dynamic, ?srcOffset:Int, ?srcLength:Int):Void #end - { - var count = 0; + { + var count = 0; - if (srcLength != null) count = srcLength; - else if (v != null) count = Std.int(v.length / 9); - __tempPointer.set(v, srcOffset); - this.uniformMatrix3fv(location, count, transpose, __tempPointer); - } + if (srcLength != null) count = srcLength; + else if (v != null) count = Std.int(v.length / 9); + __tempPointer.set(v, srcOffset); + this.uniformMatrix3fv(location, count, transpose, __tempPointer); + } - public function uniformMatrix3x2fv(location:GLUniformLocation, transpose:Bool, - v:Float32Array, srcOffset:Int = 0, ?srcLength:Int):Void - { - var count = 0; - if (srcLength != null) count = srcLength; - else if (v != null) count = Std.int(v.length / 6); + public function uniformMatrix3x2fv(location:GLUniformLocation, transpose:Bool, + v:Float32Array, srcOffset:Int = 0, ?srcLength:Int):Void + { + var count = 0; + if (srcLength != null) count = srcLength; + else if (v != null) count = Std.int(v.length / 6); - __tempPointer.set(v, srcOffset); + __tempPointer.set(v, srcOffset); - this.uniformMatrix3x2fv(location, count, transpose, __tempPointer); - } + this.uniformMatrix3x2fv(location, count, transpose, __tempPointer); + } - public function uniformMatrix3x4fv(location:GLUniformLocation, transpose:Bool, - v:Float32Array, srcOffset:Int = 0, ?srcLength:Int):Void - { - var count = 0; - if (srcLength != null) count = srcLength; - else if (v != null) count = Std.int(v.length / 12); + public function uniformMatrix3x4fv(location:GLUniformLocation, transpose:Bool, + v:Float32Array, srcOffset:Int = 0, ?srcLength:Int):Void + { + var count = 0; + if (srcLength != null) count = srcLength; + else if (v != null) count = Std.int(v.length / 12); - __tempPointer.set(v, srcOffset); + __tempPointer.set(v, srcOffset); - this.uniformMatrix3x4fv(location, count, transpose, __tempPointer); - } + this.uniformMatrix3x4fv(location, count, transpose, __tempPointer); + } #if !lime_webgl - public function uniformMatrix4fv(location:GLUniformLocation, transpose:Bool, - v:Float32Array, srcOffset:Int = 0, ?srcLength:Int):Void + public function uniformMatrix4fv(location:GLUniformLocation, transpose:Bool, + v:Float32Array, srcOffset:Int = 0, ?srcLength:Int):Void #else - public inline function uniformMatrix4fv(location:GLUniformLocation, transpose:Bool, - v:Dynamic, ?srcOffset:Int, ?srcLength:Int):Void + public inline function uniformMatrix4fv(location:GLUniformLocation, transpose:Bool, + v:Dynamic, ?srcOffset:Int, ?srcLength:Int):Void #end - { - var count = 0; + { + var count = 0; - if (srcLength != null) count = srcLength; - else if (v != null) count = v.length >> 4; - __tempPointer.set(v, srcOffset); - this.uniformMatrix4fv(location, count, transpose, __tempPointer); - } + if (srcLength != null) count = srcLength; + else if (v != null) count = v.length >> 4; + __tempPointer.set(v, srcOffset); + this.uniformMatrix4fv(location, count, transpose, __tempPointer); + } - public function uniformMatrix4x2fv(location:GLUniformLocation, - transpose:Bool, v:Float32Array, srcOffset:Int = 0, ?srcLength:Int):Void - { - var count = 0; - if (srcLength != null) count = srcLength; - else if (v != null) count = Std.int(v.length / 8); + public function uniformMatrix4x2fv(location:GLUniformLocation, + transpose:Bool, v:Float32Array, srcOffset:Int = 0, ?srcLength:Int):Void + { + var count = 0; + if (srcLength != null) count = srcLength; + else if (v != null) count = Std.int(v.length / 8); - __tempPointer.set(v, srcOffset); + __tempPointer.set(v, srcOffset); - this.uniformMatrix4x2fv(location, count, transpose, __tempPointer); - } + this.uniformMatrix4x2fv(location, count, transpose, __tempPointer); + } - public function uniformMatrix4x3fv(location:GLUniformLocation, transpose:Bool, - v:Float32Array, srcOffset:Int = 0, ?srcLength:Int):Void - { - var count = 0; - if (srcLength != null) count = srcLength; - else if (v != null) count = Std.int(v.length / 12); + public function uniformMatrix4x3fv(location:GLUniformLocation, transpose:Bool, + v:Float32Array, srcOffset:Int = 0, ?srcLength:Int):Void + { + var count = 0; + if (srcLength != null) count = srcLength; + else if (v != null) count = Std.int(v.length / 12); - __tempPointer.set(v, srcOffset); + __tempPointer.set(v, srcOffset); - this.uniformMatrix4x3fv(location, count, transpose, __tempPointer); - } + this.uniformMatrix4x3fv(location, count, transpose, __tempPointer); + } - public inline function useProgram(program:GLProgram):Void - { - this.useProgram(program); - } + public inline function useProgram(program:GLProgram):Void + { + this.useProgram(program); + } - public inline function validateProgram(program:GLProgram):Void - { - this.validateProgram(program); - } + public inline function validateProgram(program:GLProgram):Void + { + this.validateProgram(program); + } - public inline function vertexAttrib1f(indx:Int, x:Float):Void - { - this.vertexAttrib1f(indx, x); - } + public inline function vertexAttrib1f(indx:Int, x:Float):Void + { + this.vertexAttrib1f(indx, x); + } - public inline function vertexAttrib1fv(indx:Int, - values:#if (!lime_webgl && !doc_gen) DataPointer #else Float32Array #end):Void - { - this.vertexAttrib1fv(indx, values); - } + public inline function vertexAttrib1fv(indx:Int, + values:#if (!lime_webgl && !doc_gen) DataPointer #else Float32Array #end):Void + { + this.vertexAttrib1fv(indx, values); + } - public inline function vertexAttrib2f(indx:Int, x:Float, y:Float):Void - { - this.vertexAttrib2f(indx, x, y); - } + public inline function vertexAttrib2f(indx:Int, x:Float, y:Float):Void + { + this.vertexAttrib2f(indx, x, y); + } - public inline function vertexAttrib2fv(indx:Int, - values:#if (!lime_webgl && !doc_gen) DataPointer #else Float32Array #end):Void - { - this.vertexAttrib2fv(indx, values); - } + public inline function vertexAttrib2fv(indx:Int, + values:#if (!lime_webgl && !doc_gen) DataPointer #else Float32Array #end):Void + { + this.vertexAttrib2fv(indx, values); + } - public inline function vertexAttrib3f(indx:Int, x:Float, y:Float, z:Float):Void - { - this.vertexAttrib3f(indx, x, y, z); - } + public inline function vertexAttrib3f(indx:Int, x:Float, y:Float, z:Float):Void + { + this.vertexAttrib3f(indx, x, y, z); + } - public inline function vertexAttrib3fv(indx:Int, - values:#if (!lime_webgl && !doc_gen) DataPointer #else Float32Array #end):Void - { - this.vertexAttrib3fv(indx, values); - } + public inline function vertexAttrib3fv(indx:Int, + values:#if (!lime_webgl && !doc_gen) DataPointer #else Float32Array #end):Void + { + this.vertexAttrib3fv(indx, values); + } - public inline function vertexAttrib4f(indx:Int, x:Float, y:Float, z:Float, - w:Float):Void - { - this.vertexAttrib4f(indx, x, y, z, w); - } + public inline function vertexAttrib4f(indx:Int, x:Float, y:Float, z:Float, + w:Float):Void + { + this.vertexAttrib4f(indx, x, y, z, w); + } - public inline function vertexAttrib4fv(indx:Int, - values:#if (!lime_webgl && !doc_gen) DataPointer #else Float32Array #end):Void - { - this.vertexAttrib4fv(indx, values); - } + public inline function vertexAttrib4fv(indx:Int, + values:#if (!lime_webgl && !doc_gen) DataPointer #else Float32Array #end):Void + { + this.vertexAttrib4fv(indx, values); + } - public inline function vertexAttribDivisor(index:Int, divisor:Int):Void - { - this.vertexAttribDivisor(index, divisor); - } + public inline function vertexAttribDivisor(index:Int, divisor:Int):Void + { + this.vertexAttribDivisor(index, divisor); + } - public inline function vertexAttribI4i(indx:Int, x:Int, y:Int, z:Int, - w:Int):Void - { - this.vertexAttribI4i(indx, x, y, z, w); - } + public inline function vertexAttribI4i(indx:Int, x:Int, y:Int, z:Int, + w:Int):Void + { + this.vertexAttribI4i(indx, x, y, z, w); + } - public inline function vertexAttribI4iv(indx:Int, - values:#if (!lime_webgl && !doc_gen) DataPointer #else Float32Array #end):Void - { - this.vertexAttribI4iv(indx, values); - } + public inline function vertexAttribI4iv(indx:Int, + values:#if (!lime_webgl && !doc_gen) DataPointer #else Float32Array #end):Void + { + this.vertexAttribI4iv(indx, values); + } - public inline function vertexAttribI4ui(indx:Int, x:Int, y:Int, z:Int, - w:Int):Void - { - this.vertexAttribI4ui(indx, x, y, z, w); - } + public inline function vertexAttribI4ui(indx:Int, x:Int, y:Int, z:Int, + w:Int):Void + { + this.vertexAttribI4ui(indx, x, y, z, w); + } - public inline function vertexAttribI4uiv(indx:Int, - values:#if (!lime_webgl && !doc_gen) DataPointer #else Float32Array #end):Void - { - this.vertexAttribI4uiv(indx, values); - } + public inline function vertexAttribI4uiv(indx:Int, + values:#if (!lime_webgl && !doc_gen) DataPointer #else Float32Array #end):Void + { + this.vertexAttribI4uiv(indx, values); + } - public inline function vertexAttribIPointer(index:Int, size:Int, type:Int, - stride:Int, offset:DataPointer):Void - { - this.vertexAttribIPointer(index, size, type, stride, offset); - } + public inline function vertexAttribIPointer(index:Int, size:Int, type:Int, + stride:Int, offset:DataPointer):Void + { + this.vertexAttribIPointer(index, size, type, stride, offset); + } - public inline function vertexAttribPointer(indx:Int, size:Int, type:Int, - normalized:Bool, stride:Int, offset:DataPointer):Void - { - this.vertexAttribPointer(indx, size, type, normalized, stride, offset); - } + public inline function vertexAttribPointer(indx:Int, size:Int, type:Int, + normalized:Bool, stride:Int, offset:DataPointer):Void + { + this.vertexAttribPointer(indx, size, type, normalized, stride, offset); + } - public inline function viewport(x:Int, y:Int, width:Int, height:Int):Void - { - this.viewport(x, y, width, height); - } + public inline function viewport(x:Int, y:Int, width:Int, height:Int):Void + { + this.viewport(x, y, width, height); + } - public inline function waitSync(sync:GLSync, flags:Int, timeout:Int64):Void - { - this.waitSync(sync, flags, timeout); - } + public inline function waitSync(sync:GLSync, flags:Int, timeout:Int64):Void + { + this.waitSync(sync, flags, timeout); + } - @:from private static function fromRenderContext(context:RenderContext):WebGL2RenderContext - { - return context.webgl2; - } + @:from private static function fromRenderContext(context:RenderContext):WebGL2RenderContext + { + return context.webgl2; + } #if (!doc_gen && (lime_opengl || lime_opengles)) - @:from private static function fromOpenGLES3RenderContext(gl:OpenGLES3RenderContext):WebGL2RenderContext - { - return cast gl; - } + @:from private static function fromOpenGLES3RenderContext(gl:OpenGLES3RenderContext):WebGL2RenderContext + { + return cast gl; + } #end - @:from private static function fromGL(gl:Class):WebGL2RenderContext - { - return cast GL.context; - } - } + @:from private static function fromGL(gl:Class):WebGL2RenderContext + { + return cast GL.context; + } +} #end