1 #include "deviceinfo.h"
3 #include "texture2dmultisample.h"
10 Texture2DMultisample::Texture2DMultisample():
15 void Texture2DMultisample::storage(PixelFormat fmt, unsigned wd, unsigned ht, unsigned sm)
19 if(fmt!=format || wd!=width || ht!=height || sm!=samples)
20 throw incompatible_data("Texture2DMultisample::storage");
24 throw invalid_argument("Texture2DMultisample::storage");
25 if(!sm || sm>DeviceInfo::get_global().limits.max_samples)
26 throw invalid_argument("Texture2DMultisample::storage");
36 void Texture2DMultisample::image(const Graphics::Image &, unsigned)
38 throw invalid_operation("Texture2DMultisample::image");
41 uint64_t Texture2DMultisample::get_data_size() const
43 return id ? width*height*get_pixel_size(format)*samples : 0;