public void DebugLoadBsp(TagFileName name)
 {
     m_activeBsp = new TagBsp();
     m_activeBsp.LoadTagBuffer(name);
     m_activeBsp.LoadTagData();
     SetPreviewMode(PreviewMode.Bsp);
     MdxRender.SetZbufRange(30.0f, 300.0f);
     MdxRender.Camera.UpdateCameraByCentroid(m_activeBsp.m_BoundingBox);
 }
        static public void LoadBsp(TagFileName bsp_tfn, TagFileName sky_tfn)
        {
            if (bsp_tfn.Version == MapfileVersion.XHALO2)
            {
                Halo1_Bsp = null;
                //TODO: load Halo2 bsp
            }
            else
            {
                if (sky_tfn != null)
                {
                    int index = MdxRender.MM.RegisterModel(sky_tfn);
                    MdxRender.SkyBox = MdxRender.MM.GetModel(index);
                }
                //TODO: null out Halo2 bsp, clean up old resources

                Halo1_Bsp = new TagBsp();
                Halo1_Bsp.LoadTagBuffer(bsp_tfn);
                Halo1_Bsp.LoadTagData();
                MdxRender.Camera.UpdateCameraByCentroid(Halo1_Bsp.m_BoundingBox);
            }
        }