Hi, I have a simular problem, although I don't really know if it is the same.
As soon as I clicked the "build solution" button, it showed 12 errors, all in the Colors.h folder. It says "illegal statement or sub-expression for 'constexpr' function (compiling source file **** )" I am a complete noob, I'm sure there is a simple solution for this, but I don't want to screw up something by accident.
https://ibb.co/D5vSsjd - this is a link to a picture of the screen. If everything is right.
Thank you for any answers in advance!
dxerr.lib error running Chili Framework
Re: dxerr.lib error running Chili Framework
That's not build errors, but rather the intellisense engine linting your code and trying to point out error before you build. Unfortunately, Intellisense quite often fucks up. Build it and show the /Output/ window. That's where the real errors are.
Chili
-
- Posts: 4373
- Joined: February 28th, 2013, 3:23 am
- Location: Oklahoma, United States
Re: dxerr.lib error running Chili Framework
Yeah, I've explained this before on here somewhere, but would be probably pretty difficult to find if you aren't looking for it...if it's the same situation as I'm thinking.
The parameters for Color are unsigned char which is fine because color channels are only 8 bits wide. However, the constructor bitwise or's together the 3-4 values to make a 32 bit value, which doesn't fit into an unsigned char. Doing the or and shift operations on chars promotes them to ints which the compiler complains if the values being passed to the constructor and or'd together are over std::numeric_limits<int>::max(). If you however change the parameters to unsigned ints instead of unsigned chars, the "errors" will go away, but that does have other side effects.
The parameters for Color are unsigned char which is fine because color channels are only 8 bits wide. However, the constructor bitwise or's together the 3-4 values to make a 32 bit value, which doesn't fit into an unsigned char. Doing the or and shift operations on chars promotes them to ints which the compiler complains if the values being passed to the constructor and or'd together are over std::numeric_limits<int>::max(). If you however change the parameters to unsigned ints instead of unsigned chars, the "errors" will go away, but that does have other side effects.
If you think paging some data from disk into RAM is slow, try paging it into a simian cerebrum over a pair of optical nerves. - gameprogrammingpatterns.com