This is literally the bane of any low-resolution-texture aficionado. Any way to turn it off?
https://i.imgur.com/b8UjOr1.png
Any way to get rid of bilinear filtering?
Forum rules
Please upload a testscene that allows developers to reproduce the problem, and attach some images.
Please upload a testscene that allows developers to reproduce the problem, and attach some images.
-
- Posts: 6
- Joined: Sun May 06, 2018 10:10 pm
- alpistinho
- Developer
- Posts: 198
- Joined: Thu Jul 05, 2018 11:38 pm
- Location: Rio de Janeiro
Re: Any way to get rid of bilinear filtering?
Not currently, bilinear is always used.
PS: Dade, were you notified of this quote?
Where is that located in the code?Dade wrote: ↑Wed May 09, 2018 9:15 amNot at the moment, bilinear interpolation is always used. Indeed, it would be quite easy to add as an option but it has never be done until now.happysmash27 wrote: ↑Wed May 09, 2018 3:23 am I am trying to change the interpolation of an image texture to be nearest neighbour, with sharper, cleaner lines. However, I don't see an interpolation option. Is it currently possible to do this without manually making the texture larger?
PS: Dade, were you notified of this quote?
-
- Posts: 6
- Joined: Sun May 06, 2018 10:10 pm
Re: Any way to get rid of bilinear filtering?
I've seen that post. I think no interpolation really needs to be added as an option. For now, the only way to get blocky pixels is to pre-scale the textures.
Re: Any way to get rid of bilinear filtering?
The code for image maps bi-linear interpolation is here: https://github.com/LuxCoreRender/LuxCor ... p.cpp#L345
But, as usual, the hard part is not the C++ code but the OpenCL one.
-
- Posts: 20
- Joined: Sun May 06, 2018 2:36 am
Re: Any way to get rid of bilinear filtering?
Can someone, perhaps, explain what, exactly, it is doing? I don't quite understand the inputs and outputs, and it doesn't help that I am more familiar with C than C++.
Re: Any way to get rid of bilinear filtering?
It maps UV coordinates to 4 texels in the image texture and performs bilinear filtering on those 4 texels.
It returns the resulting color (basically a weighted mix between the 4 texels).
See https://en.wikipedia.org/wiki/Bilinear_filtering
I think if you want to implement a method without bilinear filtering, you would just evaluate one texel at the UV location and return its color.
It returns the resulting color (basically a weighted mix between the 4 texels).
See https://en.wikipedia.org/wiki/Bilinear_filtering
I think if you want to implement a method without bilinear filtering, you would just evaluate one texel at the UV location and return its color.