Welcome, Guest. Please login or register.

Login with username, password and session length

 
Advanced search

1411504 Posts in 69373 Topics- by 58429 Members - Latest Member: Alternalo

April 25, 2024, 06:29:01 PM

Need hosting? Check out Digital Ocean
(more details in this thread)
TIGSource ForumsDeveloperArt (Moderator: JWK5)Аliased retro 3D look?
Pages: [1]
Print
Author Topic: Аliased retro 3D look?  (Read 1771 times)
Artylo
Level 0
***


I'm just a voice, pal - a most talented failure, b


View Profile WWW
« on: July 16, 2015, 03:41:53 PM »

I've seen this artstyle most prominently in Tom van den Boogaart's games.
It seems pretty simple to execute, but all my attempts at doing something similar have failed.
I know that he uses Unity, which is what I use too, so it's eather a script in C#/JS or a simple config option for some sort of AA manipulation.

I've done something similar in Blender while modelling:


... but my whole reason for this thread is to make this interactive and not simply a render.
« Last Edit: July 28, 2015, 09:36:24 AM by Artylo » Logged
Oddball
Level 10
*****


David Williamson


View Profile WWW
« Reply #1 on: July 16, 2015, 10:50:13 PM »

Edit>Project Settings>Quality>Anti Aliasing>Disabled

It's generally good practice to set up custom Quality Profiles tailored to your projects anyway.

I use a 'render to texture' to do the downscale itself.
Logged

Artylo
Level 0
***


I'm just a voice, pal - a most talented failure, b


View Profile WWW
« Reply #2 on: July 17, 2015, 02:21:30 AM »

Edit>Project Settings>Quality>Anti Aliasing>Disabled

It's generally good practice to set up custom Quality Profiles tailored to your projects anyway.

I use a 'render to texture' to do the downscale itself.

Thank you for the reply, but I don't fully understand how you use 'render to texture' to downscale. I've rendered the camera onto a texture before, but I'm not fairly competent in that field. It might be something for the Technical category, but I feel making another thread is pointless.

I'd normally approach doing downscaling by tinkering with the resolution, but that definitely doesn't work, due to everything getting blurry.

I know some engines (if I remember Unreal did) support render downscaling as a config option or something.
Logged
Oddball
Level 10
*****


David Williamson


View Profile WWW
« Reply #3 on: July 17, 2015, 02:41:06 AM »

I use a two camera set up. The main camera renders to texture, that texture is applied to a quad, and the second camera renders that quad to the screen. There's a little more to it like altering the quads size to fill the screen and disabling filtering on the texture. If you are worried about the technical side and don't mind throwing down a couple of dollars then there are some assets for it on the Unity store. This one seems pretty good - Pixel Camera - but I'm sure there's plenty of others.
Logged

Artylo
Level 0
***


I'm just a voice, pal - a most talented failure, b


View Profile WWW
« Reply #4 on: July 17, 2015, 03:00:44 AM »

I use a two camera set up. The main camera renders to texture, that texture is applied to a quad, and the second camera renders that quad to the screen. There's a little more to it like altering the quads size to fill the screen and disabling filtering on the texture. If you are worried about the technical side and don't mind throwing down a couple of dollars then there are some assets for it on the Unity store. This one seems pretty good - Pixel Camera - but I'm sure there's plenty of others.

Thanks again! I'll look into it.
I'm not worried about anything technical. Overall the idea is to learn how to do something yourself, isn't it.

The asset from the Unity store, seems fairly good for a start, but it is mostly a shader as I see it. There is nothing bad with shaders, but setting up cameras and altering quads seem fairly simple to do with the right know-how.
Logged
Zorg
Level 9
****



View Profile
« Reply #5 on: July 17, 2015, 03:24:15 AM »

It's pretty easy, i was able to produce this with only a few lines of code, mostly for the buttons:

http://zachau.info/krams/unity/rendertexturetest-u5/

