Hi all.
I want to share textures via Spout from a Processing sketch to Touchdesigner, both running on the same computer, but am running into problems trying to access the stream.
If I use the example Spout sender sketch as provided by the Spout for Processing’s Github, the sketch runs without issue in Processing and although the Spout stream is available to select in via TouchDesigner’s Spout In operator, an error message appears when I try to use it:
“Unable to open shared Spout texture. Spout may not be Vulkan compatible on this GPU”.
I can get Spout sharing working internally for either - ie.Touch Spout out->Touch Spout In works fine as well as using a Processing sender sketch to a receiver sketch. So I know there is no inherent hardware issues with my laptop and Spout. I have also had success in the past sharing via Spout from Max MSP to Touchdesigner.
I am using TD build 64-bit 2022.33910 and have tried with both Processing v4 and an earlier build 3.5.4.
Any help to troubleshoot this apparent incompatibility between to two programs’ implementations of Spout would be greatly appreciated.
Also keen to hear if anyone has done texture sharing between Processing and Touchdesigner successfully before, whether by Spout or other means. I have found some indication in forum posts here that NDI could be an option, but unfortunately there is scant information on how to implement such a thing on the Processing side. I also understand that NDI is unlikely to be the best way to achieve what I am after, which is just to share between the two applications on the same computer.
Hello,
That’s funny because I adopted TD to avoid complicated system using Isadora, Processing and Unity…
But I just reinstalled Processing (4.3) and the spout library (2.0.7.0) and all is working perfectly with the test Processing file and the same TD version.
Are you sure your graphic card driver is up to date ?
Thanks so much for taking a look into this. I’ve now managed to try on a different computer (desktop with an Nvidia GTX1080ti) and was able to get it working with the latest version of processing. Seems like the issue may be to do with my laptop which is running an RTX3050. Ill see if I can get to the bottom of why that specific setup doesn’t seem to be working well with spout. The GPU driver was all up to date.
Can you confirm that both processes are running on your dedicated GPU? (Or at least one the same GPU?)
As SPOUT needs both processes to run on the same GPU (as this is a memoryshare-process) this might be the issue. (Maybe…)
Thanks alphamoonbase. I was thinking along the same lines and have been troubleshooting in this direction. I did notice that in task manager on the PC where it was working, when running the processing Spout sketch a second instance of the application appeared in the list showing usage of the GPU (“GPU 0 - 3D”).
This didn’t appear to be happening on my laptop so after a bit of further reading, I deduced it may be a power saving feature of the device, defaulting to the integrated graphics.
Processing’s preferences don’t seem to include anything else to tell it to use your GPU. I did manually add Processing’s .exe to use the discrete GPU via display settings>graphics settings>graphics performance preferences, where it was indeed set by default to “let Windows decide” whether to use the Integrated Graphics or dedicated GPU.
This however hasn’t made the issue go away, including after a restart to let everything take effect. Not quite sure what else to try now.
Task manager (OpenJDK Platform binary appears to be Processing):
Okay, i managed to fix this now. In case it is helpful for anyone else experiencing this on their laptop, the thing which solved it was to also add the below via the same steps I outlined in the post above so it is forced to use the GPU:
Thanks for all the useful pointers.
1 Like