VOGONS


First post, by antrad

User metadata
Rank Member
Rank
Member

We can force anisotropic filtering using dgVoodoo and it affects both 3D rendering and the 2D GUI and HUD elements.

Is it possible to apply anisotropic filtering only on 3D, while using no filtering (or nearest) on 2D HUD and GUI elements ? With anisotropic filtering those often look blurry and sometimes there are artifacts around text.

I am also asking about this possibility in cases when you force resolution to make the GUI larger.

https://antonior-software.blogspot.com

Reply 1 of 6, by Dege

User metadata
Rank l33t
Rank
l33t

The problem is that dgVoodoo cannot tell the difference between 2D/3D elements. Both of them are just drawn as polygons thorugh the 3D hw in most cases.
If it's drawn through 2D hw or by direct cpu access then it's not affected by the texture filtering.

Reply 2 of 6, by antrad

User metadata
Rank Member
Rank
Member
Dege wrote on 2020-02-24, 22:04:

The problem is that dgVoodoo cannot tell the difference between 2D/3D elements. Both of them are just drawn as polygons thorugh the 3D hw in most cases.
If it's drawn through 2D hw or by direct cpu access then it's not affected by the texture filtering.

Too bad.

But since we are at it, how does GUI/HUD scaling work ? When you leave the game settings at 1280x720, but force 1920x1080 in dgVoodoo, the 2D elements are rendered larger than when running the game in real 1920x1080. How does that work if dgVoodoo doesn't know what is 2D and what is 3D?

https://i.imgur.com/oRnAovc.jpg
https://i.imgur.com/CfWoE8X.jpg

https://antonior-software.blogspot.com

Reply 4 of 6, by ZellSF

User metadata
Rank l33t
Rank
l33t

This is a common problem with emulators too. There's just no way to consistently tell what textures are GUI elements or not.

For the opposite of what you want there's a creative workaround for this problem:
https://www.libretro.com/index.php/introducin … lemednafen-psx/ (look for "Adaptive smoothing")
Which I would really like to see as a ReShade shader, since unfiltered GUI scaling often looks ugly to me.

Reply 5 of 6, by robertmo

User metadata
Rank l33t++
Rank
l33t++

The best option is to use "Force point sampled" and "disable mipmapping".
You don't need anisotropic filtering for this.
It actually looks even better
and no annoying lines between textures, world doesn't look like a bathroom 😉

Reply 6 of 6, by Dege

User metadata
Rank l33t
Rank
l33t
antrad wrote on 2020-02-24, 23:47:
Too bad. […]
Show full quote
Dege wrote on 2020-02-24, 22:04:

The problem is that dgVoodoo cannot tell the difference between 2D/3D elements. Both of them are just drawn as polygons thorugh the 3D hw in most cases.
If it's drawn through 2D hw or by direct cpu access then it's not affected by the texture filtering.

Too bad.

But since we are at it, how does GUI/HUD scaling work ? When you leave the game settings at 1280x720, but force 1920x1080 in dgVoodoo, the 2D elements are rendered larger than when running the game in real 1920x1080. How does that work if dgVoodoo doesn't know what is 2D and what is 3D?

https://i.imgur.com/oRnAovc.jpg
https://i.imgur.com/CfWoE8X.jpg

If the HUD is drawn as 3D polygons then they simply get scaled along with all other polygons (and dgVoodoo doesn't know which polygons are HUD).
If the HUD is drawn through 2D bitmap blitting then they also scaled (2d-scaling), either with point sampled or bilinear filtering (see option 'Bilinear blit stretch').
If the HUD is drawn by direct CPU access then the written pixels get 2D-scaled with point sampled filtering.