pkdawson / imgui-godot

Dear ImGui plugin for Godot 4
MIT License
492 stars 28 forks source link

How to change the SamplerFilter? #89

Open rakzin opened 1 month ago

rakzin commented 1 month ago

Basicly, I want to show a texture with SamplerFilter.Nearest

I saw there is a samplerstate in Internal/RdRenderer.cs file. which writes SamplerFilter.Linear

But as I'm using GDScript, changing it seems takes no effect.

pkdawson commented 1 month ago

I'd thought about this problem before, but it was way back in Godot 3, where you could just change the filter in the texture's import settings. That doesn't work anymore.

I'll add a config option which lets you change the texture filter. This could affect how the UI looks too, but in typical usage it should make no difference.

rakzin commented 1 month ago

That would be great

rakzin commented 1 month ago

As Omar replied me in a question post, they added something to change the render state.

https://bsky.app/profile/ocornut.bsky.social/post/3l7alfgrfua2q

Hope this can be usefull