Different results with multisampling in DirectX 9 vs OpenGL

536 views Asked by At

First, some context :

  • The 3D engine I wrote for my game allows me to switch between DirectX 9 and OpenGL, thanks to an intermediate API layer.

  • Both allow the user to enable multisampling (via GL_ARB_multisample for OpenGL, D3DMULTISAMPLE_x_SAMPLES for DirectX). Multisampling is enabled for the game window buffer.

  • The models for my characters use one big texture with texture atlases, so I disabled mipmapping there in order to avoid texture bleeding.

I experience the following results :

  • As I should, I get the same result when disabling multi-sampling for DirectX or OpenGL.

  • As I should, I correctly get edge smoothing on polygons when enabling multi-sampling for both.

  • However, in OpenGL, it seems that multi-sampling also has an effect akin to texture filtering, probably multi-sampling at different spots in the texture for each pixel, as the results are comparable to what mipmap would achieve, without texture bleeding - obviously, great. On the other hand, however, DirectX doesn't seem to provide this benefit as the result of texture mapping isn't anti-aliased, and the same as when multi-sampling is disabled.

I would very much like to know if there is anything I can do in order to get the same result in DirectX as in OpenGL. Maybe I am not aware of the good keywords, but I haven't been able to find documentation that relates to this specific aspect of multisampling.

0

There are 0 answers