-
-
Notifications
You must be signed in to change notification settings - Fork 404
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Incorrect string marshaling when "ID3D12Object::SetName" was called #630
Comments
So basically every second character makes it? I guess it's a problem with UTF16 vs UTF8, which indicates an annotation mistake. @Perksey assigning you for now, assuming this is BuildTools work? |
Yes, the native API uses LPCWSTR to receive the name, which points to UTF-16 wchar. HRESULT SetName(
LPCWSTR Name
); |
Will fix this for 2.10. Assuming that BuildTools already collects the |
* Build improvements & dynamic Windows SDK resolution (backport from 3.0) * Changes to some code formatting * Fix build errors * Fix build error * Enhanced typedef-powered renaming * Fix #652 * Marshal generic pointers in COM vtable wrapper functions * String generation improvements (fixes #630) * Sanity check, remove JetBrains.Annotations
* Build improvements & dynamic Windows SDK resolution (backport from 3.0) * Changes to some code formatting * Fix build errors * Fix build error * Enhanced typedef-powered renaming * Fix #652 * Marshal generic pointers in COM vtable wrapper functions * String generation improvements (fixes #630) * Sanity check, remove JetBrains.Annotations
Summary
SetName("DepthStencil")
But I got
(0x000001CAA011C1C0:'Dphtni)
Steps to reproduce
Then I got this error:
Comments
It looks like Silk is using
Marshal.StringToHGlobalAnsi()
rather thanStringToBSTR()
, which drops half of the letters due to the encoding.The text was updated successfully, but these errors were encountered: