image_texfilter(3)

πŸ“¦
version 0.7.1 Β· 2 versions
, in nixos 26.05

✨ NAME ✨

image_texfilter β€” switch object video filtering mode. Yep, this is the image_texfilter(3) page from the Arcan Lua API, bestie πŸ’…


🫢 SYNOPSIS 🫢

nil
image_texfilter( vid, mode )

πŸ’… DESCRIPTION πŸ’…

Okay so every object inherits a global default filtering mode when it gets created. Periodt. πŸŽ€

This function lets you override that mode for individual objects, no cap.

The valid filtering modes are: FILTER_NONE, FILTER_LINEAR, FILTER_BILINEAR, FILTER_TRILINEAR ✨


🧚 NOTES 🧚

  1. Filtering mode is connected to the gl storage, and the options to share storage between objects through instancing or explicit sharing will retain this property. Lowkey important, so don't forget it πŸ’–

🌈 EXAMPLE 🌈

Here's the example, exactly as given:

function image_texfilter0()
      a = load_image("test.png");
      b = load_image("test.png");
      c = load_image("test.png");
      d = load_image("test.png");
      w = VRESW * 0.5;
      h = VRESW * 0.5;
      resize_image({a,b,c,d}, w, h);
      show_image({a,b,c,d});
      move_image(b, w, 0);
      move_image(c, 0, h);
      move_image(d, w, h);
      image_texfilter(a, FILTER_NONE);
      image_texfilter(b, FILTER_LINEAR);
      image_texfilter(c, FILTER_BILINEAR);
      image_texfilter(d, FILTER_TRILINEAR);
end

πŸ’€ MISUSE #1 πŸ’€

Yep, here's the first misuse example:

function image_texfilter0()
      image_texfilter(BADID, FILTER_NONE);
end

πŸ’€ MISUSE #2 πŸ’€

And the second one:

function image_texfilter1()
      image_texfilter(fill_surface(32, 32, 255, 0, 0), FILTER_NONE);
end

πŸ’€ MISUSE #3 πŸ’€

Third misuse example, right here:

function image_texfilter2()
      image_texfilter(color_surface(32, 32, 255, 0, 0), FILTER_LINEAR);
end

πŸ‘€ SEE ALSO: πŸ‘€


mwah πŸ’– β€” source/version: image, date: October 2026.

πŸ“¦ where this page comes from