spacer spacer spacer
spacer spacer spacer
spacer
NASA Logo - Jet Propulsion Laboratory    + View the NASA Portal
spacer
JPL Home Earth Solar System Stars & Galaxies Technology
ParVox Parallel Volume Rendering System
ParVox Home ../Images & Animations ParVox Document Download Source PAT Home Section 387 Division 38
spacer
spacer spacer spacer
spacer

vlread_environ


NAME

    vlread_environ  - Read in a previously saved environment file in NetCDF format.

SYNOPSIS

    #include <parvox.h>

    void vlread_environ(char* environ_filename);


DESCRIPTION

    vlread_environ() reads in an environment file environ_filename in NetCDF format and sets the rendering parameters accordingly.  The environ_filename could be either a full filename or a file prefix with a fixed extension ".env.nc".  The environment file can be generated using the ParVox GUI program, xmparvox, by selecting the "save env" option under the "file" pull-down menu.  The environment file contains all the information necessary to start a rendering session, including the volume classification information, such as the data range, the color map, the opacity map, the slice definition and the iso-surface definition, and the viewing parameters, such as the transformation matrix, the scaling factors, the lighting and the material setup.  In addition, it also includes input decomposition information, i.e., the block size or the number of blocks per processor, and the output image size. A sample environment file looks like as follows: (output from ncdump)
 
netcdf test3.env {
dimensions:
        num_vars = 1 ;
        cmaps_size = 768 ;
        num_cmaps = 1 ;
        opacs_size = 256 ;
        num_opacs = 1 ;
        map_dim = 2 ;
        num_surfs = 8 ;
        surface_fields = 6 ;
        mat_fields = 4 ;
        num_lights = 5 ;
        light_fields = 4 ;

variables:
        char colormap(num_cmaps, cmaps_size) ;
        float opacity(num_opacs, opacs_size) ;
        short map(num_vars, map_dim) ;
        float surface(num_vars, num_surfs, surface_fields) ;
        float material(num_vars, mat_fields) ;
        float light(num_lights, light_fields) ;
        char light_enabled(num_lights) ;

// global attributes:
                :filter_type = 1 ;
                :screen_width = 768 ;
                :screen_height = 768 ;
                :block_per_pe = 2 ;
                :block_idim = 128 ;
                :block_jdim = 128 ;
                :block_kdim = 37 ;
                :nodata_color = 1.f, 0.f, 0.f, 0.f ;
                :translations = 18.18f, 9.0900002f ;
                :scale_factors = 0.69999999f, 1.3f, 0.69999999f ;
                :trans_matrix = 0.88649267f, -0.1382862f, -0.44159749f, 0.f,
                               -0.46216598f, -0.21694544f, -0.85984772f, 0.f,
                                0.023102611f, 0.96634072f, -0.2562322f, 0.f,
                                0.f, 0.f, 0.f, 1.f ;
                :file_type = 0 ;
                :outputfile = "parvox" ;
                :num_iso_tbl = 1s ;

data:

 colormap =
  "\377\000\377\372\000\377\365\000\377\360\000\377\353\000\377\346\000\377
\341\000\377\334\000\377\327\000\377\322\000\377\315\000\377\310\000\377\303
\000\377\276\000\377\271\000\377\264\000\377\257\000\377\252\000\377\245\000
\377\240\000\377\233\000\377
    "\000\377\005\000\377\000\000\377\000\005\377\000\n",
    "\377\000\017\377\000\024\377\000\031\377\000\036\377\000#\377\000(\377
\000-\377\0002\377\0007\377\000<\377\000A\377\000F\377\000K\377\000P\377\000U
\377\000Z\377\000_\377\000d\377\000i\377\000n\377\000s\377\000x\377\000}\377
\000\202\377\000\207\377\00
    "\000\377\005\000\377\000\005\377\000\n",
    "\377\000\017\377\000\024\377\000\031\377\000\036\377\000#\377\000(\377
\000-\377\0002\377\0007\377\000<\377\000A\377\000F\377\000K\377\000P\377\000U
\377\000Z\377\000_\377\000d\377\000i\377\000n\377\000s\377\000x\377\000}\377
\000\202\377\000\207\377\00
    "\000\377\005\000\377" ;

 opacity =
  0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 ,
    0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 ,
    0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 ,
    0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 ,
    0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4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 , 0.4 , 0.4 ,
    0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 ,
    0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 , 0.4 ,
    0.4 , 0.4 , 0.4 , 0.4  ;

 map =
  0, 0 ;

 surface =
  18.18 , 1 , 1 , -1 , -1 , -1 ,
  0 , 0 , 0 , 0 , 0 , 0 ,
  0 , 0 , 0 , 0 , 0 , 0 ,
  0 , 0 , 0 , 0 , 0 , 0 ,
  0 , 0 , 0 , 0 , 0 , 0 ,
  0 , 0 , 0 , 0 , 0 , 0 ,
  0 , 0 , 0 , 0 , 0 , 0 ,
  0 , 0 , 0 , 0 , 0 , 0  ;

 material =
  1 , 0.3 , 0.8 , 0.5 , 0.35  ;

 light =
  1 , -1 , 1 , 1 ,
  1 , 1 , -1 , 1 ,
  0 , 0 , 0 , 0 ,
  0 , 0 , 0 , 0 ,
  0 , 0 , 0 , 0  ;

 light_enabled = "\001\001" ;
}


SEE ALSO

    vlinit_fb , xmparvox
 

BACK TO INDEX

spacer
spacer spacer spacer
spacer
Privacy / Copyrights FAQ Contact JPL Sitemap
spacer
spacer spacer spacer
spacer
FIRST GOV   NASA Home Page This page, http://pat.jpl.nasa.gov/public/ParVox/API/vlread_environ.html, is maintained by Peggy Li and was last modified Wednesday, 09-Mar-2005 16:55:25 PST
spacer
spacer spacer spacer
spacer spacer spacer
JPL NASA Caltech