OGLplus (0.52.0) a C++ wrapper for OpenGL

path.hpp
Go to the documentation of this file.
1 
12 #pragma once
13 #ifndef OGLPLUS_EXT_NV_PATH_RENDERING_PATH_1203031902_HPP
14 #define OGLPLUS_EXT_NV_PATH_RENDERING_PATH_1203031902_HPP
15 
16 #if OGLPLUS_DOCUMENTATION_ONLY || GL_NV_path_rendering
17 
18 #include <oglplus/string/ref.hpp>
19 #include <oglplus/error/object.hpp>
21 #include <oglplus/data_type.hpp>
22 
32 #if !OGLPLUS_NO_VARIADIC_TEMPLATES
34 #endif
35 
36 #include <vector>
37 
38 namespace oglplus {
39 
41 
48 template <>
49 class ObjGenDelOps<tag::PathNV>
50 {
51 protected:
52  static void Gen(tag::Generate, GLsizei count, GLuint* names)
53  {
54  assert(names != nullptr);
55  GLuint base = OGLPLUS_GLFUNC(GenPathsNV)(count);
56  for(GLsizei i=0; i!=count; ++i)
57  names[i] = base+i;
58  OGLPLUS_CHECK_SIMPLE(GenPathsNV);
59  }
60 
61  static void Delete(GLsizei count, GLuint* names)
62  {
63  assert(names != nullptr);
64  OGLPLUS_GLFUNC(DeletePathsNV)(count, *names);
65  OGLPLUS_VERIFY_SIMPLE(DeletePathsNV);
66  }
67 
68  static GLboolean IsA(GLuint name)
69  {
70  assert(name != 0);
71  GLboolean result = OGLPLUS_GLFUNC(IsPathNV)(name);
72  OGLPLUS_VERIFY_SIMPLE(IsPathNV);
73  return result;
74  }
75 };
76 
78 
80 template <>
81 class ObjectOps<tag::DirectState, tag::PathNV>
82  : public ObjZeroOps<tag::DirectState, tag::PathNV>
83 {
84 protected:
85  ObjectOps(void){ }
86 public:
88 
92  template <typename CoordType>
94  GLsizei num_commands,
95  const PathNVCommand* commands,
96  GLsizei num_coords,
97  const CoordType* coords
98  )
99  {
100  OGLPLUS_GLFUNC(PathCommandsNV)(
101  this->_name,
102  num_commands,
103  (const GLubyte*)commands,
104  num_coords,
105  GLenum(GetDataType<CoordType>()),
106  (const void*)coords
107  );
108  OGLPLUS_CHECK(
109  PathCommandsNV,
110  ObjectError,
111  Object(*this)
112  );
113  return *this;
114  }
115 
117 
121  template <typename CoordType>
123  const std::vector<PathNVCommand>& commands,
124  const std::vector<CoordType>& coords
125  )
126  {
127  OGLPLUS_GLFUNC(PathCommandsNV)(
128  this->_name,
129  GLsizei(commands.size()),
130  (const GLubyte*)commands.data(),
131  GLsizei(coords.size()),
132  GLenum(GetDataType<CoordType>()),
133  (const void*)coords.data()
134  );
135  OGLPLUS_CHECK(
136  PathCommandsNV,
137  ObjectError,
138  Object(*this)
139  );
140  return *this;
141  }
142 
143 #if OGLPLUS_DOCUMENTATION_ONLY || !OGLPLUS_NO_VARIADIC_TEMPLATES
144 
151  template <typename CoordType>
153  {
154  return Commands<CoordType>(spec._commands, spec._coords);
155  }
156 #endif
157 
159 
163  template <typename CoordType>
164  ObjectOps& Coords(GLsizei num_coords, const CoordType* coords)
165  {
166  OGLPLUS_GLFUNC(PathCoordsNV)(
167  this->_name,
168  num_coords,
169  GLenum(GetDataType<CoordType>()),
170  static_cast<const void*>(coords)
171  );
172  OGLPLUS_CHECK(
173  PathCoordsNV,
174  ObjectError,
175  Object(*this)
176  );
177  return *this;
178  }
179 
181 
185  template <typename CoordType>
186  ObjectOps& Coords(const std::vector<CoordType>& coords)
187  {
188  OGLPLUS_GLFUNC(PathCoordsNV)(
189  this->_name,
190  GLsizei(coords.size()),
191  GLenum(GetDataType<CoordType>()),
192  (const void*)coords.data()
193  );
194  OGLPLUS_CHECK(
195  PathCoordsNV,
196  ObjectError,
197  Object(*this)
198  );
199  return *this;
200  }
201 
203 
207  template <typename CoordType>
209  GLsizei command_start,
210  GLsizei commands_to_delete,
211  GLsizei num_commands,
212  const PathNVCommand* commands,
213  GLsizei num_coords,
214  const CoordType* coords
215  )
216  {
217  OGLPLUS_GLFUNC(PathSubCommandsNV)(
218  this->_name,
219  command_start,
220  commands_to_delete,
221  num_commands,
222  (const GLubyte*)commands,
223  num_coords,
224  GLenum(GetDataType<CoordType>()),
225  (const void*)coords
226  );
227  OGLPLUS_CHECK(
228  PathSubCommandsNV,
229  ObjectError,
230  Object(*this)
231  );
232  return *this;
233  }
234 
236 
240  template <typename CoordType>
242  GLsizei command_start,
243  GLsizei commands_to_delete,
244  const std::vector<PathNVCommand>& commands,
245  const std::vector<CoordType>& coords
246  )
247  {
248  OGLPLUS_GLFUNC(PathSubCommandsNV)(
249  this->_name,
250  command_start,
251  commands_to_delete,
252  GLsizei(commands.size()),
253  (const GLubyte*)commands.data(),
254  GLsizei(coords.size()),
255  GLenum(GetDataType<CoordType>()),
256  (const void*)coords.data()
257  );
258  OGLPLUS_CHECK(
259  PathSubCommandsNV,
260  ObjectError,
261  Object(*this)
262  );
263  return *this;
264  }
265 
266 #if OGLPLUS_DOCUMENTATION_ONLY || !OGLPLUS_NO_VARIADIC_TEMPLATES
267 
272  template <typename CoordType>
274  GLsizei command_start,
275  GLsizei commands_to_delete,
276  const PathNVSpec<CoordType>& spec
277  )
278  {
279  return SubCommands<CoordType>(
280  command_start,
281  commands_to_delete,
282  spec._commands,
283  spec._coords
284  );
285  }
286 #endif
287 
289 
293  template <typename CoordType>
295  GLsizei coord_start,
296  GLsizei num_coords,
297  const CoordType* coords
298  )
299  {
300  OGLPLUS_GLFUNC(PathSubCoordsNV)(
301  this->_name,
302  coord_start,
303  num_coords,
304  GLenum(GetDataType<CoordType>()),
305  static_cast<const void*>(coords)
306  );
307  OGLPLUS_CHECK(
308  PathSubCoordsNV,
309  ObjectError,
310  Object(*this)
311  );
312  return *this;
313  }
314 
316 
320  template <typename CoordType>
322  GLsizei coord_start,
323  const std::vector<CoordType>& coords
324  )
325  {
326  OGLPLUS_GLFUNC(PathSubCoordsNV)(
327  this->_name,
328  coord_start,
329  GLsizei(coords.size()),
330  GLenum(GetDataType<CoordType>()),
331  (const void*)coords
332  );
333  OGLPLUS_CHECK(
334  PathSubCoordsNV,
335  ObjectError,
336  Object(*this)
337  );
338  return *this;
339  }
340 
341 
343 
348  PathNVFormat format,
349  GLsizei length,
350  const GLchar* path_string
351  )
352  {
353  OGLPLUS_GLFUNC(PathStringNV)(
354  this->_name,
355  GLenum(format),
356  length,
357  static_cast<const void*>(path_string)
358  );
359  OGLPLUS_CHECK(
360  PathStringNV,
361  ObjectError,
362  Object(*this)
363  );
364  return *this;
365  }
366 
368 
372  ObjectOps& PathString(PathNVFormat format, StrCRef path_string)
373  {
374  OGLPLUS_GLFUNC(PathStringNV)(
375  this->_name,
376  GLenum(format),
377  path_string.size(),
378  static_cast<const void*>(path_string.c_str())
379  );
380  OGLPLUS_CHECK(
381  PathStringNV,
382  ObjectError,
383  Object(*this)
384  );
385  return *this;
386  }
387 
389 
394  ObjectOps& SVGString(GLsizei length, const GLchar* path_string)
395  {
396  PathString(PathNVFormat::SVG, length, path_string);
397  return *this;
398  }
399 
401 
407  {
408  PathString(PathNVFormat::SVG, path_string);
409  return *this;
410  }
411 
413 
418  ObjectOps& PSString(GLsizei length, const GLchar* path_string)
419  {
420  PathString(PathNVFormat::PS, length, path_string);
421  return *this;
422  }
423 
425 
430  ObjectOps& PSString(StrCRef path_string)
431  {
432  PathString(PathNVFormat::PS, path_string);
433  return *this;
434  }
435 
437 
441  bool IsPointInFill(GLuint mask, GLfloat x, GLfloat y) const
442  {
443  GLboolean result = OGLPLUS_GLFUNC(IsPointInFillPathNV)(
444  this->_name,
445  mask,
446  x, y
447  );
448  OGLPLUS_VERIFY(
449  IsPointInFillPathNV,
450  ObjectError,
451  Object(*this)
452  );
453  return result == GL_TRUE;
454  }
455 
457 
461  bool IsPointInStroke(GLfloat x, GLfloat y) const
462  {
463  GLboolean result = OGLPLUS_GLFUNC(IsPointInStrokePathNV)(
464  this->_name,
465  x, y
466  );
467  OGLPLUS_VERIFY(
468  IsPointInStrokePathNV,
469  ObjectError,
470  Object(*this)
471  );
472  return result == GL_TRUE;
473  }
474 
476 
480  GLfloat GetLength(GLsizei start_segment, GLsizei num_segments) const
481  {
482  GLfloat result = OGLPLUS_GLFUNC(GetPathLengthNV)(
483  this->_name,
484  start_segment,
485  num_segments
486  );
487  OGLPLUS_CHECK(
488  GetPathLengthNV,
489  ObjectError,
490  Object(*this)
491  );
492  return result;
493  }
494 
496 
501  GLsizei start_segment,
502  GLsizei num_segments,
503  GLfloat distance,
504  GLfloat& ref_x,
505  GLfloat& ref_y,
506  GLfloat& ref_tg_x,
507  GLfloat& ref_tg_y
508  ) const
509  {
510  GLboolean result = OGLPLUS_GLFUNC(PointAlongPathNV)(
511  this->_name,
512  start_segment,
513  num_segments,
514  distance,
515  &ref_x,
516  &ref_y,
517  &ref_tg_x,
518  &ref_tg_y
519  );
520  OGLPLUS_CHECK(
521  PointAlongPathNV,
522  ObjectError,
523  Object(*this)
524  );
525  return result == GL_TRUE;
526  }
527 
529 
534  ObjectOps& StrokeWidth(GLfloat width)
535  {
536  OGLPLUS_GLFUNC(PathParameterfNV)(
537  this->_name,
538  GL_PATH_STROKE_WIDTH_NV,
539  width
540  );
541  OGLPLUS_CHECK(
542  PathParameterfNV,
543  ObjectError,
544  Object(*this)
545  );
546  return *this;
547  }
548 
550 
555  GLfloat StrokeWidth(void)
556  {
557  GLfloat result;
558  OGLPLUS_GLFUNC(GetPathParameterfvNV)(
559  this->_name,
560  GL_PATH_STROKE_WIDTH_NV,
561  &result
562  );
563  OGLPLUS_VERIFY(
564  GetPathParameterfvNV,
565  ObjectError,
566  Object(*this)
567  );
568  return result;
569  }
570 
572 
577  ObjectOps& MiterLimit(GLfloat width)
578  {
579  OGLPLUS_GLFUNC(PathParameterfNV)(
580  this->_name,
581  GL_PATH_MITER_LIMIT_NV,
582  width
583  );
584  OGLPLUS_CHECK(
585  PathParameterfNV,
586  ObjectError,
587  Object(*this)
588  );
589  return *this;
590  }
591 
593 
598  GLfloat MiterLimit(void)
599  {
600  GLfloat result;
601  OGLPLUS_GLFUNC(GetPathParameterfvNV)(
602  this->_name,
603  GL_PATH_MITER_LIMIT_NV,
604  &result
605  );
606  OGLPLUS_VERIFY(
607  GetPathParameterfvNV,
608  ObjectError,
609  Object(*this)
610  );
611  return result;
612  }
613 
615 
621  {
622  OGLPLUS_GLFUNC(PathParameterfNV)(
623  this->_name,
624  GL_PATH_JOIN_STYLE_NV,
625  GLenum(style)
626  );
627  OGLPLUS_CHECK(
628  PathParameterfNV,
629  ObjectError,
630  Object(*this)
631  );
632  return *this;
633  }
634 
636 
642  {
643  OGLPLUS_GLFUNC(PathParameterfNV)(
644  this->_name,
645  GL_PATH_INITIAL_END_CAP_NV,
646  GLenum(style)
647  );
648  OGLPLUS_CHECK(
649  PathParameterfNV,
650  ObjectError,
651  Object(*this)
652  );
653  return *this;
654  }
655 
657 
663  {
664  OGLPLUS_GLFUNC(PathParameterfNV)(
665  this->_name,
666  GL_PATH_TERMINAL_END_CAP_NV,
667  GLenum(style)
668  );
669  OGLPLUS_CHECK(
670  PathParameterfNV,
671  ObjectError,
672  Object(*this)
673  );
674  return *this;
675  }
676 
678 
684  {
685  OGLPLUS_GLFUNC(PathParameterfNV)(
686  this->_name,
687  GL_PATH_INITIAL_DASH_CAP_NV,
688  GLenum(style)
689  );
690  OGLPLUS_CHECK(
691  PathParameterfNV,
692  ObjectError,
693  Object(*this)
694  );
695  return *this;
696  }
697 
699 
705  {
706  OGLPLUS_GLFUNC(PathParameterfNV)(
707  this->_name,
708  GL_PATH_TERMINAL_DASH_CAP_NV,
709  GLenum(style)
710  );
711  OGLPLUS_CHECK(
712  PathParameterfNV,
713  ObjectError,
714  Object(*this)
715  );
716  return *this;
717  }
718 
720 
725  ObjectOps& DashOffset(GLfloat width)
726  {
727  OGLPLUS_GLFUNC(PathParameterfNV)(
728  this->_name,
729  GL_PATH_DASH_OFFSET_NV,
730  width
731  );
732  OGLPLUS_CHECK(
733  PathParameterfNV,
734  ObjectError,
735  Object(*this)
736  );
737  return *this;
738  }
739 
741 
746  GLfloat DashOffset(void)
747  {
748  GLfloat result;
749  OGLPLUS_GLFUNC(GetPathParameterfvNV)(
750  this->_name,
751  GL_PATH_DASH_OFFSET_NV,
752  &result
753  );
754  OGLPLUS_VERIFY(
755  GetPathParameterfvNV,
756  ObjectError,
757  Object(*this)
758  );
759  return result;
760  }
761 
763 
769  {
770  OGLPLUS_GLFUNC(PathParameterfNV)(
771  this->_name,
772  GL_PATH_DASH_OFFSET_RESET_NV,
773  GLenum(mode)
774  );
775  OGLPLUS_CHECK(
776  PathParameterfNV,
777  ObjectError,
778  Object(*this)
779  );
780  return *this;
781  }
782 
784 
788  ObjectOps& DashArray(GLsizei dash_count, const GLfloat* dash_array)
789  {
790  OGLPLUS_GLFUNC(PathDashArrayNV)(
791  this->_name,
792  dash_count,
793  dash_array
794  );
795  OGLPLUS_CHECK(
796  PathDashArrayNV,
797  ObjectError,
798  Object(*this)
799  );
800  return *this;
801  }
802 
803 #if OGLPLUS_DOCUMENTATION_ONLY || !OGLPLUS_NO_VARIADIC_TEMPLATES
804 
809  template <typename ... T>
810  ObjectOps& Dashes(T ... dashes)
811  {
812  const std::size_t N = sizeof ... (dashes);
813  const GLfloat dash_array[N] = { GLfloat(dashes)... };
814  return DashArray(N, dash_array);
815  }
816 #endif
817 
819 
824  ObjectOps& ClientLength(GLfloat value)
825  {
826  OGLPLUS_GLFUNC(PathParameterfNV)(
827  this->_name,
828  GL_PATH_CLIENT_LENGTH_NV,
829  value
830  );
831  OGLPLUS_CHECK(
832  PathParameterfNV,
833  ObjectError,
834  Object(*this)
835  );
836  return *this;
837  }
838 
840 
845  GLfloat ClientLength(void)
846  {
847  GLfloat result;
848  OGLPLUS_GLFUNC(GetPathParameterfvNV)(
849  this->_name,
850  GL_PATH_CLIENT_LENGTH_NV,
851  &result
852  );
853  OGLPLUS_VERIFY(
854  GetPathParameterfvNV,
855  ObjectError,
856  Object(*this)
857  );
858  return result;
859  }
860 
861 
863 
868  {
869  OGLPLUS_GLFUNC(StencilFillPathNV)(
870  this->_name,
871  GLenum(mode),
872  mask
873  );
874  OGLPLUS_CHECK(
875  StencilFillPathNV,
876  ObjectError,
877  Object(*this)
878  );
879  return *this;
880  }
881 
883 
888  {
889  OGLPLUS_GLFUNC(CoverFillPathNV)(this->_name, GLenum(mode));
890  OGLPLUS_CHECK(
891  CoverFillPathNV,
892  ObjectError,
893  Object(*this)
894  );
895  return *this;
896  }
897 
899 
903  ObjectOps& StencilStroke(GLint reference, GLuint mask)
904  {
905  OGLPLUS_GLFUNC(StencilStrokePathNV)(
906  this->_name,
907  reference,
908  mask
909  );
910  OGLPLUS_CHECK(
911  StencilStrokePathNV,
912  ObjectError,
913  Object(*this)
914  );
915  return *this;
916  }
917 
919 
924  {
925  OGLPLUS_GLFUNC(CoverStrokePathNV)(this->_name, GLenum(mode));
926  OGLPLUS_CHECK(
927  CoverStrokePathNV,
928  ObjectError,
929  Object(*this)
930  );
931  return *this;
932  }
933 
935 
939  static PathNVName Copy(
940  PathNVName dest_path,
941  PathNVName src_path
942  )
943  {
944  OGLPLUS_GLFUNC(CopyPathNV)(
945  GetGLName(dest_path),
946  GetGLName(src_path)
947  );
948  OGLPLUS_CHECK(
949  CopyPathNV,
950  ObjectPairError,
951  Subject(src_path).
952  Object(dest_path)
953  );
954  return dest_path;
955  }
956 
958 
963  PathNVName dest_path,
964  PathNVName path_a,
965  PathNVName path_b,
966  GLfloat weight
967  )
968  {
969  OGLPLUS_GLFUNC(InterpolatePathsNV)(
970  GetGLName(dest_path),
971  GetGLName(path_a),
972  GetGLName(path_b),
973  weight
974  );
975  OGLPLUS_CHECK(
976  InterpolatePathsNV,
977  ObjectError,
978  Object(dest_path)
979  );
980  return dest_path;
981  }
982 
984 
989  PathNVName dest_path,
990  PathNVName src_path,
991  PathNVTransformType transform_type,
992  const GLfloat* transform_values
993  )
994  {
995  OGLPLUS_GLFUNC(TransformPathNV)(
996  GetGLName(dest_path),
997  GetGLName(src_path),
998  GLenum(transform_type),
999  transform_values
1000  );
1001  OGLPLUS_CHECK(
1002  TransformPathNV,
1003  ObjectPairError,
1004  Subject(src_path).
1005  Object(dest_path)
1006  );
1007  return dest_path;
1008  }
1009 };
1010 
1012 typedef ObjectOps<tag::DirectState, tag::PathNV>
1014 
1016 
1019 typedef Object<PathNVOps> PathNV;
1020 
1021 } // namespace oglplus
1022 
1023 #endif // NV_path_rendering
1024 
1025 #endif // include guard
const Char * c_str(void) const
Returns the null-terminated c-string.
Definition: ref_tpl.hpp:200
ObjectOps & CoverStroke(PathNVStrokeCoverMode mode)
Covers the stencilled path stroke.
Definition: path.hpp:923
PathNVDashOffsetReset
Path dash offset reset mode enumeration.
Definition: dash_offset_reset.hpp:27
ObjectOps & Commands(GLsizei num_commands, const PathNVCommand *commands, GLsizei num_coords, const CoordType *coords)
Specifies the path via a sequence of commands and coordinates.
Definition: path.hpp:93
ObjectOps & ClientLength(GLfloat value)
Sets the client length value.
Definition: path.hpp:824
GLfloat ClientLength(void)
Returns the client length value.
Definition: path.hpp:845
ObjectOps & TerminalEndCap(PathNVCapStyle style)
Sets the terminal end cap style.
Definition: path.hpp:662
PathNVFillCoverMode
Path fill covering mode.
Definition: fill_cover_mode.hpp:27
PathNVCommand
Path specification command enumeration.
Definition: command.hpp:27
static PathNVName Copy(PathNVName dest_path, PathNVName src_path)
Copy path.
Definition: path.hpp:939
bool PointAlong(GLsizei start_segment, GLsizei num_segments, GLfloat distance, GLfloat &ref_x, GLfloat &ref_y, GLfloat &ref_tg_x, GLfloat &ref_tg_y) const
Get a point along the specified segment of the path.
Definition: path.hpp:500
ObjectOps & Dashes(T...dashes)
Sets the path dash array.
Definition: path.hpp:810
Wrapper for the NV_path_rendering transform type enumeration.
Wrapper for the NV_path_rendering dash offset reset enumeration.
Wrapper for the NV_path_rendering fill cover mode enumeration.
ObjectOps & DashOffsetReset(PathNVDashOffsetReset mode)
Sets the dash reset mode.
Definition: path.hpp:768
Wrapper for the NV_path_rendering fill mode enumeration.
PathNVStrokeCoverMode
Path stroke covering move.
Definition: stroke_cover_mode.hpp:27
Wrapper for the NV_path_rendering format enumeration.
ObjectOps & Commands(const std::vector< PathNVCommand > &commands, const std::vector< CoordType > &coords)
Specifies the path via a sequence of commands and coordinates.
Definition: path.hpp:122
PathNVFormat
Path specification string format enumeration.
Definition: format.hpp:27
ObjectOps & PSString(StrCRef path_string)
Specifies the path using a Postscript string.
Definition: path.hpp:430
Wrapper for the NV_path_rendering extension.
Declaration of OGLplus object-related error.
Wrapper for the NV_path_rendering stroke cover mode enumeration.
Generic OpenGL object wrapper.
PathNVCapStyle
Path cap mode enumeration.
Definition: cap_style.hpp:27
static PathNVName Interpolate(PathNVName dest_path, PathNVName path_a, PathNVName path_b, GLfloat weight)
Interpolates between two paths.
Definition: path.hpp:962
ObjectOps & SVGString(GLsizei length, const GLchar *path_string)
Specifies the path using an SVG string.
Definition: path.hpp:394
ObjectOps & Coords(GLsizei num_coords, const CoordType *coords)
Specifies the path via a sequence of coordinates.
Definition: path.hpp:164
Implements operations applicable to named (non-zero) objects.
Definition: wrap_tpl.hpp:45
bool IsPointInFill(GLuint mask, GLfloat x, GLfloat y) const
Checks if the specified point is in the path interior.
Definition: path.hpp:441
Wrapper for the NV_path_rendering path specification wrapper.
GLuint GetGLName(ObjectName< ObjTag > named)
Returns the GLuint OpenGL name assigned to named object.
Definition: name.hpp:38
String reference.
ObjectOps & MiterLimit(GLfloat width)
Sets the miter limit.
Definition: path.hpp:577
std::size_t size(void) const
Return the size (length) string.
Definition: ref_tpl.hpp:149
ObjectOps & SubCommands(GLsizei command_start, GLsizei commands_to_delete, const std::vector< PathNVCommand > &commands, const std::vector< CoordType > &coords)
Replaces a part of the the path with new commands and coordinates.
Definition: path.hpp:241
GLfloat DashOffset(void)
Gets the dash offset value.
Definition: path.hpp:746
PathNVFillMode
Path fill mode.
Definition: fill_mode.hpp:27
ObjectOps & CoverFill(PathNVFillCoverMode mode)
Covers the stencilled path interior (fill)
Definition: path.hpp:887
ObjectOps & PSString(GLsizei length, const GLchar *path_string)
Specifies the path using a Postscript string.
Definition: path.hpp:418
ObjectOps & SubCoords(GLsizei coord_start, const std::vector< CoordType > &coords)
Replaces some of the paths coordinates.
Definition: path.hpp:321
bool IsPointInStroke(GLfloat x, GLfloat y) const
Checks if the specified point is on the path outline.
Definition: path.hpp:461
String const reference wrapper template.
Definition: ref_tpl.hpp:72
ObjectOps & Spec(const PathNVSpec< CoordType > &spec)
Specifies the path via the PathNVSpec class.
Definition: path.hpp:152
ObjectOps & Coords(const std::vector< CoordType > &coords)
Specifies the path via a sequence of coordinates.
Definition: path.hpp:186
Wrapper for the NV_path_rendering cap style enumeration.
GLfloat MiterLimit(void)
Gets the miter limit value.
Definition: path.hpp:598
Implements operations applicable to any object including object 0 (zero)
Definition: fwd.hpp:157
Data type-related declarations.
ObjectOps & DashOffset(GLfloat width)
Sets the dash offset.
Definition: path.hpp:725
ObjectOps & InitialDashCap(PathNVCapStyle style)
Sets the initial dash cap style.
Definition: path.hpp:683
Template class for convenient specifying of path commands and coordinates.
Definition: path_spec.hpp:32
GLfloat StrokeWidth(void)
Gets the stroke width value.
Definition: path.hpp:555
Wrapper for the NV_path_rendering command enumeration.
PathNVJoinStyle
Stroke line join style enumeration.
Definition: join_style.hpp:27
ObjectOps & StrokeWidth(GLfloat width)
Sets the stroke width value.
Definition: path.hpp:534
static PathNVName Transform(PathNVName dest_path, PathNVName src_path, PathNVTransformType transform_type, const GLfloat *transform_values)
Transforms a path.
Definition: path.hpp:988
ObjectOps & DashArray(GLsizei dash_count, const GLfloat *dash_array)
Sets the path dash array.
Definition: path.hpp:788
ObjectOps & SVGString(StrCRef path_string)
Specifies the path using an SVG string.
Definition: path.hpp:406
ObjectOps & InitialEndCap(PathNVCapStyle style)
Sets the initial end cap style.
Definition: path.hpp:641
PATH_FORMAT_PS_NV.
ObjectOps & SubCoords(GLsizei coord_start, GLsizei num_coords, const CoordType *coords)
Replaces some of the paths coordinates.
Definition: path.hpp:294
Exception class for GL object-related errors.
Definition: object.hpp:24
ObjectOps< tag::DirectState, tag::PathNV > PathNVOps
PathNV operations with direct state access.
Definition: path.hpp:1013
ObjectOps & SubCommands(GLsizei command_start, GLsizei commands_to_delete, GLsizei num_commands, const PathNVCommand *commands, GLsizei num_coords, const CoordType *coords)
Replaces a part of the the path with new commands and coordinates.
Definition: path.hpp:208
ObjectOps & PathString(PathNVFormat format, StrCRef path_string)
Specifies the path using an SVG string.
Definition: path.hpp:372
GLfloat GetLength(GLsizei start_segment, GLsizei num_segments) const
Returns the approximation of the length of the path.
Definition: path.hpp:480
ObjectOps & PathString(PathNVFormat format, GLsizei length, const GLchar *path_string)
Specifies the path using a string.
Definition: path.hpp:347
ObjectOps & JoinStyle(PathNVJoinStyle style)
Sets the stroke join style.
Definition: path.hpp:620
PATH_FORMAT_SVG_NV.
PathNVTransformType
Path transform type enumeration.
Definition: transform_type.hpp:27
ObjectOps & StencilStroke(GLint reference, GLuint mask)
Writes the path stroke into the stencil buffer.
Definition: path.hpp:903
ObjectOps & SubSpec(GLsizei command_start, GLsizei commands_to_delete, const PathNVSpec< CoordType > &spec)
Replaces a part of the the path with new commands and coordinates.
Definition: path.hpp:273
Object< PathNVOps > PathNV
An oglplus_object encapsulating the nVidia path functionality.
Definition: path.hpp:1019
ObjectOps & StencilFill(PathNVFillMode mode, GLuint mask)
Writes the path interior (fill) into the stencil buffer.
Definition: path.hpp:867
ObjectOps & TerminalDashCap(PathNVCapStyle style)
Sets the terminal dash cap style.
Definition: path.hpp:704

Copyright © 2010-2014 Matúš Chochlík, University of Žilina, Žilina, Slovakia.
<matus.chochlik -at- fri.uniza.sk>
<chochlik -at -gmail.com>
Documentation generated on Mon Sep 22 2014 by Doxygen (version 1.8.6).