FX compilation problems

Source: Internet
Author: User

A few days ago, I updated the dxsdk, used 2006 (DEC) under the wild boar, ran the editor, and found
One problem is that FX that can be correctly compiled previously is not working now. We can trace it step by step and find that d3dxcreateeffectfromfile
The returned error is include "Global. FXX. However, the global. FXX file obviously exists.
In the same directory as the FX file to be compiled. I tried various methods to modify various configurations, that is, the compilation failed.
Finally, I had to write the absolute path of Global. FXX in FX. OK. It's strange.
Analysis result: When d3dxcreateeffectfromfile is used, the include processing is not similar to C ++.
Relative to this FX file, is it related to the current path? So I modified the include and considered to executeProgramOf
Current path. Everything works. I faint. The strange setting is that August 2005 didn't do this before ..
How can I know the current path when I write FX?
The proposed solution uses macros to define absolute paths, but # include cannot use macro.
Do I have to use setcurrentdirectory for createeffect? Isn't that disgusting?
Of course, when the game was finally released in my engine, I made a d3dxinclude interface to solve the problem.
This problem, but during the debugging period, I hope to be able to RT debug FX. I got sick.

I haven't updated my blog for a long time. I want to write a few other things that have happened recently:
1. Xiao Wei made another colleague and asked him to separate the scenes.
2. I accidentally bumped into a rock when I was eating and parking, and my heart hurts.
3. Unfortunately recently, my wife and I are both ill.
4. In the company, too many sb. I'm going to get sick of them.
 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.