[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: AW: Lua x DirectX
- From: Sebastian Rohde <rohde@...>
- Date: Wed, 15 Mar 2006 18:08:33 +0100
I think 1+3 or 1+2 would be the best options. For the third option: Wouldn't
it be feasible to add the check upon the first call to this macro in the
Another thing: This problem could be caused by DirectX but mentioning it
only in this context seems improper to me. We had this problem because we
decided to use single precision an ensured this everywhere (Whether that is
good or not doesn't matter for the fact that it is not a DirectX issue).
[mailto:firstname.lastname@example.org] Im Auftrag von
Gesendet: Mittwoch, 15. März 2006 17:52
An: Lua discussion list
Betreff: Lua x DirectX
It seems that too many people are having problems with this DirectX issue.
How can we solve that??
- Some people suggested adding some warning in the manual. Would this
really help? I mean, if you find an unexpected bug in a program, where
will you search for help? In the manual? In what section?
- Another option would be to simply turn off the offending macro
(lua_number2int) in Windows. This will slow down Lua a bit... Of
course, anyone is free to use it, but the default would avoid the
problem. (Doesn't Windows offer lrint? Could we use it instead?)
- Other option would be to add a check somewhere in the code, so
that this situation is detected early and gives a proper error message.
(Unfortunately, the test cannot be when creating a Lua state, because
there is no way to return an error message. Maybe when loading a chunk?)