|
1 | 1 | # XMapLib |
2 | 2 | A closer to the metal library for Xbox controller to keyboard and mouse input. |
3 | 3 |
|
4 | | -<a href="https://ibb.co/vmjctWD"><img src="https://i.ibb.co/ZKMfZrN/XMap-Lib-uml.jpg" alt="XMap-Lib-uml" border="0"></a> |
5 | | - |
6 | | -The main classes for use are : |
7 | | -<b><p><a href="https://github.com/calebtt/XMapLib/blob/master/XMapLib/MouseMapper.h">MouseMapper</a></p></b> |
8 | | -<b><p><a href="https://github.com/calebtt/XMapLib/blob/master/XMapLib/KeyboardMapper.h">KeyboardMapper</a></p></b> |
9 | | -<b><p><a href="https://github.com/calebtt/XMapLib/blob/master/XMapLib/MousePlayerInfo.h">MousePlayerInfo</a></p></b> |
10 | | -<b><p><a href="https://github.com/calebtt/XMapLib/blob/master/XMapLib/KeyboardPlayerInfo.h">KeyboardPlayerInfo</a></p></b> |
11 | | -To set the mapping details <b><a href="https://github.com/calebtt/XMapLib/blob/master/XMapLib/KeyboardKeyMap.h">KeyboardKeyMap</a></b> encapsulates the information comprising a controller key to keyboard/mouse key mapping. |
| 4 | +<p>XMapLibSharp is a C# .NET GUI project using the C++ project code through a DLL. With this approach, |
| 5 | +the project has access to the entire .NET framework for GUI work while keeping the native performance and power of the C++ XMapLib project code. |
| 6 | + <p>The project utilizes |
| 7 | +<ul> |
| 8 | + <li>.NET multi-threading</li> |
| 9 | + <li>events</li> |
| 10 | + <li>programmatic UI element creation</li> |
| 11 | + <li>a producer/consumer design pattern.</li> |
| 12 | + <li>managed/native interop via custom C++ DLL</li> |
| 13 | +</ul> |
| 14 | + |
| 15 | +<a href="https://ibb.co/x28d2WX"><img src="https://i.ibb.co/0nVvnTm/XMap-Lib-gui1.jpg" alt="XMap-Lib-gui1" border="0"></a> |
| 16 | + |
| 17 | + <b><p>A high level code diagram of the XMapLib project code (native C++)</b> |
| 18 | + <p>The project utilizes |
| 19 | + <ul> |
| 20 | + <li>C++ templates</li> |
| 21 | + <li>Template SFINAE</li> |
| 22 | + <li>constexpr</li> |
| 23 | + <li>unit testing with Microsoft <a href="https://docs.microsoft.com/en-us/visualstudio/test/how-to-use-microsoft-test-framework-for-cpp?view=vs-2022">CppUnitTestingFramework</a></li> |
| 24 | + <li>multi-threading, many threads running concurrently and interacting</li> |
| 25 | + <li>concurrency synchronization objects, like mutexes and RAII scoped locks</li> |
| 26 | + <li>C++ standard atomics</li> |
| 27 | + <li>lambdas, and passing lambdas as arguments</li> |
| 28 | + <li>usage of several Windows API functions including the XInput lib</li> |
| 29 | + <li>operator overloads</li> |
| 30 | + <li>input simulation</li> |
| 31 | + <li>C++ pointer wrappers like unique_ptr</li> |
| 32 | + <li>if-constexpr to do compile-time decisions instead of run-time</li> |
| 33 | + <li>STL containers and algorithms</li> |
| 34 | + <li>it is a real time system (or very close)</li> |
| 35 | + <li>lots and lots of object oriented programming</li> |
| 36 | + </ul> |
| 37 | + <a href="https://ibb.co/kBvqrRX"><img src="https://i.ibb.co/g9htX5J/XMap-Lib-uml3.png" alt="XMapLib-uml" border="0"></a> |
| 38 | + |
| 39 | + <b>The main classes for use in the native C++ XMapLib project are :</b> |
| 40 | + <ul> |
| 41 | +<li><b><a href="https://github.com/calebtt/XMapLib/blob/master/XMapLib/MouseMapper.h">MouseMapper</a></b></li> |
| 42 | +<li><b><a href="https://github.com/calebtt/XMapLib/blob/master/XMapLib/KeyboardMapper.h">KeyboardMapper</a></b></li> |
| 43 | +<li><b><a href="https://github.com/calebtt/XMapLib/blob/master/XMapLib/MousePlayerInfo.h">MousePlayerInfo</a></b></li> |
| 44 | +<li><b><a href="https://github.com/calebtt/XMapLib/blob/master/XMapLib/KeyboardPlayerInfo.h">KeyboardPlayerInfo</a></b></li> |
| 45 | +<li>To set the mapping details <b><a href="https://github.com/calebtt/XMapLib/blob/master/XMapLib/KeyboardKeyMap.h">KeyboardKeyMap</a></b> encapsulates the information comprising a controller key to keyboard/mouse key mapping.</li> |
| 46 | + </ul> |
12 | 47 | <p>Also, please see the <b><a href="https://github.com/calebtt/XMapLib/blob/master/XMapLib/XMapLib.cpp">Example</a></b></p> |
| 48 | + |
| 49 | +<b><p>The DLL API exposed from XMapLibDLL is described totally in <a href="https://github.com/calebtt/XMapLib/blob/master/XMapLibDLL/apifuncs.h">apifuncs.h</a> in the DLL project.</b> |
0 commit comments