Page 1 of 1
3D Grid blurring
Posted: Sun Jul 01, 2012 10:36 pm
by Arcturus
I have noticed that when a grid-like texture is applied to a plane the lines blur insanely in the distance with visible bands at various intervals. An example can be seen in the PB examples including CameraTrack.pb and ThirdPerson.pb. I would prefer crisp lines rather than burring to nothing, however the only way I have managed to do so is seting the filtering mode to "None" instead of "Bi/Trilinear" which results in poor quality.
I would like to know if there is any way to make these grid patterns look crisp and not so blurred in the distance.
Re: 3D Grid blurring
Posted: Mon Jul 02, 2012 12:53 am
by Zach
Anti-Aliasing and Anisotropic Filtering ?
Re: 3D Grid blurring
Posted: Mon Jul 02, 2012 2:42 am
by Arcturus
I've tried changing the Anti-Aliasing settings, but it makes no difference. Can you tell me more about anisotropic filtering?
Re: 3D Grid blurring
Posted: Mon Jul 02, 2012 3:31 am
by IdeasVacuum
Can you tell me more about anisotropic filtering?
..... it's a difficult word to pronounce

(sorry, couldn't resist)
anisotropic filtering
Re: 3D Grid blurring
Posted: Mon Jul 02, 2012 1:25 pm
by Arcturus
I should have worded that better
What I meant to ask, is if it can be done in Ogre (and if so, some advice on how to do so)
Re: 3D Grid blurring
Posted: Mon Jul 02, 2012 2:20 pm
by Zach
I honestly don't know anything about Ogre, nor especially the version used by PB.
Sorry.
Re: 3D Grid blurring
Posted: Mon Jul 02, 2012 4:35 pm
by Comtois
You can use a script material
Code: Select all
material Examples/anisotropic
{
technique
{
pass
{
texture_unit
{
texture drawline.png
max_anisotropy 8
filtering anisotropic
}
}
}
}
Re: 3D Grid blurring
Posted: Mon Jul 02, 2012 10:39 pm
by Arcturus
Comtois wrote:You can use a script material
Thanks, I'll do a bit of research on this and test it out.
Re: 3D Grid blurring
Posted: Tue Jul 03, 2012 7:55 am
by Comtois
here are my modification in CameraTrack.pb
Code: Select all
Add3DArchive("Data/textures" , #PB_3DArchive_FileSystem)
Add3DArchive("Data/models" , #PB_3DArchive_FileSystem)
Add3DArchive("Data/GUI" , #PB_3DArchive_FileSystem)
Add3DArchive("Data/Scripts" , #PB_3DArchive_FileSystem)
Add3DArchive("Data/Packs/desert.zip", #PB_3DArchive_Zip)
Parse3DScripts()
WorldShadows(#PB_Shadow_Modulative)
CreateImage(1, 256, 256)
StartDrawing(ImageOutput(1))
Box(0, 0, 256, 256, $002255)
DrawingMode(#PB_2DDrawing_Outlined)
Box(0, 0, 256, 256, $FFFFFF)
Box(10, 10, 236, 236, $FFFF)
StopDrawing()
UsePNGImageEncoder()
SaveImage(1, "Data/textures/drawline.png", #PB_ImagePlugin_PNG)
CreateMaterial(0, LoadTexture(0, "r2skin.jpg"))
GetScriptMaterial(1, "Examples/anisotropic")
;robot
And then you copy the script material in the file 'examples.material' or create a new file (folder Data/Scripts)