Namespaces | |
| LuaFunctions | |
Data Structures | |
| class | App |
| class | Attribute |
| class | AttributeBase |
| The AttributeBase class only exists for some templating acrobatics reasons (as an abstract base class for Attribute) More... | |
| class | AudioManager |
| class | BARECEGUI |
| class | BasicRenderer |
| class | BumpyGlyph |
| This is a glyph, but with bumpmap (for lighting etc.). More... | |
| class | BumpyRenderer |
| This is a BasicRenderer, but it includes the usage of bumpmaps. This can be useful for lighting. Has an additional uniform bumpmapSampler (sampler2D). More... | |
| class | Cache |
| This is a skeleton cache class. This can only be used by the ResourceManager or other classes who actually maintain proper pointer ownership. More... | |
| class | Camera2D |
| The basic camera for a 2D world. There are two spaces - the Worldspace and the Viewspace. The Worldspace is standard for all cameras, it is the 'gameworld' space. The Viewspace is the subspace of the worldspace. It is what the camera captures. Scale is zoom factor. NOT resolution scalar. More... | |
| class | CameraState |
| Holds some basic information that the camera holds in a state. More... | |
| struct | CEGUIContextWrapper |
| class | CharacterGlyph |
| Represents a render glyph, modified for fonts! More... | |
| struct | Circle |
| class | Colour |
| An RGBA 8-bit colour value. More... | |
| class | DebugRenderer |
| class | FBORenderer |
| The FBORenderer represents and manages an entire FrameBufferObject. This allows one to draw entire scenes first to a texture, then perform some operations on that texture, then draw that texture to the screen. Shaders have uniforms projectionMatrix (mat4), colourTexture (sampler2D), and depthTexture (sampler2D) More... | |
| class | Filesystem |
| class | Font |
| Essentially just a wrapper for the SDL TTF_Font type. More... | |
| class | FontRenderer |
| The FontRenderer... renders fonts. It is just a very basic extension of the BasicRenderer, so it works the same. More... | |
| class | GLContext |
| class | GLContextManager |
| class | Glyph |
| The glyph represents a renderbatch's primitive data, which is created from each draw call in the basic renderer. More... | |
| class | InputManager |
| This is the input manager. It does what you expect! Nearly completely copied from GLEngine, the ol' gal. More... | |
| class | IOManager |
| struct | Line |
| class | Logger |
| For general purpose logging, this is the logger! It is a singleton class. More... | |
| class | LuaContextManager |
| class | LuaScript |
| class | LuaScriptContextWrapper |
| class | LuaScriptEngine |
| class | LuaScriptQueue |
| struct | Music |
| class | MutableTexture |
| A child of Texture which allows (and gives helpful functions for) mutation. More... | |
| class | ParticleEngine2D |
| class | Position |
| Positional data. More... | |
| struct | Rectangle |
| class | Renderer |
| The renderer class holds some shader program, manages some VBO, some render batch(es), and allows customizable, simple rendering. More... | |
| class | ResourceManager |
| The resource manager manages resources. Groundbreaking news, I know. In short, the resource manager loads and manages Textures, Sounds, Scripts, Fonts, etc. More... | |
| class | Screen |
| This is meant to be a parent for other, app-specific, screen classes, which is essentially where all game mechanics will "happen", so to speak. This class decides what happens on updates, draws, when to go to different screens, etc. More... | |
| class | ScreenList |
| Holds and connects all of the screens used in the program in a list. Keeps track of the previous screen. Contains functions to move to the next or previous screens. More... | |
| class | ShaderProgram |
| The ShaderProgram is a GLSL program which combines two shaders - the vertex shader and the fragment shader - to allow rendering. Each renderer should have its own program. More... | |
| struct | Sound |
| struct | Texture |
| The texture struct holds very basic stuff - the filepath, width, height, and ID,. More... | |
| class | TexturelessRenderer |
| class | Timer |
| Not only does the timer keep track of the current time and delta-times, it can do all the "fancy" calculations for timestepping! Uses semi-fixed timestepping, as this engine isn't going to be used for advanced physics! More... | |
| class | UV |
| Holds two floats which can act as UV sizes or positions. More... | |
| class | VAO |
| A wrapper class for OpenGL's VAO, as well as its associated VBO and attributes. More... | |
| class | Vertex |
| Just holds vertex data for convenience. More... | |
| class | Window |
| It's a graphical window, holds the contexts for GL and SDL. More... | |
| class | XMLData |
| Holds all the very basic information for XML data. Designed to be a base class from which a user can derive custom data formats. To derive, please overload the default constructor and XMLData(std::string dataType, unsigned int ID) More... | |
| class | XMLDataManager |
| A singleton class that statically manages all XML data, including read and write operations. More... | |
Functions | |
| void | init () |
| Inits the required systems used by BARE2D. More... | |
| CEGUI::Key::Scan | SDLKeyToCEGUIKey (SDL_Keycode key) |
| CEGUI::MouseButton | SDLButtonToCEGUIButton (Uint8 sdlButton) |
| std::string | getErrString (BAREError err) |
| Returns the string representing/explaining the error that occurred. More... | |
| void | throwFatalError (BAREError err, std::string message="") |
| Throws an error (fatal). Also calls displayErrors and exits the program. More... | |
| void | throwError (BAREError err, std::string message="") |
| Throws an error silently. Adds it to the pile. More... | |
| void | displayErrors () |
| Displays the latest thrown errors (really just all the thrown errors) in the console. More... | |
| void | initGLErrorCallback (GLErrorSeverity minSeverity=GLErrorSeverity::NOTIF) |
| Initializes the GL Debug Message Callback function, and enables debug output straight from OpenGL. More... | |
| template<> | |
| void | ShaderProgram::setUniform< glm::vec2 > (const std::string uniform, glm::vec2 *data, unsigned int num) |
| template<> | |
| void | ShaderProgram::setUniform< glm::vec3 > (const std::string uniform, glm::vec3 *data, unsigned int num) |
| template<> | |
| void | ShaderProgram::setUniform< glm::vec4 > (const std::string uniform, glm::vec4 *data, unsigned int num) |
| template<> | |
| void | ShaderProgram::setUniform< glm::ivec2 > (const std::string uniform, glm::ivec2 *data, unsigned int num) |
| template<> | |
| void | ShaderProgram::setUniform< glm::ivec3 > (const std::string uniform, glm::ivec3 *data, unsigned int num) |
| template<> | |
| void | ShaderProgram::setUniform< glm::ivec4 > (const std::string uniform, glm::ivec4 *data, unsigned int num) |
| template<> | |
| void | ShaderProgram::setUniformMatrix< glm::mat4 > (const std::string uniform, bool transpose, glm::mat4 *data, unsigned int num) |
| int | decodePNG (std::vector< unsigned char > &out_image, unsigned long &image_width, unsigned long &image_height, const unsigned char *in_png, std::size_t in_size, bool convert_to_rgba32) |
| int | decodePNG (std::vector< unsigned char > &out_image, unsigned long &image_width, unsigned long &image_height, const unsigned char *in_png, size_t in_size, bool convert_to_rgba32=true) |
| Loads a PNG from a file. That's... All I've got. More... | |
Variables | |
| GLErrorSeverity | GLErrorMinSeverity = GLErrorSeverity::LOW |
| std::vector< BAREError > | thrownErrors |
|
strong |
| Enumerator | |
|---|---|
| STRING | |
| UNSIGNED_INT | |
| VECTOR_UNSIGNED_INT | |
| INT | |
| FLOAT | |
| VECTOR_FLOAT | |
| BOOL | |
| VECTOR_BOOL | |
| VEC2 | |
| VECTOR_VEC2 | |
| SCRIPT | |
| TEXTURE | |
Definition at line 10 of file XMLDataTypes.hpp.
|
strong |
Represents a specific type of error that has occured.
Definition at line 18 of file BAREErrors.hpp.
|
strong |
| Enumerator | |
|---|---|
| NOTIF | |
| LOW | |
| MED | |
| HIGH | |
| UNKNOWN | |
Definition at line 49 of file BAREErrors.hpp.
|
strong |
| Enumerator | |
|---|---|
| RIGHT | |
| MIDDLE | |
| LEFT | |
Definition at line 12 of file FontRenderer.hpp.
|
strong |
| Enumerator | |
|---|---|
| RUNNING | |
| CHANGE_NEXT | |
| CHANGE_PREV | |
| EXIT_APPLICATION | |
Definition at line 5 of file Screen.hpp.
| int BARE2D::decodePNG | ( | std::vector< unsigned char > & | out_image, |
| unsigned long & | image_width, | ||
| unsigned long & | image_height, | ||
| const unsigned char * | in_png, | ||
| size_t | in_size, | ||
| bool | convert_to_rgba32 = true |
||
| ) |
Loads a PNG from a file. That's... All I've got.
| out_image | output parameter, this will contain the raw pixels after decoding. By default the output is 32-bit RGBA color. The std::vector is automatically resized to the correct size. |
| image_width | output_parameter, this will contain the width of the image in pixels. |
| image_height | output_parameter, this will contain the height of the image in pixels. |
| in_png | pointer to the buffer of the PNG file in memory. To get it from a file on disk, load it and store it in a memory buffer yourself first. |
| in_size | size of the input PNG file in bytes. |
| convert_to_rgba32 | optional parameter, true by default. Set to true to get the output in RGBA 32-bit (8 bit per channel) color format no matter what color type the original PNG image had. This gives predictable, useable data from any random input PNG. Set to false to do no color conversion at all. The result then has the same data type as the PNG image, which can range from 1 bit to 64 bits per pixel. Information about the color type or palette colors are not provided. You need to know this information yourself to be able to use the data so this only works for trusted PNG files. Use LodePNG instead of picoPNG if you need this information. |
| int BARE2D::decodePNG | ( | std::vector< unsigned char > & | out_image, |
| unsigned long & | image_width, | ||
| unsigned long & | image_height, | ||
| const unsigned char * | in_png, | ||
| std::size_t | in_size, | ||
| bool | convert_to_rgba32 | ||
| ) |
Definition at line 28 of file PicoPNG.cpp.
Referenced by BARE2D::ResourceManager::loadTexture().
Here is the caller graph for this function:| void BARE2D::displayErrors | ( | ) |
Displays the latest thrown errors (really just all the thrown errors) in the console.
Definition at line 201 of file BAREErrors.cpp.
References getErrString(), and thrownErrors.
Referenced by throwFatalError().
Here is the call graph for this function:
Here is the caller graph for this function:| std::string BARE2D::getErrString | ( | BAREError | err | ) |
Returns the string representing/explaining the error that occurred.
| err | The error enum, which a function returns. |
Definition at line 134 of file BAREErrors.cpp.
References DOUBLE_INIT, FBO_FAILURE, FONT_FAILURE, FRAGMENT_SHADER_FAILURE, GL_FAILURE_VERSION, GLEW_FAILURE, GLSL_PROGRAM_FAILURE, LOGGER_FAILURE, LUA_FAILURE, NULL_PTR_ACCESS, SDL_FAILURE, SHADER_COMPILE_FAILURE, SHADER_LINK_FAILURE, TEXTURE_FAILURE, UNIFORM_NOT_FOUND, UNINITIALIZED_FUNCTION, VERTEX_SHADER_FAILURE, and XML_FAILURE.
Referenced by displayErrors(), and throwError().
Here is the caller graph for this function:| void BARE2D::init | ( | ) |
Inits the required systems used by BARE2D.
Definition at line 10 of file BARE2DEngine.cpp.
References SDL_FAILURE, and throwFatalError().
Referenced by BARE2D::App::init().
Here is the call graph for this function:
Here is the caller graph for this function:| void BARE2D::initGLErrorCallback | ( | GLErrorSeverity | minSeverity | ) |
Initializes the GL Debug Message Callback function, and enables debug output straight from OpenGL.
Definition at line 211 of file BAREErrors.cpp.
References GLErrorMinSeverity, and MessageCallback().
Referenced by BARE2D::App::run().
Here is the call graph for this function:
Here is the caller graph for this function:| CEGUI::MouseButton BARE2D::SDLButtonToCEGUIButton | ( | Uint8 | sdlButton | ) |
Definition at line 477 of file BARECEGUI.cpp.
Referenced by BARE2D::BARECEGUI::handleSDLEvent().
Here is the caller graph for this function:| CEGUI::Key::Scan BARE2D::SDLKeyToCEGUIKey | ( | SDL_Keycode | key | ) |
Definition at line 283 of file BARECEGUI.cpp.
Referenced by BARE2D::BARECEGUI::handleSDLEvent().
Here is the caller graph for this function:| void BARE2D::ShaderProgram::setUniform< glm::ivec2 > | ( | const std::string | uniform, |
| glm::ivec2 * | data, | ||
| unsigned int | num | ||
| ) |
Definition at line 297 of file ShaderProgram.cpp.
| void BARE2D::ShaderProgram::setUniform< glm::ivec3 > | ( | const std::string | uniform, |
| glm::ivec3 * | data, | ||
| unsigned int | num | ||
| ) |
Definition at line 309 of file ShaderProgram.cpp.
| void BARE2D::ShaderProgram::setUniform< glm::ivec4 > | ( | const std::string | uniform, |
| glm::ivec4 * | data, | ||
| unsigned int | num | ||
| ) |
Definition at line 321 of file ShaderProgram.cpp.
| void BARE2D::ShaderProgram::setUniform< glm::vec2 > | ( | const std::string | uniform, |
| glm::vec2 * | data, | ||
| unsigned int | num | ||
| ) |
Definition at line 261 of file ShaderProgram.cpp.
| void BARE2D::ShaderProgram::setUniform< glm::vec3 > | ( | const std::string | uniform, |
| glm::vec3 * | data, | ||
| unsigned int | num | ||
| ) |
Definition at line 273 of file ShaderProgram.cpp.
| void BARE2D::ShaderProgram::setUniform< glm::vec4 > | ( | const std::string | uniform, |
| glm::vec4 * | data, | ||
| unsigned int | num | ||
| ) |
Definition at line 285 of file ShaderProgram.cpp.
| void BARE2D::ShaderProgram::setUniformMatrix< glm::mat4 > | ( | const std::string | uniform, |
| bool | transpose, | ||
| glm::mat4 * | data, | ||
| unsigned int | num | ||
| ) |
Definition at line 334 of file ShaderProgram.cpp.
| void BARE2D::throwError | ( | BAREError | err, |
| std::string | message = "" |
||
| ) |
Throws an error silently. Adds it to the pile.
| err | The error to throw. |
| message | (Optional) The message to display along with the error. |
Definition at line 190 of file BAREErrors.cpp.
References getErrString(), and thrownErrors.
Referenced by BARE2D::XMLDataManager::addData(), BARE2D::LuaScriptContextWrapper::createThread(), BARE2D::AudioManager::destroy(), BARE2D::ShaderProgram::getUniformLocation(), BARE2D::AudioManager::init(), BARE2D::LuaScriptContextWrapper::loadLua(), BARE2D::XMLData::read(), BARE2D::LuaScriptEngine::registerModule(), BARE2D::LuaContextManager::removeContext(), BARE2D::LuaScriptContextWrapper::start(), throwFatalError(), and BARE2D::LuaScriptContextWrapper::update().
Here is the call graph for this function:
Here is the caller graph for this function:| void BARE2D::throwFatalError | ( | BAREError | err, |
| std::string | message = "" |
||
| ) |
Throws an error (fatal). Also calls displayErrors and exits the program.
| err | The type of error to throw. |
| message | (Optional) The message to display along with the error. |
Definition at line 178 of file BAREErrors.cpp.
References displayErrors(), and throwError().
Referenced by BARE2D::ShaderProgram::compileShaderFromSource(), BARE2D::ShaderProgram::compileShadersFromSource(), BARE2D::Window::create(), BARE2D::FBORenderer::createFBO(), BARE2D::BumpyRenderer::draw(), init(), BARE2D::Font::init(), BARE2D::App::init(), BARE2D::ShaderProgram::linkShaders(), BARE2D::ResourceManager::loadMusic(), BARE2D::ResourceManager::loadSound(), BARE2D::ResourceManager::loadTexture(), BARE2D::XMLDataManager::loadXML(), BARE2D::Logger::Logger(), BARE2D::AudioManager::moveSound(), BARE2D::AudioManager::playMusic(), BARE2D::AudioManager::playSound(), BARE2D::XMLDataManager::readXMLData(), and BARE2D::XMLDataManager::saveXML().
Here is the call graph for this function:
Here is the caller graph for this function:| GLErrorSeverity BARE2D::GLErrorMinSeverity = GLErrorSeverity::LOW |
Definition at line 130 of file BAREErrors.cpp.
Referenced by initGLErrorCallback(), and MessageCallback().
| std::vector< BAREError > BARE2D::thrownErrors |
Definition at line 132 of file BAREErrors.cpp.
Referenced by displayErrors(), and throwError().