我希望在连接用于Direct3D 9.0的顶点声明时解决以下警告
int elements = 1 + useNormals + useTextures + useColors + 1;
D3DVERTEXELEMENT9 customvertex[elements];
customvertex[0] = POSITIONELEMENT;
int i = 1;
if (useNormals) { customvertex[i] = NORMALELEMENT; i += 1; }
if (useTextures) { customvertex[i] = TEXTUREELEMENT; i += 1; }
if (useColors) { customvertex[i] = COLORELEMENT; i += 1; }
customvertex[i] = D3DDECL_END();
最后一行是使用MinGW编译时产生以下警告的行。
Graphics_Systems / Direct3D9 / DX9model.cpp:340:20:警告:扩展初始化程序列表仅适用于-std = c ++ 11或-std = gnu ++ 11 [默认启用]