Home Artists Posts Import Register
Join the new SimpleX Chat Group!

Content

Several unused cvars were removed in this version.

Some progress was done in the anisotropic texturemapping algorithm. Now it computes the anisotropic scaling at both the nearest and the farthest screenspace points of the surface. However, only the scaling of the nearest point is being used right now, which results in the image being sharper than it should, giving some moire artifacts.

Since perspective correction is, as far as I understand, a function of screen depth, in the future it should be possible to quickly interpolate the anisotropic scaling in the screenspace during the perspective correction steps, to make all parts of the surfaces equally smooth.

Anisotropic texturemapping is difficult and it's quite impossible to find example implementations of it. I'm sure my algorithm of it will always be significantly flawed, but at least it does improve things. Anyway, I'll implement a cvar to disable it.

Comments

Pritchard

I suppose AF is just one of those things that's been done in hardware for so long that no one has bothered to try and write it themselves... I wonder if you would have to go back to old papers on the subject or something like that to find answers.

mankrip

The only papers I found were patented, so I didn't bother reading them. My implementation works mostly fine, including on sheared perspective. But on diagonal perspectives, it either looks too blurry or too sharp. It also doesn't take the in-surface texture scaling into account, so if you stretch the scale in a map editor, the engine will interpret that as an anisotropic projection. This I can fix, eventually. The main challenges right now are to implement trilinear dithering between different anisotropic scales, and to implement per-depth interpolation of anisotropic scales in the perspective correction of the rasterizer. This should be enough to reach an acceptable quality.