August 26, 2014 at 7:03 pm #819
I want to make Openframeworks
but,I was made to see the file, but could not be made.
Could you tell me how to make a openframeworks someone?August 27, 2014 at 12:21 am #820
are you using the the current Spout Version 1 dll?
Are you able to create a project and compile the sender example?
The easiest way to do this is make a copy of the Openframeworks example project and replace the source files with the Spout example.
Let me know what the problem is and I will try to help.August 27, 2014 at 1:07 am #821
Thank you for your quick reply.
My under system environment is
・Microsoft Visual Studio Express 2012 for Windows Desktop
The following procedures were followed.
① I made 「ofxSpout」folder
src and bin file was put in the ofxSpout.
②I made new projectfile of openframeworks
then check a ofxSpout
③file of「main.cpp , ofApp.cpp , ofApp.h」 was rewritten to 「main.cpp,testApp.cpp,testApp.h」of ofSpoutSender.
but I can’t build
What will be the cause?August 27, 2014 at 7:47 am #822
The Spout Openframeworks example is not an addon, so you don’t copy the files into the addon folder.
Also I am sorry that I forgot to check your Openframeworks version and remind you that the examples were made with an older version of Openframeworks, Version 071, so the source file names are different. With Version 083, the project generator produces ofApp.cpp and ofApp.h, so if you replace them with the old style testApp.cpp and testApp.h, the project will not find the original files and it will not compile.
I can’t update to Openframeworks 083 just yet due to other problems with VS2012 and VS2013, and Version 083 is not compatible with VS2010, so I can’t provide a working copy for you.
What I would suggest is to create an empty project with projectgenerator and make sure that it compiles. I suggest using release instead of debug. Then you can copy and paste parts of the Spout example into the files ofApp.cpp and ofApp.h.
Start by copying Spout.h into your project src folder. Then paste the code from the header file testApp.h into ofApp.h and check whether it compiles OK. It might complain about exit being missing. If so, comment that out in the header for now.
After you get that working, you will need “SpoutLogoMarble3.bmp” in the data folder and “Spout32.dll” in the bin folder.
Then copy parts from the Spout example testApp.cpp into ofApp.cpp. Start by adding the function “InitTexture” and make sure you change testApp to ofApp and check if it compiles OK.
Then copy all of the Setup function. If it compiles, you are half way there. Continue with exit and windowresized and finally draw.
Along the way you will probably find changes from 071 to 083. As I say, I can’t test this for you so I hope you can get it working.
With the new Spout2 SDK in development I will be looking at updating the Openframeworks example.
Let me know how you get on.August 28, 2014 at 2:40 am #823
Thank you for the connection.
I try instantly.
I will report, if a result comes out.September 25, 2014 at 12:19 pm #901
I just created a small addon to simplify the integration with an OpenFrameworks project :
https://github.com/Mat-Loz/ofxSpoutSeptember 25, 2014 at 12:36 pm #902
That’s brilliant. Hold that thought and we will work on this shortly with Spout 2.September 27, 2014 at 12:09 pm #903
Thanks. By the way, I just noticed that image in receiver is upside downSeptember 27, 2014 at 1:10 pm #904
OK. Try :
SendTexture(_spoutTexture, GL_TEXTURE_2D, _width, _height, true); // invert = true
Let us know if this fixes it.
Corrected in Version 2.September 29, 2014 at 6:54 am #909
That fixed it, thanks !May 12, 2017 at 1:12 am #3474
Hello there ! Sorry for reviving this post, im tryng to compile the OF example .
I´ve already have all the spout files in my proyect thought im having this weird error :
Cant include ‘resource.h’:May 12, 2017 at 1:40 pm #3475
resource.h and resource.rc are included with the example source, but they are only there to load a custom icon and really the example should be more basic. Anyway, check that you have these files in the “src” folder.
Otherwise just remove :
From ofApp.h :
#include "resource.h" // for custom icon
From ofApp.cpp :
SetClassLong(GetActiveWindow(), GCL_HICON, (LONG)LoadIconA(GetModuleHandle(NULL), MAKEINTRESOURCEA(IDI_ICON1)));
You must be logged in to reply to this topic.