在Unreal Engine 4的Runtime中,使用Assimp库导入各类3D文件(如fbx、obj和gltf)到UStaticMesh
备忘笔记..........
---------------------------- 割 --------------------------------------------
实现的插件地址:
https://github.com/linqingwudiv1/RuntimeMeshLoaderextend
(居于https://github.com/GameInstitute/RuntimeMeshLoader 开源的修改)
原本的RuntimeMeshLoader 源码仅支持从Assimp数据到UProducalMeshComponent。
并不能满足我希望从assimp网格化数据到UStaticMesh的转换
所以就参考UE4源码的ProceduralMeshComponentEditor 模块的ProceduralMeshComponentDetails.cpp里的ClickedOnConvertToStaticMesh 函数,
对RuntimeMeshLoader插件进行扩展
予人肥皂,手有余香 ( 滑稽 )
可优化点记录: (随缘更新完善)
1.使用TBB加速
2.StaticMesh 单分段单材质,并导入格式自带贴图
3.SkeletalMesh的动态加载
4.可Transform变换
5.以及全平台支持(Assimp是支持全平台的,但是,目前我只编译了Windows 和 Mac OSX 平台下的Assimp Library(带 export 模块),linux或andorid/IOS等需要自己编译集成.a,.so)
6.Collision多方式支持
-------------------------------------- 割 -------------------------------------------
nOTE:有个挺严重的问题:打包后Collision失效,正在翻UStaticMesh的BodySetup尝试决解ing..(人生苦短我看源码,难啊!)
翻源码的分析过程记录:
目标:在不改动源码的的情况下,在Runtime环境下根据Assimp加载的网格创建UStaticMesh
主要参考 UE4 自带插件 UProceduralMeshComponent 的 Editor 功能:FProceduralMeshComponentDetails::ClickedOnConvertToStaticMesh 函数,
在使用assimp库导入原生信息时,Vertex到StaticMesh的过程,中间有遇到一些Editor函数转
通过assimp加载网格 环境完整代码参考:
.h
UENUM(BlueprintType) enum class EPathType : uint8 { Absolute UMETA(DisplayName = "Absolute"), Relative UMETA(DisplayName = "Relative") }; USTRUCT(BlueprintType) struct FMeshInfo { GENERATED_USTRUCT_BODY() UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "ReturnedData") TArray<FVector> Vertices; UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "ReturnedData") /** Vertices index */ TArray<int32> Triangles; UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "ReturnedData") TArray<FVector> Normals; UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "ReturnedData") TArray<FVector2D> UV0; UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "ReturnedData") TArray<FVector2D> UV1; UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "ReturnedData") TArray<FVector2D> UV2; UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "ReturnedData") TArray<FVector2D> UV3; UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "ReturnedData") TArray<FLinearColor> VertexColors; UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "ReturnedData") TArray<FProcMeshTangent> Tangents; UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "ReturnedData") FTransform RelativeTransform; }; USTRUCT(BlueprintType) struct FReturnedData { GENERATED_USTRUCT_BODY() public: UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "ReturnedData") /**/ bool bSuccess; /** Contain Mesh Count */ UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "ReturnedData") int32 NumMeshes; UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "ReturnedData") TArray<FMeshInfo> meshInfo; }; /** * */ UCLASS() class RUNTIMEMESHLOADER_API ULoaderBPFunctionLibrary : public UBlueprintFunctionLibrary { GENERATED_BODY() public: /** */ UFUNCTION( BlueprintCallable, Category="MeshLoader") static FReturnedData LoadMesh(const FString& filepath, const FTransform& tran, EPathType type= EPathType:: Absolute ); /** */ UFUNCTION( BlueprintCallable, Category = "MeshLoader", meta = ( HidePin = "WorldContextObject", DefaultToSelf = "WorldContextObject" ) ) static UStaticMesh* LoadMeshToStaticMesh( UObject* WorldContextObject, const FString& filepath, const FTransform& tran, EPathType type = EPathType::Absolute ); };
.cpp
void FindMeshInfo(const aiScene* scene, aiNode* node, FReturnedData& result,const FTransform &tran = FTransform()) { //transform... aiMatrix4x4 TranMat,tempMat; bool bTran = false; if ( !tran.GetLocation().Equals(FVector{ 0.0f }, 0.01f ) ) { bTran = true; TranMat = TranMat.Translation(aiVector3D{ tran.GetLocation().X, tran.GetLocation().Y, tran.GetLocation().Z }, tempMat); } if ( !tran.GetScale3D().Equals( FVector{ 1.0f }, 0.01f ) ) { bTran = true; TranMat = TranMat.Scaling(aiVector3D{ tran.GetScale3D().X, tran.GetScale3D().Y, tran.GetScale3D().Z }, tempMat); } if ( !tran.GetRotation().Equals( FRotator{ 0.0f }.Quaternion(), 0.01f ) ) { bTran = true; TranMat = TranMat.RotationX( PI / 180.f * tran.GetRotation().Rotator().Roll , tempMat ); TranMat = TranMat.RotationY( PI / 180.f * tran.GetRotation().Rotator().Yaw , tempMat ); TranMat = TranMat.RotationZ( PI / 180.f * tran.GetRotation().Rotator().Pitch , tempMat ); } // for (uint32 i = 0; i < node->) for (uint32 i = 0; i < node->mNumMeshes; i++) { std::string TestString = node->mName.C_Str(); FString Fs = FString(TestString.c_str()); UE_LOG(LogTemp, Warning, TEXT("FindMeshInfo. %s\n"), *Fs); int meshidx = *node->mMeshes; aiMesh *mesh = scene->mMeshes [ meshidx ]; FMeshInfo &mi = result.meshInfo [ meshidx ]; aiMatrix4x4 tempTrans = node->mTransformation; //如果变换 if (bTran) { tempTrans = tempTrans * TranMat; } FMatrix tempMatrix; // e.g // _______________ // | A0,B0,C0,D0 | // | A1,B1,C1,D1 | // | A2,B2,C2,D2 | // | A3,B3,C3,D3 | // |_____________| // tempMatrix.M[0][0] = tempTrans.a1; tempMatrix.M[0][1] = tempTrans.b1; tempMatrix.M[0][2] = tempTrans.c1; tempMatrix.M[0][3] = tempTrans.d1; tempMatrix.M[1][0] = tempTrans.a2; tempMatrix.M[1][1] = tempTrans.b2; tempMatrix.M[1][2] = tempTrans.c2; tempMatrix.M[1][3] = tempTrans.d2; tempMatrix.M[2][0] = tempTrans.a3; tempMatrix.M[2][1] = tempTrans.b3; tempMatrix.M[2][2] = tempTrans.c3; tempMatrix.M[2][3] = tempTrans.d3; tempMatrix.M[3][0] = tempTrans.a4; tempMatrix.M[3][1] = tempTrans.b4; tempMatrix.M[3][2] = tempTrans.c4; tempMatrix.M[3][3] = tempTrans.d4; // Mesh transform on scene mi.RelativeTransform = FTransform(tempMatrix); // fill Mesh Vertices 填充Mesh顶点 for (uint32 j = 0; j < mesh->mNumVertices; ++j) { FVector vertex = FVector ( mesh->mVertices[j].x , mesh->mVertices[j].y , mesh->mVertices[j].z ); vertex = mi.RelativeTransform.TransformFVector4(vertex); // vertex = mi.RelativeTransform.Trans mi.Vertices.Push( vertex ); //Normal if (mesh->HasNormals()) { FVector normal = FVector( mesh->mNormals[j].x , mesh->mNormals[j].y , mesh->mNormals[j].z );
if (bTran)
{
normal = mi.RelativeTransform.TransformFVector4(normal);
}
mi.Normals.Push(normal); } else { mi.Normals.Push(FVector::ZeroVector); } // UV0 Coordinates - inconsistent coordinates if (mesh->HasTextureCoords(0)) { FVector2D uv = FVector2D(mesh->mTextureCoords[0][j].x, -mesh->mTextureCoords[0][j].y); mi.UV0.Add(uv); } // UV1 Coordinates - inconsistent coordinates if (mesh->HasTextureCoords(1)) { FVector2D uv = FVector2D(mesh->mTextureCoords[1][j].x, -mesh->mTextureCoords[1][j].y); mi.UV1.Add(uv); } // UV2 Coordinates - inconsistent coordinates if (mesh->HasTextureCoords(2)) { FVector2D uv = FVector2D(mesh->mTextureCoords[2][j].x, -mesh->mTextureCoords[2][j].y); mi.UV2.Add(uv); } // UV3 Coordinates - inconsistent coordinates if (mesh->HasTextureCoords(3)) { FVector2D uv = FVector2D(mesh->mTextureCoords[3][j].x, -mesh->mTextureCoords[3][j].y); mi.UV3.Add(uv); } // Tangent /切线 if (mesh->HasTangentsAndBitangents()) { FProcMeshTangent meshTangent = FProcMeshTangent( mesh->mTangents[j].x, mesh->mTangents[j].y, mesh->mTangents[j].z ); mi.Tangents.Push(meshTangent); } //Vertex color if (mesh->HasVertexColors(0)) { FLinearColor color = FLinearColor( mesh->mColors[0][j].r, mesh->mColors[0][j].g, mesh->mColors[0][j].b, mesh->mColors[0][j].a ); mi.VertexColors.Push(color); } } } } void FindMesh(const aiScene* scene, aiNode* node, FReturnedData& retdata, const FTransform &tran) { FindMeshInfo(scene, node, retdata); // tree node for ( uint32 m = 0; m < node->mNumChildren; ++m ) { FindMesh(scene, node->mChildren[m], retdata, tran); } } /** * */ TMap<UMaterialInterface*, FPolygonGroupID> BuildMaterialMapExchange(FReturnedData& ReturnedData, /* UProceduralMeshComponent* ProcMeshComp ,*/ FMeshDescription& MeshDescription) { TMap<UMaterialInterface*, FPolygonGroupID> UniqueMaterials; const int32 NumSections = ReturnedData.meshInfo.Num(); //ProcMeshComp->GetNumSections(); UniqueMaterials.Reserve(NumSections); FStaticMeshAttributes AttributeGetter(MeshDescription); TPolygonGroupAttributesRef<FName> PolygonGroupNames = AttributeGetter.GetPolygonGroupMaterialSlotNames(); for ( int32 SectionIdx = 0; SectionIdx < NumSections; SectionIdx++ ) { FMeshInfo MeshInfo = ReturnedData.meshInfo[SectionIdx]; // MeshInfo.Normals UMaterialInterface* Material = UMaterial::GetDefaultMaterial(MD_Surface); if ( !UniqueMaterials.Contains(Material) ) { FPolygonGroupID NewPolygonGroup = MeshDescription.CreatePolygonGroup(); UniqueMaterials.Add(Material, NewPolygonGroup); PolygonGroupNames[NewPolygonGroup] = Material->GetFName(); } } return UniqueMaterials; } /** * */ FMeshDescription BuildMeshDescriptionExtend( FReturnedData& MeshsData /* UProceduralMeshComponent* ProcMeshComp */) { FMeshDescription MeshDescription; FStaticMeshAttributes AttributeGetter(MeshDescription); AttributeGetter.Register(); TPolygonGroupAttributesRef<FName> PolygonGroupNames = AttributeGetter.GetPolygonGroupMaterialSlotNames(); TVertexAttributesRef<FVector> VertexPositions = AttributeGetter.GetVertexPositions(); TVertexInstanceAttributesRef<FVector> Tangents = AttributeGetter.GetVertexInstanceTangents(); TVertexInstanceAttributesRef<float> BinormalSigns = AttributeGetter.GetVertexInstanceBinormalSigns(); TVertexInstanceAttributesRef<FVector> Normals = AttributeGetter.GetVertexInstanceNormals(); TVertexInstanceAttributesRef<FVector4> Colors = AttributeGetter.GetVertexInstanceColors(); TVertexInstanceAttributesRef<FVector2D> UVs = AttributeGetter.GetVertexInstanceUVs(); // Materials to apply to new mesh const int32 NumSections = MeshsData.meshInfo.Num(); // ProcMeshComp->GetNumSections(); int32 VertexCount = 0; int32 VertexInstanceCount = 0; int32 PolygonCount = 0; TMap<UMaterialInterface*, FPolygonGroupID> UniqueMaterials = BuildMaterialMapExchange(MeshsData, MeshDescription); TArray<FPolygonGroupID> PolygonGroupForSection; PolygonGroupForSection.Reserve(NumSections); // Calculate the totals for each ProcMesh element type for (int32 SectionIdx = 0; SectionIdx < NumSections; SectionIdx++) { FMeshInfo MeshInfo = MeshsData.meshInfo[SectionIdx]; VertexCount += MeshInfo.Vertices.Num () ; // ProcSection->ProcVertexBuffer.Num(); VertexInstanceCount += MeshInfo.Triangles.Num() ; // ProcSection->ProcIndexBuffer.Num(); PolygonCount += MeshInfo.Triangles.Num() / 3 ; // ProcSection->ProcIndexBuffer.Num() / 3; } MeshDescription.ReserveNewVertices(VertexCount); MeshDescription.ReserveNewVertexInstances(VertexInstanceCount); MeshDescription.ReserveNewPolygons( PolygonCount ); MeshDescription.ReserveNewEdges( PolygonCount * 2); UVs.SetNumIndices(4); // Create the Polygon Groups for (int32 SectionIdx = 0; SectionIdx < NumSections; SectionIdx++) { FMeshInfo MeshInfo = MeshsData.meshInfo[SectionIdx]; UMaterialInterface* Material = UMaterial::GetDefaultMaterial(MD_Surface); FPolygonGroupID* PolygonGroupID = UniqueMaterials.Find(Material); check( PolygonGroupID != nullptr ); PolygonGroupForSection.Add(*PolygonGroupID); } // Add Vertex and VertexInstance and polygon for each section for (int32 SectionIdx = 0; SectionIdx < NumSections; SectionIdx++) { FMeshInfo MeshInfo = MeshsData.meshInfo[SectionIdx]; FPolygonGroupID PolygonGroupID = PolygonGroupForSection[SectionIdx]; // Create the vertex int32 NumVertex = MeshInfo.Vertices.Num(); TMap<int32, FVertexID> VertexIndexToVertexID; VertexIndexToVertexID.Reserve(NumVertex); for (int32 VertexIndex = 0; VertexIndex < NumVertex; ++VertexIndex) { FVector Vert = MeshInfo.Vertices[VertexIndex]; const FVertexID VertexID = MeshDescription.CreateVertex(); VertexPositions[VertexID] = Vert; VertexIndexToVertexID.Add(VertexIndex, VertexID); } // Create the VertexInstance int32 NumIndices = MeshInfo.Triangles.Num(); int32 NumTri = NumIndices / 3; TMap<int32, FVertexInstanceID> IndiceIndexToVertexInstanceID; IndiceIndexToVertexInstanceID.Reserve(NumVertex); for (int32 IndiceIndex = 0; IndiceIndex < NumIndices; IndiceIndex++) { const int32 VertexIndex = MeshInfo.Triangles[IndiceIndex]; const FVertexID VertexID = VertexIndexToVertexID[VertexIndex]; const FVertexInstanceID VertexInstanceID = MeshDescription.CreateVertexInstance(VertexID); IndiceIndexToVertexInstanceID.Add(IndiceIndex, VertexInstanceID); FVector ProcVertex = MeshInfo.Vertices[VertexIndex]; // FProcMeshVertex& ProcVertex = ProcSection->ProcVertexBuffer[VertexIndex]; FProcMeshTangent VertexTanents = MeshInfo.Tangents[VertexIndex]; FLinearColor VertexColor = MeshInfo.VertexColors.Num() > VertexIndex ? MeshInfo.VertexColors[VertexIndex] : FLinearColor(1.0, 0.0, 0.0); Tangents[VertexInstanceID] = VertexTanents.TangentX; // ProcVertex.Tangent.TangentX; Normals[VertexInstanceID] = MeshInfo.Normals[VertexIndex]; // ProcVertex.Normal; BinormalSigns[VertexInstanceID] = VertexTanents.bFlipTangentY ? -1.f : 1.f; Colors[VertexInstanceID] = VertexColor; //FLinearColor(ProcVertex.Color); if ( MeshInfo.UV0.Num() > VertexIndex) { UVs.Set(VertexInstanceID, 0, MeshInfo.UV0[VertexIndex]); } if ( MeshInfo.UV1.Num() > VertexIndex) { UVs.Set(VertexInstanceID, 1, MeshInfo.UV1[VertexIndex]); } if ( MeshInfo.UV2.Num() > VertexIndex ) { UVs.Set(VertexInstanceID, 2, MeshInfo.UV2[VertexIndex]); } if ( MeshInfo.UV3.Num() > VertexIndex ) { UVs.Set(VertexInstanceID, 3, MeshInfo.UV3[VertexIndex]); } } // Create the polygons for this section for (int32 TriIdx = 0; TriIdx < NumTri; TriIdx++) { FVertexID VertexIndexes[3]; TArray<FVertexInstanceID> VertexInstanceIDs; VertexInstanceIDs.SetNum(3); for (int32 CornerIndex = 0; CornerIndex < 3; ++CornerIndex) { const int32 IndiceIndex = (TriIdx * 3) + CornerIndex; const int32 VertexIndex = MeshInfo.Triangles[IndiceIndex]; //ProcSection->ProcIndexBuffer[IndiceIndex]; VertexIndexes[CornerIndex] = VertexIndexToVertexID[VertexIndex]; VertexInstanceIDs[CornerIndex] = IndiceIndexToVertexInstanceID[IndiceIndex]; } // Insert a polygon into the mesh MeshDescription.CreatePolygon(PolygonGroupID, VertexInstanceIDs); } } return MeshDescription; } UStaticMesh* ULoaderBPFunctionLibrary::LoadMeshToStaticMesh( UObject* WorldContextObject, const FString& filepath, const FTransform& tran, EPathType type /* = EPathType::Absolute */ ) { FReturnedData&& MeshInfo = ULoaderBPFunctionLibrary::LoadMesh(filepath, tran, type); FString NewNameSuggestion = FString(TEXT("ProcMesh")); FString PackageName = FString(TEXT("/Game/Meshes/")) + NewNameSuggestion; FString Name; FString UserPackageName = TEXT(""); FName MeshName(*FPackageName::GetLongPackageAssetName(UserPackageName)); // Check if the user inputed a valid asset name, if they did not, give it the generated default name if (MeshName == NAME_None) { // Use the defaults that were already generated. UserPackageName = PackageName; MeshName = *Name; } FMeshDescription MeshDescription = BuildMeshDescriptionExtend(MeshInfo); UStaticMesh* StaticMesh = NewObject<UStaticMesh>(WorldContextObject, MeshName, RF_Public | RF_Standalone); StaticMesh->InitResources(); StaticMesh->LightingGuid = FGuid::NewGuid(); TArray<const FMeshDescription*> arr; arr.Add(&MeshDescription); StaticMesh->BuildFromMeshDescriptions(arr, false); //// MATERIALS TSet<UMaterialInterface*> UniqueMaterials; const int32 NumSections = 1; for (int32 SectionIdx = 0; SectionIdx < NumSections; SectionIdx++) { UMaterialInterface* Material = UMaterial::GetDefaultMaterial(MD_Surface); UniqueMaterials.Add(Material); } // Copy materials to new mesh int32 MaterialID = 0; for (UMaterialInterface* Material : UniqueMaterials) { // Material FStaticMaterial&& StaticMat = FStaticMaterial(Material); StaticMat.UVChannelData.bInitialized = true; StaticMesh->StaticMaterials.Add(StaticMat); #pragma region 模拟填充 FMeshSectionInfo FStaticMeshRenderData* const RenderData = StaticMesh->RenderData.Get(); int32 LODIndex = 0; int32 MaxLODs = RenderData->LODResources.Num(); for (; LODIndex < MaxLODs; ++LODIndex) { FStaticMeshLODResources& LOD = RenderData->LODResources[LODIndex]; for (int32 SectionIndex = 0; SectionIndex < LOD.Sections.Num(); ++SectionIndex) { FStaticMeshSection& Section = LOD.Sections[SectionIndex]; Section.MaterialIndex = MaterialID; Section.bEnableCollision = true; Section.bCastShadow = true; Section.bForceOpaque = false; } } #pragma endregion MaterialID++; } return StaticMesh; }
推荐阅读
-
在Unreal Engine 4的Runtime中,使用Assimp库导入各类3D文件(如fbx、obj和gltf)到UStaticMesh
-
41 个下载免费 3D 模型的最佳网站-使用说明:使用权限可能因型号而异。因此,在下载文件之前,请仔细检查每个下载页面上的许可证和使用权限。 17. Clara.io Clara.io 是一个创建 3D 内容的全球平台,也是一个培养新 3D 艺术家的社区。Clara.io 提供+100,000个免费的3D模型,包括OBJ,Blend,STL,FBX,DAE,Babylon.JS,Three.JS格式,用于 Clara.io,Unity 3D,Blender,Sketchup,Cinema 4D,3DS Max和Maya。 使用说明:免费,标准和专业帐户仅供个人使用,如果您需要将 clara.io 用于商业用途,请与销售团队联系。 18. 3DExport 3DExport是一个市场,您可以在其中购买和销售用于CG项目的3D模型,3D打印模型和纹理。它提供15 +不同的3D格式供下载,如3DS MAX(.max),Cinema4D(.c4d),Maya(.mb,.ma),Lightwave(.lwo),Softimage(.xsi),Wavefront OBJ(.obj),Autodesk FBX(.fbx)等。它还提供15种不同的语言! 使用说明:免费下载仅供个人和非商业用途。 19. 3D Warehouse 3D Warehouse是一个开放的库,允许用户共享和下载SketchUp 3D模型,用于建筑,设计,施工和娱乐!任何人都可以免费制作,修改和重新上传内容到3D仓库,您可以找到任何您能想到的东西,如家具,电子产品,室内产品等。 使用说明:3D Warehouse中的所有模型都是免费的,因此任何人都可以下载文件以用于SketchUp甚至其他软件,如AutoCAD,Revit和ArchiCAD。 20. CadNav.com CadNav是CGI平面设计师和CAD / CAM / CAE工程师的在线3D模型库,我们提供超过50000 +免费3D模型和CAD模型下载。在CadNav网站上,您可以下载高质量的多边形网格3D模型,3D CAD实体对象,纹理,Vray材料,3D作品,CAD图纸等。 使用说明:免费下载仅供个人和非商业用途。 21. All3dfree.net 就像网站名称一样,它提供免费的3D模型,还包括Vray材料,CAD块,2d和3d纹理集合,无需注册即可免费下载。它是不断更新的,因此您可以查找或请求3DS,MAX,C4D,skp,OBJ,FBX,MTL等格式的模型。 使用说明:所有资源均不允许用于商业用途,否则您将承担责任。 22. Hum3D 自2005年以来,Hum3D帮助来自3多个国家的80D艺术家节省3D建模时间,并制作逼真的3D模型,用于电影,视频游戏,AR应用程序和可视化。所有模型均由首席3D艺术家进行验证,他们检查其是否符合专业要求和最新的3D建模标准。 使用说明:免费下载仅供个人和非商业用途。 23. Artist-3D.com 艺术家-3D 库存的免费 3D 模型下载按通用类别排序。它为人体解剖学、汽车、家具、火箭、卫星等模型提供 AutoDesk 3DS Max 格式。您还可以在浏览他们的网站时找到教程和类似类型的建模。 使用说明:使用权限可能因型号而异。因此,在下载文件之前,请仔细检查每个下载页面上的许可证和使用权限。 24. Free the models 就像本网站的标题一样,它为3d应用程序和3d游戏引擎提供免费的内容模型。您可以为您的任何项目找到许多有趣且有用的模型!它提供3ds,wavefront,bryce,poser,lightwave,md2和unity3d格式的模型。还有一个很棒的纹理集合,可以在您最喜欢的建模和渲染程序中使用。 使用说明:您从这里下载的所有内容都可以免费使用,除非它不能包含在另一个免费的网络或CD收藏中,也不能单独出售。否则,您可以在商业游戏,3D应用程序或渲染作品中使用它。您不必提供信用,但如果您这样做,那就太好了。 25. Resources.blogscopia 本网站由一家名为Scopia的公司创建。他们制作3D图像和视频,您可以找到许多为CGI工作的信息架构设计的模型,所有这些都可以在现实生活中使用。您可以免费下载它们,但是,如果您想一次下载它们,您可以支付 3 到 9 欧元。 使用说明:您可以免费下载模型部分的所有文件。每个压缩文件都包含您也可以在此处找到的许可证。基本上,您可以对文件执行任何操作。唯一的限制是不归属于Scopia的重新分发。 26.ambientCG 1000+公共领域PBR材料适合所有人!环境CG是使用许多不同的方法和资产类型创建的,例如照片纹理(PBR),贴花(PBR),图集(PBR),照片纹理(普通),物质存档(SBSAR),雕刻画笔,3D模型和地形。您可以在所有项目中*使用它们! 使用说明:在 ambientCG 上提供下载的所有 PBR 材料、画笔、照片和 3D 模型均根据知识共享 CC0 1.0 通用许可提供。您可以复制、修改、分发和执行作品,即使是出于商业目的,也无需征得许可。信用将不胜感激。 不要满足于平庸的大理石纹理 - 立即使用我们的免费PBR大理石纹理升级您的3D设计。 27.Pixar One Twenty Eight 这是一个提供官方动画行业经典纹理的网站:皮克斯,创建于 1993 年,该纹理库包括 128 个重复纹理,现在免费提供。 它包含您来到的纹理,包括砖块和动物毛皮。肯定会有一些你可以使用的东西。 使用说明:皮克斯动画工作室的《Pixar One Twenty Eight》根据知识共享署名4.0国际许可协议进行许可。即使出于商业目的,您也可以重新混合、调整和构建您的作品,只要您以相同的条款对新创作进行信用和许可。 访问数以千计的免费纹理并提升您的设计游戏 - 立即开始下载! 28. 3DXO 即使有近 620 个免费贴纸可供下载,3DXO 也不是最大的资源,但它的内容非常有用,不需要注册。无论是简单的墙壁或地板,还是一些奇怪的小东西,您都需要的纹理都可以在此网站上看到。 使用说明:使用权限可能因型号而异。因此,在下载文件之前,请仔细检查每个下载页面上的许可证和使用权限。 29. 3DModelsCC0 3DModelsCC0 与其他产品的不同之处在于它包含超过 250+ 个高质量 3D 模型,并且本网站上的所有内容都是免费的,完全是公共领域!使用我们的模型时无需信用或归属! 使用说明:为每个人提供完全免费的公共领域内容。 30.Sketch up texture club Sketchup Texture Club是一个非营利性的教育和信息门户网站,由3D社区的图像促进协会管理,特别强调面向学生和建筑和室内设计专业人士的可视化和渲染技术,以及所有正在学习3D可视化的人。 使用说明:您无需支付版税或使用费。纹理可以免费下载和使用。不允许将纹理作为竞争产品出售或重新分发,即使图像被修改也是如此。 31. FlippedNormals FlippedNormal 是一个提供计算机图形和 3D 资产的市场,您可以找到许多用于雕刻、建模、纹理、概念艺术、3D 模型、游戏资产或课程的高级资产! 使用说明:使用权限可能因型号而异。因此,在下载文件之前,请仔细检查每个下载页面上的许可证和使用权限。 32. NASA 3D NASA 3D网站是一个在线门户,提供与太空和各种NASA任务相关的大量三维模型和模拟。该网站是用户友好的,并提供有关每个型号的详细信息。该网站允许用户探索和下载几种不同格式的模型,包括 OBJ、STL 和 FBX,只需单击下载按钮即可。 使用说明: 要下载模型,只需单击模型页面上的下载按钮并选择所需的格式。 33. 3DAGOGO (Astroprint) 3DAGOGO 是一个提供广泛 3D 模型的网站,包括角色、车辆和建筑物。3DAGOGO 的独特功能之一是它专注于适合 3D 打印的模型,使其成为希望创建物理原型或模型的设计师的绝佳资源。要使用 3DAGOGO,设计师只需在网站上搜索他们正在寻找的模型类型,然后下载 STL 格式的文件。 使用说明: 要使用 3DAGOGO,只需搜索所需的 3D 模型类型并下载 STL 格式的文件。根据需要自定义模型,并确保在将其用于商业目的之前检查使用权限。 34. FreeCAD FreeCAD是一款了不起的3D建模软件,可让您在计算机上创建令人难以置信的3D设计。该软件可免费下载和使用,它提供了广泛的工具和功能,可用于创建用于各种目的的3D模型。 该网站易于浏览,您可以找到开始使用FreeCAD的所有必要信息。此外,该网站还提供一系列教程和指南,可帮助您了解 3D 建模的来龙去脉。 使用说明: 要下载模型,请访问网站并从库中选择所需的模型。该网站还提供了一系列使用该软件的教程和指南。 35. Pinshape Pinshape是一个提供一系列3D打印模型的网站。网站上提供的型号质量很高,因此您可以确保您的最终印刷产品看起来很棒。该网站提供了广泛的模型,包括从家居用品到小雕像和珠宝的所有物品。 但这还不是Pinshape所能提供的全部!该网站还允许用户上传和共享自己的3D模型。这意味着您不仅可以下载出色的模型,还可以通过分享自己的设计为社区做出贡献。此外,Pinshape 提供了一系列自定义选项,因此您可以调整和调整模型以满足您的特定需求。 使用说明: 要下载模型,请在网站上创建一个帐户,搜索所需的模型,然后单击下载按钮。该网站还为每种型号提供了一系列定制选项。 36.Yeggi Yeggi 提供了大量免费的 3D 模型,您可以下载各种格式的模型,例如 STL、OBJ 和 FBX。该网站易于使用,您可以按关键字、类别或特定网站搜索模型。 Yeggi 对于任何寻找 3D 模型的人来说都是一个很好的资源。它提供了大量的模型集合,从日常物品到复杂的机械,以及介于两者之间的一切。该网站的收藏量在不断增长,每天都有新的型号增加。 使用说明: 要下载模型,请在网站上搜索所需的模型,然后单击下载按钮。该网站还提供指向托管模型的原始网站的链接。 37. Open3DModel 来自开放3D模型的图像 Open3DModel具有各种类别的模型,包括建筑,车辆和角色。无论您需要建筑物,汽车还是人的3D模型,都可以在此网站上找到。 该网站易于浏览,您可以按类别或关键字搜索模型。每个模型都附带预览图像和详细信息,例如文件格式、大小和多边形数量。此信息可以帮助您选择适合您需求的模型。 使用说明: 要下载模型,请访问网站,从库中选择所需的模型,然后单击下载按钮。 使用最好的 3D 资产管理工具简化您的 3D 制作流程。立即试用它们,将您的 3D 项目提升到一个新的水平! 38. 3DExport 对于那些为其 3D 设计项目寻找 3D 模型、纹理和其他资源的人来说,该平台是一个很好的资源。该网站有大量模型可供选择,包括 3D 打印对象、游戏资产等。用户可以按类别、文件格式或价格范围浏览,以找到适合其项目的完美资源。此外,3DExport 还提供一系列教程和其他 3D 资源,以帮助用户提高技能并创建更令人印象深刻的设计。 使用说明: 要使用 3DExport,只需创建一个帐户并浏览可用型号。您可以按类别、格式和价格进行搜索,以找到所需的型号。找到喜欢的模型后,只需下载它并开始在您的项目中使用它。 39.Blend Swap Blend Swap是一个社区驱动的市场,提供与Blender软件兼容的各种免费3D模型。该平台允许用户共享和下载模型、纹理和其他资产,以便在他们的项目中使用。 使用说明: 创建免费帐户后,您可以浏览社区上传的大量3D模型。当您找到要使用的一个时,只需下载它并将其导入您选择的 3D 软件即可。 40. 3DShook 3DShook 是一个高级 3D 模型市场,提供一系列用于建筑、游戏等各个行业的高质量模型。该平台提供基于订阅的模型,具有不同的定价计划,允许用户访问一系列模型。 使用说明: 注册免费帐户后,只需浏览3D模型库,选择您喜欢的模型,然后以您需要的格式下载它们。 41. Smithsonian X 3D 史密森尼 X 3D 对于正在寻找历史文物和文物的高质量 3D 模型的设计师来说,这是一个独特的资源。该平台提供了大量3D模型,这些模型是根据史密森尼博物馆和研究中心中的真实物体扫描创建的。 使用说明: