2012-04-12 19:43:08 +00:00
|
|
|
//
|
|
|
|
|
// KRContext.h
|
|
|
|
|
// KREngine
|
|
|
|
|
//
|
|
|
|
|
// Created by Kearwood Gilbert on 12-04-12.
|
|
|
|
|
// Copyright (c) 2012 Kearwood Software. All rights reserved.
|
|
|
|
|
//
|
|
|
|
|
|
|
|
|
|
#ifndef KREngine_KRContext_h
|
|
|
|
|
#define KREngine_KRContext_h
|
|
|
|
|
|
2012-10-19 23:17:43 +00:00
|
|
|
#import "KREngine-common.h"
|
2012-09-11 03:06:35 +00:00
|
|
|
#import "KRBundleManager.h"
|
2012-04-12 19:43:08 +00:00
|
|
|
#import "KRSceneManager.h"
|
|
|
|
|
#import "KRTextureManager.h"
|
|
|
|
|
#import "KRMaterialManager.h"
|
|
|
|
|
#import "KRShaderManager.h"
|
|
|
|
|
#import "KRModelManager.h"
|
2012-10-19 23:17:43 +00:00
|
|
|
|
2012-04-12 19:43:08 +00:00
|
|
|
class KRContext {
|
|
|
|
|
public:
|
2012-10-19 23:17:43 +00:00
|
|
|
static int KRENGINE_MAX_VBO_HANDLES;
|
|
|
|
|
static int KRENGINE_MAX_VBO_MEM;
|
|
|
|
|
static int KRENGINE_MAX_SHADER_HANDLES;
|
|
|
|
|
static int KRENGINE_MAX_TEXTURE_HANDLES;
|
|
|
|
|
static int KRENGINE_MAX_TEXTURE_MEM;
|
|
|
|
|
static int KRENGINE_TARGET_TEXTURE_MEM_MAX;
|
|
|
|
|
static int KRENGINE_TARGET_TEXTURE_MEM_MIN;
|
|
|
|
|
static int KRENGINE_MAX_TEXTURE_DIM;
|
|
|
|
|
static int KRENGINE_MIN_TEXTURE_DIM;
|
|
|
|
|
|
|
|
|
|
|
2012-04-13 23:24:07 +00:00
|
|
|
KRContext();
|
2012-04-12 19:43:08 +00:00
|
|
|
~KRContext();
|
|
|
|
|
|
2012-09-11 03:06:35 +00:00
|
|
|
void loadResource(const std::string &file_name, KRDataBlock *data);
|
2012-04-12 19:43:08 +00:00
|
|
|
void loadResource(std::string path);
|
|
|
|
|
|
2012-09-11 03:06:35 +00:00
|
|
|
KRBundleManager *getBundleManager();
|
2012-04-12 19:43:08 +00:00
|
|
|
KRSceneManager *getSceneManager();
|
|
|
|
|
KRTextureManager *getTextureManager();
|
|
|
|
|
KRMaterialManager *getMaterialManager();
|
|
|
|
|
KRShaderManager *getShaderManager();
|
|
|
|
|
KRModelManager *getModelManager();
|
|
|
|
|
|
2012-08-17 01:04:49 +00:00
|
|
|
KRCamera *createCamera(int width, int height);
|
|
|
|
|
|
2012-09-26 20:07:48 +00:00
|
|
|
void rotateBuffers(bool new_frame);
|
2012-09-13 20:09:19 +00:00
|
|
|
|
2012-04-12 19:43:08 +00:00
|
|
|
private:
|
2012-09-11 03:06:35 +00:00
|
|
|
KRBundleManager *m_pBundleManager;
|
2012-04-12 19:43:08 +00:00
|
|
|
KRSceneManager *m_pSceneManager;
|
|
|
|
|
KRTextureManager *m_pTextureManager;
|
|
|
|
|
KRMaterialManager *m_pMaterialManager;
|
|
|
|
|
KRShaderManager *m_pShaderManager;
|
|
|
|
|
KRModelManager *m_pModelManager;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
#endif
|