-/*\r
-* Copyright (c) 2011 Sveriges Television AB <info@casparcg.com>\r
-*\r
-* This file is part of CasparCG (www.casparcg.com).\r
-*\r
-* CasparCG is free software: you can redistribute it and/or modify\r
-* it under the terms of the GNU General Public License as published by\r
-* the Free Software Foundation, either version 3 of the License, or\r
-* (at your option) any later version.\r
-*\r
-* CasparCG is distributed in the hope that it will be useful,\r
-* but WITHOUT ANY WARRANTY; without even the implied warranty of\r
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\r
-* GNU General Public License for more details.\r
-*\r
-* You should have received a copy of the GNU General Public License\r
-* along with CasparCG. If not, see <http://www.gnu.org/licenses/>.\r
-*\r
-* Author: Robert Nagy, ronag89@gmail.com\r
-*/\r
-\r
-#pragma once\r
-\r
-#include <common/memory.h>\r
-#include <common/enum_class.h>\r
-\r
-#include <cstdint>\r
-\r
-namespace caspar { namespace accelerator { namespace ogl {\r
- \r
-class buffer sealed\r
-{\r
- buffer(const buffer&);\r
- buffer& operator=(const buffer&);\r
-public:\r
-\r
- // Static Members\r
-\r
- struct usage_def\r
- {\r
- enum type\r
- {\r
- write_only,\r
- read_only\r
- };\r
- };\r
- typedef enum_class<usage_def> usage;\r
- \r
- // Constructors\r
-\r
- buffer(std::size_t size, usage usage);\r
- buffer(buffer&& other);\r
- ~buffer();\r
-\r
- // Methods\r
-\r
- buffer& operator=(buffer&& other);\r
- \r
- void map();\r
- void unmap();\r
-\r
- void bind() const;\r
- void unbind() const;\r
-\r
- // Properties\r
-\r
- uint8_t* data();\r
- std::size_t size() const; \r
-\r
- int id() const;\r
-\r
-private:\r
- struct impl;\r
- spl::unique_ptr<impl> impl_;\r
-};\r
-\r
+/*
+* Copyright (c) 2011 Sveriges Television AB <info@casparcg.com>
+*
+* This file is part of CasparCG (www.casparcg.com).
+*
+* CasparCG is free software: you can redistribute it and/or modify
+* it under the terms of the GNU General Public License as published by
+* the Free Software Foundation, either version 3 of the License, or
+* (at your option) any later version.
+*
+* CasparCG is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+* GNU General Public License for more details.
+*
+* You should have received a copy of the GNU General Public License
+* along with CasparCG. If not, see <http://www.gnu.org/licenses/>.
+*
+* Author: Robert Nagy, ronag89@gmail.com
+*/
+
+#pragma once
+
+#include <common/memory.h>
+#include <common/enum_class.h>
+
+#include <cstdint>
+
+namespace caspar { namespace accelerator { namespace ogl {
+
+class buffer sealed
+{
+ buffer(const buffer&);
+ buffer& operator=(const buffer&);
+public:
+
+ // Static Members
+
+ struct usage_def
+ {
+ enum type
+ {
+ write_only,
+ read_only
+ };
+ };
+ typedef enum_class<usage_def> usage;
+
+ // Constructors
+
+ buffer(std::size_t size, usage usage);
+ buffer(buffer&& other);
+ ~buffer();
+
+ // Methods
+
+ buffer& operator=(buffer&& other);
+
+ void map();
+ void unmap();
+
+ void bind() const;
+ void unbind() const;
+
+ // Properties
+
+ uint8_t* data();
+ std::size_t size() const;
+
+ int id() const;
+
+private:
+ struct impl;
+ spl::unique_ptr<impl> impl_;
+};
+
}}}
\ No newline at end of file