PhotoGENius V1.0.0
A basic library for generating photorealistic images, developed for the course Numerical techniques for photorealistic image generation.
Public Member Functions | Public Attributes | List of all members
PGENLib.CheckeredPigment Class Reference

A checkered pigment. The number of rows/columns in the checkered pattern is tunable, but you cannot have a different number of repetitions along the u/v directions. The parameters defined in this dataclass are the following:

Col1 first Color
Col2 second Color
NumStep int number of repetition
More...

Inheritance diagram for PGENLib.CheckeredPigment:
PGENLib.Pigment

Public Member Functions

 CheckeredPigment (Color col1, Color col2, int numStep=10)
 
override Color GetColor (Vec2d uv)
 Calculate a color (type color) associated with a (u,v) coordinate. More...
 
virtual Color GetColor (Vec2d uv)
 Calculate a color (type color) associated with a (u,v) coordinate. More...
 

Public Attributes

Color Col1
 
Color Col2
 
int NumStep
 

Additional Inherited Members

- Protected Member Functions inherited from PGENLib.Pigment
 Pigment (Color color=default)
 
- Protected Attributes inherited from PGENLib.Pigment
Color Color
 

Detailed Description

A checkered pigment. The number of rows/columns in the checkered pattern is tunable, but you cannot have a different number of repetitions along the u/v directions. The parameters defined in this dataclass are the following:

Col1 first Color
Col2 second Color
NumStep int number of repetition

Member Function Documentation

◆ GetColor()

override Color PGENLib.CheckeredPigment.GetColor ( Vec2d  uv)
virtual

Calculate a color (type color) associated with a (u,v) coordinate.

Parameters
uv2D vector
Returns
the color of the pigment at the specified coordinates

Reimplemented from PGENLib.Pigment.


The documentation for this class was generated from the following file: