HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
GU_MergeUtils.h
Go to the documentation of this file.
1 /*
2  * PROPRIETARY INFORMATION. This software is proprietary to
3  * Side Effects Software Inc., and is not to be reproduced,
4  * transmitted, or disclosed in any way without written permission.
5  *
6  * NAME: GU_MergeUtils.h ( GU Library, C++)
7  *
8  * COMMENTS:
9  */
10 
11 #ifndef __GU_MergeUtils__
12 #define __GU_MergeUtils__
13 
14 #include "GU_API.h"
15 #include <UT/UT_Array.h>
16 
17 class GU_Detail;
18 
19 /// Merge multiple geometry details into a single detail.
20 ///
21 /// Before merging, this function will perform analysis on the input details to
22 /// ensure that attributes will be promoted to a level which will prevent any
23 /// loss of data.
24 ///
25 /// For example, if one source detail has a point attribute which matches a
26 /// vertex attribute on another source, the attribute will be promoted to a
27 /// vertex attribute before merging.
28 ///
29 /// In addition, if any geometry has detail attributes which have different
30 /// values from other geometry detail attributes, the attributes will be
31 /// promoted to primitive attributes to preserve the information.
32 ///
33 /// @note The source details must be non-const since attributes may be promoted.
36 
37 /// Perform attribute matching and merging on two details.
39 
40 /// Perform attribute matching and merging on two details. This may be
41 /// significantly more expensive since the source detail is considered
42 /// constant. If the source is constant and attributes need to be promoted,
43 /// the source is duplicated before merging.
45 
46 /// Perform attribute matching and merging on an array of details.
48  GU_Detail *const*sources,
49  int nsources);
50 
51 #endif
GU_API bool GUexpensiveMatchAndMerge(GU_Detail &dest, const GU_Detail &src)
GLsizei GLenum * sources
Definition: glcorearb.h:2541
GU_API bool GUmatchAttributesAndMerge(GU_Detail &dest, const UT_Array< GU_Detail * > &sources)
#define GU_API
Definition: GU_API.h:12
GLenum src
Definition: glcorearb.h:1792