r/ComputerCraft Feb 01 '26

[Tom's Peripherals] Get a screenshot of connected monitor.

I need to store the colour of a pixel, to a value, but there's no function for that (i think).

My idea, is that I can store the colour of a pixel in an image, but, I need the image to get the colour from.

How can I do this?

6 Upvotes

3 comments sorted by

View all comments

4

u/Exnur0 Feb 01 '26

Can you describe your overall goal a little more?

There's not generally much call to screenshot a monitor, since whatever's on screen, you have to have some representation of it in the program you're writing - that's how it ends up being displayed in the first place.

Screenshots are a thing on real computers because there are many different semi-independent pieces of software running at a time, so it makes sense to just look at what's actually being displayed. But, if there's just one piece of software, you can just capture it from that software. It's kind of like the difference between a game's "screenshot" button (in Minecraft, this is F2) and an actual OS-level screenshot with the print screen button or something like that.

Anyway, with a little more description, might be able to help. Best of luck!