tag:blogger.com,1999:blog-11211961289505458432024-03-05T20:34:44.470+00:00Runtime-Compiled C++Edit your C++ code while it's runningMatthew Jackhttp://www.blogger.com/profile/10376036816175954433noreply@blogger.comBlogger33125tag:blogger.com,1999:blog-1121196128950545843.post-14975582267365399732020-02-02T11:11:00.002+00:002020-02-02T11:12:27.531+00:00Runtime Compiled C++ Dear ImGui and DirectX11 TutorialI've just published a new tutorial on RCC++ over on our devlog: <a href="https://www.enkisoftware.com/devlogpost-20200202-1-Runtime-Compiled-C++-Dear-ImGui-and-DirectX11-Tutorial">Runtime Compiled C++ Dear ImGui and DirectX11 Tutorial</a><br />
<br />
This comes with full source code and in addition to the article a set of videos running through it.Doug Binkshttp://www.blogger.com/profile/18011269239780247978noreply@blogger.com0tag:blogger.com,1999:blog-1121196128950545843.post-6708370764894279382017-10-31T11:29:00.000+00:002017-10-31T11:29:17.426+00:00Speeding up Runtime Compiled C++ compile times in MSVC with d2cgsummary<br />
I'm moving new RCC++ blog posts to my own site over at <a href="https://www.enkisoftware.com/devlog-rcc++">enkisoftware RCC++</a> as it's much more convenient for me to write posts with our own system.<br />
<br />
New Blog post: <a href="https://www.enkisoftware.com/devlogpost-20171031-1-Speeding-up-Runtime-Compiled-C++-compile-times-in-MSVC-with-d2cgsummary">Speeding up Runtime Compiled C++ compile times in MSVC with d2cgsummary </a><br />
<br />
<br />
<table align="center" cellpadding="0" cellspacing="0" class="tr-caption-container" style="margin-left: auto; margin-right: auto; text-align: center;"><tbody>
<tr><td style="text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh_S3yfZ6NLTyl7zuT_ZUAY9rBozqtaQZXetTjc-6cfHIdfZKWKmnfiNYTf_NWD6WhCQiLSgvRMEaNQduIMjzSi8zCCSQTQrpoopZLKil3iYRQaxqRwLyavrTwrlScPnmgFxt1fz_Cn7wo/s1600/Avoyd_2017-10-30_RCCpp_Compile_Performance.jpg" imageanchor="1" style="margin-left: auto; margin-right: auto;"><img border="0" height="180" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh_S3yfZ6NLTyl7zuT_ZUAY9rBozqtaQZXetTjc-6cfHIdfZKWKmnfiNYTf_NWD6WhCQiLSgvRMEaNQduIMjzSi8zCCSQTQrpoopZLKil3iYRQaxqRwLyavrTwrlScPnmgFxt1fz_Cn7wo/s320/Avoyd_2017-10-30_RCCpp_Compile_Performance.jpg" width="320" /></a></td></tr>
<tr><td class="tr-caption" style="text-align: center;">Faster Runtime Compilation after using /d2cgsummary in MSVC to diagnose slow compile times.</td></tr>
</tbody></table>
<br />Doug Binkshttp://www.blogger.com/profile/18011269239780247978noreply@blogger.com0tag:blogger.com,1999:blog-1121196128950545843.post-52227977138668069592016-04-17T16:21:00.000+01:002016-04-17T16:21:22.131+01:00Runtime Compiled C++ article available onlineOur <a href="http://www.gameaipro.com/GameAIPro/GameAIPro_Chapter15_Runtime_Compiled_C++_for_Rapid_AI_Development.pdf">2013 article on Runtime Compiled C++ for Game AI Pro is now available for free online</a>. If you're interested in AI development <a href="http://www.gameaipro.com/">the entire book can be found for for free at the bottom of the main Game AI Pro website.</a><br />
<br />
<table align="center" cellpadding="0" cellspacing="0" class="tr-caption-container" style="margin-left: auto; margin-right: auto; text-align: center;">
<tbody>
<tr>
<td style="text-align: center;"><img alt="Game AI Pro" border="0" height="200" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhWCqNTg8iwgfCWk9bzLXHvsXgj74Mzl7-T8NJLLMlqLglvnk83p3V7l0kFK-quSnLtDaeM3shWcaZgkihW4C2Iu7aPqDtsX7TQXu1j2NkJpCTL7v7_a0oTbdQ5DFEatgYRdGPpI2KLpUQ/s200/gameaipro_large.jpg" style="margin-left: auto; margin-right: auto;" title="" width="161" /></td>
<td style="text-align: center;"><img alt="Runtime Compiled C++ for Rapid AI Development" border="0" height="200" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh6qzRpgaA1vmpLsk3RKaT3s0UyCQyzH1NXQwYdjvKC6CPT1Rgv_qVmcUkHQEnMiXvqMPR4p0cctZoGyZ1XEEhvkp9VBo1k6Ck6s3i0C5UWqSV304YYRBk0lc_b3SjC_CLsx0d4E-FM6H4/s200/GameAIPro.PNG" style="margin-left: auto; margin-right: auto;" title="" width="185" /></td>
</tr>
<tr>
<td class="tr-caption" style="text-align: center;"><a href="http://www.gameaipro.com/">Game AI Pro</a></td>
<td class="tr-caption" style="text-align: center;"><a href="http://www.gameaipro.com/GameAIPro/GameAIPro_Chapter15_Runtime_Compiled_C++_for_Rapid_AI_Development.pdf">Runtime Compiled C++ chapter</a></td>
</tr>
</tbody>
</table>
<h2>
Sections</h2>
<ol>
<li>Introduction</li>
<li>Alternative Approaches</li>
<li>Runtime Compiled C++</li>
<li>Runtime Compiled C++ Implementation</li>
<li>Runtime Compilation in Practice—a Step-by-Step Example</li>
<li>Runtime Error Recovery</li>
<li>More Complex Code-State Preservation and Header File Handling</li>
<li>Code Optimizations for Performance-Critical Code</li>
<li>Use Case: A Behavior Tree and Blackboard Architecture</li>
<li>Crytek Case Study</li>
<li>Future Work</li>
<li>Conclusion
</li>
</ol>
<h3>
1. Introduction</h3>
Scripting languages have always been a foundation of rapid AI development but with the increasing demands of AI, their performance drawbacks are becoming ever more problematic. On the other hand, traditional C++ development approaches generally
lead to lengthy compile and link times, which limit the amount of iteration and testing that programmers can undertake. Though development tools are progressing in this area, developers still need to run the build and load content to see the end result, and edit-and-continue style approaches do not work for all codebases or changes.<br />
In this article we demonstrate how the same fast iteration times and error-handling can be achieved using pure C++ through a novel approach, which we call Runtime Compiled C++ (RCC++). RCC++ allows developers to change code while the game is running,
and have the code compiled and linked into the game rapidly with state preserved. Programmers can thus get feedback on their changes in seconds rather than minutes or more. The technique has been used in the development of AAA games at Crytek, and gives similar results to Hot Reload as seen in Epic’s Unreal Engine 4. <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus">The RCC++ code is available as a permissively licensed open source project on GitHub</a>...<br />
<br />
<h4>
<a href="http://www.gameaipro.com/GameAIPro/GameAIPro_Chapter15_Runtime_Compiled_C++_for_Rapid_AI_Development.pdf">Continue (pdf)</a></h4>
Doug Binkshttp://www.blogger.com/profile/18011269239780247978noreply@blogger.com0tag:blogger.com,1999:blog-1121196128950545843.post-17165409001816953052015-08-04T14:25:00.002+01:002015-08-04T14:25:55.986+01:00Faster Runtime Compiles and Improved Compiler supportRecent code changes have concentrated on getting faster runtime compiles, and improving compiler support.<br />
<br />
<br />
<ul>
<li>The Posix compiler (for Linux and OS X) now outputs intermediates. Motivated <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/issues/64">by a request</a> from <a href="https://github.com/procedural">Github user procedural</a>, I finally got around to getting this to work. I've seen <b>up to a 2x performance boost </b>on repeat compiles, and small compile times are now much shorter than a second. Developers should be aware that they may need to clean their <a href="http://runtimecompiledcplusplus.blogspot.fr/2015/01/per-project-build-intermediate.html">runtime Intermediate folder</a> via the <span style="font-family: Courier New, Courier, monospace;">IRuntimeObjectSystem::CleanObjectFiles()</span> function.</li>
<li>Visual Studio 2015 is now fully supported from both upgrading the solution or generating with cmake. After reading <a href="https://twitter.com/BruceDawson0xB">Bruce Dawson</a>'s <a href="https://randomascii.wordpress.com/2015/07/27/programming-is-puzzles/">excellent post on /DEBUG:FASTLINK</a> I've added support for this to compiles, with generated pdb's being much smaller and runtime compiles faster. Thanks to <a href="https://github.com/Ashalah">github user Ashalah</a> for <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/commit/a999b13ec7fea228a1fea00ece3d35eec3106bec">spotting I had the VS2015 version number incorrect</a> as MS skipped 13!</li>
<li>CMake support for OS X has been added, so developers can use this instead of the included XCode project if needed.</li>
<li>Runtime dependencies have been extended to support arbitrary file and extensions. <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/wiki/Runtime-source-dependencies">See the documentation on the wiki</a> for more details.</li>
<li><a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/commit/e5b244e27d51f5617ee503e483defd65be7f5f63">Added cmake install support</a> from <a href="https://github.com/kubaroth">Github user kubaroth</a>.</li>
</ul>
<br />
<br />
<br />Doug Binkshttp://www.blogger.com/profile/18011269239780247978noreply@blogger.com2tag:blogger.com,1999:blog-1121196128950545843.post-29457177560712502512015-07-11T13:07:00.000+01:002015-07-11T13:07:02.705+01:00Runtime Compiled C++ at Develop:Brighton 2015I'll be attending <a href="http://www.developconference.com/">Develop:Brighton 2015</a> (but won't be <a href="http://runtimecompiledcplusplus.blogspot.co.uk/2014/02/video-rcc-at-2012-develop-conference.html">giving a talk like we did in 2012</a>), so if anyone there would like to meet up and chat about RCC++ then please drop me a line through my twitter account <a href="https://twitter.com/dougbinks">@dougbinks</a> or email me through doug@enkisoftware.com.Doug Binkshttp://www.blogger.com/profile/18011269239780247978noreply@blogger.com0tag:blogger.com,1999:blog-1121196128950545843.post-65301198534229593352015-01-04T17:05:00.003+00:002015-01-04T17:08:56.136+00:00Per-project build intermediate directories and cmake additions.The latest additions to Runtime Compiled C++ improves <a href="http://www.cmake.org/">cmake</a> support by fixing a few issues with <a href="http://www.visualstudio.com/">Visual Studio</a> and <a href="https://qt-project.org/wiki/Category:Tools::QtCreator">QtCreator</a> on Windows, and adds per project build intermediate directories.<br />
<br />
Developers can now call <span style="font-family: Courier New, Courier, monospace;">RuntimeObjectSystem::SetIntermediateDir( const char* path_, unsigned short projectId_ = 0 );</span><span style="font-family: Courier New, Courier, monospace; font-size: x-small;"> </span>to set a path for the given project id. The main use for this is when a project might include the same source file but compile it with different settings.<br />
<br />
Additionally the <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/wiki/Controlling-Optimization-Levels">optimization level</a> used is automatically added to the intermediate directory, so there is no need to clean a build when switching from debug to release and vice versa.<br />
<br />
As usual, see the <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/pull/51">Pull Request</a> for more details.Doug Binkshttp://www.blogger.com/profile/18011269239780247978noreply@blogger.com0tag:blogger.com,1999:blog-1121196128950545843.post-28245365936945142812014-09-08T10:50:00.000+01:002014-09-08T10:53:19.519+01:00Undo / Redo and Optimization Level features in Runtime Compiled C++.I've just <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/pull/46">merged the code for two new features</a> I've been working on into the master branch & repo for RCC++. Check out the video for a quick introduction to what these do - for HD video click on the <a href="http://vimeo.com/105532657">vimeo link</a>.<br />
<br />
<div style="text-align: center;">
<iframe allowfullscreen="" frameborder="0" height="281" mozallowfullscreen="" src="//player.vimeo.com/video/105532657?byline=0&color=ffffff" webkitallowfullscreen="" width="500"></iframe>
</div>
<br />
The Undo / Redo feature allows developers to move backwards and forwards between changes made to code in their running program, and as this doesn't involve compilation it can be extremely fast. I find this very useful for comparing subtle changes, and for performance profiling. Note that by default the history size is 0, so the feature is disabled, and this doesn't alter or keep any source code changes. For more details on <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/wiki/Undo-&-Redo-via-the-Object-Constructor-History">how to use the new Undo / Redo feature see the wiki</a>.<br />
<br />
The Optimization Level feature, used in the video to get Optimize for Debug in Release code, is a simple set of optimization controls for Runtime Compiled C++. The enumeration RCppOptimizationLevel can be used to control what level of optimization is used; for example the video demonstrates switching between RCCPPOPTIMIZATIONLEVEL_DEBUG and RCCPPOPTIMIZATIONLEVEL_DEFAULT. For many advanced developers who wish to control their own optimizations, the RCCPPOPTIMIZATIONLEVEL_NOT_SET can be used so that they can control their own settings via the additional compile options. Once again <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/wiki/Controlling-Optimization-Levels">see the wiki for more information on using Optmization Levels</a>.<br />
<br />
The latest code also corrects a bug where the <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/wiki/Setting-Additional-Compile-and-Link-Options">additional compile and link options</a> were not being sent to the Posix (Linux / Mac OS X) compiler. Posix (gcc and clang++) compile options are appended to the compile string, and link options are appended with a preceding -Wl, so should use comma separated parameters.Doug Binkshttp://www.blogger.com/profile/18011269239780247978noreply@blogger.com0tag:blogger.com,1999:blog-1121196128950545843.post-65384737512116413192014-03-14T13:39:00.000+00:002014-12-19T08:16:15.148+00:00Runtime Compiled C++ is in Kythera, the AI behind Star Citizen.<table align="center" cellpadding="0" cellspacing="0" class="tr-caption-container" style="margin-left: auto; margin-right: auto; text-align: center;"><tbody>
<tr><td style="text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgssFS8axz-6PKUQoc5TqiBxMPO8EclwkjX8tRz5Ovv25S-m21U2vibkST6CcpSIHXo8Qn6_6d42s3z8EQYaDWWzjNEqyEv4uZeOSKV0BYQjImH4KHrS7Mwi17TUmjfEtgb-_zgwJrMYbg/s1600/DogfightDebug2.jpg" imageanchor="1" style="margin-left: auto; margin-right: auto;"><img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgssFS8axz-6PKUQoc5TqiBxMPO8EclwkjX8tRz5Ovv25S-m21U2vibkST6CcpSIHXo8Qn6_6d42s3z8EQYaDWWzjNEqyEv4uZeOSKV0BYQjImH4KHrS7Mwi17TUmjfEtgb-_zgwJrMYbg/s1600/DogfightDebug2.jpg" height="225" width="400" /></a></td></tr>
<tr><td class="tr-caption" style="text-align: center;">Debug view of Kythera in action during a dogfight in Star Citizen</td></tr>
</tbody></table>
<br />
Moon Collider and Cloud Imperium <a href="http://kythera.ai/news/2014/03/12/moon-collider-and-cloud-imperium-announce-partnership-supply-new-kythera-ai">recently announced</a> that the hugely ambitious crowd funded space sim <a href="https://robertsspaceindustries.com/about-the-game">Star Citizen</a> has its AI powered by <a href="http://kythera.ai/">Kythera</a>. Regular followers of our blog might spot that Moon Collider is helmed by <a href="http://kythera.ai/our-team">Matthew Jack</a>, co-founder of Runtime Compiled C++. Naturally Matthew turned to using RCC++ for making it possible to change high-level code such as behaviour selection and behaviours (<a href="http://kythera.ai/meet-kythera/technical-details">more details on the Kythera website</a>). With Kythera behind other upcoming games I expect RCC++ usage to continue to grow.<br />
<br />
In addition to some amazing games featuring RCC++, Moon Collider (previously Intelligent Artefacts) have been contributing to RCC++ development and helping to fund me taking time away from my own project <a href="http://www.enkisoftware.com/">Avoyd </a>(which uses RCC++ for almost the entire code-base) to develop new features for RCC++.<br />
<br />
I'm looking forwards to hearing more from Moon Collider, Cloud Imperium, and other developers using Kythera about their experience with RCC++ in future, and will post any relevant news on the blog. If you happen to be in San Francisco for the <a href="http://www.gdconf.com/">GDC Conference</a>, Matthew and the rest of the Kythera team will be there, so do try to meet up to find out more about their AI middleware and RCC++.Doug Binkshttp://www.blogger.com/profile/18011269239780247978noreply@blogger.com0tag:blogger.com,1999:blog-1121196128950545843.post-2524162730452062102014-03-13T18:27:00.002+00:002014-03-13T18:27:39.680+00:00Introducing Runtime Compiled ProjectsI've finally gotten around to testing and integrating a bunch of work on RCC++ which I've had on <a href="https://github.com/dougbinks/RuntimeCompiledCPlusPlus">my development fork</a> for a while. The main feature was requested by the team behind <a href="http://kythera.ai/">Kythera AI</a> (previously Intelligent Artefacts and now Moon Collider) who've been sponsoring much of the recent work on RCC++. They've found that it would be beneficial to be able to set compile options such as include and library paths on a per-module basis, so we've introduced a feature called 'Projects'. Read more about that on our wiki page for <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/wiki/Using-ProjectIds-and-Projects">Using ProjectIds and Projects</a>.<br />
<br />
For the complete list of changes, <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/pull/37">see the pull request</a>.Doug Binkshttp://www.blogger.com/profile/18011269239780247978noreply@blogger.com1tag:blogger.com,1999:blog-1121196128950545843.post-12068124235409324742014-02-05T20:28:00.000+00:002016-11-20T15:31:59.357+00:00Video: RCC++ at the 2012 Develop Conference<iframe allowfullscreen="" frameborder="0" height="310" mozallowfullscreen="" src="//player.vimeo.com/video/85934969?byline=0&color=ffffff" webkitallowfullscreen="" width="500"></iframe>
<b>Rapid Development with Runtime Compiled C++</b><br />
<a href="https://runtimecompiledcplusplus.blogspot.com/p/rapid-development-with-rcc-talk.html">Transcript and slides</a><br />
<br />
The wonderful folk who organise the yearly <a href="http://www.developconference.com/" target="_blank">Develop Conference in Brighton, UK</a>, have given us permission to publish the video we took of our 2012 talk on RCC++.<br />
<br />
Looking back at the talk Runtime Compiled C++ has come a long way, with Mac OS X and Linux support along with a host of features which make it easier to use. Even more developers have implemented runtime compilation, with the <a href="http://molecularmusings.wordpress.com/2013/08/27/using-runtime-compiled-c-code-as-a-scripting-language/" target="_blank">Molecule Engine adding support for C++ code as scripts</a>, and Seiya Ishibashi (<a href="https://twitter.com/i_saint">@i_saint</a>) having developed a commercial plugin for Visual Studio called <a href="http://alcantarea-cpp.com/" target="_blank">Alcantarea </a>along with a <a href="https://github.com/i-saint/DynamicPatcher" target="_blank">Dynamic Patcher available on Github</a> which is apparently used by Riot Games.Doug Binkshttp://www.blogger.com/profile/18011269239780247978noreply@blogger.com2tag:blogger.com,1999:blog-1121196128950545843.post-43835718288653600042013-10-21T15:32:00.002+01:002014-03-14T14:43:26.441+00:00Source directory discovery and turning off RCC++I've just added support for discovering the source directories when the paths compiled into the modules do not match that of the machine the code is being run from. This is especially useful when using pre-compiled libraries. Once again I'd like to thank the team at <a href="http://www.intelligentartefacts.com/">Intelligent Artefacts</a> for highlighting this issue and helping to develop the solution. For more information on this see <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/wiki/Source-code-location-discovery">the documentation</a>.<br />
<br />
This source code discovery doesn't noticeably increase start up times, but it brought forwards my priorities on the issue of improvements to turning off RCC++. I've introduced two new methods, one which can be used at runtime and another which is a compile flag. <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/wiki/Disabling-runtime-compilation">Documentation is again available on the wiki</a>.<br />
<br />
Details of the changes for both these fixes are found in the <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/commit/ea08383b7073249559350783cd6a6263e140f0f9">pull request here</a> and <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/commit/4024b58788426b17ab243f5caa3c9a7a7ba9a270">bug fix here</a>.<br />
<br />
Márton Tamás once again has helped finding and fixing a bug with the alternative file watcher API on Windows, and whilst testing this fix I found that the watched paths were not being cleaned of ..'s so I also fixed that. The fixes for these are in the <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/commit/485b9686329e89f79f0be5c132ba056a34d349c6">pull request here</a>.Doug Binkshttp://www.blogger.com/profile/18011269239780247978noreply@blogger.com0tag:blogger.com,1999:blog-1121196128950545843.post-42916892087871779342013-09-29T10:47:00.000+01:002014-03-14T14:44:22.466+00:00Build Tests, Improved Documentation and more<h3>
Build Tests</h3>
The team over at <a href="http://www.intelligentartefacts.com/">Intelligent Artefacts</a> recently asked if I could help them add build tests for their continuous integration testing. These tests are needed to ensure that they know if they'd added code which would breaks runtime compilation. This is a really good addition to the library, and I'm thankful to them for sponsoring the work and allowing me to include the changes under the standard RCC++ zlib license so that anyone can use and modify the code.<br />
<a href="http://www.blogger.com/"></a><br />
<br />
There are two new test functions added to <span style="font-family: Courier New, Courier, monospace;">IRuntimeObjectSystem </span>and implemented in <span style="font-family: Courier New, Courier, monospace;">RuntimeObjectSystem</span>:<br />
<br />
<br />
<span style="font-family: Courier New, Courier, monospace; font-size: x-small;">struct IRuntimeObjectSystem</span><br />
<span style="font-family: Courier New, Courier, monospace; font-size: x-small;">{</span><br />
<span style="font-family: Courier New, Courier, monospace; font-size: x-small;"> // other functions...</span><br />
<span style="font-size: x-small;"><span style="font-family: Courier New, Courier, monospace;"><br /></span>
<span style="font-family: Courier New, Courier, monospace;"> // tests one by one touching each runtime modifiable source file</span></span><br />
<span style="font-family: Courier New, Courier, monospace; font-size: x-small;"> // returns the number of errors - 0 if all passed.</span><br />
<span style="font-family: Courier New, Courier, monospace; font-size: x-small;"> virtual int TestBuildAllRuntimeSourceFiles(</span><br />
<span style="font-family: Courier New, Courier, monospace; font-size: x-small;"> ITestBuildNotifier* callback, bool bTestFileTracking ) = 0;</span><br />
<span style="font-size: x-small;"><span style="font-family: Courier New, Courier, monospace;"><br /></span>
<span style="font-family: Courier New, Courier, monospace;"> // tests touching each header which has RUNTIME_MODIFIABLE_INCLUDE.</span></span><br />
<span style="font-family: Courier New, Courier, monospace; font-size: x-small;"> // returns the number of errors - 0 if all passed.</span><br />
<span style="font-family: Courier New, Courier, monospace; font-size: x-small;"> virtual int TestBuildAllRuntimeHeaders(</span><br />
<span style="font-family: Courier New, Courier, monospace; font-size: x-small;"> ITestBuildNotifier* callback, bool bTestFileTracking ) = 0;</span><br />
<span style="font-size: x-small;"><span style="font-family: Courier New, Courier, monospace;"><br /></span>
<span style="font-family: Courier New, Courier, monospace;">};</span></span><br />
<span style="font-family: Courier New, Courier, monospace;"><br /></span>
For the most simple use case, the following <span style="font-family: Courier New, Courier, monospace;">s</span>hould be sufficient to perform the required tests:<br />
<br />
<span style="font-size: x-small;"><span style="font-family: 'Courier New', Courier, monospace;">pRuntimeObjectSystem-></span><span style="font-family: 'Courier New', Courier, monospace;">CleanObjectFiles();</span></span><br />
<span style="font-family: 'Courier New', Courier, monospace; font-size: x-small;">pRuntimeObjectSystem->TestBuildAllRuntimeSourceFiles( NULL, false );</span><br />
<br />
Have a look at the SimpleTest application example in the source file Game.cpp for a more complete example. This updates the GUI and permits cancelling mid test by closing the application normally. The tests are performed using the Options menu.<br />
<br />
Note that the <span style="font-family: 'Courier New', Courier, monospace;">bTestFileTracking</span><span style="font-family: 'Courier New', Courier, monospace;"> </span> parameter should be false for most circumstances. When true this also tests the file change notification system in RCC++ by changing the modification times on the files. This will then require a full rebuild of these when you next come to normally compiling the code. The <span style="font-family: 'Courier New', Courier, monospace;">TestBuildAllRuntimeHeaders</span> function will test the header file tracking code in RCC++. Both of these tests are mainly for those modifying The RuntimeObjectSystem or RuntimeCompiler libraries.<br />
<br />
Running these alongside any normal compilation checks on a build server after check-ins is a great way to ensure you don't break RCC++ by accident without realizing.<br />
<br />
The <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/pull/32">changeset for these changes is here</a>.<br />
<br />
<h3>
Improved Documentation</h3>
I've been making some effort to increase the documentation. If you're curious <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/wiki">head over to the wiki</a> and take a look. As always feedback appreciated. In future I plan to move to using <a href="http://www.stack.nl/~dimitri/doxygen/">Doxygen</a> so everything is part of the git repository.<br />
<br />
<h3>
An alternative Windows file watcher</h3>
<div>
Márton Tamás <a href="https://groups.google.com/forum/#!topic/runtimecompiledcplusplus/OQTtcEvcfYQ">spotted an issue</a> with the current Windows file watcher, in that it's incompatible with an alternate API, making integration with libraries using that API difficult. Márton has contributed an alternative solution using this API, which can be enabled with the define <span style="font-family: Courier New, Courier, monospace; font-size: x-small;">WIN32_FW_USE_FINDFIRST_API</span>.</div>
<div>
<br /></div>
<div>
<h3>
And more...</h3>
</div>
<div>
<ul>
<li>Matthew Jack at Intelligent Artefacts (and a founder of RCC++) discovered an issue when using code on machine with no development environment. I've submitted the fix <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/pull/31">here</a>.</li>
<li>Ethan Trịnh has contributed <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/pull/29">a compile fix for VS2013</a>.</li>
<li>Some further fixes, added missing license files for included dependencies and the alternate Windows file watcher API <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/pull/30">are all listed here</a>.</li>
</ul>
</div>
Doug Binkshttp://www.blogger.com/profile/18011269239780247978noreply@blogger.com0tag:blogger.com,1999:blog-1121196128950545843.post-26667412058988404022013-07-31T11:39:00.001+01:002014-03-14T14:44:57.106+00:00Added runtime compile of source dependencies, and improved compiler support.The latest <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/pull/28">update</a> adds support for the runtime compile of source dependencies, significantly enhancing the amount and type of code which can be runtime compiled. Additionally, I've improved compiler support amongst other changes. Full details below.<br />
<br />
<h2>
Runtime compile of source dependencies</h2>
<div>
If you have a header which adds a <a href="http://runtimecompiledcplusplus.blogspot.fr/2013/04/runtime-source-dependencies-and-linux.html">source dependency</a>, and you also mark that header as being <a href="http://runtimecompiledcplusplus.blogspot.fr/2012/06/new-feature-include-file-tracking.html">runtime modifiable</a>, the runtime object system will now track both the header and the source file for changes and recompile them along with any runtime compiled code which includes the header.</div>
<div>
<br /></div>
<div>
This allows pretty much any code to be runtime compiled so long as the source and header names are in the format name.h and name.cpp, and you can add the following to the header:</div>
<div>
<br /></div>
<div>
<div>
<span style="font-family: Courier New, Courier, monospace;">#include "RuntimeSourceDependency.h"</span></div>
<div>
<span style="font-family: Courier New, Courier, monospace;">RUNTIME_COMPILER_SOURCEDEPENDENCY;</span></div>
<div>
<span style="font-family: Courier New, Courier, monospace;"><br /></span></div>
<div>
<span style="font-family: Courier New, Courier, monospace;">#include "RuntimeInclude.h"</span></div>
<div>
<span style="font-family: Courier New, Courier, monospace;">RUNTIME_MODIFIABLE_INCLUDE;</span></div>
</div>
<div>
<br /></div>
<div>
Note that in order for this to work properly, the header must be included from a source file which uses the REGISTERCLASS macro on an IObject based class (either directly or via another header). This is because the program needs to preserve state somehow across compiles, and currently the IObject class handles this.</div>
<div>
<br /></div>
<div>
Take care using this feature, as it can be easy to introduce changes which break the code - though in practice I've found this very useful.<br />
<br /></div>
<div>
<h2>
Improved compiler support</h2>
</div>
<div>
<ul>
<li>Added support for Visual Studio 2013 - however this is as yet untested.</li>
<li>Added support for cross compile to 32bit on 64bit Linux/MacOSX systems, thanks to <a href="https://groups.google.com/forum/#!topic/runtimecompiledcplusplus/uu2ppZlj1Us">Gaoren Xu </a>for discovering this issue and helping with the solution.</li>
</ul>
</div>
<div>
<h2>
Singleton support</h2>
</div>
<div>
At the request of a project using RCC++ I've improved support for singleton type classes. This is especially useful as a good practice in using RCC++ in a performant way is to have singleton system classes which operate on arrays of data.</div>
<div>
<br /></div>
<div>
The REGISTERSINGLETON macro takes a class name and a boolean as arguments, where the boolean controls auto construction of the class. This macro causes the constructor to only ever make one instance of the class. For an example look at the MainObject.cpp file in SimpleTest where we use the macro as:</div>
<div>
<br /></div>
<div>
REGISTERSINGLETON(MainObject, true);</div>
<div>
<br /></div>
<div>
to auto construct an instance of the MainObject class during the Initialise call of RuntimeObjectSystem.<br />
<br /></div>
<h2>
Cleaning build temporaries</h2>
<div>
Build temporaries can now be cleaned up using the RuntimeObjectSystem::CleanObjectFiles() call, which uses the new FileSystemUtils::PathIterator class. The demos currently do this when the program ends.</div>
Doug Binkshttp://www.blogger.com/profile/18011269239780247978noreply@blogger.com0tag:blogger.com,1999:blog-1121196128950545843.post-55357074855309681352013-05-23T17:58:00.000+01:002013-05-23T17:58:36.235+01:00Spelling fix, improved module support and Windows fast compile option.We've made a few changes, one of which alters the interface for the recently introduced <a href="http://runtimecompiledcplusplus.blogspot.fr/2013/04/runtime-source-dependencies-and-linux.html">runtime source dependency</a>. The main changes are:<br />
<br />
<ol>
<li>The macro for the runtime source dependency has had it's spelling corrected, and is now RUNTIME_COMPILER_SOURCEDEPENDENCY (no longer missing the second D). We've also cleaned up the internals as several different wrong spellings of 'dependency' were in use!</li>
<li>On initialization the runtime object system now directly uses the PerModuleInterface::GetInstance(), rather than querying the executable. This way RCC++ can be used in a DLL in the project, and multiple DLL's are supported though you will need to explicitly call RuntimeObjectSystem::SetupObjectConstructors() for each one.</li>
<li>On Windows, the compiler now kills the compile cmd process by default when complete. This adds about 0.3s to the startup of following compiles due to running the batch file for Visual Studio to set up the environment variables, however it resolves an issue where the cmd process was holding onto handles (for example sockets) the main process wanted to close. This is especially a problem if the main process terminated abnormally, as a zombie cmd process is then left behind. To get faster compiles by keeping the cmd process alive (with the risks this entails), call the RuntimeObjectSystem::SetFastCompileMode() function with true as the parameter.</li>
</ol>
The full change list can be found <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/pull/26">here</a>.Doug Binkshttp://www.blogger.com/profile/18011269239780247978noreply@blogger.com5tag:blogger.com,1999:blog-1121196128950545843.post-67810669105185945822013-04-26T12:49:00.000+01:002014-03-14T14:45:37.020+00:00Runtime Source Dependencies and Linux Runtime Include bug fixThe latest code on <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/pull/23">Github </a>includes a new feature - Runtime Source Dependencies - along with a bugfix for Linux builds which resolves an issue with <a href="http://runtimecompiledcplusplus.blogspot.fr/2012/06/new-feature-include-file-tracking.html">Runtime Includes</a>.<br />
<br />
A runtime source dependency is a source file which you need to have compiled when a given header is included by a runtime modifiable source file. Whilst having the source in a library and using the <a href="http://runtimecompiledcplusplus.blogspot.fr/2013/01/boost-removal-improved-library-support.html">Runtime Link Library</a> feature solves this problem to an extent, sometimes you don't want to create a whole library and thus the ability to compile in dependencies is a really useful feature. Using this feature simply requires the following lines in a header:<br />
<br />
#include "RuntimeSourceDependency.h"<br />
RUNTIME_COMPILER_SOURCEDEPENENCY;<br />
<br />
If the header is called SomeFeature.h then the source file SomeFeature.cpp is compiled when any runtime modifiable code is changed which includes this header. Using the same filename as the header is required at the moment, in part due to issues with getting full paths from builds on Linux with GCC.<br />
<br />
This brings us to the bug fix on Linux - although we'd implemented a system to get the full path for runtime modified source files from GCC, this hadn't been implemented for runtime includes and making the above changes caught this bug, so it's now been fixed. GCC only embeds the path passed in for __FILE__, which can be a relative path from the compile location, so we have to embed the compile path using the pre-processor define COMPILE_PATH="$(PWD)/"; Note that this isn't required if your build system uses full paths, which the cmake builds do, as does the internal GCC runtime compiler.<br />
<br />
Note that I'm experiencing an odd issue on my cmake builds on Linux with makefiles - the Eclipse generated files work well however the makefile ones compile but the SimpleTest program fails to create a glfw window.Doug Binkshttp://www.blogger.com/profile/18011269239780247978noreply@blogger.com0tag:blogger.com,1999:blog-1121196128950545843.post-36303897496616643852013-03-13T18:24:00.004+00:002013-03-13T18:24:38.684+00:00Added cmake filesThanks to <a href="https://github.com/ABuus">Anders Buus</a> we now have a set of cmake files for the project.Doug Binkshttp://www.blogger.com/profile/18011269239780247978noreply@blogger.com0tag:blogger.com,1999:blog-1121196128950545843.post-6494070891931919382013-03-11T16:22:00.000+00:002014-12-19T08:28:54.836+00:00Linux port of SimpleTest game example<table align="center" cellpadding="0" cellspacing="0" class="tr-caption-container" style="margin-left: auto; margin-right: auto; text-align: center;"><tbody>
<tr><td style="text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiZ5UXrFKtrpxYmbanCn9nFCKIyWlIVcaJdbB8kCl52ElOfwv82BrjZUpF10YtyT9sYAejz38k0xCUBLS8V9AQgJO4v635exY6gpqllOMKt7CplbIXGMc1Mlf0etxSsY-AJX_YKfGLrQZw/s1600/UbuntuRCCpp.JPG" imageanchor="1" style="margin-left: auto; margin-right: auto;"><img border="0" height="244" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiZ5UXrFKtrpxYmbanCn9nFCKIyWlIVcaJdbB8kCl52ElOfwv82BrjZUpF10YtyT9sYAejz38k0xCUBLS8V9AQgJO4v635exY6gpqllOMKt7CplbIXGMc1Mlf0etxSsY-AJX_YKfGLrQZw/s320/UbuntuRCCpp.JPG" width="320" /></a></td></tr>
<tr><td class="tr-caption" style="text-align: center;">The Pulse demo from project SimpleTest running on Ubuntu Linux compiling changes at runtime.</td></tr>
</tbody></table>
<br />
The SimpleTest example project, otherwise known as the Pulse game demo, now works on Linux with the Eclipse IDE. There's a known bug in that the app shut down appears to crash, which I'll investigate and fix as soon as possible. Grab the latest from <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus">Github</a> to see it in action.<br />
<br />
[Edit 2013/03/12:] The crash on exit bug for the SimpleTest example has now been fixed.Doug Binkshttp://www.blogger.com/profile/18011269239780247978noreply@blogger.com0tag:blogger.com,1999:blog-1121196128950545843.post-85210065563512990852013-03-09T16:13:00.000+00:002013-03-11T10:27:02.345+00:00Linux port with Eclipse progress updateYesterday I started porting RCC++ to Linux, using the Eclipse IDE as this seemed the favourite option, or at least that's what's been specifically asked for. It's been a while since I've done any serious Linux/Unix coding, and that was in the days before decent IDEs using vi and simple makefiles, so it took a fair few hours to get done. There's now a working version of the runtime compiler and ConsoleExample in my <a href="https://github.com/dougbinks/RuntimeCompiledCPlusPlus">personal fork of RCC++</a>, which I'll pull onto the main fork after some further testing.<br />
<br />
[EDIT 2013/11/03]: The code (with a few fixes) has now been pulled into the <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus">main fork at Github</a>.<br />
<br />
The base RCC++ libaries and the ConsoleExample have no dependencies, so the most difficult problem was getting __FILE__ to reliably generate full paths, since Eclipse builds each project from the path of the output. This required embedding the compile path using COMPILE_PATH=\"$(PWD)/\" as a preprocessor define option (-DCOMPILE_PATH=\"$(PWD)/\" on the gcc command line), which uncovered some bugs in my FileSystemUtils header. Note that the executable needs to be build with the flag -export-dynamic in order to allow symbol resolution by name.<br />
<br />
I've not yet ported the rather complex SimpleTest (which needs renaming) due to the dependencies, but this shouldn't stop anyone from using the base libs. Additionally, I'm a little at a loss as yet as to the best way to distribute multiple eclipse projects which are part of a hierarchy. For now you'll need to manually add them to your workspace, which eclipse makes easy by defaulting project files to being hidden. I feel that I've not yet spent enough time with the IDE to complain, but it seems like a good part of a programmers life is fighting the build systems rather than using the language.Doug Binkshttp://www.blogger.com/profile/18011269239780247978noreply@blogger.com0tag:blogger.com,1999:blog-1121196128950545843.post-25395634744378999842013-01-23T11:06:00.000+00:002014-03-14T14:46:00.442+00:00Boost removal, improved library support and VS 2012 buildsWe've developed a cut-down implementation of the boost::filesystem features we required in our FileSystemUtils.h header, allowing us to remove our dependency on Boost. As ever this is permissively licensed so feel free to use that file if it meets your needs outside of RCC++, and extend / modify as you need.<br />
<br />
Additionally, we've added the capability to link libraries at runtime, in both Windows and Mac OS X builds. A simple example for how to use this with the <a href="https://github.com/dougbinks/glewfw">glewfw library</a> is to create a header which you include instead of the glewfw.h header as follows:<br />
<blockquote class="tr_bq">
#pragma once<br />
<br />
#include <GL/glewfw.h><br />
#include "RuntimeLinkLibrary.h"<br />
<br />
#ifdef _WIN32<br />
<span class="Apple-tab-span" style="white-space: pre;"> </span>RUNTIME_COMPILER_LINKLIBRARY( "glewfw.lib");<br />
<span class="Apple-tab-span" style="white-space: pre;"> </span>RUNTIME_COMPILER_LINKLIBRARY( "opengl32.lib");<br />
#endif<br />
#ifdef __APPLE__<br />
RUNTIME_COMPILER_LINKLIBRARY( "-framework glewfw");<br />
RUNTIME_COMPILER_LINKLIBRARY( "-framework OpenGL");<br />
#endif</blockquote>
When included by runtime compiled code, the library will be linked during compilation as and when required. Note that for OS X, we need to specify frameworks with "-framework [name]" and "-l[name]" where [name] is the framework or library (see <a href="http://developer.apple.com/library/mac/#documentation/Darwin/Reference/ManPages/man1/ld.1.html#//apple_ref/doc/man/1/ld">ld documentation on Apple's developer site</a>). You can link to both static and dynamic libraries this way, but the use of dynamic libraries should be preferred. With dynamic libraries only one instance will be loaded by the executable, and resources (such as graphics data) can be preserved without serialization between runtime compiles.<br />
<br />
Being able to use libraries is a significant improvement in functionality. For example, core rendering functionality can now be runtime compiled.<br />
<br />
Furthermore, we've fixed up the Visual Studio property sheets so the solution will now build with Visual Studio 2012 (including the express version), though you'll need to upgrade the solution so that it uses the default VS 2012 toolset (called v110) if you want or need to. Visual Studio should prompt you to upgrade the solution when opened.<br />
<div>
There's quite a lot more, For full list <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/pull/14">check out the commits.</a>.</div>
Doug Binkshttp://www.blogger.com/profile/18011269239780247978noreply@blogger.com2tag:blogger.com,1999:blog-1121196128950545843.post-24083577875846550782012-10-23T16:22:00.000+01:002012-10-23T16:22:54.077+01:00Mac OS X and Simultaneous Multi Platform Runtime CompilingWith the help of the lightweight cross platform GL windowing library <a href="http://www.glfw.org/">GLFW</a> and the <a href="http://code.google.com/p/simplefilewatcher/">Simple File Watcher</a>, we've added Mac OS X support to Runtime Compiled C++. As an added benefit, you can now run multiple platforms from a shared directory, using one of them to code on the fly. Turn around times on Mac OS X with XCode 4 and Clang++ are excellent, better than windows on a similar system.<br />
<div>
<br />
<table align="center" cellpadding="0" cellspacing="0" class="tr-caption-container" style="margin-left: auto; margin-right: auto;"><tbody>
<tr><td style="text-align: center;"><div style="text-align: start;">
<br /></div>
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgI8l4_h-6QDj_tvwvCyzRqfu91OsOpWgPw1yc8xh95vXzIZWJSks70Xyl26sFTbl9C0OVUhtJ7lYARCvFvtPqorguwRjzFMCxdoP0f58g_0YkiNb7UdiIhG6PFHADsQDmo0uD6FLCP1V4/s1600/SimultaneousOSXandWin7RCCpp.png" imageanchor="1" style="margin-left: auto; margin-right: auto;"><img alt="RCC++ on OS X and Windows 7 simultaneously" border="0" height="288" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgI8l4_h-6QDj_tvwvCyzRqfu91OsOpWgPw1yc8xh95vXzIZWJSks70Xyl26sFTbl9C0OVUhtJ7lYARCvFvtPqorguwRjzFMCxdoP0f58g_0YkiNb7UdiIhG6PFHADsQDmo0uD6FLCP1V4/s400/SimultaneousOSXandWin7RCCpp.png" title="" width="400" /></a></td></tr>
<tr><td class="tr-caption" style="text-align: center;">Mac OS X 10.8 with XCode 4 running the SimpleTest example natively top right along with a Windows 7 Parallels Desktop Coherence mode version of the example running bottom right. The apps in each OS have just compiled changes made from XCode. Turn-around times are significantly faster when not running the VM.</td></tr>
</tbody></table>
<br />
For the moment you'll need OS X 10.8 and XCode 4 to run the code on the Mac (we've not tested with OS X 10.7 but it might work). If you change the debugger to GDB the exception handling mechanism doesn't work as smoothly as with the default LLDB debugger, since GDB doesn't pass the exception signal on to the app.<br />
<br />
We'll have more information on the port, the changes and our plans for the future soon.<br />
<br />
Please do give us your feedback on the OS X version, as we've had limited ability to test this on other systems as yet.</div>
Doug Binkshttp://www.blogger.com/profile/18011269239780247978noreply@blogger.com9tag:blogger.com,1999:blog-1121196128950545843.post-76040467344489720252012-08-09T12:57:00.004+01:002014-03-14T15:33:03.695+00:00Building a Console<iframe src="//player.vimeo.com/video/47231578?byline=0&color=ffffff" width="500" height="375" frameborder="0" webkitallowfullscreen mozallowfullscreen allowfullscreen></iframe>
<p><a href="http://vimeo.com/47231578">Building a Console</a> from <a href="http://vimeo.com/runtimecompiledcplusplus">RuntimeCompiledC++</a> on <a href="http://vimeo.com">Vimeo</a>.</p>
<p>Many game engines include a command console that allows a user to issue text commands to adjust settings, get debugging information, change the state of the world and so on. The feature opens up a great deal of potential for rapid development.</p>
<p>However, the implementation will usually be based on a scripting language of some kind: either giving access to one already integrated or using simple custom syntax. Both of these represent significant barriers and maintenance costs. To allow you to access all the features of your engine a scripting language must be pervasively integrated, which is a lot of work - and if you've been reading this blog, you know we see a lot of disadvantages in this approach. A simple custom scripting language will also take work and will always be much less powerful.</p>
<p>RCC++ offers a new option: allow the user to give commands directly in C++.</p>
<p>We can do this by taking the text the user has entered and dropping it into a simple .cpp file, forming the content of a standard <code>execute()</code> method. We can then compile this file at runtime and immediately execute it, just once, as a "snippet" of disposable code. By passing in virtual interfaces to our major subsystems we can have access to our existing functionality with very little work. In essence, anything you could do in the C++ code, you can now do on the command console.</p>
<p>The same crash protection discussed before allows us to catch basic crash errors, so we can use it with confidence. We can also go further: if we restrict the symbols and methods we expose, we can make it safer to use; if we write some nicer wrapper methods we can make it easier to use. This opens the way for a console friendly enough for non-programmers. </p>
<p>We've got some other ideas for applications of code "snippets" and making them easier for designers to use - you can expect this topic to return in future posts.</p>Matthew Jackhttp://www.blogger.com/profile/10376036816175954433noreply@blogger.com0tag:blogger.com,1999:blog-1121196128950545843.post-52094821488211651762012-07-19T15:12:00.001+01:002014-03-16T18:52:12.941+00:00RCC++ at the Develop ConferenceLast week we gave a talk on RCC++ at Develop in Brighton. 45 minutes long, it included live demos of everything you've seen on this blog and some features we so far haven't covered. We featured videos of recent integrations with the Dynamic Resolution Rendering demo Doug developed with Intel, and with the popular Recast navigation toolkit that features in my own work. We also received permission to give an overview of Crytek's Softcode implementation, which was based on our work. <br />
We've really appreciated the great feedback we had after the talk and on Twitter.
We'll be blogging about those other features and integrations in the coming weeks. In the meantime, you can <a href="http://www.enkisoftware.com/downloads/RCCpp/RCCpp_Slides_Develop2012.pdf">download the slides</a>.<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEivgDUCHClz6yAUvAvnA6DgCgK61PhGT4hFamZTGJWbksJsl10kBnRWWpLmJ1qJ-tVWtJyRTaET3zhNg-bBd4-hDlFA-DztRA33Ws5j1EHBTq5iphbmt2NLPr4-x834rnpi7h3bg-p_U04/s1600/Screen+shot+2012-07-19+at+13.56.01.jpg" imageanchor="1"><img border="0" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEivgDUCHClz6yAUvAvnA6DgCgK61PhGT4hFamZTGJWbksJsl10kBnRWWpLmJ1qJ-tVWtJyRTaET3zhNg-bBd4-hDlFA-DztRA33Ws5j1EHBTq5iphbmt2NLPr4-x834rnpi7h3bg-p_U04/s400/Screen+shot+2012-07-19+at+13.56.01.jpg" height="227" width="400" /></a></div>
Matthew Jackhttp://www.blogger.com/profile/10376036816175954433noreply@blogger.com0tag:blogger.com,1999:blog-1121196128950545843.post-20817468132536658612012-07-02T10:57:00.000+01:002012-07-02T10:57:00.069+01:00Library SupportWe've just added improved support for libraries. Whilst it was previously possible to have runtime code linked against a library using the Visual Studio <span style="font-family: 'Courier New', Courier, monospace;">#pragma comment(lib, "nameOfLibrary"),</span> the directories for library search were only specified if added as an environment variable. You can now add library directories as well as include directories, as shown in the example below for supporting DirectX:<br />
<br />
<span style="font-family: 'Courier New', Courier, monospace;">m_pRuntimeObjectSystem = new RuntimeObjectSystem;</span><br />
<span style="font-family: 'Courier New', Courier, monospace;">m_pRuntimeObjectSystem->AddIncludeDir( "%DXSDK_DIR%/Include");</span><br />
<br />
<span style="font-family: 'Courier New', Courier, monospace;">#ifdef _WIN64</span><br />
<span style="font-family: 'Courier New', Courier, monospace;"><span class="Apple-tab-span" style="white-space: pre;"> </span>m_pRuntimeObjectSystem->AddLibraryDir( "%DXSDK_DIR%/lib/x64/" );</span><br />
<span style="font-family: 'Courier New', Courier, monospace;">#else</span><br />
<span style="font-family: 'Courier New', Courier, monospace;"><span class="Apple-tab-span" style="white-space: pre;"> </span>m_pRuntimeObjectSystem->AddLibraryDir( "%DXSDK_DIR%/lib" );</span><br />
<span style="font-family: 'Courier New', Courier, monospace;">#endif</span><br />
<span style="font-family: 'Courier New', Courier, monospace;"><br /></span><br />
We hope to improve upon this in future so that developers don't need to specify libraries and paths in both their project file and their code, and to support compilers which don't use the lib comment for libraries.<br />
<br />
These features allow some significantly increased flexibility to what can be runtime coded. For example I was able to move scene rendering code to RCC++ for a project, allowing me to not only modify shaders but also C++ code on the fly.Doug Binkshttp://www.blogger.com/profile/18011269239780247978noreply@blogger.com0tag:blogger.com,1999:blog-1121196128950545843.post-12544601721981085022012-06-30T14:54:00.002+01:002012-06-30T14:54:42.715+01:00Visual Studio 2011 and x64 SupportWe've just added support for x64 builds and Visual Studio 2011. Additionally, if you have multiple versions of Visual Studio installed, the runtime compiler will now default to the version used to compile the code originally.Doug Binkshttp://www.blogger.com/profile/18011269239780247978noreply@blogger.com0tag:blogger.com,1999:blog-1121196128950545843.post-85657228033583848762012-06-24T17:46:00.001+01:002012-06-26T13:43:36.408+01:00New: installation and integration instructions, tutorialsWe've updated the <a href="https://github.com/RuntimeCompiledCPlusPlus/RuntimeCompiledCPlusPlus/wiki">Wiki on Github</a>. New:<br />
<ul>
<li>Instructions for installing the demo code;</li>
<li>3 detailed tutorials enabling you to reproduce the content of the videos;</li>
<li>Basic integration instructions.</li>
</ul>
<div>
If you have any feedback, post on the <a href="https://groups.google.com/group/runtimecompiledcplusplus">RCC++ discussion group</a>.<br />
<br />
Edit: 26 June, thanks to <a href="http://www.mooncollider.com/people/">Mike Bell</a> for spotting that we'd not pulled the tutorial changes from our development fork. Now fixed! </div>Juliette Foucauthttp://www.blogger.com/profile/15660261624536028882noreply@blogger.com0