GL Studio C++ Runtime API
tessellate.h
Go to the documentation of this file.
1/*! \file
2 \brief Tesselator functions. Allows tesselation of complex polygons into simple ones.
3
4 \par Copyright Information
5
6 Copyright (c) 2017 by The DiSTI Corporation.<br>
7 11301 Corporate Blvd; Suite 100<br>
8 Orlando, Florida 32817<br>
9 USA<br>
10 <br>
11 All rights reserved.<br>
12
13 This Software contains proprietary trade secrets of DiSTI and may not be
14reproduced, in whole or part, in any form, or by any means of electronic,
15mechanical, or otherwise, without the written permission of DiSTI. Said
16permission may be derived through the purchase of applicable DiSTI product
17licenses which detail the distribution rights of this content and any
18Derivative Works based on this or other copyrighted DiSTI Software.
19
20 NO WARRANTY. THE SOFTWARE IS PROVIDED "AS-IS," WITHOUT WARRANTY OF ANY KIND,
21AND ANY USE OF THIS SOFTWARE PRODUCT IS AT YOUR OWN RISK. TO THE MAXIMUM EXTENT
22PERMITTED BY APPLICABLE LAW, DISTI AND ITS SUPPLIERS DISCLAIM ALL WARRANTIES
23AND CONDITIONS, EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
24IMPLIED WARRANTIES AND CONDITIONS OF MERCHANTABILITY AND/OR FITNESS FOR A
25PARTICULAR PURPOSE, TITLE, AND NON-INFRINGEMENT, WITH REGARD TO THE SOFTWARE.
26
27 LIMITATION OF LIABILITY. TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE LAW,
28IN NO EVENT SHALL DISTI OR ITS SUPPLIERS BE LIABLE FOR ANY SPECIAL, INCIDENTAL,
29INDIRECT, OR CONSEQUENTIAL DAMAGES WHATSOEVER (INCLUDING, WITHOUT LIMITATION,
30DAMAGES FOR LOSS OF BUSINESS PROFITS, BUSINESS INTERRUPTION, LOSS OF BUSINESS
31INFORMATION, OR ANY OTHER PECUNIARY LOSS) ARISING OUT OF THE USE OF OR
32INABILITY TO USE THE SOFTWARE, EVEN IF DISTI HAS BEEN ADVISED OF THE POSSIBILITY
33OF SUCH DAMAGES. DISTI'S ENTIRE LIABILITY AND YOUR EXCLUSIVE REMEDY SHALL NOT
34EXCEED FIVE DOLLARS (US$5.00).
35
36 The aforementioned terms and restrictions are governed by the laws of the
37State of Florida and the United States of America.
38
39*/
40#ifndef __TESSELLATE_H
41#define __TESSELLATE_H
42
43#include "dynamic_array.h"
44#include "gls_include.h"
45
46// copied from gui_defs.h
47#define ID_TESSELLATE_SINGLE 340 ///< Unused, kept for backward compatibility.
48#define ID_TESSELLATE_UNION 341 ///< Perform tessellation as a union of objects.
49#define ID_TESSELLATE_INTERSECT 342 ///< Perform tessellation as the intersection of objects.
50#define ID_TESSELLATE_DIFFERENCE 343 ///< Perform tessellation as a difference of objects.
51
52namespace disti
53{
54typedef DisplayObject* ( *CreateGroupFunc )(); ///< Typedef for a function pointer used to create a group.
55typedef DisplayObject* ( *CreatePolyFunc )(); ///< Typedef for a function pointer used to create a polygon.
56typedef Group* ( *DecomposeFunc )( DisplayObject* ); ///< Typedef for a function pointer used to decompose an object.
57
58/**
59 Tesselator functions. Implements polygon tessellation.
60 */
61
62/** Called by application to perform a CSG operation while tesselating one group of objects.
63 * \param obj_list Pointer to group of objects to tessellate
64 * \return Pointer to the group of the polygons generated during tesselation.
65 * The polygons will all be 2, or 3 vertices no more!
66 */
68
69/** Called by application to perform a CSG operation while tesselating two objects.
70 * \param object_list List containing the two objects to tessellate
71 * \param tesstype The operation to perform (union, intersect, subtract)
72 * \return Pointer to the group of the polygons generated during tesselation
73 */
74
76
77/** Called by application to perform a CSG operation on a character glyph
78 * \param obj_list Pointer to group of objects to tessellate
79 * \return Pointer to the group of the polygons generated during tesselation.
80 * The polygons will have OpenGl drawing primatives, e.g. TRIANGLE_FAN as
81 * generated by the tessellator
82 */
84
85} // namespace disti
86
87#endif
Definition: display.h:96
Definition: group.h:53
The disti::DynamicArray class. A templated array of objects capable of dynamically growing.
A file for all GL Studio files to include.
#define GLS_EXPORT
Macro denoting which functions should be visible from the runtime library.
Definition: gls_include.h:52
Force inclusion of the DirectShow library.
Definition: bmpimage.h:47
DisplayObject *(* CreatePolyFunc)()
Typedef for a function pointer used to create a polygon.
Definition: tessellate.h:55
Group * Tessellate(Group *obj_list, CreateGroupFunc, CreatePolyFunc, DecomposeFunc)
DisplayObject *(* CreateGroupFunc)()
Typedef for a function pointer used to create a group.
Definition: tessellate.h:54
Group *(* DecomposeFunc)(DisplayObject *)
Typedef for a function pointer used to decompose an object.
Definition: tessellate.h:56
Group * TessellateGlyph(Group *obj_list, CreateGroupFunc, CreatePolyFunc, DecomposeFunc)