#include <iostream>
enum Type {
UNTEXTURED = 0,
TEXTURED = 2
};
template <Type type>
struct Vertex {
float pos[3];
float normal[3];
float texCoord[type];
};
template <Type type>
class Mesh {
Vertex<type> array[256];
};
int main() {
Mesh<TEXTURED> test1;
std::cout << sizeof(test1) << std::endl;
Mesh<UNTEXTURED> test2;
std::cout << sizeof(test2) << std::endl;
return 0;
}
I2luY2x1ZGUgPGlvc3RyZWFtPgoKZW51bSBUeXBlIHsKICAgIFVOVEVYVFVSRUQgPSAwLAogICAgVEVYVFVSRUQgPSAyCn07Cgp0ZW1wbGF0ZSA8VHlwZSB0eXBlPgpzdHJ1Y3QgVmVydGV4IHsKICAgIGZsb2F0IHBvc1szXTsKICAgIGZsb2F0IG5vcm1hbFszXTsKICAgIGZsb2F0IHRleENvb3JkW3R5cGVdOwp9OwoKdGVtcGxhdGUgPFR5cGUgdHlwZT4KY2xhc3MgTWVzaCB7CiAgICBWZXJ0ZXg8dHlwZT4gYXJyYXlbMjU2XTsKfTsKCmludCBtYWluKCkgewogICAgTWVzaDxURVhUVVJFRD4gdGVzdDE7CiAgICBzdGQ6OmNvdXQgPDwgc2l6ZW9mKHRlc3QxKSA8PCBzdGQ6OmVuZGw7CiAgICAKICAgIE1lc2g8VU5URVhUVVJFRD4gdGVzdDI7CiAgICBzdGQ6OmNvdXQgPDwgc2l6ZW9mKHRlc3QyKSA8PCBzdGQ6OmVuZGw7CiAgICAKICAgIHJldHVybiAwOwp9