DracoFormat
Inheritance: java.lang.Object, com.aspose.threed.FileFormat
public class DracoFormat extends FileFormat
Google Draco-formaat Voorbeeld: De volgende code laat zien hoe je een Mesh kunt coderen en decoderen naar/van een byte-array:
Mesh mesh = (new Sphere()).toMesh();
//encode mesh into Draco format
byte[] draco = FileFormat.DRACO.encode(mesh);
//decode mesh from Draco format
Mesh decodedMesh = (Mesh)FileFormat.DRACO.decode(draco);
Velden
| Veld | Beschrijving |
|---|---|
| AMF | Bestandsformaat voor additive manufacturing |
| ASE | ASCII-scène-exportformaat van 3D Studio Max. |
| ASPOSE3D_WEB | Aspose.3D Web-formaat. |
| BLENDER | 3D-bestandsformaat van Blender |
| COLLADA | Collada-bestandsformaat |
| DISCREET3DS | Bestandsformaat van 3D Studio |
| DRACO | Google Draco Mesh |
| DXF | AutoCAD DXF |
| FBX6100ASCII | ASCII FBX-bestandsformaat, versie 6.1.0 |
| FBX6100_BINARY | Binaire FBX-bestandsformaat, versie 6.1.0 |
| FBX7200ASCII | ASCII FBX-bestandsformaat, versie 7.2.0 |
| FBX7200_BINARY | Binaire FBX-bestandsformaat, versie 7.2.0 |
| FBX7300ASCII | ASCII FBX-bestandsformaat, versie 7.3.0 |
| FBX7300_BINARY | Binaire FBX-bestandsformaat, versie 7.3.0 |
| FBX7400ASCII | ASCII FBX-bestandsformaat, versie 7.4.0 |
| FBX7400_BINARY | Binaire FBX-bestandsformaat, versie 7.4.0 |
| FBX7500ASCII | ASCII FBX-bestandsformaat, met versie 7.5.0 |
| FBX7500_BINARY | Binair FBX-bestandsformaat, met versie 7.5.0 |
| FBX7600ASCII | ASCII FBX-bestandsformaat, met versie 7.6.0 |
| FBX7600_BINARY | Binair FBX-bestandsformaat, met versie 7.6.0 |
| FBX7700ASCII | ASCII FBX-bestandsformaat, met versie 7.7.0 |
| FBX7700_BINARY | Binair FBX-bestandsformaat, met versie 7.7.0 |
| GLTF | glTF van de Khronos Group |
| GLTF2 | glTF versie 2.0 van de Khronos Group |
| GLTF2_BINARY | glTF versie 2.0 van de Khronos Group |
| GLTF_BINARY | glTF van de Khronos Group in binair formaat |
| HTML5 | HTML5-bestand |
| IFC | ISO 16739-1 Industry Foundation Classes datamodel. |
| MAYAASCII | Autodesk Maya in ASCII-formaat |
| MAYA_BINARY | Autodesk Maya in binair formaat |
| MICROSOFT3MF | Microsoft 3D Manufacturing-formaat |
| PCD | PCL Point Cloud Data-bestand in ASCII-modus |
| PCD_BINARY | PCL Point Cloud Data-bestand in binair modus |
| Portable Document Format van Adobe | |
| PLY | Polygon File Format of Stanford Triangle Format |
| RVM_BINARY | AVEVA Plant Design Management System-model in binair formaat |
| RVM_TEXT | AVEVA Plant Design Management System-model in tekstformaat |
| SIEMENSJT8 | Siemens JT-bestand versie 8 |
| SIEMENSJT9 | Siemens JT-bestand versie 9 |
| STLASCII | ASCII STL-bestandsformaat |
| STL_BINARY | Binair STL-bestandsformaat |
| UNIVERSAL3D | Universal3D-bestandsformaat |
| USD | Universele Scènebeschrijving |
| USDA | Universele Scènebeschrijving in ASCII-indeling. |
| USDZ | Gecomprimeerde Universele Scènebeschrijving |
| VRML | De Virtual Reality Modeling Language |
| WAVEFRONTOBJ | Wavefront’s Obj-bestandsformaat |
| XYZ | Xyz-puntwolkbestand |
| X_BINARY | DirectX X-bestand in binaire indeling |
| X_TEXT | DirectX X-bestand in binaire indeling |
| ZIP | Zip-archief dat andere 3D-bestandsformaten bevat. |
Methoden
| Methode | Beschrijving |
|---|---|
| createLoadOptions() | Maak standaard laadopties voor dit bestandsformaat |
| createSaveOptions() | Maak standaard opslaanopties voor dit bestandsformaat |
| decode(byte[] data) | Decodeer de puntwolk of mesh vanuit geheugengegevens |
| decode(String fileName) | Decodeer de puntwolk of mesh vanuit opgegeven bestandsnaam |
| detect(Stream stream, String fileName) | Detecteer het bestandsformaat vanuit datastroom, bestandsnaam is optioneel voor het raden van typen die geen magic header hebben. |
| detect(String fileName) | Detecteer het bestandsformaat vanuit bestandsnaam, bestand moet leesbaar zijn zodat Aspose.3D het bestandsformaat via de bestandsheader kan detecteren. |
| encode(Entity entity) | Encodeer het object naar rauwe Draco-gegevens |
| encode(Entity entity, DracoSaveOptions options) | Encodeer het object naar rauwe Draco-gegevens |
| encode(Entity entity, Stream stream) | Encodeer het object naar opgegeven stream |
| encode(Entity entity, Stream stream, DracoSaveOptions options) | Encodeer het object naar opgegeven stream |
| encode(Entity entity, String fileName) | Encodeer het object naar opgegeven bestand |
| encode(Entity entity, String fileName, DracoSaveOptions options) | Encodeer het object naar opgegeven bestand |
| equals(Object arg0) | |
| getCanExport() | Geeft aan of Aspose.3D export van scène naar het huidige bestandsformaat ondersteunt. |
| getCanImport() | Geeft aan of Aspose.3D import van scène vanuit het huidige bestandsformaat ondersteunt. |
| getClass() | |
| getContentType() | Haalt het contenttype van het bestandsformaat op. |
| getExtension() | Haalt de extensienaam van dit type op. |
| getExtensions() | Haalt de extensienamen van dit type op. |
| getFileFormatType() | Haalt het bestandsformaattype op. |
| getFormatByExtension(String extensionName) | Haalt het voorkeursbestandsformaat op basis van de extensienaam. De extensienaam moet beginnen met een punt (’.’). |
| getFormats() | Toegang tot alle ondersteunde formaten |
| getVersion() | Haalt de versie van het bestandsformaat op. |
| hashCode() | |
| notify() | |
| notifyAll() | |
| toString() | Formaten naar string |
| wait() | |
| wait(long arg0) | |
| wait(long arg0, int arg1) |
AMF
public static final FileFormat AMF
Bestandsformaat voor additive manufacturing
ASE
public static final FileFormat ASE
ASCII-scène-exportformaat van 3D Studio Max.
ASPOSE3D_WEB
public static final FileFormat ASPOSE3D_WEB
Aspose.3D Web-formaat.
BLENDER
public static final FileFormat BLENDER
3D-bestandsformaat van Blender
COLLADA
public static final FileFormat COLLADA
Collada-bestandsformaat
DISCREET3DS
public static final FileFormat DISCREET3DS
Bestandsformaat van 3D Studio
DRACO
public static final DracoFormat DRACO
Google Draco Mesh
DXF
public static final FileFormat DXF
AutoCAD DXF
FBX6100ASCII
public static final FileFormat FBX6100ASCII
ASCII FBX-bestandsformaat, versie 6.1.0
FBX6100_BINARY
public static final FileFormat FBX6100_BINARY
Binaire FBX-bestandsformaat, versie 6.1.0
FBX7200ASCII
public static final FileFormat FBX7200ASCII
ASCII FBX-bestandsformaat, versie 7.2.0
FBX7200_BINARY
public static final FileFormat FBX7200_BINARY
Binaire FBX-bestandsformaat, versie 7.2.0
FBX7300ASCII
public static final FileFormat FBX7300ASCII
ASCII FBX-bestandsformaat, versie 7.3.0
FBX7300_BINARY
public static final FileFormat FBX7300_BINARY
Binaire FBX-bestandsformaat, versie 7.3.0
FBX7400ASCII
public static final FileFormat FBX7400ASCII
ASCII FBX-bestandsformaat, versie 7.4.0
FBX7400_BINARY
public static final FileFormat FBX7400_BINARY
Binaire FBX-bestandsformaat, versie 7.4.0
FBX7500ASCII
public static final FileFormat FBX7500ASCII
ASCII FBX-bestandsformaat, met versie 7.5.0
FBX7500_BINARY
public static final FileFormat FBX7500_BINARY
Binair FBX-bestandsformaat, met versie 7.5.0
FBX7600ASCII
public static final FileFormat FBX7600ASCII
ASCII FBX-bestandsformaat, met versie 7.6.0
FBX7600_BINARY
public static final FileFormat FBX7600_BINARY
Binair FBX-bestandsformaat, met versie 7.6.0
FBX7700ASCII
public static final FileFormat FBX7700ASCII
ASCII FBX-bestandsformaat, met versie 7.7.0
FBX7700_BINARY
public static final FileFormat FBX7700_BINARY
Binair FBX-bestandsformaat, met versie 7.7.0
GLTF
public static final FileFormat GLTF
glTF van de Khronos Group
GLTF2
public static final FileFormat GLTF2
glTF versie 2.0 van de Khronos Group
GLTF2_BINARY
public static final FileFormat GLTF2_BINARY
glTF versie 2.0 van de Khronos Group
GLTF_BINARY
public static final FileFormat GLTF_BINARY
glTF van de Khronos Group in binair formaat
HTML5
public static final FileFormat HTML5
HTML5-bestand
IFC
public static final FileFormat IFC
ISO 16739-1 Industry Foundation Classes datamodel.
MAYAASCII
public static final FileFormat MAYAASCII
Autodesk Maya in ASCII-formaat
MAYA_BINARY
public static final FileFormat MAYA_BINARY
Autodesk Maya in binair formaat
MICROSOFT3MF
public static final Microsoft3MFFormat MICROSOFT3MF
Microsoft 3D Manufacturing-formaat
PCD
public static final FileFormat PCD
PCL Point Cloud Data-bestand in ASCII-modus
PCD_BINARY
public static final FileFormat PCD_BINARY
PCL Point Cloud Data-bestand in binair modus
public static final PdfFormat PDF
Portable Document Format van Adobe
PLY
public static final PlyFormat PLY
Polygon File Format of Stanford Triangle Format
RVM_BINARY
public static final RvmFormat RVM_BINARY
AVEVA Plant Design Management System-model in binair formaat
RVM_TEXT
public static final RvmFormat RVM_TEXT
AVEVA Plant Design Management System-model in tekstformaat
SIEMENSJT8
public static final FileFormat SIEMENSJT8
Siemens JT-bestand versie 8
SIEMENSJT9
public static final FileFormat SIEMENSJT9
Siemens JT-bestand versie 9
STLASCII
public static final FileFormat STLASCII
ASCII STL-bestandsformaat
STL_BINARY
public static final FileFormat STL_BINARY
Binair STL-bestandsformaat
UNIVERSAL3D
public static final FileFormat UNIVERSAL3D
Universal3D-bestandsformaat
USD
public static final FileFormat USD
Universele Scènebeschrijving
USDA
public static final FileFormat USDA
Universele Scènebeschrijving in ASCII-indeling.
USDZ
public static final FileFormat USDZ
Gecomprimeerde Universele Scènebeschrijving
VRML
public static final FileFormat VRML
De Virtual Reality Modeling Language
WAVEFRONTOBJ
public static final FileFormat WAVEFRONTOBJ
Wavefront’s Obj-bestandsformaat
XYZ
public static final FileFormat XYZ
Xyz-puntwolkbestand
X_BINARY
public static final FileFormat X_BINARY
DirectX X-bestand in binaire indeling
X_TEXT
public static final FileFormat X_TEXT
DirectX X-bestand in binaire indeling
ZIP
public static final FileFormat ZIP
Zip-archief dat andere 3D-bestandsformaten bevat.
createLoadOptions()
public LoadOptions createLoadOptions()
Maak standaard laadopties voor dit bestandsformaat
Returns: LoadOptions - A default load option for current format
createSaveOptions()
public SaveOptions createSaveOptions()
Maak standaard opslaanopties voor dit bestandsformaat
Returns: SaveOptions - A default save option for current format
decode(byte[] data)
public Geometry decode(byte[] data)
Decodeer de puntwolk of mesh vanuit geheugengegevens
Parameters:
| Parameter | Type | Beschrijving |
|---|---|---|
| gegevens | byte[] | De ruwe drc-bytes |
Returns: Geometry - A Mesh or PointCloud instance depends on the content
decode(String fileName)
public Geometry decode(String fileName)
Decodeer de puntwolk of mesh vanuit opgegeven bestandsnaam
Parameters:
| Parameter | Type | Beschrijving |
|---|---|---|
| fileName | java.lang.String | De bestandsnaam bevat het drc-bestand |
Returns: Geometry - A Mesh or PointCloud instance depends on the file content
detect(Stream stream, String fileName)
public static FileFormat detect(Stream stream, String fileName)
Detecteer het bestandsformaat vanuit datastroom, bestandsnaam is optioneel voor het raden van typen die geen magic header hebben.
Parameters:
| Parameter | Type | Beschrijving |
|---|---|---|
| stream | Stream | Stroom met gegevens om te detecteren |
| fileName | java.lang.String | Originele bestandsnaam van de gegevens, gebruikt als hint. |
Returns: FileFormat - The FileFormat instance of the detected type or null if failed.
detect(String fileName)
public static FileFormat detect(String fileName)
Detecteer het bestandsformaat vanuit bestandsnaam, bestand moet leesbaar zijn zodat Aspose.3D het bestandsformaat via de bestandsheader kan detecteren.
Parameters:
| Parameter | Type | Beschrijving |
|---|---|---|
| fileName | java.lang.String | Pad naar het bestand om het bestandsformaat te detecteren. |
Returns: FileFormat - The FileFormat instance of the detected type or null if failed.
encode(Entity entity)
public byte[] encode(Entity entity)
Encodeer het object naar rauwe Draco-gegevens
Parameters:
| Parameter | Type | Beschrijving |
|---|---|---|
| entity | Entity | Het object dat moet worden gecodeerd |
Returns: byte[] - De gecodeerde draco-gegevens weergegeven in bytes Example: De volgende code toont hoe een Mesh te coderen en te decoderen naar/van een byte-array:
Mesh mesh = (new Sphere()).toMesh();
//encode mesh into Draco format
byte[] draco = FileFormat.DRACO.encode(mesh);
//decode mesh from Draco format
Mesh decodedMesh = (Mesh)FileFormat.DRACO.decode(draco);
encode(Entity entity, DracoSaveOptions options)
public byte[] encode(Entity entity, DracoSaveOptions options)
Encodeer het object naar rauwe Draco-gegevens
Parameters:
| Parameter | Type | Beschrijving |
|---|---|---|
| entity | Entity | Het object dat moet worden gecodeerd |
| options | DracoSaveOptions | Extra opties voor het coderen van de puntwolk |
Returns: byte[] - De gecodeerde draco-gegevens weergegeven in bytes Example: De volgende code toont hoe een Mesh te coderen en te decoderen naar/van een byte-array:
Mesh mesh = (new Sphere()).toMesh();
//encode mesh into Draco format
byte[] draco = FileFormat.DRACO.encode(mesh);
//decode mesh from Draco format
Mesh decodedMesh = (Mesh)FileFormat.DRACO.decode(draco);
encode(Entity entity, Stream stream)
public void encode(Entity entity, Stream stream)
Encodeer het object naar opgegeven stream
Parameters:
| Parameter | Type | Beschrijving |
|---|---|---|
| entity | Entity | Het object dat moet worden gecodeerd |
| stream | Stream | De stream waar gecodeerde data naartoe wordt geschreven |
encode(Entity entity, Stream stream, DracoSaveOptions options)
public void encode(Entity entity, Stream stream, DracoSaveOptions options)
Encodeer het object naar opgegeven stream
Parameters:
| Parameter | Type | Beschrijving |
|---|---|---|
| entity | Entity | Het object dat moet worden gecodeerd |
| stream | Stream | De stream waar gecodeerde data naartoe wordt geschreven |
| options | DracoSaveOptions | Extra opties voor het coderen van de puntwolk |
encode(Entity entity, String fileName)
public void encode(Entity entity, String fileName)
Encodeer het object naar opgegeven bestand
Parameters:
| Parameter | Type | Beschrijving |
|---|---|---|
| entity | Entity | Het object dat moet worden gecodeerd |
| fileName | java.lang.String | De bestandsnaam die moet worden geschreven |
encode(Entity entity, String fileName, DracoSaveOptions options)
public void encode(Entity entity, String fileName, DracoSaveOptions options)
Encodeer het object naar opgegeven bestand
Parameters:
| Parameter | Type | Beschrijving |
|---|---|---|
| entity | Entity | Het object dat moet worden gecodeerd |
| fileName | java.lang.String | De bestandsnaam die moet worden geschreven |
| options | DracoSaveOptions | Extra opties voor het coderen van de puntwolk |
equals(Object arg0)
public boolean equals(Object arg0)
Parameters:
| Parameter | Type | Beschrijving |
|---|---|---|
| arg0 | java.lang.Object |
Returns: boolean
getCanExport()
public boolean getCanExport()
Geeft aan of Aspose.3D export van scène naar het huidige bestandsformaat ondersteunt.
Returns: boolean - of Aspose.3D ondersteuning biedt voor het exporteren van een scène naar het huidige bestandsformaat. Voorbeeld: De volgende code toont hoe te controleren of exporteren naar het opgegeven formaat wordt ondersteund.
var outputFormat = ".glb";
var format = FileFormat.getFormatByExtension(outputFormat);
if (format.getCanExport())
System.out.printf("Can export to %s", outputFormat);
getCanImport()
public boolean getCanImport()
Geeft aan of Aspose.3D import van scène vanuit het huidige bestandsformaat ondersteunt.
Returns: boolean - of Aspose.3D ondersteuning biedt voor het importeren van een scène vanuit het huidige bestandsformaat. Voorbeeld: De volgende code toont hoe te controleren of importeren vanuit het opgegeven formaat wordt ondersteund.
var outputFormat = ".glb";
var format = FileFormat.getFormatByExtension(outputFormat);
if (format.getCanImport())
System.out.printf("Can import from %s", outputFormat);
getClass()
public final native Class<?> getClass()
Returns: java.lang.Class
getContentType()
public FileContentType getContentType()
Haalt het contenttype van het bestandsformaat op.
Returns: FileContentType - file format content type Example:
var format = FileFormat.MAYA_BINARY;
if (format.getContentType() == FileContentType.BINARY)
System.out.printf("%s is binary format", format);
else
System.out.printf("%s is text-based format", format);
getExtension()
public String getExtension()
Haalt de extensienaam van dit type op.
Returns: java.lang.String - de extensienaam van dit type. Voorbeeld:
var format = FileFormat.MAYA_BINARY;
System.out.printf("Extension of %s is %s", format, format.getExtension());
getExtensions()
public String[] getExtensions()
Haalt de extensienamen van dit type op.
Returns: java.lang.String[] - de extensienamen van dit type.
getFileFormatType()
public FileFormatType getFileFormatType()
Haalt het bestandsformaattype op.
Returns: FileFormatType - file format type
getFormatByExtension(String extensionName)
public static FileFormat getFormatByExtension(String extensionName)
Haalt het voorkeursbestandsformaat op basis van de extensienaam. De extensienaam moet beginnen met een punt (’.’).
Parameters:
| Parameter | Type | Beschrijving |
|---|---|---|
| extensionName | java.lang.String | De extensienaam begint met ‘.’ om te zoeken. |
Returns: FileFormat - Instance of FileFormat, otherwise null returned. Example: The following code shows how to save scene to memory using specified format
Scene scene = new Scene(new Box());
var outputFormat = ".glb";
var format = FileFormat.getFormatByExtension(outputFormat);
var output = new ByteArrayOutputStream();
scene.save(output);
getFormats()
public static List<FileFormat> getFormats()
Toegang tot alle ondersteunde formaten
Returns: java.util.List<com.aspose.threed.FileFormat> - Toegang tot alle ondersteunde formaten
getVersion()
public Version getVersion()
Haalt de versie van het bestandsformaat op.
Returns: Version - file format version
hashCode()
public native int hashCode()
Returns: int
notify()
public final native void notify()
notifyAll()
public final native void notifyAll()
toString()
public String toString()
Formaten naar string
Returns: java.lang.String - Objecttekenreeks
wait()
public final void wait()
wait(long arg0)
public final void wait(long arg0)
Parameters:
| Parameter | Type | Beschrijving |
|---|---|---|
| arg0 | long |
wait(long arg0, int arg1)
public final void wait(long arg0, int arg1)
Parameters:
| Parameter | Type | Beschrijving |
|---|---|---|
| arg0 | long | |
| arg1 | int |