1 file changed +17
-5
lines changed Original file line number Diff line number Diff line change @@ -10,19 +10,31 @@ SwiftOSC is a Swift Open Sound Control (OSC) 1.1 client and server framework.
10
10
11
11
## Installation
12
12
13
- ```
13
+ ### [ CocoaPods] ( http://cocoapods.org )
14
+
15
+ ```` ruby
14
16
pod ' SwiftOSC' , ' ~> 2.0'
17
+ ````
18
+
19
+ ### [ Swift Package Manager] ( https://swift.org/package-manager/ )
20
+
21
+ ``` swift
22
+ dependencies: [
23
+ .package (url : " https://github.com/soundflix/SwiftOSC.git" , from : " 2.0" )
24
+ ]
15
25
```
16
26
17
- OR
27
+ Alternatively, you can add the package [ directly via Xcode] ( https://developer.apple.com/documentation/xcode/adding_package_dependencies_to_your_app ) .
28
+
29
+ OR install locally:
18
30
19
31
### Step 1
20
32
21
33
Clone or download repository from Github.
22
34
23
35
### Step 2
24
36
25
- Open SwiftOSC.xcworkspace and build SwiftOSC frameworks.
37
+ Open SwiftOSC.xcworkspace and build SwiftOSC frameworks.
26
38
27
39
### Step 3
28
40
@@ -47,7 +59,7 @@ var server = OSCServer(port: 8080)
47
59
Setup server delegate to handle incoming OSC Data
48
60
``` swift
49
61
class OSCHandler : OSCServerDelegate {
50
-
62
+
51
63
func didReceive (_ message : OSCMessage){
52
64
if let integer = message.arguments[0 ] as? Int {
53
65
print (" Received int \( integer ) " )
@@ -93,7 +105,7 @@ client.send(message)
93
105
```
94
106
## Known Issues
95
107
- OSCClient loses connection following returning from being in the background. Call client.restart() in this situation.\
96
-
108
+
97
109
98
110
## About
99
111
0 commit comments