switch_default_texfilter - Switch the default texture filtering mode for
all newly created objects.
nil
switch_default_texfilter( filtermode )
This function accepts either FILTER_NONE , FILTER_LINEAR ,
FILTER_BILINEAR and FILTER_TRILINEAR which are texture
post-processing stages usually supported in-hardware. Others will have to be
implemented as temporary rendertargets with appropriate shaders.
- 1
- any value to filtermode outside the accepted values is a terminal state
transition.
function switch_default_texfilter0()
switch_default_texfilter(FILTER_NONE);
a = load_image("test.png");
show_image(a);
scale_image(a, 1.25, 1.25);
switch default_texfilter(FILTER_TRILINEAR);
b = load_image("test.png");
show_image(b);
scale_image(b, 1.25, 1.25);
local props = image_surface_properties(a);
move_image(b, 0, props.height);
end
function switch_default_texfilter0()
switch_default_texfilter("none");
end
function switch_default_texfilter1()
switch_default_texfilter(1000);
end