Public Member Functions | Public Attributes | Private Member Functions | Private Attributes | List of all members
window Class Reference

#include <example.hpp>

Public Member Functions

void close ()
 
float height () const
 
 operator bool ()
 
 operator GLFWwindow * ()
 
void show (rs2::frame frame)
 
void show (const rs2::frame &frame, const rect &rect)
 
void show (const std::map< int, rs2::frame > &frames)
 
void show (const frames_mosaic &frames)
 
float width () const
 
 window (int width, int height, const char *title)
 
 window (unsigned width, unsigned height, const char *title, unsigned tiles_in_row, unsigned tiles_in_col, float canvas_width=0.8f, float canvas_height=0.6f, float canvas_left_top_x=0.1f, float canvas_left_top_y=0.075f)
 
 ~window ()
 

Public Attributes

std::function< void(int)> on_key_release = [](int) {}
 
std::function< void(bool)> on_left_mouse = [](bool) {}
 
std::function< void(double, double)> on_mouse_move = [](double, double) {}
 
std::function< void(double, double)> on_mouse_scroll = [](double, double) {}
 

Private Member Functions

rect calc_grid (rect r, size_t streams)
 
std::vector< rectcalc_grid (rect r, std::vector< rs2::frame > &frames)
 
bool can_render (const rs2::frame &f) const
 
void render_frameset (const rs2::frameset &frames, const rect &r)
 
void render_motion_frame (const rs2::motion_frame &f, const rect &r)
 
void render_pose_frame (const rs2::pose_frame &f, const rect &r)
 
void render_video_frame (const rs2::video_frame &f, const rect &r)
 

Private Attributes

int _canvas_height
 
float _canvas_left_top_x
 
float _canvas_left_top_y
 
int _canvas_width
 
int _height
 
std::map< int, imu_renderer_imus
 
text_renderer _main_win
 
std::map< int, pose_renderer_poses
 
std::map< int, texture_textures
 
float _tile_height_pixels
 
float _tile_width_pixels
 
unsigned _tiles_in_col
 
unsigned _tiles_in_row
 
int _width
 
GLFWwindowwin
 

Detailed Description

Definition at line 498 of file example.hpp.

Constructor & Destructor Documentation

window::window ( int  width,
int  height,
const char *  title 
)
inline

Definition at line 506 of file example.hpp.

window::window ( unsigned  width,
unsigned  height,
const char *  title,
unsigned  tiles_in_row,
unsigned  tiles_in_col,
float  canvas_width = 0.8f,
float  canvas_height = 0.6f,
float  canvas_left_top_x = 0.1f,
float  canvas_left_top_y = 0.075f 
)
inline

Definition at line 545 of file example.hpp.

window::~window ( )
inline

Definition at line 616 of file example.hpp.

Member Function Documentation

rect window::calc_grid ( rect  r,
size_t  streams 
)
inlineprivate

Definition at line 802 of file example.hpp.

std::vector<rect> window::calc_grid ( rect  r,
std::vector< rs2::frame > &  frames 
)
inlineprivate

Definition at line 823 of file example.hpp.

bool window::can_render ( const rs2::frame f) const
inlineprivate

Definition at line 786 of file example.hpp.

void window::close ( )
inline

Definition at line 622 of file example.hpp.

float window::height ( ) const
inline

Definition at line 628 of file example.hpp.

window::operator bool ( )
inline

Definition at line 630 of file example.hpp.

window::operator GLFWwindow * ( )
inline

Definition at line 729 of file example.hpp.

void window::render_frameset ( const rs2::frameset frames,
const rect r 
)
inlineprivate

Definition at line 761 of file example.hpp.

void window::render_motion_frame ( const rs2::motion_frame f,
const rect r 
)
inlineprivate

Definition at line 749 of file example.hpp.

void window::render_pose_frame ( const rs2::pose_frame f,
const rect r 
)
inlineprivate

Definition at line 755 of file example.hpp.

void window::render_video_frame ( const rs2::video_frame f,
const rect r 
)
inlineprivate

Definition at line 743 of file example.hpp.

void window::show ( rs2::frame  frame)
inline

Definition at line 652 of file example.hpp.

void window::show ( const rs2::frame frame,
const rect rect 
)
inline

Definition at line 657 of file example.hpp.

void window::show ( const std::map< int, rs2::frame > &  frames)
inline

Definition at line 669 of file example.hpp.

void window::show ( const frames_mosaic frames)
inline

Definition at line 696 of file example.hpp.

float window::width ( ) const
inline

Definition at line 627 of file example.hpp.

Member Data Documentation

int window::_canvas_height
private

Definition at line 739 of file example.hpp.

float window::_canvas_left_top_x
private

Definition at line 738 of file example.hpp.

float window::_canvas_left_top_y
private

Definition at line 738 of file example.hpp.

int window::_canvas_width
private

Definition at line 739 of file example.hpp.

int window::_height
private

Definition at line 737 of file example.hpp.

std::map<int, imu_renderer> window::_imus
private

Definition at line 734 of file example.hpp.

text_renderer window::_main_win
private

Definition at line 736 of file example.hpp.

std::map<int, pose_renderer> window::_poses
private

Definition at line 735 of file example.hpp.

std::map<int, texture> window::_textures
private

Definition at line 733 of file example.hpp.

float window::_tile_height_pixels
private

Definition at line 741 of file example.hpp.

float window::_tile_width_pixels
private

Definition at line 741 of file example.hpp.

unsigned window::_tiles_in_col
private

Definition at line 740 of file example.hpp.

unsigned window::_tiles_in_row
private

Definition at line 740 of file example.hpp.

int window::_width
private

Definition at line 737 of file example.hpp.

std::function<void(int)> window::on_key_release = [](int) {}

Definition at line 504 of file example.hpp.

std::function<void(bool)> window::on_left_mouse = [](bool) {}

Definition at line 501 of file example.hpp.

std::function<void(double, double)> window::on_mouse_move = [](double, double) {}

Definition at line 503 of file example.hpp.

std::function<void(double, double)> window::on_mouse_scroll = [](double, double) {}

Definition at line 502 of file example.hpp.

GLFWwindow* window::win
private

Definition at line 732 of file example.hpp.


The documentation for this class was generated from the following file:


librealsense2
Author(s): Sergey Dorodnicov , Doron Hirshberg , Mark Horn , Reagan Lopez , Itay Carpis
autogenerated on Mon May 3 2021 02:50:33