OpenCV
3.4.1
Open Source Computer Vision
|
#include "ovis.hpp"
Public Member Functions | |
virtual | ~WindowScene () |
virtual Rect2d | createCameraEntity (const String &name, InputArray K, const Size &imsize, float zFar, InputArray tvec=noArray(), InputArray rot=noArray())=0 |
virtual void | createEntity (const String &name, const String &meshname, InputArray tvec=noArray(), InputArray rot=noArray())=0 |
virtual void | createLightEntity (const String &name, InputArray tvec=noArray(), InputArray rot=noArray(), const Scalar &diffuseColor=Scalar::all(1), const Scalar &specularColor=Scalar::all(1))=0 |
virtual void | fixCameraYawAxis (bool useFixed, InputArray up=noArray())=0 |
virtual void | getCameraPose (OutputArray R=noArray(), OutputArray tvec=noArray(), bool invert=false)=0 |
virtual void | getScreenshot (OutputArray frame)=0 |
virtual void | removeEntity (const String &name)=0 |
virtual void | setBackground (InputArray image)=0 |
virtual void | setBackground (const Scalar &color)=0 |
virtual void | setCameraIntrinsics (InputArray K, const Size &imsize)=0 |
virtual void | setCameraLookAt (const String &target, InputArray offset=noArray())=0 |
virtual void | setCameraPose (InputArray tvec=noArray(), InputArray rot=noArray(), bool invert=false)=0 |
virtual void | setEntityPose (const String &name, InputArray tvec=noArray(), InputArray rot=noArray(), bool invert=false)=0 |
virtual void | updateEntityPose (const String &name, InputArray tvec=noArray(), InputArray rot=noArray())=0 |
A 3D viewport and the associated scene
|
virtual |
|
pure virtual |
convenience method to visualize a camera position
the entity uses a material with the same name that can be used to change the line color.
name | entity name |
K | intrinsic matrix |
imsize | image size |
zFar | far plane in camera coordinates |
rot | Rodrigues vector or 3x3 rotation matrix |
tvec | translation |
|
pure virtual |
place an entity of an mesh in the scene
the mesh needs to be created beforehand. Either programmatically by e.g. createPointCloudMesh or by placing an Ogre .mesh file in a resource location.
name | entity name |
meshname | mesh name |
rot | Rodrigues vector or 3x3 rotation matrix |
tvec | translation |
|
pure virtual |
creates a point light in the scene
name | entity name |
rot | Rodrigues vector or 3x3 rotation matrix |
tvec | translation |
diffuseColor | |
specularColor |
|
pure virtual |
convenience method to force the "up" axis to stay fixed
works with both programmatic changes and SCENE_INTERACTIVE
useFixed | whether to enforce the fixed yaw axis |
up | the axis to be fixed |
|
pure virtual |
Retrieves the current camera pose
R | 3x3 rotation matrix |
tvec | translation vector |
invert | return the inverted pose |
|
pure virtual |
read back the image generated by the last call to waitKey
|
pure virtual |
remove an entity from the scene
name | entity name |
|
pure virtual |
set window background to custom image
creates a texture named "<title>_Background"
image |
|
pure virtual |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
|
pure virtual |
set intrinsics of the camera
K | intrinsic matrix |
imsize | image size |
|
pure virtual |
convenience method to orient the camera to a specific entity
target | entity name |
offset | offset from entity centre |
|
pure virtual |
Sets the current camera pose
rot | Rodrigues vector or 3x3 rotation matrix |
tvec | translation |
invert | use the inverse of the given pose |
|
pure virtual |
set entity pose in the world coordinate space.
name | enitity name |
rot | Rodrigues vector or 3x3 rotation matrix |
tvec | translation |
invert | use the inverse of the given pose |
|
pure virtual |
update entity pose by transformation in the parent coordinate space. (pre-rotation)
name | entity name |
rot | Rodrigues vector or 3x3 rotation matrix |
tvec | translation |