浏览我们的产品

Aspose.3D for Java 22.6发行说明

改进和变更

钥匙摘要类别
THREEDNET-1152允许保存3D场景而不指定文件格式新功能
THREEDNET-1157USDZ导入不支持SdfValueBlock改进
THREEDNET-1156GLF异常: 导入glTF失败,未在访问器中定义byteOffset错误修复
THREEDNET-1154Aspose.ThreeD.ExportException: 规范重复,同时DAE USDZ转换错误修复
THREEDNET-1153将USDZ保存到GLTF时发生异常错误修复

API更改

向类com.aspose.threed.FileFormat添加了新方法:

    /**
     * Gets the preferred file format from the file extension name
     * The extension name should starts with a dot('.').
     * @param extensionName 
     */
    public static FileFormat getFormatByExtension(String extensionName)

您可以通过扩展名名称获取文件格式实例,示例代码:

var scene = new Scene(new Box());
var format = FileFormat.getFormatByExtension(".fbx");
//save the scene to memory stream using FileFormat returned by GetFormatByExtension
var stream = new ByteArrayOutputStream();
scene.save(Stream.wrap(stream), format);

向类com.aspose.threed.Scene添加了新方法:

    /**
     * Saves the scene to specified path using specified file format.
     * @param fileName File name.
     */
    public void save(String fileName)
        throws IOException;

新方法允许您将场景保存到3D文件,而无需提供文件格式。

示例代码:

var scene = Scene.fromFile("Input.fbx");
scene.save("Output.usdz);


 
 简体中文