Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>I don't know for sure why the DirectMusic framework would use one set of codepages, and MME another, but the solution here on your end is probably to build an abstraction layer and then make specific implementations for each API. That way, the higher levels of your software don't need to concern itself with details like this.</p> <p>That said, the endpoint names definitely come from the OS. USB MIDI devices specify only endpoint types (ie, either input or output, and the number), but the OS is free to interpret them as it sees fit, which is why they are localized.</p> <p>There is not a specific API call (as far as I know) to find out which codepage the framework will deliver its strings in. However, DirectMusic does seem to use double wide characters with OEM codepage as a general convention, though I could not find this clearly stated in any of the MSDN docs. In the <a href="http://msdn.microsoft.com/en-us/library/dd551307(VS.85).aspx" rel="nofollow noreferrer">MSDN DirectMusic documentation about MIDI port capability structures</a>, the description type clearly is defined as a WCHAR, and the <a href="http://books.google.se/books?id=0TAE5me0GhwC&amp;pg=PA219&amp;lpg=PA219&amp;dq=directmusic+double+wide+characters&amp;source=bl&amp;ots=_5IAA0ZTNV&amp;sig=-vmYaPOJcM2igD-UDXsAH3KRmy0&amp;hl=sv&amp;ei=TDtWSu2PCZ6mnQPyxeTdCQ&amp;sa=X&amp;oi=book_result&amp;ct=result&amp;resnum=1" rel="nofollow noreferrer">Game Audio Programming</a> book seems to also indicate that this type is an API-wide convention. While it's dangerous to assume that OEM is the default encoding for these chars, I can't find anything that says otherwise (and googling for "DirectMusic codepage" now lists this page as the top hit).</p> <p><em>Edit</em>: Check out this <a href="https://stackoverflow.com/questions/909913/how-can-i-programmatically-determine-the-current-default-codepage-of-windows">stackoverflow question on determining the current OS codepage</a>. It is possible that the DirectMusic API sets the codepage in this manner.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload