Introduction
Hello everyone, I was up all night, working on something you guys might like. This is a thing on Roblox I made that will allow you to see your own computers screen in live time in Roblox.
Sending Pixels
To make this work, I have to loop through every pixel on my screen using python and get the color. But the data that has to be sent to Roblox, is way too big to be useful in any way. So I divide the screens X and Y resolution by 20, take a screenshot, read the color of every pixel in the downscaled image, apply it to an array, and send it to Roblox.
Reading Pixels
To read pixels, I have a function that will receive all the colors of every pixel using HttpService. Once I get the table of colors, I run a function that will spawn tons of frames on a surfacegui (each frame will represent a pixel). Next, I loop through every pixel, just like I do in the python code. But instead of getting the color, I set it to the color in the table that represents that pixel.
Final thoughts
I think that this is a pretty cool project, and it was fun making it. I definitely think stuff like this has potential in Roblox, and I might release this as an asset if it’s not against TOS. I will release code if you guys want it .
(Here’s a little showcase)
Video
(also credit to this post for giving inspiration and helping me with this)
How to use in your own project
(THIS ONLY WORKS IN STUDIO UNLESS PORTFORWARDED)
Use of this is not recommended in a game you plan on actually making. Unless you optimize this, it’s kinda laggy when receiving pixels. To download this into your own project go to the model and put it into your game. Next, you’re gonna want to download the actual thing that runs on your computer, this python file. Now, go into your game settings, and enable HTTPS requests. Lastly, open the python file, and run your game. You should see your computer screen running on the screen in game. If you run into any problems, message me, or solve it. Thanks