mf
Media Framework
|
View frustum of a perspective camera. More...
#include <view_frustum.h>
Public Types | |
enum | intersection { outside_frustum, inside_frustum, partially_inside_frustum } |
using | edge = std::pair< Eigen_vec3, Eigen_vec3 > |
using | corners_array = std::array< Eigen_vec3, 8 > |
using | edges_array = std::array< edge, 12 > |
using | planes_array = std::array< Eigen_hyperplane3, 6 > |
Public Member Functions | |
const Eigen_projective3 & | view_projection_transformation () const |
const depth_projection_parameters & | depth_parameters () const |
Eigen_hyperplane3 | near_plane () const |
Eigen_hyperplane3 | far_plane () const |
Eigen_hyperplane3 | left_plane () const |
Eigen_hyperplane3 | right_plane () const |
Eigen_hyperplane3 | bottom_plane () const |
Eigen_hyperplane3 | top_plane () const |
planes_array | planes () const |
corners_array | corners () const |
edges_array | edges () const |
bool | contains (const Eigen_vec3 &, bool consider_z_planes=true) const |
intersection | contains (const bounding_box &) const |
view_frustum | transform (const Eigen_affine3 &) const |
Static Public Member Functions | |
static intersection | contains (const planes_array &, const bounding_box &) |
Protected Member Functions | |
view_frustum (const Eigen_mat4 &mat, const depth_projection_parameters &dparam) | |
view_frustum ()=delete | |
Eigen_mat4 & | matrix_ () |
const Eigen_mat4 & | matrix_ () const |
View frustum of a perspective camera.
Represented using 4x4 view-projection matrix, with additional information about convention used. Includes the affine world to view transformation. Can be constructed only as projection_view_frustum
(which does not include this view transformation), and can then be transformed using transform().
using mf::view_frustum::corners_array = std::array<Eigen_vec3, 8> |
using mf::view_frustum::edge = std::pair<Eigen_vec3, Eigen_vec3> |
using mf::view_frustum::edges_array = std::array<edge, 12> |
using mf::view_frustum::planes_array = std::array<Eigen_hyperplane3, 6> |
|
protected |
|
protecteddelete |
Eigen_hyperplane3 mf::view_frustum::bottom_plane | ( | ) | const |
bool mf::view_frustum::contains | ( | const Eigen_vec3 & | world_point, |
bool | consider_z_planes = true |
||
) | const |
auto mf::view_frustum::contains | ( | const bounding_box & | box | ) | const |
|
static |
auto mf::view_frustum::corners | ( | ) | const |
|
inline |
auto mf::view_frustum::edges | ( | ) | const |
Eigen_hyperplane3 mf::view_frustum::far_plane | ( | ) | const |
Eigen_hyperplane3 mf::view_frustum::left_plane | ( | ) | const |
|
inlineprotected |
|
inlineprotected |
Eigen_hyperplane3 mf::view_frustum::near_plane | ( | ) | const |
auto mf::view_frustum::planes | ( | ) | const |
Eigen_hyperplane3 mf::view_frustum::right_plane | ( | ) | const |
Eigen_hyperplane3 mf::view_frustum::top_plane | ( | ) | const |
view_frustum mf::view_frustum::transform | ( | const Eigen_affine3 & | trans | ) | const |
|
inline |