OSX Version of Kraken and importer now compiling again.
This commit is contained in:
@@ -318,7 +318,7 @@
|
|||||||
E4EC73C11720B1FF0065299F /* KRVector4.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E4EC73BF1720B1FF0065299F /* KRVector4.cpp */; };
|
E4EC73C11720B1FF0065299F /* KRVector4.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E4EC73BF1720B1FF0065299F /* KRVector4.cpp */; };
|
||||||
E4EC73C21720B1FF0065299F /* KRVector4.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E4EC73BF1720B1FF0065299F /* KRVector4.cpp */; };
|
E4EC73C21720B1FF0065299F /* KRVector4.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E4EC73BF1720B1FF0065299F /* KRVector4.cpp */; };
|
||||||
E4EC73C31720B1FF0065299F /* KRVector4.h in Headers */ = {isa = PBXBuildFile; fileRef = E4EC73C01720B1FF0065299F /* KRVector4.h */; };
|
E4EC73C31720B1FF0065299F /* KRVector4.h in Headers */ = {isa = PBXBuildFile; fileRef = E4EC73C01720B1FF0065299F /* KRVector4.h */; };
|
||||||
E4EC73C41720B1FF0065299F /* KRVector4.h in Headers */ = {isa = PBXBuildFile; fileRef = E4EC73C01720B1FF0065299F /* KRVector4.h */; };
|
E4EC73C41720B1FF0065299F /* KRVector4.h in Headers */ = {isa = PBXBuildFile; fileRef = E4EC73C01720B1FF0065299F /* KRVector4.h */; settings = {ATTRIBUTES = (Public, ); }; };
|
||||||
E4F027C716979CCD00D4427D /* KRAudioManager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E4F027C516979CCD00D4427D /* KRAudioManager.cpp */; };
|
E4F027C716979CCD00D4427D /* KRAudioManager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E4F027C516979CCD00D4427D /* KRAudioManager.cpp */; };
|
||||||
E4F027C816979CCD00D4427D /* KRAudioManager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E4F027C516979CCD00D4427D /* KRAudioManager.cpp */; };
|
E4F027C816979CCD00D4427D /* KRAudioManager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E4F027C516979CCD00D4427D /* KRAudioManager.cpp */; };
|
||||||
E4F027C916979CCD00D4427D /* KRAudioManager.h in Headers */ = {isa = PBXBuildFile; fileRef = E4F027C616979CCD00D4427D /* KRAudioManager.h */; settings = {ATTRIBUTES = (Public, ); }; };
|
E4F027C916979CCD00D4427D /* KRAudioManager.h in Headers */ = {isa = PBXBuildFile; fileRef = E4F027C616979CCD00D4427D /* KRAudioManager.h */; settings = {ATTRIBUTES = (Public, ); }; };
|
||||||
@@ -406,15 +406,15 @@
|
|||||||
E42CB1EF158446AB0066E0D8 /* KRQuaternion.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = KRQuaternion.cpp; sourceTree = "<group>"; };
|
E42CB1EF158446AB0066E0D8 /* KRQuaternion.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = KRQuaternion.cpp; sourceTree = "<group>"; };
|
||||||
E4324BA316444C0D0043185B /* KRParticleSystem.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KRParticleSystem.h; sourceTree = "<group>"; };
|
E4324BA316444C0D0043185B /* KRParticleSystem.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KRParticleSystem.h; sourceTree = "<group>"; };
|
||||||
E4324BA716444C230043185B /* KRParticleSystem.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = KRParticleSystem.cpp; sourceTree = "<group>"; };
|
E4324BA716444C230043185B /* KRParticleSystem.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = KRParticleSystem.cpp; sourceTree = "<group>"; };
|
||||||
E4324BAA16444DEF0043185B /* KRParticleSystemNewtonian.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KRParticleSystemNewtonian.h; sourceTree = "<group>"; };
|
E4324BAA16444DEF0043185B /* KRParticleSystemNewtonian.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; lineEnding = 0; path = KRParticleSystemNewtonian.h; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.objcpp; };
|
||||||
E4324BAD16444E120043185B /* KRParticleSystemNewtonian.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = KRParticleSystemNewtonian.cpp; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.cpp; };
|
E4324BAD16444E120043185B /* KRParticleSystemNewtonian.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = KRParticleSystemNewtonian.cpp; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.cpp; };
|
||||||
E437849716C488360037FD43 /* hrtf_kemar.krbundle */ = {isa = PBXFileReference; lastKnownFileType = file; path = hrtf_kemar.krbundle; sourceTree = "<group>"; };
|
E437849716C488360037FD43 /* hrtf_kemar.krbundle */ = {isa = PBXFileReference; lastKnownFileType = file; path = hrtf_kemar.krbundle; sourceTree = "<group>"; };
|
||||||
E43B0AD415DDCA0C00A5CB9F /* KRContextObject.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = KRContextObject.cpp; sourceTree = "<group>"; };
|
E43B0AD415DDCA0C00A5CB9F /* KRContextObject.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = KRContextObject.cpp; sourceTree = "<group>"; };
|
||||||
E43B0AD515DDCA0D00A5CB9F /* KRContextObject.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KRContextObject.h; sourceTree = "<group>"; };
|
E43B0AD515DDCA0D00A5CB9F /* KRContextObject.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KRContextObject.h; sourceTree = "<group>"; };
|
||||||
E44F38231683B22C00399B5D /* KRRenderSettings.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KRRenderSettings.h; sourceTree = "<group>"; };
|
E44F38231683B22C00399B5D /* KRRenderSettings.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KRRenderSettings.h; sourceTree = "<group>"; };
|
||||||
E44F38271683B24400399B5D /* KRRenderSettings.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = KRRenderSettings.cpp; sourceTree = "<group>"; };
|
E44F38271683B24400399B5D /* KRRenderSettings.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = KRRenderSettings.cpp; sourceTree = "<group>"; };
|
||||||
E450273716E0491D00FDEC5C /* KRReverbZone.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = KRReverbZone.cpp; sourceTree = "<group>"; };
|
E450273716E0491D00FDEC5C /* KRReverbZone.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = KRReverbZone.cpp; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.cpp; };
|
||||||
E450273816E0491D00FDEC5C /* KRReverbZone.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KRReverbZone.h; sourceTree = "<group>"; };
|
E450273816E0491D00FDEC5C /* KRReverbZone.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; lineEnding = 0; path = KRReverbZone.h; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.objcpp; };
|
||||||
E459040316C30CC5002B00A0 /* AudioUnit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AudioUnit.framework; path = Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk/System/Library/Frameworks/AudioUnit.framework; sourceTree = DEVELOPER_DIR; };
|
E459040316C30CC5002B00A0 /* AudioUnit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AudioUnit.framework; path = Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk/System/Library/Frameworks/AudioUnit.framework; sourceTree = DEVELOPER_DIR; };
|
||||||
E459040516C30CD9002B00A0 /* AudioUnit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AudioUnit.framework; path = System/Library/Frameworks/AudioUnit.framework; sourceTree = SDKROOT; };
|
E459040516C30CD9002B00A0 /* AudioUnit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AudioUnit.framework; path = System/Library/Frameworks/AudioUnit.framework; sourceTree = SDKROOT; };
|
||||||
E460292516681CFE00261BB9 /* KRTextureAnimated.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KRTextureAnimated.h; sourceTree = "<group>"; };
|
E460292516681CFE00261BB9 /* KRTextureAnimated.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KRTextureAnimated.h; sourceTree = "<group>"; };
|
||||||
@@ -443,7 +443,7 @@
|
|||||||
E47C25A413F4F66F00FF4370 /* KRShader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; lineEnding = 0; path = KRShader.h; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.objcpp; };
|
E47C25A413F4F66F00FF4370 /* KRShader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; lineEnding = 0; path = KRShader.h; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.objcpp; };
|
||||||
E47C25A613F4F6AB00FF4370 /* KRShaderManager.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = KRShaderManager.cpp; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.cpp; };
|
E47C25A613F4F6AB00FF4370 /* KRShaderManager.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = KRShaderManager.cpp; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.cpp; };
|
||||||
E47C25A813F4F6DD00FF4370 /* KRShader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = KRShader.cpp; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.cpp; };
|
E47C25A813F4F6DD00FF4370 /* KRShader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = KRShader.cpp; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.cpp; };
|
||||||
E480BE671671C641004EC8AD /* KRBone.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KRBone.h; sourceTree = "<group>"; };
|
E480BE671671C641004EC8AD /* KRBone.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; lineEnding = 0; path = KRBone.h; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.objcpp; };
|
||||||
E480BE6B1671C653004EC8AD /* KRBone.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = KRBone.cpp; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.cpp; };
|
E480BE6B1671C653004EC8AD /* KRBone.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = KRBone.cpp; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.cpp; };
|
||||||
E488399215F928CA00BD66D5 /* KRBundle.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = KRBundle.cpp; sourceTree = "<group>"; };
|
E488399215F928CA00BD66D5 /* KRBundle.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = KRBundle.cpp; sourceTree = "<group>"; };
|
||||||
E488399315F928CA00BD66D5 /* KRBundle.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KRBundle.h; sourceTree = "<group>"; };
|
E488399315F928CA00BD66D5 /* KRBundle.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KRBundle.h; sourceTree = "<group>"; };
|
||||||
@@ -452,7 +452,7 @@
|
|||||||
E48B3CBC14393DF5000C50E2 /* KRCamera.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; lineEnding = 0; path = KRCamera.h; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.objcpp; };
|
E48B3CBC14393DF5000C50E2 /* KRCamera.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; lineEnding = 0; path = KRCamera.h; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.objcpp; };
|
||||||
E48B3CBF14393E2F000C50E2 /* KRCamera.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = KRCamera.cpp; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.cpp; };
|
E48B3CBF14393E2F000C50E2 /* KRCamera.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = KRCamera.cpp; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.cpp; };
|
||||||
E48B68131697794F00D99917 /* KRAudioSource.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = KRAudioSource.cpp; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.cpp; };
|
E48B68131697794F00D99917 /* KRAudioSource.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = KRAudioSource.cpp; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.cpp; };
|
||||||
E48B68141697794F00D99917 /* KRAudioSource.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KRAudioSource.h; sourceTree = "<group>"; };
|
E48B68141697794F00D99917 /* KRAudioSource.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; lineEnding = 0; path = KRAudioSource.h; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.objcpp; };
|
||||||
E48C696E15374F5A00232E28 /* KRContext.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; lineEnding = 0; path = KRContext.h; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.objcpp; };
|
E48C696E15374F5A00232E28 /* KRContext.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; lineEnding = 0; path = KRContext.h; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.objcpp; };
|
||||||
E48C697115374F7E00232E28 /* KRContext.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = KRContext.cpp; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.cpp; };
|
E48C697115374F7E00232E28 /* KRContext.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; lineEnding = 0; path = KRContext.cpp; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.cpp; };
|
||||||
E491016113C99B9E0098455B /* libkraken.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libkraken.a; sourceTree = BUILT_PRODUCTS_DIR; };
|
E491016113C99B9E0098455B /* libkraken.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libkraken.a; sourceTree = BUILT_PRODUCTS_DIR; };
|
||||||
@@ -1302,10 +1302,10 @@
|
|||||||
E450273C16E0491D00FDEC5C /* KRReverbZone.h in Headers */,
|
E450273C16E0491D00FDEC5C /* KRReverbZone.h in Headers */,
|
||||||
E44F38251683B23000399B5D /* KRRenderSettings.h in Headers */,
|
E44F38251683B23000399B5D /* KRRenderSettings.h in Headers */,
|
||||||
E499BF1D16AE74FF007FCDBE /* KRTextureAnimated.h in Headers */,
|
E499BF1D16AE74FF007FCDBE /* KRTextureAnimated.h in Headers */,
|
||||||
|
E4EC73C41720B1FF0065299F /* KRVector4.h in Headers */,
|
||||||
E4AE63601704FB0A00B460CD /* KRLODGroup.h in Headers */,
|
E4AE63601704FB0A00B460CD /* KRLODGroup.h in Headers */,
|
||||||
E499BF1F16AE753E007FCDBE /* KRCollider.h in Headers */,
|
E499BF1F16AE753E007FCDBE /* KRCollider.h in Headers */,
|
||||||
E499BF2316AE7636007FCDBE /* kraken-prefix.pch in Headers */,
|
E499BF2316AE7636007FCDBE /* kraken-prefix.pch in Headers */,
|
||||||
E4EC73C41720B1FF0065299F /* KRVector4.h in Headers */,
|
|
||||||
);
|
);
|
||||||
runOnlyForDeploymentPostprocessing = 0;
|
runOnlyForDeploymentPostprocessing = 0;
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -61,8 +61,8 @@ namespace std {
|
|||||||
public:
|
public:
|
||||||
size_t operator()(const KRAABB &s) const
|
size_t operator()(const KRAABB &s) const
|
||||||
{
|
{
|
||||||
size_t h1 = std::hash<KRVector3>()(s.min);
|
size_t h1 = hash<KRVector3>()(s.min);
|
||||||
size_t h2 = std::hash<KRVector3>()(s.max);
|
size_t h2 = hash<KRVector3>()(s.max);
|
||||||
return h1 ^ ( h2 << 1 );
|
return h1 ^ ( h2 << 1 );
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -47,7 +47,7 @@ KRAnimation::KRAnimation(KRContext &context, std::string name) : KRResource(cont
|
|||||||
}
|
}
|
||||||
KRAnimation::~KRAnimation()
|
KRAnimation::~KRAnimation()
|
||||||
{
|
{
|
||||||
for(std::unordered_map<std::string, KRAnimationLayer *>::iterator itr = m_layers.begin(); itr != m_layers.end(); ++itr){
|
for(unordered_map<std::string, KRAnimationLayer *>::iterator itr = m_layers.begin(); itr != m_layers.end(); ++itr){
|
||||||
delete (*itr).second;
|
delete (*itr).second;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -69,7 +69,7 @@ bool KRAnimation::save(KRDataBlock &data) {
|
|||||||
animation_node->SetAttribute("auto_play", m_auto_play ? "true" : "false");
|
animation_node->SetAttribute("auto_play", m_auto_play ? "true" : "false");
|
||||||
animation_node->SetAttribute("duration", m_duration);
|
animation_node->SetAttribute("duration", m_duration);
|
||||||
|
|
||||||
for(std::unordered_map<std::string, KRAnimationLayer *>::iterator itr = m_layers.begin(); itr != m_layers.end(); ++itr){
|
for(unordered_map<std::string, KRAnimationLayer *>::iterator itr = m_layers.begin(); itr != m_layers.end(); ++itr){
|
||||||
(*itr).second->saveXML(animation_node);
|
(*itr).second->saveXML(animation_node);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -120,7 +120,7 @@ KRAnimation *KRAnimation::Load(KRContext &context, const std::string &name, KRDa
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
std::unordered_map<std::string, KRAnimationLayer *> &KRAnimation::getLayers()
|
unordered_map<std::string, KRAnimationLayer *> &KRAnimation::getLayers()
|
||||||
{
|
{
|
||||||
return m_layers;
|
return m_layers;
|
||||||
}
|
}
|
||||||
@@ -139,7 +139,7 @@ void KRAnimation::update(float deltaTime)
|
|||||||
m_local_time -= m_duration;
|
m_local_time -= m_duration;
|
||||||
}
|
}
|
||||||
|
|
||||||
for(std::unordered_map<std::string, KRAnimationLayer *>::iterator layer_itr = m_layers.begin(); layer_itr != m_layers.end(); layer_itr++) {
|
for(unordered_map<std::string, KRAnimationLayer *>::iterator layer_itr = m_layers.begin(); layer_itr != m_layers.end(); layer_itr++) {
|
||||||
KRAnimationLayer *layer = (*layer_itr).second;
|
KRAnimationLayer *layer = (*layer_itr).second;
|
||||||
for(std::vector<KRAnimationAttribute *>::iterator attribute_itr = layer->getAttributes().begin(); attribute_itr != layer->getAttributes().end(); attribute_itr++) {
|
for(std::vector<KRAnimationAttribute *>::iterator attribute_itr = layer->getAttributes().begin(); attribute_itr != layer->getAttributes().end(); attribute_itr++) {
|
||||||
KRAnimationAttribute *attribute = *attribute_itr;
|
KRAnimationAttribute *attribute = *attribute_itr;
|
||||||
|
|||||||
@@ -51,7 +51,7 @@ public:
|
|||||||
static KRAnimation *Load(KRContext &context, const std::string &name, KRDataBlock *data);
|
static KRAnimation *Load(KRContext &context, const std::string &name, KRDataBlock *data);
|
||||||
|
|
||||||
void addLayer(KRAnimationLayer *layer);
|
void addLayer(KRAnimationLayer *layer);
|
||||||
std::unordered_map<std::string, KRAnimationLayer *> &getLayers();
|
unordered_map<std::string, KRAnimationLayer *> &getLayers();
|
||||||
KRAnimationLayer *getLayer(const char *szName);
|
KRAnimationLayer *getLayer(const char *szName);
|
||||||
void Play();
|
void Play();
|
||||||
void Stop();
|
void Stop();
|
||||||
@@ -62,7 +62,7 @@ public:
|
|||||||
void setDuration(float duration);
|
void setDuration(float duration);
|
||||||
bool isPlaying();
|
bool isPlaying();
|
||||||
private:
|
private:
|
||||||
std::unordered_map<std::string, KRAnimationLayer *> m_layers;
|
unordered_map<std::string, KRAnimationLayer *> m_layers;
|
||||||
bool m_auto_play;
|
bool m_auto_play;
|
||||||
bool m_loop;
|
bool m_loop;
|
||||||
bool m_playing;
|
bool m_playing;
|
||||||
|
|||||||
@@ -53,7 +53,7 @@ KRAnimationCurve *KRAnimationCurveManager::getAnimationCurve(const char *szName)
|
|||||||
return m_animationCurves[szName];
|
return m_animationCurves[szName];
|
||||||
}
|
}
|
||||||
|
|
||||||
std::unordered_map<std::string, KRAnimationCurve *> &KRAnimationCurveManager::getAnimationCurves() {
|
unordered_map<std::string, KRAnimationCurve *> &KRAnimationCurveManager::getAnimationCurves() {
|
||||||
return m_animationCurves;
|
return m_animationCurves;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -48,7 +48,7 @@ public:
|
|||||||
KRAnimationCurve *loadAnimationCurve(const char *szName, KRDataBlock *data);
|
KRAnimationCurve *loadAnimationCurve(const char *szName, KRDataBlock *data);
|
||||||
KRAnimationCurve *getAnimationCurve(const char *szName);
|
KRAnimationCurve *getAnimationCurve(const char *szName);
|
||||||
void addAnimationCurve(KRAnimationCurve *new_animation_curve);
|
void addAnimationCurve(KRAnimationCurve *new_animation_curve);
|
||||||
std::unordered_map<std::string, KRAnimationCurve *> &getAnimationCurves();
|
unordered_map<std::string, KRAnimationCurve *> &getAnimationCurves();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
unordered_map<std::string, KRAnimationCurve *> m_animationCurves;
|
unordered_map<std::string, KRAnimationCurve *> m_animationCurves;
|
||||||
|
|||||||
@@ -67,7 +67,7 @@ KRAnimation *KRAnimationManager::getAnimation(const char *szName) {
|
|||||||
return m_animations[szName];
|
return m_animations[szName];
|
||||||
}
|
}
|
||||||
|
|
||||||
std::unordered_map<std::string, KRAnimation *> &KRAnimationManager::getAnimations() {
|
unordered_map<std::string, KRAnimation *> &KRAnimationManager::getAnimations() {
|
||||||
return m_animations;
|
return m_animations;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -212,7 +212,7 @@ void KRAudioManager::renderReverbImpulseResponse(int impulse_response_offset, in
|
|||||||
int impulse_response_channels = 2;
|
int impulse_response_channels = 2;
|
||||||
for(int channel=0; channel < impulse_response_channels; channel++) {
|
for(int channel=0; channel < impulse_response_channels; channel++) {
|
||||||
bool first_sample = true;
|
bool first_sample = true;
|
||||||
for(std::unordered_map<std::string, siren_reverb_zone_weight_info>::iterator zone_itr=m_reverb_zone_weights.begin(); zone_itr != m_reverb_zone_weights.end(); zone_itr++) {
|
for(unordered_map<std::string, siren_reverb_zone_weight_info>::iterator zone_itr=m_reverb_zone_weights.begin(); zone_itr != m_reverb_zone_weights.end(); zone_itr++) {
|
||||||
siren_reverb_zone_weight_info zi = (*zone_itr).second;
|
siren_reverb_zone_weight_info zi = (*zone_itr).second;
|
||||||
if(zi.reverb_sample) {
|
if(zi.reverb_sample) {
|
||||||
if(impulse_response_offset < zi.reverb_sample->getFrameCount()) { // Optimization - when mixing multiple impulse responses (i.e. fading between reverb zones), do not process blocks past the end of a shorter impulse response sample when they differ in length
|
if(impulse_response_offset < zi.reverb_sample->getFrameCount()) { // Optimization - when mixing multiple impulse responses (i.e. fading between reverb zones), do not process blocks past the end of a shorter impulse response sample when they differ in length
|
||||||
@@ -264,7 +264,7 @@ void KRAudioManager::renderReverb()
|
|||||||
if(&source->getScene() == m_listener_scene) {
|
if(&source->getScene() == m_listener_scene) {
|
||||||
float containment_factor = 0.0f;
|
float containment_factor = 0.0f;
|
||||||
|
|
||||||
for(std::unordered_map<std::string, siren_reverb_zone_weight_info>::iterator zone_itr=m_reverb_zone_weights.begin(); zone_itr != m_reverb_zone_weights.end(); zone_itr++) {
|
for(unordered_map<std::string, siren_reverb_zone_weight_info>::iterator zone_itr=m_reverb_zone_weights.begin(); zone_itr != m_reverb_zone_weights.end(); zone_itr++) {
|
||||||
siren_reverb_zone_weight_info zi = (*zone_itr).second;
|
siren_reverb_zone_weight_info zi = (*zone_itr).second;
|
||||||
float gain = zi.weight * zi.reverb_zone->getReverbGain() * zi.reverb_zone->getContainment(source->getWorldTranslation());
|
float gain = zi.weight * zi.reverb_zone->getReverbGain() * zi.reverb_zone->getContainment(source->getWorldTranslation());
|
||||||
if(gain > containment_factor) containment_factor = gain;
|
if(gain > containment_factor) containment_factor = gain;
|
||||||
@@ -283,7 +283,7 @@ void KRAudioManager::renderReverb()
|
|||||||
// KRAudioSample *impulse_response = getContext().getAudioManager()->get("hrtf_kemar_H10e040a");
|
// KRAudioSample *impulse_response = getContext().getAudioManager()->get("hrtf_kemar_H10e040a");
|
||||||
|
|
||||||
int impulse_response_blocks = 0;
|
int impulse_response_blocks = 0;
|
||||||
for(std::unordered_map<std::string, siren_reverb_zone_weight_info>::iterator zone_itr=m_reverb_zone_weights.begin(); zone_itr != m_reverb_zone_weights.end(); zone_itr++) {
|
for(unordered_map<std::string, siren_reverb_zone_weight_info>::iterator zone_itr=m_reverb_zone_weights.begin(); zone_itr != m_reverb_zone_weights.end(); zone_itr++) {
|
||||||
siren_reverb_zone_weight_info zi = (*zone_itr).second;
|
siren_reverb_zone_weight_info zi = (*zone_itr).second;
|
||||||
if(zi.reverb_sample) {
|
if(zi.reverb_sample) {
|
||||||
int zone_sample_blocks = zi.reverb_sample->getFrameCount() / KRENGINE_AUDIO_BLOCK_LENGTH + 1;
|
int zone_sample_blocks = zi.reverb_sample->getFrameCount() / KRENGINE_AUDIO_BLOCK_LENGTH + 1;
|
||||||
@@ -1540,8 +1540,8 @@ void KRAudioManager::startFrame(float deltaTime)
|
|||||||
|
|
||||||
// Click Removal - Add ramping of gain changes for audio sources that are continuing to play
|
// Click Removal - Add ramping of gain changes for audio sources that are continuing to play
|
||||||
float gain_anticlick = 0.0f;
|
float gain_anticlick = 0.0f;
|
||||||
std::pair<std::unordered_multimap<KRVector2, std::pair<KRAudioSource *, std::pair<float, float> > >::iterator, std::unordered_multimap<KRVector2, std::pair<KRAudioSource *, std::pair<float, float> > >::iterator> prev_range = m_prev_mapped_sources.equal_range(adjusted_source_dir);
|
std::pair<unordered_multimap<KRVector2, std::pair<KRAudioSource *, std::pair<float, float> > >::iterator, unordered_multimap<KRVector2, std::pair<KRAudioSource *, std::pair<float, float> > >::iterator> prev_range = m_prev_mapped_sources.equal_range(adjusted_source_dir);
|
||||||
for(std::unordered_multimap<KRVector2, std::pair<KRAudioSource *, std::pair<float, float> > >::iterator prev_itr=prev_range.first; prev_itr != prev_range.second; prev_itr++) {
|
for(unordered_multimap<KRVector2, std::pair<KRAudioSource *, std::pair<float, float> > >::iterator prev_itr=prev_range.first; prev_itr != prev_range.second; prev_itr++) {
|
||||||
if( (*prev_itr).second.first == source) {
|
if( (*prev_itr).second.first == source) {
|
||||||
gain_anticlick = (*prev_itr).second.second.second;
|
gain_anticlick = (*prev_itr).second.second.second;
|
||||||
break;
|
break;
|
||||||
@@ -1553,7 +1553,7 @@ void KRAudioManager::startFrame(float deltaTime)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Click Removal - Map audio sources for ramp-down of gain for audio sources that have been squelched by attenuation
|
// Click Removal - Map audio sources for ramp-down of gain for audio sources that have been squelched by attenuation
|
||||||
for(std::unordered_multimap<KRVector2, std::pair<KRAudioSource *, std::pair<float, float> > >::iterator itr=m_prev_mapped_sources.begin(); itr != m_prev_mapped_sources.end(); itr++) {
|
for(unordered_multimap<KRVector2, std::pair<KRAudioSource *, std::pair<float, float> > >::iterator itr=m_prev_mapped_sources.begin(); itr != m_prev_mapped_sources.end(); itr++) {
|
||||||
|
|
||||||
KRAudioSource *source = (*itr).second.first;
|
KRAudioSource *source = (*itr).second.first;
|
||||||
float source_prev_gain = (*itr).second.second.second;
|
float source_prev_gain = (*itr).second.second.second;
|
||||||
@@ -1561,9 +1561,9 @@ void KRAudioManager::startFrame(float deltaTime)
|
|||||||
// Only create ramp-down channels for 3d sources that have been squelched by attenuation; this is not necessary if the sample has completed playing
|
// Only create ramp-down channels for 3d sources that have been squelched by attenuation; this is not necessary if the sample has completed playing
|
||||||
KRVector2 source_position = (*itr).first;
|
KRVector2 source_position = (*itr).first;
|
||||||
|
|
||||||
std::pair<std::unordered_multimap<KRVector2, std::pair<KRAudioSource *, std::pair<float, float> > >::iterator, std::unordered_multimap<KRVector2, std::pair<KRAudioSource *, std::pair<float, float> > >::iterator> new_range = m_mapped_sources.equal_range(source_position);
|
std::pair<unordered_multimap<KRVector2, std::pair<KRAudioSource *, std::pair<float, float> > >::iterator, unordered_multimap<KRVector2, std::pair<KRAudioSource *, std::pair<float, float> > >::iterator> new_range = m_mapped_sources.equal_range(source_position);
|
||||||
bool already_merged = false;
|
bool already_merged = false;
|
||||||
for(std::unordered_multimap<KRVector2, std::pair<KRAudioSource *, std::pair<float, float> > >::iterator new_itr=new_range.first; new_itr != new_range.second; new_itr++) {
|
for(unordered_multimap<KRVector2, std::pair<KRAudioSource *, std::pair<float, float> > >::iterator new_itr=new_range.first; new_itr != new_range.second; new_itr++) {
|
||||||
if( (*new_itr).second.first == source) {
|
if( (*new_itr).second.first == source) {
|
||||||
already_merged = true;
|
already_merged = true;
|
||||||
break;
|
break;
|
||||||
@@ -1588,7 +1588,7 @@ void KRAudioManager::renderAmbient()
|
|||||||
int output_offset = (m_output_accumulation_block_start) % (KRENGINE_REVERB_MAX_SAMPLES * KRENGINE_MAX_OUTPUT_CHANNELS);
|
int output_offset = (m_output_accumulation_block_start) % (KRENGINE_REVERB_MAX_SAMPLES * KRENGINE_MAX_OUTPUT_CHANNELS);
|
||||||
float *buffer = m_workspace[0].realp;
|
float *buffer = m_workspace[0].realp;
|
||||||
|
|
||||||
for(std::unordered_map<std::string, siren_ambient_zone_weight_info>::iterator zone_itr=m_ambient_zone_weights.begin(); zone_itr != m_ambient_zone_weights.end(); zone_itr++) {
|
for(unordered_map<std::string, siren_ambient_zone_weight_info>::iterator zone_itr=m_ambient_zone_weights.begin(); zone_itr != m_ambient_zone_weights.end(); zone_itr++) {
|
||||||
siren_ambient_zone_weight_info zi = (*zone_itr).second;
|
siren_ambient_zone_weight_info zi = (*zone_itr).second;
|
||||||
float gain = (*zone_itr).second.weight * zi.ambient_zone->getAmbientGain() * m_global_ambient_gain * m_global_gain;
|
float gain = (*zone_itr).second.weight * zi.ambient_zone->getAmbientGain() * m_global_ambient_gain * m_global_gain;
|
||||||
|
|
||||||
@@ -1618,7 +1618,7 @@ void KRAudioManager::renderHRTF()
|
|||||||
for(int channel=0; channel<impulse_response_channels; channel++) {
|
for(int channel=0; channel<impulse_response_channels; channel++) {
|
||||||
|
|
||||||
bool first_source = true;
|
bool first_source = true;
|
||||||
std::unordered_multimap<KRVector2, std::pair<KRAudioSource *, std::pair<float, float> > >::iterator itr=m_mapped_sources.begin();
|
unordered_multimap<KRVector2, std::pair<KRAudioSource *, std::pair<float, float> > >::iterator itr=m_mapped_sources.begin();
|
||||||
while(itr != m_mapped_sources.end()) {
|
while(itr != m_mapped_sources.end()) {
|
||||||
// Batch together sound sources that are emitted from the same direction
|
// Batch together sound sources that are emitted from the same direction
|
||||||
KRVector2 source_direction = (*itr).first;
|
KRVector2 source_direction = (*itr).first;
|
||||||
|
|||||||
@@ -207,17 +207,17 @@ private:
|
|||||||
DSPSplitComplex getHRTFSpectral(const KRVector2 &hrtf_dir, const int channel);
|
DSPSplitComplex getHRTFSpectral(const KRVector2 &hrtf_dir, const int channel);
|
||||||
|
|
||||||
|
|
||||||
std::unordered_map<std::string, siren_ambient_zone_weight_info> m_ambient_zone_weights;
|
unordered_map<std::string, siren_ambient_zone_weight_info> m_ambient_zone_weights;
|
||||||
float m_ambient_zone_total_weight = 0.0f; // For normalizing zone weights
|
float m_ambient_zone_total_weight = 0.0f; // For normalizing zone weights
|
||||||
|
|
||||||
std::unordered_map<std::string, siren_reverb_zone_weight_info> m_reverb_zone_weights;
|
unordered_map<std::string, siren_reverb_zone_weight_info> m_reverb_zone_weights;
|
||||||
float m_reverb_zone_total_weight = 0.0f; // For normalizing zone weights
|
float m_reverb_zone_total_weight = 0.0f; // For normalizing zone weights
|
||||||
|
|
||||||
boost::signals2::mutex m_mutex;
|
boost::signals2::mutex m_mutex;
|
||||||
mach_timebase_info_data_t m_timebase_info;
|
mach_timebase_info_data_t m_timebase_info;
|
||||||
|
|
||||||
|
|
||||||
std::unordered_multimap<KRVector2, std::pair<KRAudioSource *, std::pair<float, float> > > m_mapped_sources, m_prev_mapped_sources;
|
unordered_multimap<KRVector2, std::pair<KRAudioSource *, std::pair<float, float> > > m_mapped_sources, m_prev_mapped_sources;
|
||||||
bool m_anticlick_block;
|
bool m_anticlick_block;
|
||||||
bool m_high_quality_hrtf; // If true, 4 HRTF samples will be interpolated; if false, the nearest HRTF sample will be used without interpolation
|
bool m_high_quality_hrtf; // If true, 4 HRTF samples will be interpolated; if false, the nearest HRTF sample will be used without interpolation
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -55,6 +55,6 @@ KRBundle *KRBundleManager::getBundle(const char *szName) {
|
|||||||
return m_bundles[szName];
|
return m_bundles[szName];
|
||||||
}
|
}
|
||||||
|
|
||||||
std::unordered_map<std::string, KRBundle *> KRBundleManager::getBundles() {
|
unordered_map<std::string, KRBundle *> KRBundleManager::getBundles() {
|
||||||
return m_bundles;
|
return m_bundles;
|
||||||
}
|
}
|
||||||
@@ -49,10 +49,10 @@ public:
|
|||||||
KRBundle *getBundle(const char *szName);
|
KRBundle *getBundle(const char *szName);
|
||||||
|
|
||||||
std::vector<std::string> getBundleNames();
|
std::vector<std::string> getBundleNames();
|
||||||
std::unordered_map<std::string, KRBundle *> getBundles();
|
unordered_map<std::string, KRBundle *> getBundles();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
std::unordered_map<std::string, KRBundle *> m_bundles;
|
unordered_map<std::string, KRBundle *> m_bundles;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif /* defined(KRBUNDLEMANAGER_H) */
|
#endif /* defined(KRBUNDLEMANAGER_H) */
|
||||||
|
|||||||
@@ -440,7 +440,7 @@ void KRCamera::renderFrame(float deltaTime, GLint renderBufferWidth, GLint rende
|
|||||||
KRShader *pVisShader = getContext().getShaderManager()->getShader("visualize_overlay", this, std::vector<KRPointLight *>(), std::vector<KRDirectionalLight *>(), std::vector<KRSpotLight *>(), 0, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, KRNode::RENDER_PASS_FORWARD_TRANSPARENT);
|
KRShader *pVisShader = getContext().getShaderManager()->getShader("visualize_overlay", this, std::vector<KRPointLight *>(), std::vector<KRDirectionalLight *>(), std::vector<KRSpotLight *>(), 0, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, KRNode::RENDER_PASS_FORWARD_TRANSPARENT);
|
||||||
|
|
||||||
m_pContext->getModelManager()->bindVBO((void *)KRENGINE_VBO_3D_CUBE, KRENGINE_VBO_3D_CUBE_SIZE, NULL, 0, true, false, false, false, false, false, false, true);
|
m_pContext->getModelManager()->bindVBO((void *)KRENGINE_VBO_3D_CUBE, KRENGINE_VBO_3D_CUBE_SIZE, NULL, 0, true, false, false, false, false, false, false, true);
|
||||||
for(std::unordered_map<KRAABB, int>::iterator itr=m_viewport.getVisibleBounds().begin(); itr != m_viewport.getVisibleBounds().end(); itr++) {
|
for(unordered_map<KRAABB, int>::iterator itr=m_viewport.getVisibleBounds().begin(); itr != m_viewport.getVisibleBounds().end(); itr++) {
|
||||||
KRMat4 matModel = KRMat4();
|
KRMat4 matModel = KRMat4();
|
||||||
matModel.scale((*itr).first.size() * 0.5f);
|
matModel.scale((*itr).first.size() * 0.5f);
|
||||||
matModel.translate((*itr).first.center());
|
matModel.translate((*itr).first.center());
|
||||||
|
|||||||
@@ -22,7 +22,23 @@ float const D2R = PI * 2 / 360;
|
|||||||
#include <set>
|
#include <set>
|
||||||
#include <list>
|
#include <list>
|
||||||
#include <map>
|
#include <map>
|
||||||
|
|
||||||
|
#if TARGET_OS_IPHONE
|
||||||
|
|
||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
|
using std::unordered_map;
|
||||||
|
using std::unordered_multimap;
|
||||||
|
using std::hash;
|
||||||
|
|
||||||
|
#else
|
||||||
|
|
||||||
|
#include <tr1/unordered_map>
|
||||||
|
using std::tr1::unordered_map;
|
||||||
|
using std::tr1::unordered_multimap;
|
||||||
|
using std::tr1::hash;
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
#include <stack>
|
#include <stack>
|
||||||
#include <queue>
|
#include <queue>
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
@@ -52,9 +68,9 @@ using std::string;
|
|||||||
using std::set;
|
using std::set;
|
||||||
using std::list;
|
using std::list;
|
||||||
using std::map;
|
using std::map;
|
||||||
using std::unordered_map;
|
|
||||||
using std::multimap;
|
using std::multimap;
|
||||||
using std::unordered_multimap;
|
|
||||||
using std::stack;
|
using std::stack;
|
||||||
using std::queue;
|
using std::queue;
|
||||||
|
|
||||||
|
|||||||
@@ -55,7 +55,7 @@ public:
|
|||||||
void configure(bool blend_enable, GLenum blend_src, GLenum blend_dest, bool depth_test_enable, GLenum depth_func, bool depth_write_enable);
|
void configure(bool blend_enable, GLenum blend_src, GLenum blend_dest, bool depth_test_enable, GLenum depth_func, bool depth_write_enable);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
std::unordered_map<std::string, KRMaterial *> m_materials;
|
unordered_map<std::string, KRMaterial *> m_materials;
|
||||||
KRTextureManager *m_pTextureManager;
|
KRTextureManager *m_pTextureManager;
|
||||||
KRShaderManager *m_pShaderManager;
|
KRShaderManager *m_pShaderManager;
|
||||||
|
|
||||||
|
|||||||
@@ -55,7 +55,7 @@ KRMeshManager::KRMeshManager(KRContext &context) : KRContextObject(context) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
KRMeshManager::~KRMeshManager() {
|
KRMeshManager::~KRMeshManager() {
|
||||||
for(std::unordered_multimap<std::string, KRMesh *>::iterator itr = m_models.begin(); itr != m_models.end(); ++itr){
|
for(unordered_multimap<std::string, KRMesh *>::iterator itr = m_models.begin(); itr != m_models.end(); ++itr){
|
||||||
delete (*itr).second;
|
delete (*itr).second;
|
||||||
}
|
}
|
||||||
m_models.empty();
|
m_models.empty();
|
||||||
@@ -85,8 +85,8 @@ std::vector<KRMesh *> KRMeshManager::getModel(const char *szName) {
|
|||||||
|
|
||||||
std::vector<KRMesh *> matching_models;
|
std::vector<KRMesh *> matching_models;
|
||||||
|
|
||||||
std::pair<std::unordered_multimap<std::string, KRMesh *>::iterator, std::unordered_multimap<std::string, KRMesh *>::iterator> range = m_models.equal_range(lowerName);
|
std::pair<unordered_multimap<std::string, KRMesh *>::iterator, unordered_multimap<std::string, KRMesh *>::iterator> range = m_models.equal_range(lowerName);
|
||||||
for(std::unordered_multimap<std::string, KRMesh *>::iterator itr_match = range.first; itr_match != range.second; itr_match++) {
|
for(unordered_multimap<std::string, KRMesh *>::iterator itr_match = range.first; itr_match != range.second; itr_match++) {
|
||||||
matching_models.push_back(itr_match->second);
|
matching_models.push_back(itr_match->second);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -99,7 +99,7 @@ std::vector<KRMesh *> KRMeshManager::getModel(const char *szName) {
|
|||||||
return matching_models;
|
return matching_models;
|
||||||
}
|
}
|
||||||
|
|
||||||
std::unordered_multimap<std::string, KRMesh *> &KRMeshManager::getModels() {
|
unordered_multimap<std::string, KRMesh *> &KRMeshManager::getModels() {
|
||||||
return m_models;
|
return m_models;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -187,7 +187,7 @@ void KRMeshManager::bindVBO(GLvoid *data, GLsizeiptr size, GLvoid *index_data, G
|
|||||||
fprintf(stderr, "flushBuffers due to VBO exhaustion...\n");
|
fprintf(stderr, "flushBuffers due to VBO exhaustion...\n");
|
||||||
m_pContext->rotateBuffers(false);
|
m_pContext->rotateBuffers(false);
|
||||||
}
|
}
|
||||||
std::unordered_map<GLvoid *, vbo_info_type>::iterator first_itr = m_vbosPool.begin();
|
unordered_map<GLvoid *, vbo_info_type>::iterator first_itr = m_vbosPool.begin();
|
||||||
vbo_info_type firstVBO = first_itr->second;
|
vbo_info_type firstVBO = first_itr->second;
|
||||||
#if GL_OES_vertex_array_object
|
#if GL_OES_vertex_array_object
|
||||||
GLDEBUG(glDeleteVertexArraysOES(1, &firstVBO.vao_handle));
|
GLDEBUG(glDeleteVertexArraysOES(1, &firstVBO.vao_handle));
|
||||||
@@ -324,7 +324,7 @@ long KRMeshManager::getMemUsed()
|
|||||||
long KRMeshManager::getMemActive()
|
long KRMeshManager::getMemActive()
|
||||||
{
|
{
|
||||||
long mem_active = 0;
|
long mem_active = 0;
|
||||||
for(std::unordered_map<GLvoid *, vbo_info_type>::iterator itr = m_vbosActive.begin(); itr != m_vbosActive.end(); itr++) {
|
for(unordered_map<GLvoid *, vbo_info_type>::iterator itr = m_vbosActive.begin(); itr != m_vbosActive.end(); itr++) {
|
||||||
mem_active += (*itr).second.size;
|
mem_active += (*itr).second.size;
|
||||||
}
|
}
|
||||||
return mem_active;
|
return mem_active;
|
||||||
|
|||||||
@@ -57,7 +57,7 @@ public:
|
|||||||
void addModel(KRMesh *model);
|
void addModel(KRMesh *model);
|
||||||
|
|
||||||
std::vector<std::string> getModelNames();
|
std::vector<std::string> getModelNames();
|
||||||
std::unordered_multimap<std::string, KRMesh *> &getModels();
|
unordered_multimap<std::string, KRMesh *> &getModels();
|
||||||
|
|
||||||
|
|
||||||
void bindVBO(GLvoid *data, GLsizeiptr size, GLvoid *index_data, GLsizeiptr index_data_size, bool enable_vertex, bool enable_normal, bool enable_tangent, bool enable_uva, bool enable_uvb, bool enable_bone_indexes, bool enable_bone_weights, bool static_vbo);
|
void bindVBO(GLvoid *data, GLsizeiptr size, GLvoid *index_data, GLsizeiptr index_data_size, bool enable_vertex, bool enable_normal, bool enable_tangent, bool enable_uva, bool enable_uvb, bool enable_bone_indexes, bool enable_bone_weights, bool static_vbo);
|
||||||
@@ -113,7 +113,7 @@ public:
|
|||||||
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
std::unordered_multimap<std::string, KRMesh *> m_models; // Multiple models with the same name/key may be inserted, representing multiple LOD levels of the model
|
unordered_multimap<std::string, KRMesh *> m_models; // Multiple models with the same name/key may be inserted, representing multiple LOD levels of the model
|
||||||
|
|
||||||
typedef struct vbo_info {
|
typedef struct vbo_info {
|
||||||
GLuint vbo_handle;
|
GLuint vbo_handle;
|
||||||
@@ -126,8 +126,8 @@ private:
|
|||||||
long m_vboMemUsed;
|
long m_vboMemUsed;
|
||||||
vbo_info_type m_currentVBO;
|
vbo_info_type m_currentVBO;
|
||||||
|
|
||||||
std::unordered_map<GLvoid *, vbo_info_type> m_vbosActive;
|
unordered_map<GLvoid *, vbo_info_type> m_vbosActive;
|
||||||
std::unordered_map<GLvoid *, vbo_info_type> m_vbosPool;
|
unordered_map<GLvoid *, vbo_info_type> m_vbosPool;
|
||||||
|
|
||||||
RandomParticleVertexData *m_randomParticleVertexData;
|
RandomParticleVertexData *m_randomParticleVertexData;
|
||||||
VolumetricLightingVertexData *m_volumetricLightingVertexData;
|
VolumetricLightingVertexData *m_volumetricLightingVertexData;
|
||||||
|
|||||||
@@ -67,7 +67,7 @@ tinyxml2::XMLElement *KRModel::saveXML( tinyxml2::XMLNode *parent)
|
|||||||
void KRModel::loadModel() {
|
void KRModel::loadModel() {
|
||||||
if(m_models.size() == 0) {
|
if(m_models.size() == 0) {
|
||||||
std::vector<KRMesh *> models = m_pContext->getModelManager()->getModel(m_model_name.c_str()); // The model manager returns the LOD levels in sorted order, with the highest detail first
|
std::vector<KRMesh *> models = m_pContext->getModelManager()->getModel(m_model_name.c_str()); // The model manager returns the LOD levels in sorted order, with the highest detail first
|
||||||
std::unordered_map<KRMesh *, std::vector<KRBone *> > bones;
|
unordered_map<KRMesh *, std::vector<KRBone *> > bones;
|
||||||
if(models.size() > 0) {
|
if(models.size() > 0) {
|
||||||
bool all_bones_found = true;
|
bool all_bones_found = true;
|
||||||
for(std::vector<KRMesh *>::iterator model_itr = models.begin(); model_itr != models.end(); model_itr++) {
|
for(std::vector<KRMesh *>::iterator model_itr = models.begin(); model_itr != models.end(); model_itr++) {
|
||||||
|
|||||||
@@ -63,7 +63,7 @@ public:
|
|||||||
|
|
||||||
private:
|
private:
|
||||||
std::vector<KRMesh *> m_models;
|
std::vector<KRMesh *> m_models;
|
||||||
std::unordered_map<KRMesh *, std::vector<KRBone *> > m_bones; // Outer std::map connects model to set of bones
|
unordered_map<KRMesh *, std::vector<KRBone *> > m_bones; // Outer std::map connects model to set of bones
|
||||||
KRTexture *m_pLightMap;
|
KRTexture *m_pLightMap;
|
||||||
std::string m_lightMap;
|
std::string m_lightMap;
|
||||||
std::string m_model_name;
|
std::string m_model_name;
|
||||||
|
|||||||
@@ -162,11 +162,11 @@ std::vector<KRResource *> KRResource::LoadFbx(KRContext &context, const std::str
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
for(std::unordered_map<std::string, KRTexture *>::iterator texture_itr = context.getTextureManager()->getTextures().begin(); texture_itr != context.getTextureManager()->getTextures().end(); texture_itr++) {
|
for(unordered_map<std::string, KRTexture *>::iterator texture_itr = context.getTextureManager()->getTextures().begin(); texture_itr != context.getTextureManager()->getTextures().end(); texture_itr++) {
|
||||||
resources.push_back((*texture_itr).second);
|
resources.push_back((*texture_itr).second);
|
||||||
}
|
}
|
||||||
|
|
||||||
for(std::unordered_map<std::string, KRMesh *>::iterator mesh_itr = context.getModelManager()->getModels().begin(); mesh_itr != context.getModelManager()->getModels().end(); mesh_itr++) {
|
for(unordered_map<std::string, KRMesh *>::iterator mesh_itr = context.getModelManager()->getModels().begin(); mesh_itr != context.getModelManager()->getModels().end(); mesh_itr++) {
|
||||||
resources.push_back((*mesh_itr).second);
|
resources.push_back((*mesh_itr).second);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -85,13 +85,13 @@ std::set<KRReverbZone *> &KRScene::getReverbZones()
|
|||||||
return m_reverbZoneNodes;
|
return m_reverbZoneNodes;
|
||||||
}
|
}
|
||||||
|
|
||||||
void KRScene::render(KRCamera *pCamera, std::unordered_map<KRAABB, int> &visibleBounds, const KRViewport &viewport, KRNode::RenderPass renderPass, bool new_frame) {
|
void KRScene::render(KRCamera *pCamera, unordered_map<KRAABB, int> &visibleBounds, const KRViewport &viewport, KRNode::RenderPass renderPass, bool new_frame) {
|
||||||
if(new_frame) {
|
if(new_frame) {
|
||||||
// Expire cached occlusion test results.
|
// Expire cached occlusion test results.
|
||||||
// Cached "failed" results are expired on the next frame (marked with .second of -1)
|
// Cached "failed" results are expired on the next frame (marked with .second of -1)
|
||||||
// Cached "success" results are expired after KRENGINE_OCCLUSION_TEST_EXPIRY frames (marked with .second of the last frame
|
// Cached "success" results are expired after KRENGINE_OCCLUSION_TEST_EXPIRY frames (marked with .second of the last frame
|
||||||
std::set<KRAABB> expired_visible_bounds;
|
std::set<KRAABB> expired_visible_bounds;
|
||||||
for(std::unordered_map<KRAABB, int>::iterator visible_bounds_itr = visibleBounds.begin(); visible_bounds_itr != visibleBounds.end(); visible_bounds_itr++) {
|
for(unordered_map<KRAABB, int>::iterator visible_bounds_itr = visibleBounds.begin(); visible_bounds_itr != visibleBounds.end(); visible_bounds_itr++) {
|
||||||
if((*visible_bounds_itr).second == -1 || (*visible_bounds_itr).second + KRENGINE_OCCLUSION_TEST_EXPIRY < getContext().getCurrentFrame()) {
|
if((*visible_bounds_itr).second == -1 || (*visible_bounds_itr).second + KRENGINE_OCCLUSION_TEST_EXPIRY < getContext().getCurrentFrame()) {
|
||||||
expired_visible_bounds.insert((*visible_bounds_itr).first);
|
expired_visible_bounds.insert((*visible_bounds_itr).first);
|
||||||
}
|
}
|
||||||
@@ -166,7 +166,7 @@ void KRScene::render(KRCamera *pCamera, std::unordered_map<KRAABB, int> &visible
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void KRScene::render(KROctreeNode *pOctreeNode, std::unordered_map<KRAABB, int> &visibleBounds, KRCamera *pCamera, std::vector<KRPointLight *> &point_lights, std::vector<KRDirectionalLight *> &directional_lights, std::vector<KRSpotLight *>&spot_lights, const KRViewport &viewport, KRNode::RenderPass renderPass, std::vector<KROctreeNode *> &remainingOctrees, std::vector<KROctreeNode *> &remainingOctreesTestResults, std::vector<KROctreeNode *> &remainingOctreesTestResultsOnly, bool bOcclusionResultsPass, bool bOcclusionTestResultsOnly)
|
void KRScene::render(KROctreeNode *pOctreeNode, unordered_map<KRAABB, int> &visibleBounds, KRCamera *pCamera, std::vector<KRPointLight *> &point_lights, std::vector<KRDirectionalLight *> &directional_lights, std::vector<KRSpotLight *>&spot_lights, const KRViewport &viewport, KRNode::RenderPass renderPass, std::vector<KROctreeNode *> &remainingOctrees, std::vector<KROctreeNode *> &remainingOctreesTestResults, std::vector<KROctreeNode *> &remainingOctreesTestResultsOnly, bool bOcclusionResultsPass, bool bOcclusionTestResultsOnly)
|
||||||
{
|
{
|
||||||
if(pOctreeNode) {
|
if(pOctreeNode) {
|
||||||
|
|
||||||
@@ -236,7 +236,7 @@ void KRScene::render(KROctreeNode *pOctreeNode, std::unordered_map<KRAABB, int>
|
|||||||
if(!bVisible) {
|
if(!bVisible) {
|
||||||
// Check if a previous occlusion query has returned true, taking advantage of temporal consistency of visible elements from frame to frame
|
// Check if a previous occlusion query has returned true, taking advantage of temporal consistency of visible elements from frame to frame
|
||||||
// If the previous frame rendered this octree, then attempt to render it in this frame without performing a pre-occlusion test
|
// If the previous frame rendered this octree, then attempt to render it in this frame without performing a pre-occlusion test
|
||||||
std::unordered_map<KRAABB, int>::iterator match_itr = visibleBounds.find(octreeBounds);
|
unordered_map<KRAABB, int>::iterator match_itr = visibleBounds.find(octreeBounds);
|
||||||
if(match_itr != visibleBounds.end()) {
|
if(match_itr != visibleBounds.end()) {
|
||||||
if((*match_itr).second == -1) {
|
if((*match_itr).second == -1) {
|
||||||
// We have already tested these bounds with a negative result
|
// We have already tested these bounds with a negative result
|
||||||
|
|||||||
@@ -67,9 +67,9 @@ public:
|
|||||||
bool rayCast(const KRVector3 &v0, const KRVector3 &dir, KRHitInfo &hitinfo, unsigned int layer_mask);
|
bool rayCast(const KRVector3 &v0, const KRVector3 &dir, KRHitInfo &hitinfo, unsigned int layer_mask);
|
||||||
|
|
||||||
void renderFrame(float deltaTime, int width, int height);
|
void renderFrame(float deltaTime, int width, int height);
|
||||||
void render(KRCamera *pCamera, std::unordered_map<KRAABB, int> &visibleBounds, const KRViewport &viewport, KRNode::RenderPass renderPass, bool new_frame);
|
void render(KRCamera *pCamera, unordered_map<KRAABB, int> &visibleBounds, const KRViewport &viewport, KRNode::RenderPass renderPass, bool new_frame);
|
||||||
|
|
||||||
void render(KROctreeNode *pOctreeNode, std::unordered_map<KRAABB, int> &visibleBounds, KRCamera *pCamera, std::vector<KRPointLight *> &point_lights, std::vector<KRDirectionalLight *> &directional_lights, std::vector<KRSpotLight *>&spot_lights, const KRViewport &viewport, KRNode::RenderPass renderPass, std::vector<KROctreeNode *> &remainingOctrees, std::vector<KROctreeNode *> &remainingOctreesTestResults, std::vector<KROctreeNode *> &remainingOctreesTestResultsOnly, bool bOcclusionResultsPass, bool bOcclusionTestResultsOnly);
|
void render(KROctreeNode *pOctreeNode, unordered_map<KRAABB, int> &visibleBounds, KRCamera *pCamera, std::vector<KRPointLight *> &point_lights, std::vector<KRDirectionalLight *> &directional_lights, std::vector<KRSpotLight *>&spot_lights, const KRViewport &viewport, KRNode::RenderPass renderPass, std::vector<KROctreeNode *> &remainingOctrees, std::vector<KROctreeNode *> &remainingOctreesTestResults, std::vector<KROctreeNode *> &remainingOctreesTestResultsOnly, bool bOcclusionResultsPass, bool bOcclusionTestResultsOnly);
|
||||||
|
|
||||||
void updateOctree(const KRViewport &viewport);
|
void updateOctree(const KRViewport &viewport);
|
||||||
|
|
||||||
|
|||||||
@@ -53,7 +53,7 @@ KRScene *KRSceneManager::getScene(const char *szName) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
KRScene *KRSceneManager::getFirstScene() {
|
KRScene *KRSceneManager::getFirstScene() {
|
||||||
static std::unordered_map<std::string, KRScene *>::iterator scene_itr = m_scenes.begin();
|
static unordered_map<std::string, KRScene *>::iterator scene_itr = m_scenes.begin();
|
||||||
if(scene_itr == m_scenes.end()) {
|
if(scene_itr == m_scenes.end()) {
|
||||||
return NULL;
|
return NULL;
|
||||||
} else {
|
} else {
|
||||||
@@ -61,7 +61,7 @@ KRScene *KRSceneManager::getFirstScene() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
std::unordered_map<std::string, KRScene *> KRSceneManager::getScenes() {
|
unordered_map<std::string, KRScene *> KRSceneManager::getScenes() {
|
||||||
return m_scenes;
|
return m_scenes;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -50,11 +50,11 @@ public:
|
|||||||
KRScene *getFirstScene();
|
KRScene *getFirstScene();
|
||||||
|
|
||||||
std::vector<std::string> getSceneNames();
|
std::vector<std::string> getSceneNames();
|
||||||
std::unordered_map<std::string, KRScene *> getScenes();
|
unordered_map<std::string, KRScene *> getScenes();
|
||||||
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
std::unordered_map<std::string, KRScene *> m_scenes;
|
unordered_map<std::string, KRScene *> m_scenes;
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -67,11 +67,11 @@ public:
|
|||||||
long getShaderHandlesUsed();
|
long getShaderHandlesUsed();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
//std::unordered_map<std::string, KRShader *> m_shaders;
|
//unordered_map<std::string, KRShader *> m_shaders;
|
||||||
std::map<std::pair<std::string, std::vector<int> >, KRShader *> m_shaders;
|
std::map<std::pair<std::string, std::vector<int> >, KRShader *> m_shaders;
|
||||||
|
|
||||||
std::unordered_map<std::string, std::string> m_fragShaderSource;
|
unordered_map<std::string, std::string> m_fragShaderSource;
|
||||||
std::unordered_map<std::string, std::string> m_vertShaderSource;
|
unordered_map<std::string, std::string> m_vertShaderSource;
|
||||||
|
|
||||||
KRShader *m_pShader;
|
KRShader *m_pShader;
|
||||||
char m_szCurrentShaderKey[256];
|
char m_szCurrentShaderKey[256];
|
||||||
|
|||||||
@@ -328,7 +328,7 @@ void KRTextureManager::memoryChanged(long memoryDelta)
|
|||||||
m_textureMemUsed += memoryDelta;
|
m_textureMemUsed += memoryDelta;
|
||||||
}
|
}
|
||||||
|
|
||||||
std::unordered_map<std::string, KRTexture *> &KRTextureManager::getTextures()
|
unordered_map<std::string, KRTexture *> &KRTextureManager::getTextures()
|
||||||
{
|
{
|
||||||
return m_textures;
|
return m_textures;
|
||||||
}
|
}
|
||||||
@@ -338,7 +338,7 @@ void KRTextureManager::compress()
|
|||||||
std::vector<KRTexture *> textures_to_remove;
|
std::vector<KRTexture *> textures_to_remove;
|
||||||
std::vector<KRTexture *> textures_to_add;
|
std::vector<KRTexture *> textures_to_add;
|
||||||
|
|
||||||
for(std::unordered_map<std::string, KRTexture *>::iterator itr=m_textures.begin(); itr != m_textures.end(); itr++) {
|
for(unordered_map<std::string, KRTexture *>::iterator itr=m_textures.begin(); itr != m_textures.end(); itr++) {
|
||||||
KRTexture *texture = (*itr).second;
|
KRTexture *texture = (*itr).second;
|
||||||
KRTexture *compressed_texture = texture->compress();
|
KRTexture *compressed_texture = texture->compress();
|
||||||
if(compressed_texture) {
|
if(compressed_texture) {
|
||||||
|
|||||||
@@ -62,7 +62,7 @@ public:
|
|||||||
void startFrame(float deltaTime);
|
void startFrame(float deltaTime);
|
||||||
void endFrame(float deltaTime);
|
void endFrame(float deltaTime);
|
||||||
|
|
||||||
std::unordered_map<std::string, KRTexture *> &getTextures();
|
unordered_map<std::string, KRTexture *> &getTextures();
|
||||||
|
|
||||||
void compress();
|
void compress();
|
||||||
|
|
||||||
@@ -81,7 +81,7 @@ private:
|
|||||||
|
|
||||||
long m_memoryTransferredThisFrame;
|
long m_memoryTransferredThisFrame;
|
||||||
|
|
||||||
std::unordered_map<std::string, KRTexture *> m_textures;
|
unordered_map<std::string, KRTexture *> m_textures;
|
||||||
|
|
||||||
KRTexture *m_boundTextures[KRENGINE_MAX_TEXTURE_UNITS];
|
KRTexture *m_boundTextures[KRENGINE_MAX_TEXTURE_UNITS];
|
||||||
GLuint m_wrapModeS[KRENGINE_MAX_TEXTURE_UNITS];
|
GLuint m_wrapModeS[KRENGINE_MAX_TEXTURE_UNITS];
|
||||||
|
|||||||
@@ -30,7 +30,7 @@
|
|||||||
//
|
//
|
||||||
|
|
||||||
#include "KRUnknownManager.h"
|
#include "KRUnknownManager.h"
|
||||||
#include <unordered_map>
|
#include "KREngine-common.h"
|
||||||
|
|
||||||
KRUnknownManager::KRUnknownManager(KRContext &context) : KRContextObject(context)
|
KRUnknownManager::KRUnknownManager(KRContext &context) : KRContextObject(context)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -101,8 +101,8 @@ namespace std {
|
|||||||
public:
|
public:
|
||||||
size_t operator()(const KRVector2 &s) const
|
size_t operator()(const KRVector2 &s) const
|
||||||
{
|
{
|
||||||
size_t h1 = std::hash<float>()(s.x);
|
size_t h1 = hash<float>()(s.x);
|
||||||
size_t h2 = std::hash<float>()(s.y);
|
size_t h2 = hash<float>()(s.y);
|
||||||
return h1 ^ ( h2 << 1 );
|
return h1 ^ ( h2 << 1 );
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -111,9 +111,9 @@ namespace std {
|
|||||||
public:
|
public:
|
||||||
size_t operator()(const KRVector3 &s) const
|
size_t operator()(const KRVector3 &s) const
|
||||||
{
|
{
|
||||||
size_t h1 = std::hash<float>()(s.x);
|
size_t h1 = hash<float>()(s.x);
|
||||||
size_t h2 = std::hash<float>()(s.y);
|
size_t h2 = hash<float>()(s.y);
|
||||||
size_t h3 = std::hash<float>()(s.z);
|
size_t h3 = hash<float>()(s.z);
|
||||||
return h1 ^ ( h2 << 1 ) ^ (h3 << 2);
|
return h1 ^ ( h2 << 1 ) ^ (h3 << 2);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -156,7 +156,7 @@ void KRViewport::calculateDerivedValues()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
std::unordered_map<KRAABB, int> &KRViewport::getVisibleBounds()
|
unordered_map<KRAABB, int> &KRViewport::getVisibleBounds()
|
||||||
{
|
{
|
||||||
return m_visibleBounds;
|
return m_visibleBounds;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -41,7 +41,7 @@ public:
|
|||||||
// Overload assignment operator
|
// Overload assignment operator
|
||||||
KRViewport& operator=(const KRViewport &v);
|
KRViewport& operator=(const KRViewport &v);
|
||||||
|
|
||||||
std::unordered_map<KRAABB, int> &getVisibleBounds();
|
unordered_map<KRAABB, int> &getVisibleBounds();
|
||||||
|
|
||||||
const std::set<KRLight *> &getVisibleLights();
|
const std::set<KRLight *> &getVisibleLights();
|
||||||
void setVisibleLights(const std::set<KRLight *> visibleLights);
|
void setVisibleLights(const std::set<KRLight *> visibleLights);
|
||||||
@@ -68,7 +68,7 @@ private:
|
|||||||
|
|
||||||
void calculateDerivedValues();
|
void calculateDerivedValues();
|
||||||
|
|
||||||
std::unordered_map<KRAABB, int> m_visibleBounds; // AABB's that output fragments in the last frame
|
unordered_map<KRAABB, int> m_visibleBounds; // AABB's that output fragments in the last frame
|
||||||
|
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user