A camera renders a texture and the main camera (orthographic) is pointed at an object with the texture on it. For the zoom i simply stretched the object (it's a cube, i guess quad would have been better :D). Instead of stretching the object you could divide Camera.main.orthographicSize by an integer. Render Texture could be used as GUI Texture, too.
Logged
Artylo
Level 0
***


I'm just a voice, pal - a most talented failure, b


View Profile WWW
« Reply #6 on: July 17, 2015, 03:39:10 AM »

It's pretty easy, i was able to produce this with only a few lines of code, mostly for the buttons:

http://zachau.info/krams/unity/rendertexturetest-u5/

A camera renders a texture and the main camera (orthographic) is pointed at an object with the texture on it. For the zoom i simply stretched the object (it's a cube, i guess quad would have been better :D). Instead of stretching the object you could divide Camera.main.orthographicSize by an integer. Render Texture could be used as GUI Texture, too.

Saying that, isn't it possible to not use a second camera, but just render it onto the GUI?
I haven't had the chance to tinker with the new Unity 5 GUI stuff.
Logged
Zorg
Level 9
****



View Profile
« Reply #7 on: July 17, 2015, 03:45:37 AM »

I tried to use the Render Texture as a GUI texture on the main camera, while using another camera for the scenery, but the Render Texture was stretched and partially covered by a weird white box (maybe GUI layer on the scenery cam?). I did not want to bug hunt at that time, so i used the cube instead.

I did not test it with one camera and i dont know if the GUI layer is rendered to the Render Texture either.
Logged
Artylo
Level 0
***


I'm just a voice, pal - a most talented failure, b


View Profile WWW
« Reply #8 on: July 17, 2015, 04:14:04 AM »

I think the GUI is it's own separate thing and not based on the camera.
I'll need to go through the Unity docs to see.
But if that's true, it could be possible to just scale the GUI element of the 'render to texture' from the quad and have a more flexible downscale option.
Logged
SvDvorak
Level 0
*



View Profile WWW
« Reply #9 on: July 21, 2015, 04:03:26 PM »

A bit late to the party but just a couple of days ago I converted a ShaderToy-shader I made previously to Unity that downsamples an image. Though I didn't use render to texture, I just manually sample every x'th pixel in the shader. Probably more efficient using render to texture but eh. ShaderToy and Unity examples:
https://www.shadertoy.com/view/MsjSD1
https://dl.dropboxusercontent.com/u/107494599/LowResLook/LowResLook.html

MonoBehavior (uses Camera Standard Assets for ImageEffectsBase class currently):
http://pastebin.com/Yse5YEGL
Shader:
http://pastebin.com/FaPz9Ky3

No idea how it handles GUI or similar things, hope it helps though =)
« Last Edit: July 21, 2015, 04:21:14 PM by SvDvorak » Logged
Mittens
Level 10
*****

.


View Profile WWW
« Reply #10 on: July 22, 2015, 04:16:54 AM »

I bought a pack of image effects from the unity asset store called "Colorful" and it has a pixelate filter which lets you choose the size of the pixels you want with a slider.

using an image effect you can render the game at native resolution without losing the effect. If you simply disable anti-aliasing then the retro effect may get lost when people run your game on a 4k monitor or something
Logged

ProgramGamer
Administrator
Level 10
******


aka Mireille


View Profile
« Reply #11 on: July 22, 2015, 05:24:17 AM »

Just a thought on the nomenclature of this thread. You could have simply called it "aliased retro 3D look". Just saying by the by Smiley
Logged

mgelon
Level 0
*



View Profile
« Reply #12 on: July 27, 2015, 03:11:07 PM »

A bit late to the party but just a couple of days ago I converted a ShaderToy-shader I made previously to Unity that downsamples an image.

MonoBehavior (uses Camera Standard Assets for ImageEffectsBase class currently):
http://pastebin.com/Yse5YEGL
Shader:
http://pastebin.com/FaPz9Ky3

Thanks for this, it works perfectly.  I've been looking for a simple implementation of this effect to mess around with.
Logged
Artylo
Level 0
***


I'm just a voice, pal - a most talented failure, b


View Profile WWW
« Reply #13 on: July 28, 2015, 09:39:28 AM »

Just a thought on the nomenclature of this thread. You could have simply called it "aliased retro 3D look". Just saying by the by Smiley

I can sometimes be amazed by simple things... like my own linguistics.

A bit late to the party but just a couple of days ago I converted a ShaderToy-shader I made previously to Unity that downsamples an image. Though I didn't use render to texture, I just manually sample every x'th pixel in the shader. Probably more efficient using render to texture but eh. ShaderToy and Unity examples:
https://www.shadertoy.com/view/MsjSD1
https://dl.dropboxusercontent.com/u/107494599/LowResLook/LowResLook.html

MonoBehavior (uses Camera Standard Assets for ImageEffectsBase class currently):
http://pastebin.com/Yse5YEGL
Shader:
http://pastebin.com/FaPz9Ky3

No idea how it handles GUI or similar things, hope it helps though =)

Thanks for this. I'll give it a look fairly soon.
Logged
Artylo
Level 0
***


I'm just a voice, pal - a most talented failure, b


View Profile WWW
« Reply #14 on: July 28, 2015, 09:59:55 AM »


Thanks you so much! This works perfectly!
Logged
SvDvorak
Level 0
*



View Profile WWW
« Reply #15 on: July 28, 2015, 10:40:18 AM »

No problem, happy to help! Mention if you make any cool changes or improvements.
Logged
Pages: [1]
Print
Jump to:  

Theme orange-lt created by panic