Thứ Ba, 4 tháng 6, 2013

Tuesday Traversals

Delete And Expand

For want of a better title, the code created today includes being able to completely delete a mesh item from the buffer in real-time and I have finally expanded the level in the map editor to 500x20x500 and reversed the grid Z alignment.

Delete Code

The delete stuff was pretty intense, as I had to record which buffer the reference item exited within, including the exact position of the vertex and index data within that buffer. Shuffling the remaining data to delete the intended data was simple enough, but then re-scanning the entire reference grid in the area to ensure the offsets recorded for the other items reflected the layout inside the buffer was a tough one!  There is a very strange corrupt happening very occasionally so will need to tackle that when it becomes too annoying.  In general though, it's a nice clean fast delete procedure and much better than my first theory which was simply to reduce the polygons to zero size on delete, but that would simply gobbled up memory as you continue adding and deleting during the edit.  With Add and Delete now features of the Instance Stamp system, and integrated into the map editor, it was nice to see the ability to add and move walls and floors.  It is not 100% yet as little things like combining edits are still missing, but the hard grunt work is done now.

Expand Code

The second big code chunk of the day was the 500x20x500 level size. Amazing how BIG it is.  Here is a small rough video (sorry Rick) of just how big the level edit area now is:


As you can see you really will not fill this area, and in order to stay sane and move onto other things I will keep the 99999x99999x99999 level size idea for a future upgrade.  I am not sure such a level size would make sense, but when we start seeing levels made out of 500x20x500 areas, we'll know!

Signing Off

Another hot day in Wales today, and now we've been invaded by flies. It's gone midnight here and I'm stripped to the waste typing code and blog, and each time the fly lands on me and crawls about I wish I had the moral blind-spot to squash the little git. Alas the only bugs I squash are the ones of my own making, so hopefully I can negotiate a truce with the fly and split the office down the middle. He (or her) can have the top half of the office :)

Wednesday should see more segment editing refinement so we can get back to where we w[h]ere, and hopefully segment art, textures and shaders are winging their way to me which will form the filling of my super cool deferred shader sandwich. Our concerns during the prototype stage will be performance, performance and not forgetting, performance.

Không có nhận xét nào:

Đăng nhận xét