BitmapManager: Small fixes and a demo/test project.