X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fcore%2Fpixelformat.h;h=71a8bd4c3de6c98994e618d3a382be4b9dbc1791;hb=160e9eea29bd10034733d59507fa1bcca36be401;hp=dde8594e723793a001c6166e575f18f8119aa86d;hpb=33b6ca811172d402fc891eeed9cd2a5edc28d61d;p=libs%2Fgl.git diff --git a/source/core/pixelformat.h b/source/core/pixelformat.h index dde8594e..71a8bd4c 100644 --- a/source/core/pixelformat.h +++ b/source/core/pixelformat.h @@ -1,19 +1,8 @@ #ifndef MSP_GL_PIXELFORMAT_H_ #define MSP_GL_PIXELFORMAT_H_ -#include #include #include -#include "gl.h" -#include -#include -#include -#include -#include -#include -#include -#include -#include #include "datatype.h" namespace Msp { @@ -64,6 +53,7 @@ inadvisable for programs to rely on it. */ enum PixelFormat { + NO_PIXELFORMAT = 0, R8 = 0x4100|RED, R16F = 0x3200|RED, R32F = 0x3400|RED, @@ -95,7 +85,7 @@ void operator>>(const LexicalConverter &, PixelComponents &); void operator>>(const LexicalConverter &, PixelFormat &); PixelComponents components_from_graphics(Graphics::PixelFormat); -PixelFormat pixelformat_from_image(const Graphics::Image &); +PixelFormat pixelformat_from_image(const Graphics::Image &, bool = false); PixelFormat make_pixelformat(PixelComponents, DataType, bool = false); inline PixelComponents get_components(PixelFormat f) { return static_cast(f&0xFF); } @@ -108,10 +98,9 @@ inline unsigned get_pixel_size(PixelFormat f) { return get_component_count(f)*ge void require_pixelformat(PixelFormat); -GLenum get_gl_components(PixelComponents); -GLenum get_gl_pixelformat(PixelFormat); - } // namespace GL } // namespace Msp +#include "pixelformat_backend.h" + #endif