PickedTriangle?

Blitz3D Forums/Blitz3D Programming/PickedTriangle?

Boiled Sweets(Posted 2004) [#1]
Hi,

my level editor currently has a grid of 5 * 2000 tiles.
This creates 10000 surfaces and is a nightmare as its sooo slow. I want to implement a single surface system so that the 20 different tile types are basically 20 different surfaces.

The trouble I have is if I add a tile to say the tile1 surface then use wants to change that tile to the tile2 surface how do I remove those 2 tris from the tile1 surface.

I can use PickedTriangle but how do I remove that triangle and it's other quad tris from the surface?

Hoep the above makes sence.


AntonyWells(Posted 2004) [#2]
You have to rebuild the mesh. (check out clearSurfaces)

Or another way is to just 'diable' those verts by off-setting them off screen. And then bringing 'em back when in use. I'd do that probably..be much faster unless it's a polys. but grid based..worth a shot.


Stevie G(Posted 2004) [#3]
Option2 would work better as it can get quite slow rebulding a large mesh.


Boiled Sweets(Posted 2004) [#4]
Either I don't understand what you're suggesting or you don't understand my problem.

Imagine a grid of quads 2000*5. They are all seperate surfaces.

I have 20 tile types.

I want to be make 20 surfaces, one surface for each tile.

The trouble is imagine I want tile (2,2) to be set to surface B. I can easily add a quad to surface B at position 2,2 but how do I remove the 2 tris from surface A.

Clearing the surface sounds bad news.

So how do I locate the 2 tris that I want removed?


Bremer(Posted 2004) [#5]
As far as I know you cannot remove tris/vertices from a surface, your only option is to recreate it without the ones you don't want or move the vertices in question to a remote place where they are not shown when rendered.