GameMaker [Solved] Issue with gpu_set_textfilter() and Standard Draw vs Draw GUI and views

R

r33v01v3

Guest


I'm making a maze game, using a magnify shader that follows the enemy and trying to get the best "distortion" look using "gpu_set_textfilter()". See image for details.

The maze is drawn to a surface which has the shader applied to it and I use views to follow the player.

Room size is 960 x 540 with Start Fullscreen and Keep Aspect Ratio on in the Windows settings.

The different parts of the image show what I get when using the shader in a standard draw event with texture filter off, draw event with texture filter on, draw GUI with texture filter off and draw GUI with texture filter on.

The difference is huge between them, and the best is obviously Draw GUI tex filt ON. However I then can't seem to find a way to use views to follow my character around the maze. Is it possible to make the GUI follow views?

Or, is there a way to get the same quality anti aliasing/filtering as shown in the Draw GUI with tex filt ON in a standard Draw event?

Is it an issue with the scaling used in the Draw event vs DrawGUI messing with pixel interpolation?

Thanks.
 

Nocturne

Friendly Tyrant
Forum Staff
Admin
It looks like your GUI layer has a higher base resolution than your main draw. Try setting the application surface to twice the size of the camera view... So if your main camera is (for example) 800x400, set the app surface to 1600x800. That will give you more pixel resolution without actually scaling the game.
 
R

r33v01v3

Guest
It looks like your GUI layer has a higher base resolution than your main draw. Try setting the application surface to twice the size of the camera view... So if your main camera is (for example) 800x400, set the app surface to 1600x800. That will give you more pixel resolution without actually scaling the game.
Thanks, I'll give it a try.

Edit: That fixed it, thank you so much! - Just used: surface_resize(application_surface, display_get_gui_width(), display_get_gui_height()) - in the room creation code.
 
Top