Class PgMaLoader
- java.lang.Object
-
- jv.loader.PgAbstractLoader
-
- jvx.loader.PgMaLoader
-
- All Implemented Interfaces:
- PgLoaderIf
public class PgMaLoader extends PgAbstractLoader
Loader for Maya ASCII geometries.Todo: - Orientation seems wrong, y-direction is up-vector in Maya while z-direction in JavaView. - Check export of surface colors, texture and other details ... - Lighting seems missing, currently geometry renders to black
- Author:
- Konrad Polthier
- Version:
- 19.11.17, 3.10 revised (kp) Bug in write method removed which prevented loading in Maya 2017.
09.03.15, 3.00 revised (kp) Moved to jvx.loader from dev.loader.
22.03.10, 2.00 revised (kp) Superclass changed to PgAbstractLoader.
06.10.03, 1.15 revised (kp) Interface extended by isEnabledOptimization().
19.04.03, 1.10 revised (kp) Interface extended by setGeometryOption().
10.09.02, 1.00 created (ur) By modification of the Maple loader class.
-
-
Field Summary
-
Fields inherited from interface jv.loader.PgLoaderIf
GEOM_DATA_AUTHOR, GEOM_DATA_COLORS, GEOM_DATA_HEADER, GEOM_DATA_INFO, GEOM_DATA_NORMALS, GEOM_DATA_TEXTURE, GEOM_DATA_VECTORS
-
-
Constructor Summary
Constructors Constructor and Description PgMaLoader()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method and Description PgJvxSrc[]read(java.io.BufferedReader in)Deprecated.use methods load() and getGeometries() respectively getAnimations().static PgJvxSrc[]read(java.lang.String fileName)Read geometry file in Maya ASCII file format.booleanwrite(java.io.Writer writer, PgJvxSrc[] geomArr)Write an array of geometries into an output stream writer in Maya Ascii file format, called MA.-
Methods inherited from class jv.loader.PgAbstractLoader
getAnimations, getDisplayOption, getGeometries, getSpecializedGeometries, isAnimation, isEnabledOptimization, load, read, setAnimation, setDisplayOption, setGeometryOption, write
-
-
-
-
Method Detail
-
read
public static PgJvxSrc[] read(java.lang.String fileName)
Read geometry file in Maya ASCII file format.- Author:
- Konrad Polthier
- Version:
- 21.08.00, 1.00 revised (kp)
21.08.00, 1.00 created (kp)
-
read
public PgJvxSrc[] read(java.io.BufferedReader in)
Deprecated. use methods load() and getGeometries() respectively getAnimations().Read Maya ASCII graphics data.Alternatively, one may call load(BuffereredReader) followed by getGeometries() resp. getAnimations() to have a finer control about which information one wants to use from a source. For example, optional display information must be retrieve by a subsequent call getDisplayOption() if available.
- Specified by:
readin interfacePgLoaderIf- Overrides:
readin classPgAbstractLoader- Parameters:
in- BufferedReader to read textual data from.- Returns:
- Array of JVX geometries.
- See Also:
PgAbstractLoader.write(Writer, PgJvxSrc [])- Version:
- 21.08.00, 1.00 revised (kp)
21.08.00, 1.00 created (kp)
-
write
public boolean write(java.io.Writer writer, PgJvxSrc[] geomArr) throws java.io.IOExceptionWrite an array of geometries into an output stream writer in Maya Ascii file format, called MA.Numbers with absolute value less than
jv.vecmath.PuMath#EPSare shown as zero. This avoids the annoying fact that double precision numbers fill the whole text area hiding the exponent, which hides their small value.- Specified by:
writein interfacePgLoaderIf- Overrides:
writein classPgAbstractLoader- Parameters:
writer- Write all data to this streamgeomArr- Array with geometries to save- Returns:
trueon success.- Throws:
java.io.IOException- See Also:
read(BufferedReader)- Version:
- 21.08.00, 1.00 created (kp)
-
-
"