27#ifndef EASY3D_RENDERER_DRAWABLE_TRIANGLES_H
28#define EASY3D_RENDERER_DRAWABLE_TRIANGLES_H
30#include <easy3d/renderer/drawable.h>
50 Type
type()
const override;
52 bool smooth_shading()
const {
return smooth_shading_; }
53 void set_smooth_shading(
bool b) { smooth_shading_ = b; }
59 float opacity()
const {
return opacity_; }
68 void draw(
const Camera* camera)
const override;
A perspective or orthographic camera.
Definition: camera.h:116
The base class for drawable objects. A drawable represent a set of points, line segments,...
Definition: drawable.h:56
Model * model()
the model to which the drawable is attached to (can be NULL).
Definition: drawable.h:77
The base class of renderable 3D models.
Definition: model.h:49
The drawable for rendering a set of triangles, e.g., the surface of a triangular mesh.
Definition: drawable_triangles.h:46
Type type() const override
Returns the type of the drawable.
Definition: drawable_triangles.cpp:53
float opacity() const
Query the opacity of the drawable, in the range [0.0, 1.0].
Definition: drawable_triangles.h:59
void draw(const Camera *camera) const override
The draw method.
Definition: drawable_triangles.cpp:58
void set_opacity(float opacity)
Set the opacity of the drawable.
Definition: drawable_triangles.h:65
Definition: collider.cpp:182