- Unicode Build Support added
- DX11 minimizing the renderwindow works now without problems
- DX11 alpha blending support added
- DX11 Texture source cleanup
Memory leak in Ogre::MultibyteToWidechar(...)
Patch is not complete - it is based on some other patch, as it modifies not existed file OgreMain\include\Win32\OgreMultiByteToWideCharacter.h
Also, function Ogre::OgreMultiByteToWideCharacter has confusing name as it returns narrow string if UNICODE is not defined.
Also, patch contains many modifications not related to its purpose.
Another problem is with narrow strings interpretation - in one place in the Ogre it is interpreted as CP_OEM, that is wrong too, and you hardcoded CP_ACP interpretation. Things became little more complicated as modern C runtimes converts narrow strings to wide before wide OS call, and legacy C runtimes directly uses narrow OS calls that are sensitive to SetFileApisAnsi/Oem calls.
I suggest to rewrite Ogre::MultiByteToWideChar function to always return wide string. Codepage must be selected between CP_OEM and CP_ACP based on AreFileApisAnsi() call, and all Win32 file system calls should be made explicitly to XxxW variants instead of just Xxx. And of course, memory leak needs to be fixed.
Was wrong about modifications not related to patch purpose - it seems that thay are declared, and this is just multi-purposed patch.
Anyway, IMHO it`s better to split it to several patches, as their destiny can be different.
Yeah, could you separate at least the unicode patch out?
Sry for answering so late, I didn't had time.
Yeah I will fix the memory leak and separate the patches.
Unicode Build Support
Now I had time to split it up.
The Ogre Trunk Patches_3507.patch contains all Unicode Build Support Changes and the Ogre Trunk Patches_3506.patch contains all Patches from me for DX11.
OgreMultiByteToCompiledEncoding.h is missing from the patch.
Log in to post a comment.