DeanoC wrote:gilesgoat wrote:
To me that sounds some "weird strncat problem somewhere" .. wtf .. wtf ???
I suspect you are right, the blahblahA are on the legacy line now I think, so probably not entirely tested that well these days. After all in reality only useful for Win9x, as NT has always been unicode, you can probably wrap your own version of that blablahA function just using
Code: Select all
std::string wstring_to_utf8(const std::wstring& str)
{
std::wstring_convert<std::codecvt_utf8<wchar_t>> myconv;
return myconv.to_bytes(str);
}
around the strings, will convert the unicode 16 bit code points into UTF8 so can be handled by good old char code. IIRC requires VisStudio 2012 as before there was a bug in codecvt_utf8.
No ... no no no no .. it's
le chalisse ...
One of the biggest mistakes in my life been "fuck all this shit, let's go all unicode full stop".
UTF-8 .. UTF-8 is what you want .. and NOTHING ELSE ..
1 byte per thing use extra bytes IF necessary ...
Anything else I tried with "unicode" or "other standards" always seems to miserably fail in some HW or another or one OS or another hopelessly.
Anyway back to this I was JUST telling Yak "it is true something CPP can create code that ONLY the one that made it, maybe ... I'd like to see this 6 months later .. can understand it".
I tried to debug/hack the OVR lib to understand "how the heck they enumerate those devices" .. well .. "you kinda get the idea about what the code kinda does" .. "kinda" .. but you don't really get PRECISELY how .. after getting lost in "too many templates" and not sure at this point what's calling what and where ( let alone where are the parameters going ) it's like .. "ok, the heck knows how they get something that I can't get in any way" .
Anyway turns out the problem I belived was there wasn't there, there was nothing wrong with my previous enumeration way and nor with the second I've done, in fact they were equivalent/almost identical.
"Almost" because anyway they were getting something like "Display1/Monitor1" in a CLONE mode, while I was getting a "Display1/Monitor0" and "Display2/Monitor0" as - according to MSDN - should be correct when you are in clone, you'd get
that 'Monitor1' only if your monitor is "extended".
So at that point is like "the fuck I know how they get that/who is more correct in this case and why".
But you really don't have to look at that "monitor" you really have to look and need only at that "DisplayX".
Anyway the problem wasn't there.
The problem was someone was working in clone mode with a display that was not supporting the OR "higher res".
I.E. the OR has a native res of 1200x800 BUT the display supports a couple of more modes higher than that, now many people found out that - keeping proportions and all the rest correct - as the PHYSICAL dimensions of the device don't change ( that ratio does but that gets corrected ), if you set a higher res the downsampling does a much better AA than what you'd do 'at cost 0' because it's done inside the OR HW and does not impact latency.
Try to believe it, it's *MUCH* better if you set 1920x1200 and you draw like that.
Of course if you are in clone mode and your display does not go over 1080 ....