Skip to content

Commit

Permalink
Update for 0.6.17 release
Browse files Browse the repository at this point in the history
  • Loading branch information
nicklockwood committed Aug 22, 2023
1 parent 84837b2 commit 00a3946
Show file tree
Hide file tree
Showing 7 changed files with 14 additions and 8 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Change Log

## [0.6.17](https://github.com/nicklockwood/Euclid/releases/tag/0.6.17) (2023-08-22)

- Added `Mesh.stlData()` function for exporting binary STL file data
- Added `Mesh.objString()` function for exporting Wavefront OBJ mesh data

## [0.6.16](https://github.com/nicklockwood/Euclid/releases/tag/0.6.16) (2023-08-11)

- Fixed `Mesh.stlString()` function
Expand Down
2 changes: 2 additions & 0 deletions Euclid.docc/Extensions/Mesh.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,9 @@

### Exporting Meshes

- ``Mesh/objString()``
- ``Mesh/stlString(name:)``
- ``Mesh/stlData(colorLookup:)``

### Mesh Properties

Expand Down
1 change: 0 additions & 1 deletion Euclid.docc/RenderingMeshes.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ You can convert materials using the optional closure argument for Euclid's `SCNG
When serializing Euclid geometry using `Codable`, only specific material types can be supported.
Currently, material serialization works for `String`s, `Int`s, `Color` and any class that conforms to `NSCoding` (which includes many UIKit, AppKit and SceneKit types, such as `UI/NSColor`, `UI/NSImage` and `SCNMaterial`).


### Colors

Euclid currently has no support for setting colors on a per-vertex basis, but you can apply colors to a ``Mesh`` or ``Polygon`` using the material property.
Expand Down
4 changes: 2 additions & 2 deletions Euclid.podspec.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "Euclid",
"version": "0.6.16",
"version": "0.6.17",
"license": {
"type": "MIT",
"file": "LICENSE.md"
Expand All @@ -10,7 +10,7 @@
"authors": "Nick Lockwood",
"source": {
"git": "https://github.com/nicklockwood/Euclid.git",
"tag": "0.6.16"
"tag": "0.6.17"
},
"source_files": "Sources",
"requires_arc": true,
Expand Down
4 changes: 2 additions & 2 deletions Euclid.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -768,7 +768,7 @@
"@executable_path/../Frameworks",
"@loader_path/Frameworks",
);
MARKETING_VERSION = 0.6.16;
MARKETING_VERSION = 0.6.17;
OTHER_SWIFT_FLAGS = "-Xfrontend -warn-long-expression-type-checking=75";
PRODUCT_BUNDLE_IDENTIFIER = com.charcoaldesign.Euclid;
PRODUCT_MODULE_NAME = "$(PRODUCT_NAME:c99extidentifier)";
Expand Down Expand Up @@ -801,7 +801,7 @@
"@executable_path/../Frameworks",
"@loader_path/Frameworks",
);
MARKETING_VERSION = 0.6.16;
MARKETING_VERSION = 0.6.17;
OTHER_SWIFT_FLAGS = "-Xfrontend -warn-long-expression-type-checking=75";
PRODUCT_BUNDLE_IDENTIFIER = com.charcoaldesign.Euclid;
PRODUCT_MODULE_NAME = "$(PRODUCT_NAME:c99extidentifier)";
Expand Down
4 changes: 2 additions & 2 deletions Sources/Angle.swift
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ public struct Angle: Hashable, Comparable, Sendable, AdditiveArithmetic {
/// Creates an angle from a radians value.
/// - Parameter radians: The angle in radians.
public init(radians: Double) {
self.radians = radians
self.radians = radians.isFinite ? radians : 0
}
}

Expand Down Expand Up @@ -131,7 +131,7 @@ public extension Angle {
/// Creates an angle from a radians value.
/// - Parameter radians: The angle in radians.
static func radians(_ radians: Double) -> Angle {
Angle(radians: radians.isFinite ? radians : 0)
Angle(radians: radians)
}

/// Creates an angle representing the trigonometric arc cosine of the value you provide.
Expand Down
2 changes: 1 addition & 1 deletion Sources/Euclid+SceneKit.swift
Original file line number Diff line number Diff line change
Expand Up @@ -706,7 +706,7 @@ public extension Mesh {
self.init(scnGeometry) { _ in material }
}

@available(*, deprecated, message: "Use `init(_:material:)` instead")
@available(*, deprecated, message: "Use `init(_:materialLookup:)` instead")
init?(scnGeometry: SCNGeometry, materialLookup: MaterialProvider? = nil) {
self.init(scnGeometry, materialLookup: materialLookup)
}
Expand Down

0 comments on commit 00a3946

Please sign in to comment.