HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
PRM_SharedFunc.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: PRM library (C++)
7  *
8  * COMMENTS: Shared functions available to the world
9  *
10  */
11 
12 #ifndef __PRM_SharedFunc_h__
13 #define __PRM_SharedFunc_h__
14 
15 #include "PRM_API.h"
16 
17 #include <SYS/SYS_Types.h>
18 class PRM_Name;
19 class PRM_SpareData;
20 class UT_String;
21 class IMG_TileFileInfo;
22 class PRM_Parm;
23 class UT_Ramp;
24 
25 PRM_API extern void
27  void *, PRM_Name *names, int size,
28  const PRM_SpareData *, const PRM_Parm *);
29 
30 PRM_API extern const PRM_Name *
32 
33 PRM_API extern void
35  void *, PRM_Name *names, int n,
36  const PRM_SpareData *, const PRM_Parm *);
37 
38 PRM_API extern const PRM_Name *
40 
41 PRM_API extern void
43  void *, PRM_Name *names, int,
44  const PRM_SpareData *, const PRM_Parm *);
45 
46 PRM_API extern const PRM_Name *
47 PRMgetFilterName(int idx);
48 
49 PRM_API extern void
51  void *, PRM_Name *names, int,
52  const PRM_SpareData *, const PRM_Parm *);
53 
54 PRM_API extern void
56  void *, PRM_Name *names, int,
57  const PRM_SpareData *, const PRM_Parm *);
58 
59 PRM_API extern void
61  void *, PRM_Name *names, int,
62  const PRM_SpareData *, const PRM_Parm *);
63 
64 PRM_API extern void
66  void *, PRM_Name *names, int,
67  const PRM_SpareData *, const PRM_Parm *);
68 
69 PRM_API extern void
71  void *, PRM_Name *names, int,
72  const PRM_SpareData *,
73  const PRM_Parm *);
74 
75 PRM_API extern void
77  void *, PRM_Name *names, int,
78  const PRM_SpareData *, const PRM_Parm *);
79 
80 /// utility method for sorting menu items by their label text
81 PRM_API extern void
82 PRMsortMenu(PRM_Name *menuitems, int size);
83 
84 PRM_API extern const PRM_Name *
85 PRMgetPixelFormatName(int idx);
86 
87 //
88 // The following functions are convenience functions for dealing with the
89 // PRM_TYPE_IMAGE_FORMAT* templates. There are three parameters involved in this configuration:
90 // 1) A string representing the filename of the image to save
91 // 2) A string representing the format of the image to save
92 // 3) <TWO> strings representing the options for the format. The first of
93 // these strings is the actual format determined by analyzing the
94 // filename and format strings. The second string contains the optional
95 // parameters to the format.
96 // These functions are intended to be used within the parameter change
97 // callbacks. It's up to the caller to evaluate the four strings.
98 //
99 
100 //
101 // The PRMchangeFilename() method is called when the filename parameter is
102 // changed. The function may change the option_format string. If the string
103 // needs to be changed, then the function returns 1.
104 //
105 PRM_API extern int
106 PRMchangeImageFilename(const UT_String &filename, const UT_String &format,
107  UT_String &option_format, UT_String &options);
108 
109 //
110 // When the format parameter is changed, it's possible that the extension on
111 // the filename will change along with the option-format and the option string.
112 // If this happens, then this function will return 1.
113 //
114 PRM_API extern int
116  UT_String &option_format, UT_String &options);
117 
118 #endif
PRM_API void PRMbuildFilterMenu(void *, PRM_Name *names, int, const PRM_SpareData *, const PRM_Parm *)
PRM_API void PRMbuildRiFilterMenu(void *, PRM_Name *names, int, const PRM_SpareData *, const PRM_Parm *)
PRM_API const PRM_Name * PRMgetFilterName(int idx)
PRM_API void PRMsortMenu(PRM_Name *menuitems, int size)
utility method for sorting menu items by their label text
PRM_API void PRMbuildRiDeviceMenu(void *, PRM_Name *names, int, const PRM_SpareData *, const PRM_Parm *)
PRM_API int PRMchangeImageFormat(UT_String &filename, const UT_String &format, UT_String &option_format, UT_String &options)
PRM_API int PRMchangeImageFilename(const UT_String &filename, const UT_String &format, UT_String &option_format, UT_String &options)
PRM_API const PRM_Name * PRMgetResolutionName(int index)
GLsizeiptr size
Definition: glcorearb.h:663
PRM_API const PRM_Name * PRMgetPixelFormatName(int idx)
GLdouble n
Definition: glcorearb.h:2007
PRM_API void PRMbuildPixelFormatMenu(void *, PRM_Name *names, int, const PRM_SpareData *, const PRM_Parm *)
GLint GLint GLsizei GLint GLenum format
Definition: glcorearb.h:107
PRM_API void PRMbuildRiHiderMenu(void *, PRM_Name *names, int, const PRM_SpareData *, const PRM_Parm *)
Utility class for containing a color ramp.
Definition: UT_Ramp.h:84
GLuint index
Definition: glcorearb.h:785
PRM_API void PRMbuildImageDeviceMenu(void *, PRM_Name *names, int, const PRM_SpareData *, const PRM_Parm *)
PRM_API void PRMbuildResolutionMenu(void *, PRM_Name *names, int n, const PRM_SpareData *, const PRM_Parm *)
#define PRM_API
Definition: PRM_API.h:10
PRM_API void PRMbuildImageMenu(void *, PRM_Name *names, int size, const PRM_SpareData *, const PRM_Parm *)
PRM_API void PRMbuildTakeMenu(void *, PRM_Name *names, int, const PRM_SpareData *, const PRM_Parm *)
PRM_API const PRM_Name * PRMgetImageName(int index)