restore the logic to switch between gpu lod and cpu lod depending on DX feature level.
Add some code to cleanup undisposed textures and buffers