Skip to content

Commit 238ddfe

Browse files
committed
Merge branch 'dev-update-v2'
2 parents 4906878 + 41246ae commit 238ddfe

31 files changed

+3177
-3482
lines changed

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -46,3 +46,4 @@ application.macosx
4646

4747
examples/Augmenta_2D/settings.json
4848
*.json
49+
/bin/

README.md

+21-25
Original file line numberDiff line numberDiff line change
@@ -1,67 +1,62 @@
1-
Augmenta for Processing
2-
=======================
1+
# Augmenta for Processing
32

4-
A [Processing][] Augmenta helper library and examples maintained by [Théoriz studio][]
3+
A [Processing][] helper library and examples maintained by [Théoriz studio][] that allows to use the [Augmenta][] tracking system.
54

6-
Install
7-
-------
5+
## Install
86

97
Open [Processing][] and install the OscP5 library
108

119
```
1210
Sketch -> Import Library... -> Add Library -> OscP5
1311
```
1412

15-
Then get AugmentaP5 library from here
13+
### Auto installation
1614

17-
https://github.com/Lyptik/AugmentaP5/archive/master.zip (and rename to AugmentaP5)
15+
**Coming soon:** You can get the *Augmenta for Processing* library within the Processing editor, in Sketch>import a library...>add a library... search for "Augmenta for Processing" and add it to your Processing editor. This is the prefered way of installing it.
16+
17+
### Manual installation
18+
19+
You can also download it manually:
20+
21+
get the library on github at this address: https://github.com/Theoriz/augmenta-for-processing/archive/refs/heads/master.zip and **rename it "Augmenta"**.
1822

1923
or
2024

2125
```
22-
git clone https://github.com/Theoriz/AugmentaP5.git
26+
git clone https://github.com/Theoriz/augmenta-for-processing.git
2327
```
2428

25-
in the following directory
29+
Once you have downloaded the library and **renamed it "Augmenta"**, put it in the following directory
2630

2731
- Mac OSX : /Users/Username/Documents/Processing/libraries
2832
- Windows : C:/My Documents/Processing/libraries
2933
- Linux : /home/Username/sketchbook/libraries
3034

31-
You should now have a folder named *AugmentaP5* in this directory.
32-
33-
Do the same for the TUIO library downloadable here :
34-
35-
http://prdownloads.sourceforge.net/reactivision/TUIO11_Processing-1.1.5.zip?download
35+
You should now have a folder named **Augmenta** in this directory.
3636

3737
Then restart [Processing][]
3838

39-
Use
40-
---
39+
## Usage
40+
4141
In [Processing][]
4242

4343
```
4444
Sketch -> Import Library... -> OscP5 (needed dependency)
45-
Sketch -> Import Library... -> AugmentaP5
45+
Sketch -> Import Library... -> Augmenta for Processing
4646
```
4747

48-
Examples
49-
--------
48+
## Examples
5049

5150
In [Processing][], start your example
5251

5352
```
54-
File -> Examples... -> Contributed Libraries -> AugmentaP5
53+
File -> Examples... -> Contributed Libraries -> Augmenta for Processing
5554
```
5655

5756
### Basic example
5857

5958
Receive and draw Augmenta data without any other library
6059

61-
// TODO add screenshot (insert basic view)
62-
63-
**Install TUIO library** : [TUIO11_Processing.zip](http://prdownloads.sourceforge.net/reactivision/TUIO11_Processing-1.1.5.zip?download)
64-
6560
### 2D and 3D examples
6661

6762
Examples for receiving and drawing Augmenta data including a Syphon/Spout output (Mac/Windows only) and a basic UI
@@ -100,7 +95,7 @@ Documentation
10095

10196
Data protocol is here : https://github.com/Theoriz/Augmenta/wiki
10297

103-
Here is a presentation explaining how to use the API
98+
Here is a presentation explaining how to use the API with an older version of the library. Some methods/members names have changed but the main concepts remain the same.
10499

105100
http://fr.slideshare.net/DavidAlexandreCHANEL/augmentap5-api-59334230
106101

@@ -123,3 +118,4 @@ Thanks to the devs and beta testers whose contribution are vitals to the project
123118
[Théoriz studio]: http://www.theoriz.com/
124119
[OpenTSPS]: https://github.com/labatrockwell/openTSPS/
125120
[Eclipse]: http://www.eclipse.org/
121+
[Augmenta]: https://augmenta-tech.com

examples/Augmenta_2D/Augmenta_2D.pde

+9-9
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,7 @@
1111
*
1212
*/
1313

14-
import augmentaP5.*;
15-
import TUIO.*;
14+
import augmenta.*;
1615
import oscP5.*;
1716

1817
boolean mode3D = false;
@@ -24,7 +23,8 @@ void setup() {
2423
setupSyphonSpout();
2524
setupAugmenta();
2625
setupGUI();
27-
26+
// enable the resizable window
27+
surface.setResizable(true);
2828
// Add your code here
2929
}
3030

@@ -39,15 +39,15 @@ void draw() {
3939
canvas.background(0);
4040

4141
// Draw a green disk under the first person entdered in the scene
42-
AugmentaPerson oldest = auReceiver.getOldestPerson();
42+
AugmentaObject oldest = auReceiver.getOldestObject();
4343
if (oldest != null){
4444
canvas.fill(0,255,0); // green disk
4545
canvas.noStroke(); // Without stroke
4646
canvas.ellipse(oldest.centroid.x*canvas.width, oldest.centroid.y*canvas.height, 25, 25); // 25 pixels diameter
4747
}
4848

4949
// Draw a blue disk for every persons
50-
AugmentaPerson[] people = auReceiver.getPeopleArray();
50+
AugmentaObject[] people = auReceiver.getObjectsArray();
5151

5252
for (int i=0; i<people.length; i++) {
5353

@@ -80,14 +80,14 @@ void draw() {
8080

8181
// You can also use these events functions which are triggered automatically
8282

83-
void personEntered (AugmentaPerson p) {
83+
void objectEntered (AugmentaObject o) {
8484
//println("Person entered : "+ p.pid + " at ("+p.centroid.x+","+p.centroid.y+")");
8585
}
8686

87-
void personUpdated (AugmentaPerson p) {
87+
void objectUpdated (AugmentaObject o) {
8888
//println("Person updated : "+ p.pid + " at ("+p.centroid.x+","+p.centroid.y+")");
8989
}
9090

91-
void personWillLeave (AugmentaPerson p) {
91+
void objectWillLeave (AugmentaObject o) {
9292
//println("Person will leave : "+ p.pid + " at ("+p.centroid.x+","+p.centroid.y+")");
93-
}
93+
}

0 commit comments

Comments
 (0)