GeoMipMapped Terrain Scene Node ( UPDATED 3/3/05 )
to 1.) the patch size stays at the lowest detail LOD
to 2.) 2,8 ghz p4 with ht, 512mb ram,windows xp home and ati radeon 9600
to 3.) i will try it, but if i are above the terrain and look at a 89 or 91° angle the terrain sometimes disappears, but not always.
to 4.) yes, i will upload a screenshot in a few minutes.
to 5.)oh, thats why. sorry for confusing you
"also, when you set the Y of the scale to 0, you're terrain will be flat"
but its not flat, thats the weird thing about it
im uploading a screenshot later, im uploading a directx version of irrlicht for devc++ for pink_floyd right now, sorry ^^
to 2.) 2,8 ghz p4 with ht, 512mb ram,windows xp home and ati radeon 9600
to 3.) i will try it, but if i are above the terrain and look at a 89 or 91° angle the terrain sometimes disappears, but not always.
to 4.) yes, i will upload a screenshot in a few minutes.
to 5.)oh, thats why. sorry for confusing you
"also, when you set the Y of the scale to 0, you're terrain will be flat"
but its not flat, thats the weird thing about it
im uploading a screenshot later, im uploading a directx version of irrlicht for devc++ for pink_floyd right now, sorry ^^
-
- Posts: 62
- Joined: Fri Jan 07, 2005 4:37 pm
- Location: California
Ha... with patchsize 65 and heightmap of 512 look what happens...
Could not draw triangles, too many vertices(80768), maxium is 65535.
Could not draw triangles, too many vertices(80768), maxium is 65535.
Could not draw triangles, too many vertices(80768), maxium is 65535.
[repeat a bunch of times...]
this is the 32bit indices getting overloaded right??
time for 64bit...
Could not draw triangles, too many vertices(80768), maxium is 65535.
Could not draw triangles, too many vertices(80768), maxium is 65535.
Could not draw triangles, too many vertices(80768), maxium is 65535.
[repeat a bunch of times...]
this is the 32bit indices getting overloaded right??
time for 64bit...
Yes, 65535 is the limit for a value 2^16.deprecated wrote:Ha... with patchsize 65 and heightmap of 512 look what happens...
Could not draw triangles, too many vertices(80768), maxium is 65535.
Could not draw triangles, too many vertices(80768), maxium is 65535.
Could not draw triangles, too many vertices(80768), maxium is 65535.
[repeat a bunch of times...]
this is the 32bit indices getting overloaded right??
time for 64bit...
4294967296, is the limit for a value of 2^32
I'm assuming you're using OpenGL. See, with DirectX, the maximum number of primitives allowed in a DrawPrimitive call is determined from the D3D9CAPS structure, which is determined from your video card's capabilities I believe. OpenGL uses the hard-coded value of 65535, so even if you have updated the engine to use 32 bit indices, OpenGL will still fail on more than 65,535 primitives. However, the default for the drawPrimitive calls in the Irrlicht engine is to check the number of drawn primitives with ther vertex count, not the triangle count. Make sure, in CVideoOpenGL.cpp, in the drawPrimitive function, you are passing the triangleCount value to the checkPrimitiveCount. I need to look into OpenGL and see if there is a way to get the maximal primitive count for a glDrawElements call, I just don't know OpenGL as well as DirectX, sorry.
EDIT: Oh, and you can increase the FPS by a lot, if you disable the triangle selector. As we speak, i'm looking at ways to make the triangle selector faster, but i don't think it's all that possible, unless you force it to always use a low LOD of all the patches.
Make sure you have the latest code. This definintely should work. When you upload that code, I'm gonna download it and check out the code, make sure everything is ok.GFXstyLER wrote:to 1.) the patch size stays at the lowest detail LOD
to 2.) 2,8 ghz p4 with ht, 512mb ram,windows xp home and ati radeon 9600
to 3.) i will try it, but if i are above the terrain and look at a 89 or 91° angle the terrain sometimes disappears, but not always.
to 4.) yes, i will upload a screenshot in a few minutes.
to 5.)oh, thats why. sorry for confusing you
"also, when you set the Y of the scale to 0, you're terrain will be flat"
but its not flat, thats the weird thing about it
im uploading a screenshot later, im uploading a directx version of irrlicht for devc++ for pink_floyd right now, sorry ^^
I'm working on some other things, but I've got the scene node setup now, so you can turn off dynamic updating of the selector associated with the node. You can also now pass an argument to the createTriangleSelector, specifying the LOD you want for all patches. So, for example, with the dynamic updating of the triangle selector, I was getting ~35 FPS, with a 512x512 heightmap, patchsize of 17 and MaxLOD of 5. I changed it so the triangle selector used LOD 3 and didn't dynamically update and I was getting 75 FPS. With LOD 0 on the selector, I was getting 5 FPS, but you have more choice at least with the new setup.
I've also got it so the GetMeshBufferForLOD function takes a reference to a MeshBuffer.
Working on a few more optimizations, i'm hoping will improve performance then I'll update the code and the webpages later on.
I've also got it so the GetMeshBufferForLOD function takes a reference to a MeshBuffer.
Working on a few more optimizations, i'm hoping will improve performance then I'll update the code and the webpages later on.
Last edited by Spintz on Tue Jan 25, 2005 3:39 am, edited 1 time in total.
-
- Posts: 62
- Joined: Fri Jan 07, 2005 4:37 pm
- Location: California
Spintz,
Quick question....
I downloaded your code (last night) and put the source in place of mine...
I took a look at the source and all the old functions are still in there as well as the new ones... with the same names...
I am now very confused... is this what is causing my problems...??
is the program finding the old function first and ignoring the new function...?
have you updated the source on your website since last night?
thanks much...
Quick question....
I downloaded your code (last night) and put the source in place of mine...
I took a look at the source and all the old functions are still in there as well as the new ones... with the same names...
I am now very confused... is this what is causing my problems...??
is the program finding the old function first and ignoring the new function...?
have you updated the source on your website since last night?
thanks much...
If you're GeoMipMapSceneNode is using a meshBuffer with 16 bit indices, then the DrawPrimitive with 16 bit indices will be used, not the 32 bit drawPrimitve. Did you change the original 16 bit drawIndexedPrimitive functions to pass triangleCount and not vertexCount?
If you want, I'm on AIM, sppintzz is my screenname, IM me.
If you want, I'm on AIM, sppintzz is my screenname, IM me.
Last edited by Spintz on Tue Jan 25, 2005 3:39 am, edited 1 time in total.
-
- Posts: 62
- Joined: Fri Jan 07, 2005 4:37 pm
- Location: California
Status report:
alright... after fixing a few things, (mainly the length of the line i was drawing) I am getting better frame rates ~75 - 120
anyways... this is great! cant wait for the detail map textures.
I am trying to build a program in which you focus on the ground a lot, and good quality is what I am after.
I have been looking into the GDAL api to load SDTS DEM files as hieghtmaps into irrlicht and your addition is what I needed to make the irrlicht handle the detailed data.
thanks...
GDAL
http://www.remotesensing.org/gdal/
alright... after fixing a few things, (mainly the length of the line i was drawing) I am getting better frame rates ~75 - 120
anyways... this is great! cant wait for the detail map textures.
I am trying to build a program in which you focus on the ground a lot, and good quality is what I am after.
I have been looking into the GDAL api to load SDTS DEM files as hieghtmaps into irrlicht and your addition is what I needed to make the irrlicht handle the detailed data.
thanks...
GDAL
http://www.remotesensing.org/gdal/
Just posted a bunch of updates.
As noted in the first post now, I just can't keep up with updating the how-to's, is much easier at this rate of changing the code to just keep posting the whole engine.
The web page -
http://www.spintz.com/irrlicht/geomipmapscenenode/
still has the changelog and the links to download the source of the modified Irrlicht Engine. Once I get the code closer to completion, I'll update the How-To, to help people integrate the code into an engine they may have already modified.
I've now also included a .chm file which shows the documentation from the class in a better format
As noted in the first post now, I just can't keep up with updating the how-to's, is much easier at this rate of changing the code to just keep posting the whole engine.
The web page -
http://www.spintz.com/irrlicht/geomipmapscenenode/
still has the changelog and the links to download the source of the modified Irrlicht Engine. Once I get the code closer to completion, I'll update the How-To, to help people integrate the code into an engine they may have already modified.
I've now also included a .chm file which shows the documentation from the class in a better format
Last edited by Spintz on Tue Jan 25, 2005 3:39 am, edited 1 time in total.
-
- Posts: 62
- Joined: Fri Jan 07, 2005 4:37 pm
- Location: California
Justo downloaded the new updated version it seems a lot more responsive than previous versions...
In my test program (built for older version),
FPS have increased and there is way less lag / delay while flying around...
cool...
i still need to checkout the new features...
The nicest part about this thing, is that it doesnt seem to slow down no matter how may terrain nodes i create. I still need to expand my test a bit, but I had eight 256X256 maps scaled and tiled and it loaded sooooo fast... fps good as well..
no more 32X32 terrain maps in irrlicht! woohoo!
In my test program (built for older version),
FPS have increased and there is way less lag / delay while flying around...
cool...
i still need to checkout the new features...
The nicest part about this thing, is that it doesnt seem to slow down no matter how may terrain nodes i create. I still need to expand my test a bit, but I had eight 256X256 maps scaled and tiled and it loaded sooooo fast... fps good as well..
no more 32X32 terrain maps in irrlicht! woohoo!