Can you run a Processing sketch and hide the Canvas Window?

Hi everyone. I’ve seen a few posts on this topic, but none that seem to answer what I am looking for.

I am trying to use Processing in a live, VJ type situation, with the a Processing sketch reacting to OSC messages, and seamlessly switch from one Processing sketch to another.

After a lot of homework and searching around, I found I can send the visual output of my sketch to VDMX using Syphon. And I can fade in another image in VDMX while I switch sketches in Processing.

Here is my question: Because I can see the Processing visual in VDMX I do not need to see the Processing Canvas (is that what it’s called?)

Is there a way to run a Processing sketch, preferably in fullScreen(), and not see the window running the sketch? I just want to use the output from Syphon. Hopefully this question makes sense. I am just trying to not have so many window open, and VDMX will already have a full screen window going as well.

Thank You, all ideas and suggestions are welcome.

2 Likes

Sorry, I’m not familiar with Syphon or VDMX in any way, but theres this one “live coding” solution out there that I find cool:

1 Like

Try this code and see if it makes sense: Fake Invisible Screen

If you do not need Processing, you could just write a simple java application although you might need to use other non-Processing code.

I am thinking you could set the size of the window to the minimum which is 100x100 and then use the robot class to move your window off the visible screen, like moving it to one corner of your window. I do not have a demo but you should find some leads if you search for setLocation().

Try this:

I am just thinking loud…

Kf

2 Likes

Hi kfrajer,

Wow some interesting info in those links you posted. I like the negative values for the screen.

The problem with the hidden windows, like this:

void setup() {
  surface.setVisible(false);
}

is that the canvas window pops up for a few milliseconds, and it makes VDMX full screen window disappear.

I think one thing I can do is make my sketches on a really small canvas, and then have the output of that go to VDMX through syphon. It’s not ideal, as I have to rework all my Processing sketches. I wonder if a smaller screen will mean a lower resolution as well. But then I can Let VDMX have the second screen for itself in full screen mode and a small Processing canvas on my main screen.

It’s not great but might work. Thank you for the links.

@Tony: thanks for that link. I am still a beginner and haven’t tried p5.js yet. It’s on my list of things to learn however.

Kfrafer, what it is doing is making an image of an area of the desktop the screen will overlay, placing the image as background then drawing on top of the image. If you move your mouse up to the upper left corner an area of the screen will appear and you can move the window exposing its trick.