stdecden
26-08-2007, 22:16
Sto cercando di compilare un programma utilizzando directx che carica un modello da file e caricare anche le immagini. Questo listato contiene la funzione(o macro ) CA2W che perķ sembra non essere definita!!
Ecco un pezzo del listato:
material[i] = tempMaterials[i].MatD3D; // get the material info
material[i].Ambient = material[i].Diffuse; // make ambient the same as diffuse
USES_CONVERSION; // allows certain string conversions
// if there is a texture to load, load it
if(FAILED(D3DXCreateTextureFromFile(d3ddev,
CA2W(tempMaterials[i].pTextureFilename),
&texture[i])))
texture[i] = NULL; // if there is no texture, set the texture to NULL
P.S. Utilizzo visual c++ express edition con platform sdk ed ho incluso #include<atlbase.h>
Ecco un pezzo del listato:
material[i] = tempMaterials[i].MatD3D; // get the material info
material[i].Ambient = material[i].Diffuse; // make ambient the same as diffuse
USES_CONVERSION; // allows certain string conversions
// if there is a texture to load, load it
if(FAILED(D3DXCreateTextureFromFile(d3ddev,
CA2W(tempMaterials[i].pTextureFilename),
&texture[i])))
texture[i] = NULL; // if there is no texture, set the texture to NULL
P.S. Utilizzo visual c++ express edition con platform sdk ed ho incluso #include<atlbase.h>