Archived

This topic is now archived and is closed to further replies.

billybob

loading from directories with createTextureFromFile

Recommended Posts

try \\

C/C++ reads \ as telling the compiler to prepare for a string manipulation (ie \n newline \t tab etc)

Neil

WHATCHA GONNA DO WHEN THE LARGEST ARMS IN THE WORLD RUN WILD ON YOU?!?!

Share this post


Link to post
Share on other sites
Use the current directory by not specifying that dir at all.

Instead of doing
C:\\game\\content\\blah

Do
content\\blah

Keep in mind that in Visual C++ you''ll get the build appearing in a Debug or Release dir, but the current directory is the one above that.


Helpful links:
How To Ask Questions The Smart Way | Google can help with your question | Search MSDN for help with standard C or Windows functions

Share this post


Link to post
Share on other sites
Just a note: ".\\Filename" or ".\\Directory\\Filename" also specify the ''current directory''.

_____________________________________________
Come join us on IRC in #directxdev @ irc.afternet.org

Share this post


Link to post
Share on other sites
quote:
Original post by Tergiver
Just a note: ".\\Filename" or ".\\Directory\\Filename" also specify the ''current directory''.



How would one go about setting the current directory, just to make sure things will work as one would expect?


Moe''s site

Share this post


Link to post
Share on other sites
CHAR strSoundPath[MAX_PATH];
GetCurrentDirectory(MAX_PATH, strSoundPath);

That help?

Neil

WHATCHA GONNA DO WHEN THE LARGEST ARMS IN THE WORLD RUN WILD ON YOU?!?!

Share this post


Link to post
Share on other sites