ofxNetwork error and tips for sending an image between two laptops?

Hi, I am trying to send FBO pixels from my app to another OF app in my second laptop. As the first approach I am testing this sender app from Mastering openFrameworks: Creative Coding Demystified book:

However when compiling, I get an error from the setup of pbNetWork.cpp:

void pbNetworkReceiver::setup( int port, int packetSize, bool threaded )
    _threaded = threaded;
    _wantRestart = false;

    _port = port;
    _packetSize = packetSize;

    _frame = -1;
    _size = 0;

    maxN = 1000000;        //TODO Parameter
    _buffer.resize( maxN );
    _N = 0;

    _data.resize( maxN );


    if ( _threaded ) {
        startThread( true, false );   //ERROR HERE: "No matching member function for call to 'startThread'"

I was suspecting this has something to do with the fact that example apps are 5 years old and I am using brand new ofxNetwork addon. If anyone has ideas for fixing this they are more than welcome!

However, I would be happy to know about other solutions for this. I am familiar with OSC messaging but sending images is too heavy for that. My idea is quite simple itself: I want to display the FBO contents of my app A in app B (just showing an image that gets updated). Thanks for any tips!

hello hello,
startThread expect one parameter. https://github.com/openframeworks/openFrameworks/blob/b674f7ec1f41d8f0fcfea86e3d3d3df3e9bdcf36/libs/openFrameworks/utils/ofThread.cpp#L53
There are also a couple of thread examples included with oF. They should be up to date.

depending on the size of your image, osc blob type could be a solution. i used ndi quite a alot to send video/images over the network. there are several ofxNdi addons available, not sure which ones work the best.
hope that helps.

Hi @thomasgeissl, thanks for your quick answer! startThread makes sense now and compiles with one parameter :slight_smile: I am also looking into this ofxNDI as an alternative solution:

Many thanks!

What’s the difference between this two ofxNDI repos?

Both seems recently mantained and multiplatform…
https://github.com/leadedge/ofxNDI -> updated to sdk NDI 4.5
https://github.com/nariakiiwatani/ofxNDI -> seems version 4.0

I am in Windows and I want to send the live video screen from OF to/as a virtual camera in the same computer.
And it’s the same for macOS?