|
VisuTwin Canvas
C++ 3D Engine — Metal Backend
|
#include <framework/graphics/picker.h>
Public Member Functions | |
| std::vector< MeshInstance * > | getSelection (int x, int y, int width=1, int height=1) const |
| MeshInstance * | getSelectionSingle (int x, int y) const |
| std::optional< Vector3 > | getWorldPoint (int x, int y) const |
| int | height () const |
| Picker (Engine *app, int width, int height, bool depth=false) | |
| void | prepare (CameraComponent *camera, Scene *scene, const std::vector< int > &layers={}) |
| void | resize (int width, int height) |
| int | width () const |
| visutwin::canvas::Picker::Picker | ( | Engine * | app, |
| int | width, | ||
| int | height, | ||
| bool | depth = false ) |
Definition at line 24 of file picker.cpp.
| std::vector< MeshInstance * > visutwin::canvas::Picker::getSelection | ( | int | x, |
| int | y, | ||
| int | width = 1, | ||
| int | height = 1 ) const |
Definition at line 118 of file picker.cpp.
References height(), and width().
Referenced by getSelectionSingle(), and getWorldPoint().
| MeshInstance * visutwin::canvas::Picker::getSelectionSingle | ( | int | x, |
| int | y ) const |
Definition at line 157 of file picker.cpp.
References getSelection(), and getSelectionSingle().
Referenced by getSelectionSingle().
| std::optional< Vector3 > visutwin::canvas::Picker::getWorldPoint | ( | int | x, |
| int | y ) const |
Definition at line 163 of file picker.cpp.
References getSelection(), and getWorldPoint().
Referenced by getWorldPoint().
|
inline |
Definition at line 35 of file picker.h.
Referenced by getSelection(), Picker(), and resize().
| void visutwin::canvas::Picker::prepare | ( | CameraComponent * | camera, |
| Scene * | scene, | ||
| const std::vector< int > & | layers = {} ) |
Definition at line 36 of file picker.cpp.
References visutwin::canvas::BoundingBox::center(), visutwin::canvas::Vector3::getX(), visutwin::canvas::Vector3::getY(), visutwin::canvas::Vector3::getZ(), visutwin::canvas::BoundingBox::halfExtents(), visutwin::canvas::RenderComponent::instances(), visutwin::canvas::Vector3::length(), and visutwin::canvas::Vector3::lengthSquared().
| void visutwin::canvas::Picker::resize | ( | int | width, |
| int | height ) |
|
inline |
Definition at line 34 of file picker.h.
Referenced by getSelection(), Picker(), and resize().