|
TNTmips

|
|
25 March 2009
|
page update:
26 May 11
|
mklayer.c
/**
* Sample for Mdisp layer creation from a "fixed" file and object
*
* Note: This code should compile, but is not designed to be executed by itself
**/
#include <mi32/gre.h>
#include <mi32/rvcdefns.h>
// Make layer in specified group.
static ERRVALUE MakeLayer (
GRE_GROUP *group,
const char *ascfilename,
const char *ascobjname
) {
FILEPATH filepath(ascfilename);
MISTRING objname(ascobjname);
RVC::OBJITEM ObjItem(filepath,objname);
if (!ObjItem.IsExisting()) return (R_ObjNoExist);
return (GRE_LAYER::ConstructFromObject(group,ObjItem));
}
// Function to test layer creation
ERRVALUE Test (
GRE_GROUP *group
) {
return (MakeLayer(group,"c:/data/myfile.rvc","MYOBJECT.RASTER"));
}
©MicroImages, Inc. 2013 Published in the United States of America
11th Floor - Sharp Tower, 206 South 13th Street, Lincoln NE 68508-2010 USA
Business & Sales: (402)477-9554 Support: (402)477-9562 Fax: (402)477-9559
Business info@microimages.com
Support support@microimages.com
Web webmaster@microimages.com
| |