我在Viewer Release Notes: v4.0.1
中读到现在支持Protein Materials tiling patterns
(Revit 2019)。这很棒!但是,作为3ds Max用户,我很好奇是否有计划支持来自3ds Max的bitmap-textures
或custom materials
?这确实会产生新的可能性。
答案 0 :(得分:1)
我不确定旧版本,但正如您可以从以下屏幕截图中看到一位同事创建的场景:
使用纹理转换max文件时应该没有问题,只要按照以下步骤操作:
filename = 'max_archive.zip'
bucket_name = bucketKey
url = "https://developer.api.autodesk.com"
my_object_endpoint = "/oss/v2/buckets/" + bucket_name + "/objects/" + filename
header = {
"Authorization": "Bearer " + token,
"Content-Type": "application/octet-stream",
"Content-Length": str(os.path.getsize(filename)),
}
with open(filename, 'rb') as object_to_upload:
response_upload = requests.put(url + my_object_endpoint, headers=header, data=object_to_upload)
job_endpoint = '/modelderivative/v2/designdata/job'
header = {
"Authorization": "Bearer " + token,
"Content-Type": "application/json",
}
payload = json.dumps({
"input" : {
"urn": '"' + encoded_urn + '"',
"rootFilename": "physical_material.max",
"compressedUrn": True
},
"output": {
"formats": [
{
"type": "svf",
"views": [
"2d",
"3d"
]
}
]
}
})
response = requests.post(url+job_endpoint, headers=header, data=payload)
此处的关键点是有效负载的 输入 部分,您必须指定 rootFilename 并设置压缩为 true 。
在我的情况下,我得到了上面提到的屏幕截图中的结果。