1<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 3//EN">
2<HTML><HEAD>
3		<TITLE>User's Guide - Using the Colormap Editor</TITLE>
4		<META HTTP-EQUIV="keywords" CONTENT="GRAPHICS VISUALIZATION VISUAL PROGRAM DATA
5MINING">
6	<meta http-equiv="content-type" content="text/html;charset=ISO-8859-1">
7</HEAD><BODY BGCOLOR="#FFFFFF" link="#00004b" vlink="#4b004b">
8		<TABLE width=510 border=0 cellpadding=0 cellspacing=0>
9			<TR>
10				<TD><IMG SRC="../images/spacer.gif" WIDTH=80 HEIGHT=1></TD>
11				<TD><IMG SRC="../images/spacer.gif" WIDTH=49 HEIGHT=1></TD>
12				<TD><IMG SRC="../images/spacer.gif" WIDTH=24 HEIGHT=1></TD>
13				<TD><IMG SRC="../images/spacer.gif" WIDTH=100 HEIGHT=1></TD>
14				<TD><IMG SRC="../images/spacer.gif" WIDTH=3 HEIGHT=1></TD>
15				<TD><IMG SRC="../images/spacer.gif" WIDTH=127 HEIGHT=1></TD>
16				<TD><IMG SRC="../images/spacer.gif" WIDTH=6 HEIGHT=1></TD>
17				<TD><IMG SRC="../images/spacer.gif" WIDTH=50 HEIGHT=1></TD>
18				<TD><IMG SRC="../images/spacer.gif" WIDTH=71 HEIGHT=1></TD>
19			</TR>
20			<TR>
21				<TD colspan=9><IMG src="../images/flcgh_01.gif" width=510 height=24 border="0" alt="OpenDX - Documentation"></TD>
22			</TR>
23			<TR>
24				<TD colspan=2><A href="../allguide.htm"><IMG src="../images/flcgh_02.gif" width=129 height=25 border="0" alt="Full Contents"></A></TD>
25				<TD colspan=3><A href="../qikguide.htm"><IMG src="../images/flcgh_03.gif" width=127 height=25 border="0" alt="QuickStart Guide"></A></TD>
26				<TD><A href="../usrguide.htm"><B><IMG src="../images/flcgh_04d.gif" width=127 height=25 border="0" alt="User's Guide"></B></A></TD>
27				<TD colspan=3><A href="../refguide.htm"><IMG src="../images/flcgh_05.gif" width=127 height=25 border="0" alt="User's Reference"></A></TD>
28			</TR>
29			<TR>
30				<TD><A href="usrgu041.htm"><IMG src="../images/flcgh_06.gif" width=80 height=17 border="0" alt="Previous Page"></A></TD>
31				<TD colspan=2><A href="usrgu043.htm"><IMG src="../images/flcgh_07.gif" width=73 height=17 border="0" alt="Next Page"></A></TD>
32				<TD><A href="../usrguide.htm"><IMG src="../images/flcgh_08.gif" width=100 height=17 border="0" alt="Table of Contents"></A></TD>
33				<TD colspan=3><A href="usrgu040.htm"><IMG src="../images/flcgh_09.gif" width=136 height=17 border="0" alt="Partial Table of Contents"></A></TD>
34				<TD><A href="usrgu080.htm"><IMG src="../images/flcgh_10.gif" width=50 height=17 border="0" alt="Index"></A></TD>
35				<TD><A href="../srchindx.htm"><IMG SRC="../images/flcgh_11.gif" width=71 height=17 border="0" alt="Search"></A></TD>
36			</TR>
37		</TABLE>
38		<H2><A NAME="HDRCOLMAPE" ></A>6.3 Using the Colormap Editor</H2>
39		<A NAME="IDX752"></A><A NAME="IDX753"></A>
40<P>
41The Colormap Editor is a window that enables you to map colors to
42specified data values, the results of which are displayed in the
43visual image.
44In addition to color, the Colormap Editor also controls the mapping of
45<I>opacity</I> to data, which is the degree of the image&#39;s
46transparency in relation to its background.
47Maximum opacity shows the color calculated by the hue, saturation, and
48value fields;
49minimum opacity calculates colors so that the image is faintly visible
50in front of the background.
51In summary, the Colormap Editor enables you to&#58;
52<UL COMPACT>
53<LI>Control the range of data values over which the mapping occurs.
54<LI>Select the colors that are mapped to the range of values.
55<LI>Select the opacities that are mapped to the range of values.
56</UL>
57When the <TT><STRONG>Colormap</STRONG></TT> stand-in from the
58<TT><STRONG>Special</STRONG></TT>
59category is connected to the <TT><STRONG>Color</STRONG></TT> tool as shown in
60the visual program fragment in <A HREF="#FIGCMAP1">Figure 56</A>, the
61combination
62can be used in place of the <TT><STRONG>AutoColor</STRONG></TT> tool.
63<P><B><A NAME="FIGCMAP1" HREF="../usrguide.htm#FT_FIGCMAP1">Figure 56. Fragment of
64Visual Program Using Colormap</A></B><BR>
65<B><BR><CENTER><IMG SRC="../images/fragment.gif" ALT="Figure fragment not
66displayed."></CENTER><BR></B><BR>
67<P>
68To use the Colormap Editor&#58;
69<OL COMPACT>
70<LI>Double-click on the Colormap tool in the VPE window or select
71either the <TT><STRONG>Open Selected Colormap Editors</STRONG></TT>
72option from the VPE or the <TT><STRONG>Open All Colormap
73Editors</STRONG></TT> from the Image window
74<TT><STRONG>Windows</STRONG></TT> menu.
75<TABLE><TR><TD ALIGN="LEFT" VALIGN="TOP"><B>Note:</B></TD><TD ALIGN="LEFT"
76VALIGN="TOP">From the VPE, this option is <TT><STRONG>Open Colormap
77Editor</STRONG></TT>.
78For this option to be available, the Colormap icon must be selected.
79</td></tr></table>
80<LI>The Colormap Editor appears.
81Make necessary adjustments to values, as described in
82<A HREF="#HDRENTV">"Entering Values in a Colormap Editor"</A>.
83</OL>
84<P>
85<A HREF="#FIGCOLED">Figure 57</A> illustrates the organization of the
86Colormap Editor window.
87<P><B><A NAME="FIGCOLED" HREF="../usrguide.htm#FT_FIGCOLED">Figure 57. Colormap
88Editor</A></B><BR>
89<B><BR><CENTER><IMG SRC="../images/cmaped.gif" ALT="Figure cmaped not
90displayed."></CENTER><BR></B><BR>
91<P>
92<H3><A NAME="HDRENTV" ></A>Entering Values in a Colormap Editor</H3>
93<A NAME="IDX754"></A>
94<P>
95The Colormap Editor specifies color in the hue, saturation, and value
96(HSV) color space.
97<I>Hue</I> refers to the color, for example, blue, red
98or yellow.
99The range of the hue goes from red to green to blue back to red
100again.
101<I>Saturation</I> refers to the purity of the color, and is a value
102between 0 and 1.
103A saturation of 1 is pure color; as saturation decreases, the color
104becomes more pastel, becoming white when saturation is 0.
105<I>Value</I> is the brightness of the color, and is a value between
1060 to 1.
107A value of 1 is maximum brightness; as value decreases, the color
108becomes darker, becoming black when value is 0.
109<P>
110For a thorough understanding of color and the color elements of hue,
111saturation, value, and opacity, and other elements of computer
112graphics that might relate to the Colormap characteristics,
113you may want to refer to a computer graphics text.
114<P>
115You can display the Colormap Editor by selecting the <TT><STRONG>Open All
116Colormap Editors</STRONG></TT> option on the <TT><STRONG>Windows</STRONG></TT>
117menu of
118the Image window or by double-clicking on the Colormap tool
119in the VPE window.
120The Colormap Editor displays default settings for each of the three HSV
121color space parameters, as shown in the first three boxed areas on
122the right hand side of the window.
123These three areas, labeled <TT><STRONG>Hue</STRONG></TT>,
124<TT><STRONG>Saturation</STRONG></TT>, and
125<TT><STRONG>Value</STRONG></TT>, each work independently of one another.
126As you change their values, the RGB boxed area at the left of the
127window changes automatically to correspond.
128<P>
129The <TT><STRONG>Opacity</STRONG></TT> area, located on the far right hand side
130of the
131Colormap Editor window, works in a similar way.
132As you make changes in the opacity area, the background bar (located to
133the right of the RGB bar) reflects your work.
134It shows your adjustments to the opacity of the image in relation to the
135background colors.
136By default, the background bar appears as two vertical stripes.
137However, if it is easier for you to judge the colors of the image and
138background with a checkerboard-style bar, select the <TT><STRONG>Set
139Background Style to Checkboard</STRONG></TT> option on the
140<TT><STRONG>Options</STRONG></TT> menu
141(see <A HREF="usrgu045.htm#HDRCMAPOM">"Colormap Options Menu"</A>).
142<P>
143In order to perform certain operations on an area, it must be
144selected.
145To select an area either click on the area&#39;s label
146or click in the area itself.
147Only one area can be
148selected at a time.
149When an area is selected, its label is depressed.
150<P>
151The range of data values onto which HSV and opacity values are mapped
152is controlled by the <TT><STRONG>min</STRONG></TT> and
153<TT><STRONG>max</STRONG></TT> fields
154located near the bottom and top of the Colormap Editor
155window.
156By default, <TT><STRONG>min</STRONG></TT> is set to 0, and
157<TT><STRONG>max</STRONG></TT> is set to 100.
158You can change this range to values more appropriate for your data by
159clicking on either field, typing the new value, and pressing the
160Enter key.
161<P>
162Control points are used to define the value of hue, saturation, value,
163and opacity for a given data value.
164The number and position of control points can be different in each of
165the areas.
166The control points appear as small squares on the vertical scale marks
167in each of the four areas.
168<P>
169<H4><A NAME="HDRADCONP"></A><U>Adding Control Points</U></H4>
170<A NAME="IDX755"></A>
171<P>
172Control points can be added to an area using one of four different
173methods:
174<UL COMPACT>
175<LI>double-clicking directly in the area,
176<LI>using the <TT><STRONG>Add Control Points...</STRONG></TT> dialog box,
177<LI>using the <TT><STRONG>Generate Waveforms</STRONG></TT> dialog box, or
178<LI>copying and pasting control points from another area.
179</UL>
180<P>
181To add a new control point by double-clicking, place the cursor on the
182location where you want the new control point, then double-click.
183The values between control points are linearly interpolated by the
184Colormap.
185If a new point is added as the bottom- or top-most point on the line,
186the new line continues vertically from the new point to the
187<TT><STRONG>min</STRONG></TT> or <TT><STRONG>max</STRONG></TT> value,
188respectively.
189When a new control point is added, its data value is displayed
190by default.
191<P>
192To specify exact values for new control points, click on the <TT><STRONG>Add
193Control Points...</STRONG></TT> option on the <TT><STRONG>Edit</STRONG></TT>
194menu.
195The <TT><STRONG>Add Control Points</STRONG></TT> dialog box appears, as
196illustrated
197in <A HREF="#FIGADCTPTS">Figure 58</A>.
198The <TT><STRONG>Add Control Points...</STRONG></TT> dialog allows you to
199specify
200values using two steppers.
201The "Data value" stepper allows you to specify a control point
202value between "min" and "max".
203The second stepper displayed in the dialog will reflect that area (Hue,
204Saturation, Value, or Opacity) is currently selected in the Colormap
205Editor.
206For example, if Saturation is the selected area, the dialog will display
207steppers for "Data value" and "Saturation value".
208The value for Hue, Saturation, Value, or Opacity can be a value between
2090 and 1.
210Use the <TT><STRONG>Add</STRONG></TT> button to add the control points to the
211selected area in the Colormap Editor.
212<P><B><A NAME="FIGADCTPTS" HREF="../usrguide.htm#FT_FIGADCTPTS">Figure 58.
213Colormap&#39;s Add Control Points Dialog Box</A></B><BR>
214<B><BR><CENTER><IMG SRC="../images/adctlpt.gif" ALT="Figure adctlpt not
215displayed."></CENTER><BR></B><BR>
216<P>
217<H4><A NAME="HDRSELCONP"></A><U>Selecting Control Points</U></H4>
218<A NAME="IDX756"></A>
219<P>
220Control points can be selected by doing one of the following&#58;
221<UL>
222<P><LI>Select a single control point by simply clicking on it once.
223<P><LI>Select a group of control points by clicking on a point in the
224selected area and dragging the cursor around the desired points.
225<P><LI>Select all of the control points in an area by using the
226<TT><STRONG>Select All Control Points</STRONG></TT> option under the
227<TT><STRONG>Edit</STRONG></TT> menu.
228</UL>
229<TABLE><TR><TD ALIGN="LEFT" VALIGN="TOP"><B>Note:</B></TD><TD ALIGN="LEFT"
230VALIGN="TOP">A control point is selected automatically when it is created.
231When one control point is created, all other previously selected points
232in that area are automatically deselected.
233</td></tr></table>
234<P>
235<H5><U>Deleting Selected Control Points</U></H5>
236<P>
237To delete selected control points, you can do one of the following:
238<UL COMPACT>
239<LI>Double-click on each of them, one at a time.
240<LI>Choose the <TT><STRONG>Edit</STRONG></TT> menu, then click
241on the <TT><STRONG>Delete Selected Control Points</STRONG></TT> option.
242</UL>
243<P>
244<H4><A NAME="HDRMOVCPS"></A><U>Moving Control Points</U></H4>
245<A NAME="IDX757"></A>
246<P>
247To move a control point, simply drag it to the desired location.
248Control points cannot be moved past each other; this
249facilitates the creation of step functions.
250They can be moved as a group by doing the following:
251<OL COMPACT>
252<LI>Draw a selection box around the points you want in the group.
253<LI>Position the mouse pointer on any one of them and drag it to the
254desired location.
255</OL>
256All of the control points move together within the constraints of the
257unselected points above and below.
258<P>
259The movement of control points can be constrained either horizontally
260or vertically by selecting the <TT><STRONG>Constrain Horizontal</STRONG></TT>
261or <TT><STRONG>Constrain Vertical</STRONG></TT> option from the Colormap
262<TT><STRONG>Edit</STRONG></TT> menu (see <A
263
264HREF="usrgu045.htm#HDRCMAPEM">"Colormap Edit Menu"</A>).
265By constraining horizontally after adding a precise control point, you
266can move the point to change the color or opacity mapped to specific
267value, without changing the value itself.
268<P>
269<H4><A NAME="HDRCREWVS"></A><U>Creating Waveforms</U></H4>
270<A NAME="IDX758"></A>
271<P>
272To create waveforms, select the <TT><STRONG>Generate Waveforms</STRONG></TT>
273option from the <TT><STRONG>Edit</STRONG></TT> pull-down menu.
274The <TT><STRONG>Generate Waveforms</STRONG></TT> dialog box appears
275(<A HREF="#FIGGENREF">Figure 59</A>).
276<P><B><A NAME="FIGGENREF" HREF="../usrguide.htm#FT_FIGGENREF">Figure 59. Generate
277Waveforms Dialog Box</A></B><BR>
278<B><BR><CENTER><IMG SRC="../images/genwave.gif" ALT="Figure genwave not
279displayed."></CENTER><BR></B><BR>
280<P>
281This dialog box allows you to&#58;
282<UL>
283<P><LI>Choose the shape of the waveform from an options box.
284Waveforms can be step, square, or sawtooth.
285<P><LI>Choose the range of the waveform from an options box.
286"Full" creates a waveform  that runs the full length of the
287selected area.
288"Selected" creates a wave that runs the distance between two
289selected control points in the specified area.
290<P><LI>Specify the number of steps to be created in the range of the
291waveform by using the stepper.
292The number of steps specified can be between 2 and 100.
293</UL>
294<P>
295<H4><A NAME="HDRCAPCPS"></A><U>Copying and Pasting Control Points</U></H4>
296<P>
297Control points can be copied and pasted from one Colormap area to
298another, using the <TT><STRONG>Copy</STRONG></TT> and
299<TT><STRONG>Paste</STRONG></TT> options
300of the <TT><STRONG>Edit</STRONG></TT> window.
301<OL COMPACT>
302<LI>Select the control point or control points you wish to copy.
303<LI>Click on <TT><STRONG>Copy</STRONG></TT>.
304<LI>Select the area to which you wish to copy the control
305points and then click on <TT><STRONG>Paste</STRONG></TT>.
306</OL>
307<P>
308<H4><A NAME="HDRDISCPV"></A><U>Display Control Point Values</U></H4>
309<P>
310The data values of control points are displayed by default.
311You can control which data values are displayed, using the <TT><STRONG>Display
312Control Point Data Value</STRONG></TT> cascade menu in the
313<TT><STRONG>Options</STRONG></TT>
314menu.
315If "off" is specified, no data values are shown.
316If "selected" is chosen, only the data values for the selected
317control points are shown, and if "all" is selected, the data
318values for all control points in the selected area are shown.
319<P>
320<H4><A NAME="HDRAXDISP"></A><U>Axis Display</U></H4>
321<A NAME="IDX759"></A>
322<P>
323You can control how the Colormap Editor axis is displayed by using the
324
325<TT><STRONG>Options</STRONG></TT> menu <TT><STRONG>Axis Display...</STRONG></TT>
326option.
327You have three choices for the display: <TT><STRONG>Ticks</STRONG></TT> (the
328default),
329<TT><STRONG>Histogram</STRONG></TT>, and <TT><STRONG>Log
330Histogram</STRONG></TT>.
331<TT><STRONG>Histogram</STRONG></TT> will cause the histogram of the data to be
332displayed.
333<TT><STRONG>Log Histogram</STRONG></TT> will cause the log of the histogram to
334be
335displayed.
336If the Colormap Editor is not data-driven, these two options will be
337grayed-out.
338The number of histogram bins can be controlled using the
339<TT><STRONG>Edit</STRONG></TT>
340menu <TT><STRONG>Number of histogram bins...</STRONG></TT> option.
341<P>
342<H4><A NAME="HDRCOLCNAM"></A><U>Changing the name of the Colormap Editor</U></H4>
343<P>
344Every Colormap Editor is given the default name of "Colormap
345Editor" in the box across the top of the window.
346If you want to customize the name of the Colormap Editor, you can do so
347by clicking on the <TT><STRONG>Options</STRONG></TT> menu <TT><STRONG>Change
348Colormap Name...</STRONG></TT> option and entering a new name
349in the dialog box that appears.
350<P><B>Note: </B>You can also change the name of the Colormap Editor by using the
351<TT><STRONG>title</STRONG></TT> parameter in the Colormap tool.
352<P>
353<H4><U>Saving and Loading Color Maps</U></H4>
354<P>
355You can save a color map by using the <TT><STRONG>Save As...</STRONG></TT>
356command from the <TT><STRONG>File</STRONG></TT> pull-down menu).
357You can then make the "new" color map part of any visual
358program.
359To access it, use the <TT><STRONG>Open</STRONG></TT> command from the
360<TT><STRONG>File</STRONG></TT>
361pull-down menu of the Colormap Editor menu bar.
362Note that saved color maps may also be imported (see Import in <I>IBM
363Visualization Data Explorer User&#39;s Reference</I>)
364and passed directly to the Color module.
365<P>
366<H3><A NAME="Header_198" ></A>Using Data-Driven Colormap Editors</H3>
367<P>
368The Colormap Editor may be <I>data-driven</I>, meaning that its
369attributes (e.g., minimum and maximum) can be set by connecting
370the output of a tool to the input of the Colormap tool in the
371VPE or by typing a value into the Colormap configuration
372dialog box, instead of into the Colormap Editor itself.
373<P>
374If the Colormap Editor is data-driven, the information transmitted via
375the connections or set in the Configuration dialog box overrides
376values set in the Colormap Editor.
377<P>
378Data-driven Colormap Editors allow you to create color maps that are
379appropriate for a variety of input data sets without the need to
380reset the minimum and maximum of the color map.
381<P>
382The Colormap tool has a data input to which an input data field may be
383connected.
384In this case, the Colormap Editor is automatically set so that the
385minimum is the minimum of the data set and the maximum is the
386maximum of the data set.
387However, if you would like to have more control over the exact values
388that are used, the Colormap tool allows you to specify the minimum
389and maximum directly through other input tabs that are by
390default hidden.
391You can also pass a color map or opacity map directly to the Colormap
392tool.
393The inputs for the Colormap tool are summarized in the corresponding
394module description in <I>IBM Visualization Data Explorer User&#39;s
395Reference</I>.
396<P>
397Each time an input to a data-driven Colormap Editor is changed (e.g.,
398by importing a new data set), the interactor is reexecuted,
399updating its attributes.
400
401		<P>
402		<HR>
403		<DIV align="center">
404			<P><A href="../allguide.htm"><IMG src="../images/foot-fc.gif" width="94" height="18" border="0" alt="Full Contents"></A> <A href="../qikguide.htm"><IMG src="../images/foot-qs.gif" width="94" height="18" border="0" alt="QuickStart Guide"></A> <A href="../usrguide.htm"><IMG src="../images/foot-ug.gif" width="94" height="18" border="0" alt="User's Guide"></A> <A href="../refguide.htm"><IMG src="../images/foot-ur.gif" width="94" height="18" border="0" alt="User's Reference"></A></P>
405		</DIV>
406		<DIV align="center">
407			<P><FONT size="-1">[ <A href="http://www.research.ibm.com/dx">OpenDX Home at IBM</A>&nbsp;|&nbsp;<A href="http://www.opendx.org/">OpenDX.org</A>&nbsp;] </FONT></P>
408			<P></P>
409		</DIV>
410		<P></P>
411	</BODY></HTML>
412