image_viewer_impl.h 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. #ifndef DEPTHGUIDE_IMAGE_VIEWER_IMPL_H
  2. #define DEPTHGUIDE_IMAGE_VIEWER_IMPL_H
  3. #include "module/image_viewer.h"
  4. #include "render/render_tools.h"
  5. struct image_viewer::impl {
  6. create_config conf;
  7. /* for VIEW_COLOR_DEPTH
  8. * 0 = color, 1 = depth, 2 = both
  9. * for VIEW_STEREO
  10. * 0 = left, 1 = right */
  11. int chose_index = 0;
  12. using color_conf_type = color_image_render::config_type;
  13. using depth_conf_type = depth_image_render::config_type;
  14. depth_conf_type depth_conf = {};
  15. depth_image_render depth_render;
  16. color_conf_type color_conf = {};
  17. color_image_render color_render;
  18. float depth_overlay_alpha = 0.5;
  19. void show_depth_only();
  20. void show_color_depth();
  21. void show_stereo();
  22. void show();
  23. void render_color_obj(obj_name_type name);
  24. // render depth with false color
  25. void render_depth_obj(obj_name_type name, float alpha = 1.0);
  26. void render_color_depth();
  27. void render_stereo();
  28. void render();
  29. explicit impl(create_config conf);
  30. };
  31. #endif //DEPTHGUIDE_IMAGE_VIEWER_IMPL_H