The Origin Forum
File Exchange
Try Origin for Free
The Origin Forum
Home | Profile | Register | Active Topics | Members | Search | FAQ | Send File to Tech support
Username:
Password:
Save Password
Forgot your Password? | Admin Options

 All Forums
 Origin Forum
 Origin Forum
 3D and LabTalk
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

soriano

FRANCE, Marseille
1 Posts

Posted - 02/02/1999 :  7:26:00 PM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
How can I access and modify VIA LABTALK
1) the "Contour Details" Dialog Box data
2) the "Color Map Control" 3D Dialog Box data
Thanks.

rtoomey

USA
184 Posts

Posted - 02/05/1999 :  7:21:00 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply



Response to 3D and LabTalk

The Contour Details dialog box and the Color Map Control dialog box for Contour Plots can be manipulated through script using layer.cmap.properties. To see the list of properties associated with the cmap sub-object, open the script
window and enter the following:

layer.cmap.=

Now press the Enter key on your keyboard. You should see the following list, to which I have added definitions/explanations:



  1. COLOR - this property is used to determine the combined RGB * value of a particular color seen between two Z values in the contour plot. It requires enumeration to do so (i.e. layer.cmap.color3). To change a particular color between two Z values (two contour lines), the User Defined Colors check box on Color Map Control must be checked. Unfortunately, this check box cannot be set via script, only read. A template could be created with the check box checked to get around this problem. The check box status can be read using the RAMPMODE and MODE properties (see 8 & 11 below).

    * NOTE: the formula used to calculate the combined RGB value is as follows:

    RGB = Red + 256 * Green + 655536 * Blue


  2. COLORABOVE - this property reads/sets the Color Above (as a combined RGB value) in the Color Map Control dialog box.


  3. COLORBELOW - this property reads/sets the Color Below similarly


  4. COLORHIGH - this property reads/sets the High Color similarly


  5. COLORLOW - this property reads/sets the Low Color similarly.


  6. COLORMID - this property reads/sets the Middle Color similarly.


  7. COLORMISS - this property reads/sets the color for the Z Missing value (see 15 below) in the Contour Plot details. The Missing Color can be seen on the Color Map Control. In order for the color to show up, Z missing must occur over a wider range in the matrix than just one point or a portion of 1 column.


  8. MODE - this property reads whether or not the User Defined Colors check box on the Color Map Control is checked. A value of 2 means it is checked. A value of 3 means it is not checked. This property cannot be set via script. As mentioned above in the discussion on the COLOR property, the plot can be saved as a template with this check box checked in order to allow for the individual altering of the colors inbetween each Z value.


  9. NUMCOLORS - this property is as it suggests. It represents the number of colors that are being displayed in the Contour plot. The default is 8. The setting in the Contour Details that this corresponds to is # of steps. This property is useful when cycling through both the Z and COLOR properties. By this I mean the following:

    Suppose that you have checked off the User Defined Colors check box. You can then use NUMCOLORS to find out what the RGB values are inbetween each pair of Z values. To do this, you would use a 'for' loop such as the one below:

    for(ii=1;i<=layer.cmap.numcolors;ii++) {layer.cmap.color$(ii)=}

    Running this script will yield the combined RGB values for all the colors inbetween each contour line (between each pair of Z values). Or, replace color$(ii) with Z$(ii) to read the Z values. However, be warned that the Z values you get do not match with the Z values in the Contour Control dialog box. This may be a bug, or a situation where the Z values in the Contour Details dialog box are proportional to what you would get if you ran this script. Since it is not clear which is the case, I recommend using this property at your own risk.

    The fact that this property may be buggy explains why the layer.cmap properties are not documented. It is the practice of the company to not document LabTalk properties, commands, etc. that have not been tested or
    are known to be buggy.


  10. RAMP - this property reads/sets the Color Ramping in the Color Map Control dialog box. A value of 0 sets it to 3 Color Mix. A value of 1 sets it to 3 Color Linear. A value of it to 2 Color Linear


  11. RAMPMODE - this property is the same as MODE.


  12. Z - this property, as illuded to above, reads/sets the Z values in the Contour Details dialog box. It requires enumeration to specify which Z value (Z1, Z2,...Zn)


  13. ZMAX - this property reads/sets the maximum Z value in the Z axis Scales group of the Contour Details dialog box. Specifically, it is the to Z max text box.


  14. ZMIN - this property reads/sets the minimum Z value. It is the From Z min text box.


  15. ZMISSING - this property read/sets the Z missing value text box. Specifying a Z missing value removes any color from any location on the contour plot that corresponds to that Z value.

To the best of my knowledge, this is the extent of the properties that you have access to. I hope this proves helpful to you even though it is not complete access to these two dialog boxes.

Sincerely,
Ryan Toomey



[This message has been edited by rtoomey (edited 02-05-99).]

Go to Top of Page
  Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000