|
|||||||||
上一个类 下一个类 | 框架 无框架 | ||||||||
摘要: 嵌套 | 字段 | 构造方法 | 方法 | 详细信息: 字段 | 构造方法 | 方法 |
java.lang.Object com.supermap.data.Geometry com.supermap.data.Geometry3D com.supermap.data.GeoModel
public class GeoModel
三维模型几何对象类。
该类用于建立三维几何对象的模型,从而实现对三维几何对象进行渲染。
该类仅在 Windows、Linux 平台版本中支持。
构造方法摘要 | |
---|---|
GeoModel()
构造一个新的 GeoModel 对象。 |
|
GeoModel(GeoModel geoModel)
根据给定的 GeoModel 对象构造一个与其完全相同的新对象。 |
方法摘要 | |
---|---|
GeoModel |
clone()
返回当前 GeoModel 对象的一个拷贝。 |
void |
computeBoundingBox()
根据网格面集合计算模型的包围盒。 |
void |
dispose()
释放该对象所占用的资源。 |
boolean |
fromFile(java.lang.String file)
通过 3DS 文件或 SGM 文件来创建三维模型几何对象。 |
boolean |
fromFile(java.lang.String file,
Point3D position)
通过给定的 3DS 文件或 SGM 文件以及三维模型几何对象的位置信息来创建三维模型几何对象。 |
Animation |
getAnimation()
返回模型的动画。 |
Meshes |
getMeshes()
返回三维模型几何对象的网格面集合。 |
java.lang.String |
getName()
返回三维模型几何对象的名称。 |
NodeAnimation |
getNodeAnimation()
获取GeoModel对象的节点动画。 |
void |
setBoundingBox(BoundingBox boundingBox)
设置模型的包围盒。 |
void |
setName(java.lang.String value)
设置三维模型几何对象的名称。 |
boolean |
toSGM(java.lang.String fileSGM)
将三维模型几何对象导出为 SGM 文件。 |
boolean |
toSGZ(java.lang.String fileSGZ)
将三维模型几何对象导出为 SGZ 文件。 |
从类 com.supermap.data.Geometry3D 继承的方法 |
---|
convertToGeoModel3D, convertToGeoModel3D, getBoundingBox, getGeoModel, getInnerPoint3D, getPosition, getRotationX, getRotationY, getRotationZ, getScaleX, getScaleY, getScaleZ, getStyle, getStyle3D, getVolume, hitTest, mirror, offset, resize, rotate, setPosition, setRotationX, setRotationY, setRotationZ, setScaleX, setScaleY, setScaleZ, setStyle, setStyle3D |
从类 com.supermap.data.Geometry 继承的方法 |
---|
addCustomGeometryCreatedListener, fromXML, getBounds, getID, getInnerPoint, getType, getVariantID, isEmpty, offset, removeCustomGeometryCreatedListener, setEmpty, setID, toXML |
从类 java.lang.Object 继承的方法 |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
构造方法详细信息 |
---|
public GeoModel()
public GeoModel(GeoModel geoModel)
geoModel
- 给定的 GeoModel 对象。方法详细信息 |
---|
public java.lang.String getName()
public void setName(java.lang.String value)
value
- 三维模型几何对象的名称。toSGM(String)
GeoModel.toSGM()
方法的示例。public boolean fromFile(java.lang.String file)
file
- 文件的全路径,支持 3DS 文件和 SGM 文件,目前通过文件扩展名来判断文件的类型。
public boolean fromFile(java.lang.String file, Point3D position)
file
- 文件的全路径,支持 3DS 文件和 SGM 文件,目前通过文件扩展名来判断文件的类型。position
- 三维模型几何对象的位置。
public boolean toSGM(java.lang.String fileSGM)
fileSGM
- 导出的 SGM 文件全路径。
public void toSGMTest() { // 实例化一个三维模型几何对象,对其进行设置,将其输出为 sgm 格式的文件 GeoModel model = new GeoModel(); model.setName("Model"); model.setID(110); model.setPosition(new Point3D(10, 10, 20)); model.toSGM("G:/SGM/Model.sgm"); model.dispose(); }
public boolean toSGZ(java.lang.String fileSGZ)
SGZ 文件是模型数据和其纹理数据的压缩文件。
fileSGZ
- 导出的 SGZ 文件全路径。
public Meshes getMeshes()
public void setBoundingBox(BoundingBox boundingBox)
boundingBox
- 所设置的新的包围盒。public void computeBoundingBox()
public void dispose()
Geometry
中的 dispose
public GeoModel clone()
java.lang.Object
中的 clone
public Animation getAnimation()
public NodeAnimation getNodeAnimation()
|
|||||||||
上一个类 下一个类 | 框架 无框架 | ||||||||
摘要: 嵌套 | 字段 | 构造方法 | 方法 | 详细信息: 字段 | 构造方法 | 方法 |