Skip to content

Commit

Permalink
2.0.7.9 (Version 11)
Browse files Browse the repository at this point in the history
 Update JSoutLib to Spout Version 2.007.013
  • Loading branch information
leadedge committed Dec 23, 2023
1 parent 94e7994 commit b04ffc9
Show file tree
Hide file tree
Showing 9 changed files with 67 additions and 55 deletions.
23 changes: 10 additions & 13 deletions examples/SpoutDataReceiver/SpoutDataReceiver.pde
Original file line number Diff line number Diff line change
Expand Up @@ -190,22 +190,19 @@ void draw() {
void showInfo() {

fill(255);

if(spout.isReceiverConnected()) {
// Report sender fps and frame number if the option is activated
// Applications < Spout 2.007 will have no frame information
if(spout.getSenderFrame() > 0) {
text("Receiving from : " + spout.getSenderName() + " ("
+ spout.getSenderWidth() + "x"
+ spout.getSenderHeight() + ") - fps "
+ spout.getSenderFps() + " : frame "
+ spout.getSenderFrame(), 15, 30);
}
else {
text("Receiving from : " + spout.getSenderName() + " ("
+ spout.getSenderWidth() + "x"
+ spout.getSenderHeight() + ")", 15, 30);
}
+ spout.getSenderHeight() + " - "
+ spout.getSenderFormatName() + ")", 15, 30);

// Report sender fps and frame number if the option is activated
// Applications < Spout 2.007 will have no frame information
if(spout.getSenderFrame() > 0) {
text("fps : " + spout.getSenderFps() + " : frame "
+ spout.getSenderFrame(), 15, 50);
}
}
else {
text("No sender", 30, 30);
Expand Down
12 changes: 7 additions & 5 deletions examples/SpoutDataSender/SpoutDataSender.pde
Original file line number Diff line number Diff line change
Expand Up @@ -102,8 +102,8 @@ void draw() {
// Draw the rotating cube
pushMatrix();
translate(width/2.0, height/2.0, -100);
rotateX(frameCount/60.0);
rotateY(frameCount/60.0);
rotateX(frameCount/100.0);
rotateY(frameCount/100.0);
scale(110);
TexturedCube(img);
popMatrix();
Expand Down Expand Up @@ -179,9 +179,11 @@ void draw() {
text("Sending as : "
+ spout.getSenderName() + " ("
+ spout.getSenderWidth() + "x"
+ spout.getSenderHeight() + ") - fps : "
+ spout.getSenderFps() + " : frame "
+ spout.getSenderFrame(), 15, 30);
+ spout.getSenderHeight() + ")", 15, 30);
if(spout.getSenderFrame() > 0) {
text("fps : " + spout.getSenderFps() + " : frame "
+ spout.getSenderFrame(), 15, 50);
}

}

Expand Down
36 changes: 18 additions & 18 deletions examples/SpoutReceiver/SpoutReceiver.pde
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ void setup() {
size(640, 360, P3D);

// Screen text size
textSize(16);
textSize(18);

// Needed for resizing the window to the sender size
// Processing 3+ only
Expand All @@ -39,24 +39,26 @@ void setup() {
// but you can specify the name of the sender to receive from.
// The receiver will then attempt to connect to that sender
// spout.setReceiverName("Spout Demo Sender");

}


void draw() {

//
// RECEIVE FROM A SENDER
//

// OPTION 1: Receive and draw the texture
if(spout.receiveTexture())
spout.drawTexture();

// OPTION 2: Receive into PGraphics
// pgr = spout.receiveTexture(pgr);
// if(pgr != null)
// if(pgr != null) {
// image(pgr, 0, 0, width, height);
// showInfo();
// }

// OPTION 3: Receive into PImage texture
// img = spout.receiveTexture(img);
Expand All @@ -81,22 +83,20 @@ void draw() {
void showInfo() {

fill(255);

if(spout.isReceiverConnected()) {
// Report sender fps and frame number if the option is activated
// Applications < Spout 2.007 will have no frame information
if(spout.getSenderFrame() > 0) {
text("Receiving from : " + spout.getSenderName() + " ("
+ spout.getSenderWidth() + "x"
+ spout.getSenderHeight() + ") - fps "
+ spout.getSenderFps() + " : frame "
+ spout.getSenderFrame(), 15, 30);
}
else {

text("Receiving from : " + spout.getSenderName() + " ("
+ spout.getSenderWidth() + "x"
+ spout.getSenderHeight() + ")", 15, 30);
}
+ spout.getSenderHeight() + " - "
+ spout.getSenderFormatName() + ")", 15, 30);

// Report sender fps and frame number if the option is activated
// Applications < Spout 2.007 will have no frame information
if(spout.getSenderFrame() > 0) {
text("fps " + spout.getSenderFps() + " : frame "
+ spout.getSenderFrame(), 15, 50);
}
}
else {
text("No sender", 30, 30);
Expand Down
25 changes: 16 additions & 9 deletions examples/SpoutSender/SpoutSender.pde
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,9 @@ void setup() {
// Initial window size
size(640, 360, P3D);
textureMode(NORMAL);

// Screen text size
textSize(16);
textSize(18);

// Create a graphics object
pgr = createGraphics(1280, 720, P3D);
Expand Down Expand Up @@ -81,7 +81,7 @@ void setup() {
// spout.setLogLevel(1);
// spout.spoutLogVerbose("Message");
//

// GIVE THE SENDER A NAME
// A sender can be given any name.
// Otherwise the sketch folder name is used
Expand All @@ -90,8 +90,13 @@ void setup() {

// Option - set the sketch frame rate.
// Receivers 2.007 or higher will detect this rate
frameRate(30);
// frameRate(30);

//
// Option - infoBox, messageBox, optionBox, inputBox
// Can be used within the sketch as required
// Refer to Spout for Processing, Spout class library reference

}

void draw() {
Expand All @@ -103,8 +108,8 @@ void draw() {
// Draw the rotating cube
pushMatrix();
translate(width/2.0, height/2.0, -100);
rotateX(frameCount/60.0);
rotateY(frameCount/60.0);
rotateX(frameCount/100.0);
rotateY(frameCount/100.0);
scale(110);
TexturedCube(img);
popMatrix();
Expand Down Expand Up @@ -142,9 +147,11 @@ void draw() {
text("Sending as : "
+ spout.getSenderName() + " ("
+ spout.getSenderWidth() + "x"
+ spout.getSenderHeight() + ") - fps : "
+ spout.getSenderFps() + " : frame "
+ spout.getSenderFrame(), 15, 30);
+ spout.getSenderHeight() + ")", 15, 30);
if(spout.getSenderFrame() > 0) {
text("fps " + spout.getSenderFps() + " : frame "
+ spout.getSenderFrame(), 15, 50);
}

}

Expand Down
Binary file modified lib/JNISpout_32.dll
Binary file not shown.
Binary file modified lib/JNISpout_64.dll
Binary file not shown.
4 changes: 2 additions & 2 deletions resources/build.properties
Original file line number Diff line number Diff line change
Expand Up @@ -143,12 +143,12 @@ source.repository=https://github.com/leadedge/spoutprocessing
# This is used to compare different versions of the same Library, and check if
# an update is available.

library.version = 9
library.version = 11


# The version as the user will see it.

library.prettyVersion = 2.0.7.7
library.prettyVersion = 2.0.7.9


# The min and max revision of Processing compatible with your Library.
Expand Down
4 changes: 2 additions & 2 deletions resources/library.properties
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,11 @@ paragraph = Find out more about Spout [here](https://spout.zeal.co).
# compare different versions of the same Library, and check if an update is
# available. You should think of it as a counter, counting the total number of
# releases you've had.
version = 9
version = 11

# The version as the user will see it. If blank, the version attribute will be
# used here. This should be a single word, with no spaces.
prettyVersion = 2.0.7.7
prettyVersion = 2.0.7.9

# The min and max revision of Processing compatible with your Library.
# Note that these fields use the revision and not the version of Processing,
Expand Down
18 changes: 12 additions & 6 deletions src/spout/Spout.java
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,9 @@
// Update sender examples to show sender data type
// 28.11.23 Remove #define USE_COMPUTE_EXTENSIONS from SpoutGLextensions
// For JNISpout library build (JSpoutLib)
// Rebuild Release 2.0.7.8 (Version 10)
// Rebuild Release 2.0.7.8 (Version 10) (maintencance release)
// 24.12.23 Update JSoutLib to Spout Version 2.007.013
// Rebuild Release 2.0.7.9 (Version 11)
//
// ========================================================================================================

Expand Down Expand Up @@ -788,31 +790,31 @@ public void selectSender()
JNISpout.senderDialog(spoutPtr);
}

/*
/**
* Enable logging to default console output
*/
public void enableSpoutLog()
{
JNISpout.enableSpoutLog(spoutPtr);
}

/*
/**
* Log to a file
*/
public void enableSpoutLogFile(String filename)
{
JNISpout.spoutLogToFile(filename, false, spoutPtr);
}

/*
/**
* Append logs to a file
*/
public void enableSpoutLogFile(String filename, boolean append)
{
JNISpout.spoutLogToFile(filename, append, spoutPtr);
}

/*
/**
* Set the Spout log level
* @param level
* 0 - Disable : 1 - Verbose : 2 - Notice (default)
Expand All @@ -824,7 +826,11 @@ public void setLogLevel(int level)
}



/**
* Copy text to the clipboard
* @param text - text to copy
*
*/
public boolean copyToClipBoard(String text)
{
return JNISpout.copyToClipBoard(text, spoutPtr);
Expand Down

0 comments on commit b04ffc9

Please sign in to comment.