X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fcore%2Fframeformat.cpp;h=649693a43715a94b02974501148b21e4bc576592;hb=e70662d7812464159f2e47f4bebb69d88f89ae93;hp=7fe179331abad0f9e1d70859e0da500ae142378b;hpb=38712d8ecc57d043a2419ffbaeeb57f7a6586f14;p=libs%2Fgl.git diff --git a/source/core/frameformat.cpp b/source/core/frameformat.cpp index 7fe17933..649693a4 100644 --- a/source/core/frameformat.cpp +++ b/source/core/frameformat.cpp @@ -1,7 +1,5 @@ -#include "deviceinfo.h" #include "error.h" #include "frameformat.h" -#include "gl.h" using namespace std; @@ -80,7 +78,9 @@ FrameAttachment make_typed_attachment(FrameAttachment fa, PixelFormat pf) } else { - if(comp!=RED && comp!=RG && comp!=RGB && comp!=RGBA) + if(comp!=RED && comp!=RG && comp!=RGB && comp!=RGBA && comp!=BGR && comp!=BGRA) + throw invalid_argument("make_typed_attachment"); + if(get_required_swizzle(comp)) throw invalid_argument("make_typed_attachment"); }