draw_point.h 855 B

1234567891011121314151617181920212223242526272829
  1. #ifndef IGL_DRAW_POINT_H
  2. #define IGL_DRAW_POINT_H
  3. #include "igl_inline.h"
  4. namespace igl
  5. {
  6. // Draw a nice looking, colored dot at a given point in 3d.
  7. //
  8. // Note: expects that GL_CURRENT_COLOR is set with the desired foreground color
  9. //
  10. // Inputs:
  11. // x x-coordinate of point, modelview coordinates
  12. // y y-coordinate of point, modelview coordinates
  13. // z z-coordinate of point, modelview coordinates
  14. // requested_r outer-most radius of dot {7}, measured in screen space pixels
  15. // selected fills inner circle with black {false}
  16. // Asserts that requested_r does not exceed 0.5*GL_POINT_SIZE_MAX
  17. IGL_INLINE void draw_point(
  18. const double x,
  19. const double y,
  20. const double z,
  21. const double requested_r = 7,
  22. const bool selected = false);
  23. }
  24. #ifdef IGL_HEADER_ONLY
  25. # include "draw_point.cpp"
  26. #endif
  27. #endif