<body><script type="text/javascript"> function setAttributeOnload(object, attribute, val) { if(window.addEventListener) { window.addEventListener('load', function(){ object[attribute] = val; }, false); } else { window.attachEvent('onload', function(){ object[attribute] = val; }); } } </script> <div id="navbar-iframe-container"></div> <script type="text/javascript" src="https://apis.google.com/js/platform.js"></script> <script type="text/javascript"> gapi.load("gapi.iframes:gapi.iframes.style.bubble", function() { if (gapi.iframes && gapi.iframes.getContext) { gapi.iframes.getContext().openChild({ url: 'https://www.blogger.com/navbar.g?targetBlogID\x3d38891054\x26blogName\x3dXNA+Blog\x26publishMode\x3dPUBLISH_MODE_BLOGSPOT\x26navbarType\x3dBLACK\x26layoutType\x3dCLASSIC\x26searchRoot\x3dhttps://teksquares.blogspot.com/search\x26blogLocale\x3den_US\x26v\x3d2\x26homepageUrl\x3dhttp://teksquares.blogspot.com/\x26vt\x3d8569826428279047656', where: document.getElementById("navbar-iframe-container"), id: "navbar-iframe" }); } }); </script>

quadtree updated - 03112007

Here is my updated quadtree. This is only a very simple quadtree with the following features:
  • Able to create terrain from height map data.
  • Able to define the subdivision levels you want.
  • Able to draw only parts of the quadtree you want.
  • Only uses lines to draw the tree since adding texture will complicate things.



[Entire part of the quadtree is drawn]



[Certain part of the quadtree is drawn]

You can download the full source code here.


Next up, i'll add the following things on my quadtree:

  • Textured terrain
  • Be able to easily add models
  • Be able to cull the parts of the quadtree that is visible to the camera.

Labels: ,

“quadtree updated - 03112007”

  1. Blogger Unknown Says:

    The link is for the code is not working.