Terrain Blurr

Blitz3D Forums/Blitz3D Beginners Area/Terrain Blurr

Merrie(Posted 2007) [#1]
Also if someone would be so kind is to give me a newbie step by step. Following the crash course, I set up my script and noticed that the terrain near the camera is very blurry but the distance is nice and crisp. Is there a way to make the near terrain more sharp? Thanks for the help.


Wayne(Posted 2007) [#2]
Use higher resolution textures.


jfk EO-11110(Posted 2007) [#3]
At some point you cannot use higher resolutions or bigger textures anymore (eg: 2048*2048) this is where multitexturing may become useful. Take a grainy, sandy tiling texture and apply it as a further texture layer (see entitytexture optional parameters). Additionally, use blendmode 5 or so for the texture, together with a texture that has an average color of 128,128,128. Now when you're close to the terrain, the grainy texture is visible, when far away the blurry texture will dominate.


Merrie(Posted 2007) [#4]
Im sorry to be dense here JFK but Im not sure what your saying, can you give a better example? Im very noobie :) On using the entitytexture parameters? And what blendmode 5 is , and how to tell 128,128,128 color?

Thanks!


IPete2(Posted 2007) [#5]
Merrie,

also try this. Before you load ANY textures

cleartexturefilters

That may alter things if mimapping (which makes things further away a little less sharp - ahem!). Cleartexturefilters will cause sharper but possible to harsh texturing results - in my experience.

In the 3D Sample folder which comes with B3d check out the MAK folder and look for the massive terrain example in the flying demo (name escapes me sorry) and the Mario Castle demo.

IPete2.


jfk EO-11110(Posted 2007) [#6]
Removing mipmapping by ClearTexturefilters will make the texture flicker IMHO. It isn't a real solution since it will only make the texture a little sharper but it cannot add details.Additionally, it's rendering slower than mipmapped ones.

Ok a quick guide:

take a landscape texture 1024*1024 for the terrain. Then create a new 128*128 texture, eg. in an app like photoshop or gimp. First set the forground color to 127,127,127 (mid grey) then fill the texture with this color. Then add a Noise effect or so to it. Not too much, but also not too subtile. Save this as noise.bmp.


In blitz use it like this

tex1=loadtexture("myterraintex.bmp")
tex2=loadtexture("noise.bmp")
scaletexture tex2,0.05,0.05
textureblend tex2,5

entitytexture terrain, tex1,0,0
entitytexture terrain, tex2,0,1

Now you can go much closer without to get blurry textures. Of course, this is only an illusion, caused by the additional fine grain on the big texture. Blendmode 5 will work almost like blendmode 2, but it won' t make the underlying texture darker as long as the noise texture's average color is mid grey.

BTW you will have to scale the textures relative to the terrain size, but you may use the scaling relation between the two textures I just described.


D4NM4N(Posted 2007) [#7]
Are you the merrie that bought ted recently?

If using ted and blitz its best to use the B3D with vertex alpha for better looking textures, the X option with 'supertexture' is much blurrier but a bit faster as it contains geometry for 1 layer, but uses a huge texture instead.

When using the vertex alpha option you can increase the resolution of the actual texture loaded in for even better results

Ipete, youre right, clearing the mipmap filter looks crap and really pixelated. Esp. on terrains. B3ds mipmapper is really good compared to others.
If merrie IS using ted to do terrin and uses B3D format then theres no need to change the filters as i have already set them up as optimal within the b3dmesh.


Merrie(Posted 2007) [#8]
Yes D-Grafix Im the Merrie that purchased T.ED I just have to figure out what I need to load it into Blitz :)

Thanks all!


Merrie(Posted 2007) [#9]
What Im referrring to with the above comment is that Im just learning Blitz3D so do not know the exact commands yet to load the terrain, if only the one, loadterrain is needed or additional code.


AJirenius(Posted 2007) [#10]
Don't worry Merrie. We're a lot of people just learning Blitz3D in here. I just started using it a few months ago and have recently finished my first project starting on my second but still I have loads and loads of question each day :)

welcome!


D4NM4N(Posted 2007) [#11]
merrie, im on skype (as dgrafix) and msn (as danontour2002@hotmail) if you want to talk using voice, i can talk you through what you need to do :)


Merrie(Posted 2007) [#12]
Dan do you have something other then MSN? I use AIM merries59?


Merrie(Posted 2007) [#13]
Thank you for the welcome Andreas! Everyone has been very patient and kind to me, which helps in learning as your not afraid to ask questions even if they seem elementry. :)


D4NM4N(Posted 2007) [#14]
I dont use aim, ive got skype, icq, msn. I can connect to aol on my linux machine but have no account. I dont really want anymore clients on my windows machine.

ICQ is 244-606-191


Merrie(Posted 2007) [#15]
Ok Dan I set up a Windows account, merries59@hotmail, thanks