8 #define STB_IMAGE_WRITE_IMPLEMENTATION 9 #include <stb_image_write.h> 12 #define STB_IMAGE_IMPLEMENTATION 65 draw_text(50, 50,
"This point-cloud is generated from a synthetic device:");
68 if (
now - last > std::chrono::milliseconds(1))
78 auto d = 2 + 0.1 * (1 + sin(wave_base +
j / 50.
f));
110 std::chrono::high_resolution_clock::time_point
last;
111 float wave_base = 0.f;
114 int main(
int argc,
char * argv[])
try 116 window app(1280, 1500,
"RealSense Capture Example");
161 depth_stream.register_extrinsics_to(color_stream, { { 1,0,0,0,1,0,0,0,1 },{ 0,0,0 } });
169 depth_frame.
x*depth_frame.
bpp, depth_frame.
bpp,
205 catch (
const std::exception& e)
synthetic_frame depth_frame
synthetic_frame & get_synthetic_depth(glfw_state &app_state)
GLint GLint GLsizei GLsizei GLsizei depth
STBIDEF stbi_uc * stbi_load_from_memory(stbi_uc const *buffer, int len, int *x, int *y, int *comp, int req_comp)
void map_to(frame mapped)
software_sensor add_sensor(std::string name)
frameset wait_for_frames(unsigned int timeout_ms=5000) const
frame first_or_default(rs2_stream s, rs2_format f=RS2_FORMAT_ANY) const
synthetic_frame & get_synthetic_texture()
const std::string & get_failed_args() const
synthetic_frame color_frame
void upload(const rs2::video_frame &frame)
rs2_intrinsics create_texture_intrinsics()
points calculate(frame depth) const
void create_matcher(rs2_matchers matcher)
std::vector< uint8_t > frame
static size_t splash_size
int main(int argc, char *argv[])
void draw_pointcloud(float width, float height, glfw_state &app_state, rs2::points &points)
rs2_intrinsics create_depth_intrinsics()
void draw_text(int x, int y, const char *text)
typename::boost::move_detail::remove_reference< T >::type && move(T &&t) BOOST_NOEXCEPT
void register_glfw_callbacks(window &app, glfw_state &app_state)
const std::string & get_failed_function() const
GLdouble GLdouble GLint GLint const GLdouble * points
std::chrono::high_resolution_clock::time_point last