Interesting and weird camera

Hi devs. A few hours ago i remembered that one guy from some another game made working camera, which can print an image according on thing in front of it. And the i asked myself - why don’t recreate it in studio?

And after hour of work i made it:
image
Yes, it absolutely not looks like a camera, but it works

How it works:

Basically we moving that cube in top right corner along all of big part, and on every move step raycasting from this cube.
If raycast find something, we take position of cube at the moment and painting “pixel” on surface gui according to Raycast.Instance.Color

How to set it up:

Type in console require(workspace.UltraHDCamera.ModuleScript):Generate() to add “pixels” to surface gui.
Or require(workspace.UltraHDCamera.ModuleScript):Destroy() to destroy all pixels

Pixel size sets by changing CellSize property in UIGridLayout inside Surface gui

When you’re done, put something in front of camera and run the game.
After launch will be incredible lags, don’t worry studio won’t crash (most likely), because code giving itself time to rest.

Notes:

I didn’t used CFrame or any transformations, so camera will work strange if you rotate it.
If you added or destroyed frames and didn’t do any other actions, don’t press CTRL + Z
If studio crashing, add task.wait() in main script

Model

Camera.rbxm (8.5 KB)

Some renders

Egg and me

c06220ba-485c-4c19-8eb7-3d0400f9d24a
72dde5a7-dc02-4dd9-ad4e-609ae9f74b3b

Figure

180eea5b-cad9-40ef-9f13-15deb948c87b
b69d2f46-88a4-42f0-8439-1ea4feab6310

Van

e1927885-3ab7-47f9-ae1c-ea7aab8ba4db
0ae49440-8d1f-4275-b28f-a89d8b440715

Rocket

fa440953-02a9-4602-b41b-066d1d273cc9
2533ca92-cca4-4621-af60-2c577d1b6c1c

Toilet

8693c512-012c-4a33-bd2f-b3e31c6f6a3c
42405adc-e8e2-4b4c-bf1e-9c945db5eda4

Unfortunately i can’t get better quality render cuz my pc was about to explode on 200x200 px

Try to imagine, our pc doing this 60 times per second with with hundred times better quality

Very interesting! If it was optimized, and updated in real time, it could make some nice reflections. Optimization would be one hell of a task though. The easiest way to do it would probably be Parallel Luau, reducing the pixels, and adding a blur to make it look less crude.