Quantcast
Channel: openFrameworks - Latest posts
Viewing all articles
Browse latest Browse all 40524

threadChannelExample bugs? OF 0.9.0

$
0
0

ofTexture::loadData does some auto allocation is not 100% reliable in some edge cases but for simple things like this (uploading a greayscale image) it works fine. i'm testing this again and it's working fine for me although i haven't tested in windows or visual studio.

Do you at least see the image from the camera on the left?

Also, apart from the error about the texture do you see any other error at the beginning? from what you describe it would seem like the thread had stopped and then the frames being sent to it accumulate in the threadChannel.

The threadChannel has theoretical infinte capacity so if you don't consume at least as fast as you send the data, in this case the frames, accumulate in it and keep using memory. For next versions we might add a size limit so if you try to send more messages than allowed it'll discard them but by now you have to be careful that your consuming thread is at least as fast processing the received frames as they are being sent.

i've done some fixes in the example so it's easier to debug: https://github.com/openframeworks/openFrameworks/blob/a51f487ecfc70f15ad1e9584d69e4326a2fbce24/examples/utils/threadChannelExample/src/ImgAnalysisThread.cpp you can copy that file and replace it with the one that comes with the download


Viewing all articles
Browse latest Browse all 40524

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>