Search Home Members Contacts
About Us
Products
Downloads
Community
Support
Pages: [1]
  Print  
Author Topic: Landscape chunk size...  (Read 5159 times)
Dimple
Community Member
*
Posts: 643


« on: October 26, 2014, 07:12:03 PM »

 Smiley

Hello,  I've a question or so to ask, In TV65 the max chunk size is I believe 2048 x 2048 and continues down to at least 128 x 128. But does anything below that say 64 x 64, 32 x 32, 16 x 16, 8 x 8 etc... see use in mini maps only. I'm thinking about a grass demo Arius may have made.

In any event when making some form of terrain in TV65, where should one stop using larger chunks and
start using smaller one's. I'm unsure if I should be using the term mip mapping instead though...

I hope that wasn't too confusing. I'm trying to resolve what to have in the Terrain/Landscape Editor I'm working on.

Logged

Using VB.NET, TV3D 6.5, Win 7
~~~~~~~~~~~~~~~~~~~~~~~

"Know how to ask. There is nothing more difficult for some people, nor for others, easier."

- Baltasar Gracian
Waterman
Moderator
Community Member
*****
Posts: 1159


« Reply #1 on: October 27, 2014, 10:22:51 PM »

Hey Dimple

I seem to write to this forum about once per year :-).

Sorry i don't know the TV3D Landscape object well - tried long ago, and it wasn't sufficient. I'd like to propose that you'd use your own meshes instead. That way you get much better control over everything, however it involves using a shader as well.

It's simple, really! You create an empty mesh, then use SetGeometryEx, that holds both a vertex array and an index array. It's only a matter of constructing the triangles, individually (one by one, individualy), and then find the common vertexes (since tri's share the same vertex locations) to compress the data, and re-order the indexes to point correcty.

Then you use mesh.SetShader to begin coloring everything. In the shader you can have 8 textures, some of which may be "control textures", ie. such that control where grass, sand, rock, etc. shall be placed. You can even do a texture lookup in the vertex shader, meaning you can adjust the vertex heights based on the texture pixel values (and remmember to use the TV_TEXTUREFORMAT_HDR_FLOAT32 format here - then you have more than 255 possible values per color channel). And ofc one texture input (sampler) can be your realtime shadows, or a shadow map created once in a while, depending on where you are.

To solve the LOD issue, i myself pre-create the vertex and index arrays for 3 different LOD levels. Each of them cover the same land area (around 2 by 2 kilometers) but have different amounts of triangles. You need a paging logic to manage the switching (depending on your position) but that's not a huge issue. TV3D gracefully deletes and creates meshes with no memory leaks!

I cover 30000 square kilometers in the simulator, so this system is heavily stress-tested. If you want to discuss this more, just jump to the IRC and have patience. You'll get any help me and the people there are able to give.

Well, 5 cents. i know it's annoying to abandon and re-start, but hey that's our life! Re-write from scratch :-).
Logged

Things should be described as simply as possible - but not simpler [A. Einstein]
Dimple
Community Member
*
Posts: 643


« Reply #2 on: October 29, 2014, 06:53:12 PM »

 Smiley

Thanks, for your reply I'll think about what you've said and figure out what I'm going to do.
Anyone else have any thoughts about things done in TV landscape?

Logged

Using VB.NET, TV3D 6.5, Win 7
~~~~~~~~~~~~~~~~~~~~~~~

"Know how to ask. There is nothing more difficult for some people, nor for others, easier."

- Baltasar Gracian
Pages: [1]
  Print  
 
Jump to:  

Powered by SMF 1.1.3 | SMF © 2006-2007, Simple Machines LLC
Seo4Smf v0.2 © Webmaster's Talks