Added: 1 year ago
From: handkor
Views: 1,959
Sort by time | Sort by thread (beta)

Link to this comment:

Share to:

All Comments (10)

Sign In or Sign Up now to post a comment!
  • thankyou! what a time saver. i was thinking about making the octree with models, actual cubes in modeling software but that would be more of a hassle wouldn't it? i heard of a guy who made them like that. what do you think would be the simplest way? (kiss principle)

  • @mazdaplz I create a simplified model of my world and throw it's triangles into my octree, automatically generating it. Then I query the nodes and test against those surfaces.

  • @handkor

    my question was actually about what you used to partition the space into nodes in the first place, apparently you used boundingboxes.. yeah im THAT dumb xD

  • This is probably a really noobish question (never used XNA before, but want to start because I have some really interesting ideas for games), but what is an octree?

  • @TheFXGuy It's a useful way of dividing your world into cubes organizing those divisions in a tree structure.

    Take the volume of your world and then cut it up in 8 sections. Now take one of those sections and cut it up in 8 again. Keep going until each section holds a very small number of elements from your world.

    With this you can then test for objects in proximity by only looking at cube sections that are next to your player instead of testing the whole world.

  • Very interesting stuff, very complicated! But interesting. : )

  • Too neat-o. Is this something that will be released or are you just sharing the awesome?  The only other decent octree implementation is the ziggyware one and it's kind of large, so I'm sure a lot of people would be interested.

  • @MrCaravaggio I was just showing my current progress. Once I clean it up I could post the octree class.

  • @MrCaravaggio Added link to my octree class in description.

Loading...
Alert icon
0 / 00Unsaved Playlist Return to active list
    1. Your queue is empty. Add videos to your queue using this button:
      or sign in to load a different list.
    Loading...Loading...Saving...
    • Clear all videos from this list
    • Learn more