Openize.Drako
1.4.0
Openize.Drako nuget package has been discontinued. Please use FileFormat.Drako nuget package instead.
dotnet add package Openize.Drako --version 1.4.0
NuGet\Install-Package Openize.Drako -Version 1.4.0
<PackageReference Include="Openize.Drako" Version="1.4.0" />
paket add Openize.Drako --version 1.4.0
#r "nuget: Openize.Drako, 1.4.0"
// Install Openize.Drako as a Cake Addin #addin nuget:?package=Openize.Drako&version=1.4.0 // Install Openize.Drako as a Cake Tool #tool nuget:?package=Openize.Drako&version=1.4.0
Openize.Drako
Openize.Drako was ported from Google Draco.
1. Installation
dotnet add package Openize.Drako
2. Example
using Openize.Drako;
Vector3[] controlPoints = new Vector3[]
{
new Vector3( -5, 0, 5.0f),
new Vector3( 5, 0, 5.0f),
new Vector3( 5, 10, 5.0f),
new Vector3( -5, 10, 5.0f),
new Vector3( -5, 0, -5.0f),
new Vector3( 50, 0, -5.0f),
new Vector3( 5, 10, -5.0f),
new Vector3( -5, 10, -5.0f)
};
int[] indices = new int[]
{
0,1,2, 0, 2, 3, // Front face (Z+)
1,5,6, 1, 6, 2, // Right side (X+)
5,4,7, 5, 7, 6, // Back face (Z-)
4,0,3, 4, 3, 7, // Left side (X-)
0,4,5, 0, 5, 1, // Bottom face (Y-)
3,2,6, 3, 6, 7 // Top face (Y+)
};
var mesh = new DracoMesh();
//construct an attribute for position, with type float[3],
var attrPos = PointAttribute.Wrap(AttributeType.Position, controlPoints);
mesh.AddAttribute(attrPos);
//add triangle indices
mesh.Indices.AddRange(indices);
//number of the control points, it's required for the encoder to produce correct result.
mesh.NumPoints = 8;
//You can also use following methods to deduplicate the attributes to reduce the file size
//mesh.DeduplicateAttributeValues();
//mesh.DeduplicatePointIds();
var opt = new DracoEncodeOptions();
var drcBytes = Openize.Draco.Draco.Encode(mesh, opt);
License
Openize.Drako is available under Openize License.
[!CAUTION] Openize does not and cannot grant You a patent license for the utilization of Google Draco compression/decompression technologies.
OSS Notice
Sample files used for tests and located in the "./Openize.Drako.Tests/TestsData" folder belong to Google Draco and are used according to Apache License 2.0
Coming updates
Openize.Drako will receive new features and regular updates to stay in sync with the latest versions of Google Draco. We appreciate your patience as we work on these improvements. Stay tuned for more updates soon.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net5.0 was computed. net5.0-windows was computed. net6.0 is compatible. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 is compatible. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
.NET Core | netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
.NET Standard | netstandard2.1 is compatible. |
.NET Framework | net46 is compatible. net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
MonoAndroid | monoandroid was computed. |
MonoMac | monomac was computed. |
MonoTouch | monotouch was computed. |
Tizen | tizen60 was computed. |
Xamarin.iOS | xamarinios was computed. |
Xamarin.Mac | xamarinmac was computed. |
Xamarin.TVOS | xamarintvos was computed. |
Xamarin.WatchOS | xamarinwatchos was computed. |
-
.NETFramework 4.6
- System.Memory (>= 4.5.5)
- System.Numerics.Vectors (>= 4.5.0)
-
.NETStandard 2.1
- No dependencies.
-
net6.0
- No dependencies.
-
net7.0
- No dependencies.
-
net8.0
- No dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last updated | |
---|---|---|---|
1.4.0 | 129 | 6/18/2024 |