opengl: Add tiling for multi-textures.
This commit is contained in:
@@ -226,6 +226,16 @@ is
|
||||
|
||||
|
||||
|
||||
function uniform_Variable (Self : access Item'Class; Named : in String) return Variable.uniform.vec2
|
||||
is
|
||||
the_Variable : Variable.uniform.vec2;
|
||||
begin
|
||||
the_Variable.define (Self, Named);
|
||||
return the_Variable;
|
||||
end uniform_Variable;
|
||||
|
||||
|
||||
|
||||
function uniform_Variable (Self : access Item'Class; Named : in String) return Variable.uniform.vec3
|
||||
is
|
||||
the_Variable : Variable.uniform.vec3;
|
||||
|
||||
@@ -61,6 +61,7 @@ is
|
||||
function uniform_Variable (Self : access Item'Class; Named : in String) return Variable.uniform.bool;
|
||||
function uniform_Variable (Self : access Item'Class; Named : in String) return Variable.uniform.int;
|
||||
function uniform_Variable (Self : access Item'Class; Named : in String) return Variable.uniform.float;
|
||||
function uniform_Variable (Self : access Item'Class; Named : in String) return Variable.uniform.vec2;
|
||||
function uniform_Variable (Self : access Item'Class; Named : in String) return Variable.uniform.vec3;
|
||||
function uniform_Variable (Self : access Item'Class; Named : in String) return Variable.uniform.vec4;
|
||||
function uniform_Variable (Self : access Item'Class; Named : in String) return Variable.uniform.mat3;
|
||||
|
||||
@@ -97,6 +97,20 @@ is
|
||||
|
||||
|
||||
|
||||
-- vec2
|
||||
--
|
||||
procedure Value_is (Self : in vec2; Now : in Vector_2)
|
||||
is
|
||||
begin
|
||||
Tasks.check;
|
||||
glUniform2fv (Self.gl_Variable,
|
||||
1,
|
||||
Now (1)'Address);
|
||||
Errors.log;
|
||||
end Value_is;
|
||||
|
||||
|
||||
|
||||
-- vec3
|
||||
--
|
||||
procedure Value_is (Self : in vec3; Now : in Vector_3)
|
||||
|
||||
@@ -15,7 +15,7 @@ is
|
||||
-- Forge
|
||||
--
|
||||
|
||||
procedure define (Self : in out Item; Program : access openGL.Program.item'class;
|
||||
procedure define (Self : in out Item; Program : access openGL.Program.item'Class;
|
||||
Name : in String);
|
||||
overriding
|
||||
procedure destroy (Self : in out Item);
|
||||
@@ -33,6 +33,7 @@ is
|
||||
type bool is new Variable.uniform.item with private;
|
||||
type int is new Variable.uniform.item with private;
|
||||
type float is new Variable.uniform.item with private;
|
||||
type vec2 is new Variable.uniform.item with private;
|
||||
type vec3 is new Variable.uniform.item with private;
|
||||
type vec4 is new Variable.uniform.item with private;
|
||||
type mat3 is new Variable.uniform.item with private;
|
||||
@@ -43,6 +44,7 @@ is
|
||||
procedure Value_is (Self : in bool; Now : in Boolean);
|
||||
procedure Value_is (Self : in int; Now : in Integer);
|
||||
procedure Value_is (Self : in float; Now : in Real);
|
||||
procedure Value_is (Self : in vec2; Now : in Vector_2);
|
||||
procedure Value_is (Self : in vec3; Now : in Vector_3);
|
||||
procedure Value_is (Self : in vec4; Now : in Vector_4);
|
||||
procedure Value_is (Self : in mat3; Now : in Matrix_3x3);
|
||||
@@ -58,6 +60,7 @@ private
|
||||
type int is new Variable.uniform.item with null record;
|
||||
type float is new Variable.uniform.item with null record;
|
||||
|
||||
type vec2 is new Variable.uniform.item with null record;
|
||||
type vec3 is new Variable.uniform.item with null record;
|
||||
type vec4 is new Variable.uniform.item with null record;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user