Unit a3dge.Material

Description

Define classes to describe and manage materials.

Overview

Classes, Interfaces, Objects and Records

Name Description
Class TMaterial Define a material.
Class TMaterialList A list of materials.

Functions and Procedures

function Color (const aR, aG, aB: Integer; const aA: Integer = 255): TColorDescription;
function Colorf (const aR, aG, aB: Single; const aA: Single = 1): TColorDescription;
PROCEDURE Clear; INLINE;

Types

TColorDescription = ARRAY [cR..cA] OF GLfloat;

Constants

cR = 0;
cG = 1;
cB = 2;
cA = 3;
clrBlack: TColorDescription = (N0, N0, N0, 1);
clrBlue: TColorDescription = (N0, N0, N6, 1);
clrGreen: TColorDescription = (N0, N6, N0, 1);
clrCyan: TColorDescription = (N0, N6, N6, 1);
clrRed: TColorDescription = (N6, N0, N0, 1);
clrMagenta: TColorDescription = (N6, N0, N6, 1);
clrBrown: TColorDescription = (N6, N3, N0, 1);
clrGray: TColorDescription = (N6, N6, N6, 1);
clrDarkGray: TColorDescription = (N3, N3, N3, 1);
clrBrightBlue: TColorDescription = (N3, N3, V1, 1);
clrBrightGreen: TColorDescription = (N3, V1, N3, 1);
clrBrightCyan: TColorDescription = (N3, V1, V1, 1);
clrBrightRed: TColorDescription = (V1, N3, N3, 1);
clrPink: TColorDescription = (V1, N3, V1, 1);
clrYellow: TColorDescription = (V1, V1, N3, 1);
clrWhite: TColorDescription = (1, 1, 1, 1);

Description

Functions and Procedures

function Color (const aR, aG, aB: Integer; const aA: Integer = 255): TColorDescription;

Build a color from components.

Each component is a number between 0 (black) and 255 (full color).

Parameters
aR
Red component.
aG
Green component.
aB
Blue component.
aA
Alpha component. This is, transparency. 0 is transparent, 255 is solid. Default is 255.
See also
Colorf
Build a color from components.
function Colorf (const aR, aG, aB: Single; const aA: Single = 1): TColorDescription;

Build a color from components.

Each component is a number between 0 (black) and 1 (full color).

Parameters
aR
Red component.
aG
Green component.
aB
Blue component.
aA
Alpha component. This is, transparency. 0 is transparent, 1 is solid. Default is 1.
See also
Color
Build a color from components.
PROCEDURE Clear; INLINE;

Removes all material description, returning to default.

Types

TColorDescription = ARRAY [cR..cA] OF GLfloat;

Color description.

Each element of the array is a different color component, from 0 (black) to 1 (full color).

See also
cR
Red component of a colour.
cG
Green component of a colour.
cB
Blue component of a colour.
cA
Alpha channel of a colour.

Constants

cR = 0;

Red component of a colour.

cG = 1;

Green component of a colour.

cB = 2;

Blue component of a colour.

cA = 3;

Alpha channel of a colour.

clrBlack: TColorDescription = (N0, N0, N0, 1);

Black color description.

clrBlue: TColorDescription = (N0, N0, N6, 1);

Blue color description.

clrGreen: TColorDescription = (N0, N6, N0, 1);

Green color description.

clrCyan: TColorDescription = (N0, N6, N6, 1);

Cyan color description.

clrRed: TColorDescription = (N6, N0, N0, 1);

Red color description.

clrMagenta: TColorDescription = (N6, N0, N6, 1);

Magenta color description.

clrBrown: TColorDescription = (N6, N3, N0, 1);

Brown color description.

clrGray: TColorDescription = (N6, N6, N6, 1);

Gray color description.

clrDarkGray: TColorDescription = (N3, N3, N3, 1);

Dark gray color description.

clrBrightBlue: TColorDescription = (N3, N3, V1, 1);

Bright blue color description.

clrBrightGreen: TColorDescription = (N3, V1, N3, 1);

Bright green color description.

clrBrightCyan: TColorDescription = (N3, V1, V1, 1);

Bright Cyan color description.

clrBrightRed: TColorDescription = (V1, N3, N3, 1);

Bright red color description.

clrPink: TColorDescription = (V1, N3, V1, 1);

Pink color description.

clrYellow: TColorDescription = (V1, V1, N3, 1);

Yellow color description.

clrWhite: TColorDescription = (1, 1, 1, 1);

White color description.


Generated by PasDoc 0.15.0. Generated on 2025-07-31 11:41:01.