Texture Filtering

Something has annoyed me in GMod for years. You know how when people draw text, or a HTML panel in the world it looks all pixelly? Well yeah that’s annoyed me. So I took 5 minutes to add these functions in the next update.

render.PushFilterMin( TEXFILTER.ANISOTROPIC );
render.PushFilterMag( TEXFILTER.ANISOTROPIC );

render.DrawSprite( .. blah .. )


These allow you to force the texture filter mode to a certain value – and ignore the filter value set in the textures. *Min is the filtering to use when the texture is smaller than its size on screen, *Mag is the filter to use when it’s larger (magnified). Modes are:

TEXFILTER.NONE (force normal behaviour)

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s