OpenGL-utility/include/openglu.hpp

50 lines
1.4 KiB
C++
Raw Normal View History

2021-01-21 14:30:48 +00:00
/*****************************************************************//**
* @file openglu.hpp
* @brief Basic includes and some exposed OpenGL
*
* @author Lauchmelder
* @date January 2021
*********************************************************************/
2021-01-19 18:25:46 +00:00
#ifndef OPENGLU_HPP
#define OPENGLU_HPP
2021-01-21 11:07:43 +00:00
#include <color.hpp>
2021-01-21 14:30:48 +00:00
#include <vertexArray.hpp>
2021-01-21 11:07:43 +00:00
#include <shader.hpp>
#include <texture.hpp>
2021-01-19 18:25:46 +00:00
namespace oglu
{
2021-01-21 14:30:48 +00:00
/**
* @brief Loads the GL Loader to be used by OGLU.
*
* OpenGL function addresses can vary across platforms and drivers, so we
* need to know where these functions are in order to work properly.
*
* @param[in] proc A pointer to a function that returns the addresses of OpenGL functions
*/
2021-01-19 18:25:46 +00:00
OGLU_API void LoadGLLoader(GLADloadproc proc);
2021-01-21 14:30:48 +00:00
/**
* @brief Wrapper of glViewport.
*
* @param[in] x Horizontal Position of the viewport
* @param[in] y Vertical Position of the viewport
* @param[in] width Width of the viewport
* @param[in] height Height of the viewport
*/
2021-01-19 18:25:46 +00:00
OGLU_API void SetViewport(GLint x, GLint y, GLsizei width, GLsizei height);
2021-01-21 14:30:48 +00:00
/**
* @brief Convenience function for glClear
*
* Sets the clear color and then clears the screen.
*
* @param[in] mask Buffers to be cleared
* @param[in] clearColor Color to clear the screen with
*/
2021-01-19 18:25:46 +00:00
OGLU_API void ClearScreen(GLbitfield mask, Color clearColor);
}
#endif //OPENGLU_HPP