Files
kraken/KREngine/kraken/KRLODGroup.h
Kearwood Gilbert 8a1164c44f - Implemented methods for determining amount of scene that has streamed in. (KRScene::getStreamLevel, KRNode::getStreamLevel, KRModel::getStreamLevel, KRMaterial::getStreamLevel, and KRTexture::getStreamLevel
- Implemented connection between LOD groups and texture streaming, which delays the switch to a new LOD group until the required textures have completed streaming in.
- Corrected bug in KRMaterial that resulted in reflection cube texture names being formatted incorrectly in the mtl file
- Scene graph now requires that lod_group nodes only be contained within lod_set nodes.
- Scene graph  group nodes that do not have a LOD minimum or maximum distance are now stored as "node" rather than as "lod_group" nodes.
- IMPORTANT!  Scenes exported with this version will not be backwards compatible with earlier versions due to the requirement of lod_set nodes.

--HG--
branch : nfb
extra : rebase_source : 1ff640b85338a794841ebbb2bf0087306ff59143
2014-03-10 22:32:49 -07:00

44 lines
1.1 KiB
C++

//
// KRLODGroup.h
// KREngine
//
// Created by Kearwood Gilbert on 2012-12-06.
// Copyright (c) 2012 Kearwood Software. All rights reserved.
//
#ifndef KRLODGROUP_H
#define KRLODGROUP_H
#include "KRResource.h"
#include "KRNode.h"
class KRLODGroup : public KRNode {
public:
KRLODGroup(KRScene &scene, std::string name);
virtual ~KRLODGroup();
virtual std::string getElementName();
virtual tinyxml2::XMLElement *saveXML( tinyxml2::XMLNode *parent);
virtual void loadXML(tinyxml2::XMLElement *e);
float getMinDistance();
float getMaxDistance();
void setMinDistance(float min_distance);
void setMaxDistance(float max_distance);
const KRAABB &getReference() const;
void setReference(const KRAABB &reference);
void setUseWorldUnits(bool use_world_units);
bool getUseWorldUnits() const;
bool getLODVisibility(const KRViewport &viewport);
private:
float m_min_distance;
float m_max_distance;
KRAABB m_reference; // Point of reference, used for distance calculation. Usually set to the bounding box center
bool m_use_world_units;
};
#endif