QtSculptor
v1.0.0
|
Concrete class PutSphere - Used to display a set of voxels belonging to a spherical volume. More...
#include <PutSphere.h>
Public Member Functions | |
PutSphere (int x_center_, int y_center_, int z_center_, int radius_, float r_, float g_, float b_, float a_) | |
PutSphere class constructor. More... | |
~PutSphere () | |
Destructor of the PutBox class. More... | |
void | draw (Sculptor &sculptor) |
Member function draw. More... | |
Public Member Functions inherited from GeometricFigure | |
virtual | ~GeometricFigure () |
GeometricFigure class constructor. More... | |
Private Attributes | |
int | x_center |
int | y_center |
int | z_center |
int | radius |
Additional Inherited Members | |
Protected Attributes inherited from GeometricFigure | |
float | r |
float | g |
float | b |
float | a |
Concrete class PutSphere - Used to display a set of voxels belonging to a spherical volume.
It will inform the system that all voxels, present in a certain spherical region and belonging to the space of the three-dimensional array of voxels allocated by an instance of the Sculptor class, it should be displayed.
x_center | Represents a coordinate on the x axis belonging to the voxel matrix that denotes the center of the sphere to be created; |
y_center | Represents a coordinate on the y axis belonging to the voxel matrix that denotes the center of the sphere to be created; |
z_center | Represents a coordinate on the z axis belonging to the voxel matrix that denotes the center of the sphere to be created; |
radius | Represents the radius of the sphere to be created, in the three dimensions, x, y and z; |
It inherits directly from the GeometricFigure abstract class.
PutSphere::PutSphere | ( | int | x_center_, |
int | y_center_, | ||
int | z_center_, | ||
int | radius_, | ||
float | r_, | ||
float | g_, | ||
float | b_, | ||
float | a_ | ||
) |
PutSphere class constructor.
This constructor will receive as parameters the dimensional coordinates of the voxel sphere to be created, as well as its color and transparency. Therefore, will construct an instance of the PutSphere class.
x_center_ | Central coordinate of the sphere on the x axis; |
y_center_ | Central coordinate of the sphere on the y axis; |
z_center_ | Central coordinate of the sphere on the z axis; |
radius_ | Raio da esfera nas três dimensões; |
r_ | Represents a red component of the color the sphere will be painted; |
g_ | Represents a green component of the color the sphere will be painted; |
b_ | Represents a blue component of the color the sphere will be painted; |
a_ | Represents the transparency component of the color that the painted sphere; |
|
inline |
Destructor of the PutBox class.
Acts as the default destructor;
|
virtual |
Member function draw.
Method that creates, from an instance of the Sculptor class passed as a parameter, a sphere present in its array of voxels.
sculptor | instância da classe Escultor; |
Implements GeometricFigure.
|
private |
Raio da esfera nas três dimensões.
|
private |
Central coordinate of the sphere on the x axis.
|
private |
Central coordinate of the sphere on the y axis.
|
private |
Central coordinate of the sphere on the z axis.