|
- <!DOCTYPE html>
- <html>
- <meta charset="utf-8">
- <head>
- <link rel="stylesheet" href="../../style.css">
- </head>
- <body>
- <script data-goatcounter="https://services.opengamestudio.org:443/count" async src="//services.opengamestudio.org:443/count.js"></script>
- <div id="header">
- <div class="header2">
- <div class="menu">
- <a href="../../en/news/index.html">News</a>
- <a href="../../en/game/index.html">Games</a>
- <a href="../../en/tool/index.html">Tools</a>
- <a href="../../en/page/about.html">About</a>
- </div>
- <div id="lang">
- <a href="../../en/news/2016-november-recap.html">EN</a>
- <a href="../../ru/news/2016-november-recap.html">RU</a>
- </div>
- <div class="clear"></div>
- </div>
- </div>
- <h3 class="left_item_title">In the news...</h3>
- <center>
- <div class="news_item">
- <h2 class="news_item_title">
- <a href="2016-november-recap.html">November 2016 recap</a>
- </h2>
- <p class="news_item_date">
- 2016-12-15 00:00
- </p>
- <div class="news_item_contents">
- <p><img src="../../images/2016-12-15_2016-november-recap.png" alt="Construction of a building" /></p>
- <p>This article describes the start of MJIN library separation into modules.</p>
- <p>Once we built OpenSceneGraph for Android, it became obvious that some MJIN functionality is not suitable for Android. For example, UIQt provides a basis for OGS Editor UI. Since OGS Editor is a desktop application, we don't need UIQt for Android.</p>
- <p>We decided to have a look at two approaches to separate MJIN into modules: build-time separation and run-time one.
- <strong>Build-time</strong> separation means MJIN becomes highly configurable and each platform gets specifically tailored MJIN build.
- <strong>Run-time</strong> separation means MJIN is divided into smaller libraries that are connected at run-time, which makes it easy to change functionality without rebuilding.</p>
- <p><strong>Run-time separation research.</strong></p>
- <p>Since run-time separation has more benefits, we started researching it first. The easiest way to achieve it was to use C API, because C ABI rules are much simpler than C++ one's.</p>
- <p>We created a sample project consisting of the application, library, and plugin:</p>
- <ul>
- <li><strong>The application</strong> has been linked to the library and used it to load the plugin.</li>
- <li><strong>The library</strong> provided functions to register plugins and call their functions.</li>
- <li><strong>The plugin</strong> provided functions for the library and called library functions.</li>
- </ul>
- <p>The research was successful: the sample project worked correctly under Linux and Windows. However, since MJIN is currently a single large entity, we postponed C API application until we finish build-time separation.</p>
- <p><strong>Build-time separation start.</strong></p>
- <p>We extracted the following modules from MJIN:</p>
- <ul>
- <li>Android: provides Java Native Interface (JNI) to MJIN</li>
- <li>Sound: provides access to OpenAL</li>
- <li>UIQt: provides access to Qt UI</li>
- </ul>
- <p>Sound and UIQt modules are currently statically linked into MJIN library, while Android module is already a separate library due to JNI requirements.</p>
- <p>In the coming year, we're going to significantly restructure MJIN so that it suits as many platforms as possible.</p>
- <p>That's it for describing the start of MJIN library separation into modules.</p>
- </div>
- </div>
- <div id="disqus_thread"></div>
- <script>
- var disqus_config = function () {
- this.page.url = "https://opengamestudio.org/en/news/2016-november-recap.html";
- this.page.identifier = "2016-november-recap.html";
- };
- (function() { // DON'T EDIT BELOW THIS LINE
- var d = document, s = d.createElement('script');
- s.src = 'https://opengamestudio.disqus.com/embed.js';
- s.setAttribute('data-timestamp', +new Date());
- (d.head || d.body).appendChild(s);
- })();
- </script>
- <noscript>Please enable JavaScript to view the <a href="https://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
- <div id="footer">
- The site has been generated by <a href="http://opengamestudio.org/pskov">PSKOV</a>
- from <a href="http://github.com/ogstudio/site-opengamestudio">this source code</a>.
- </div>
- </center>
- </body>
- </html>
|