Unidata - To provide the data services, tools, and cyberinfrastructure leadership that advance Earth system science, enhance educational opportunities, and broaden participation. Unidata
         
  advanced  
 

Re:

Amaral:

First off, since the default box size is ~.7 (meaning about 70% of the window/frame size) you might not be able to see any difference. However, you probably also should put in the code to handle the 3D DisplayImpl as well...something like this (uses 90% so the change is obvious):

ProjectionControl pc = disp.getProjectionControl();
double[] mat = pc.getMatrix();
if (mat.length > 10) {
  mat[0] = .9;
  mat[5] = .9;
  mat[1] = .9;
} else {
  mat[0] = .9/.64;
  mat[3] = -.9/.64;
}
pc.setMatrix(mat);

Works nicely in my test...

Hope that helps.

tom

Amaral wrote:
I would like to chage the box size using java (not Jython). I tried the code below ( inspired by file subs.py) but something is missing because I could not get done. I appreciate some help: ProjectionControl pc;
pc = display.getProjectionControl();
double[] mat = pc.getMatrix();
mat[0] = .70/.64;
mat[3] = -.70/.64;
pc.setMatrix(mat);

--
Tom Whittaker (tomw@xxxxxxxxxxxxx)
University of Wisconsin-Madison
Space Science and Engineering Center
Cooperative Institute for Meteorological Satellite Studies
Phone/VoiceMail: 608.262.2759


 
 
  Contact Us     Site Map     Search     Terms and Conditions     Privacy Policy     Participation Policy
 
National Science Foundation (NSF) UCAR Community Programs   Unidata is a member of the UCAR Community Programs, is managed by the University Corporation for Atmospheric Research, and is sponsored by the National Science Foundation.
P.O. Box 3000     Boulder, CO 80307-3000 USA     Tel: 303-497-8643     Fax: 303-497-8690