<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
  <id>http://dwayneb.free.fr/</id>
  <title>davidB'log</title>
  <updated>2013-09-17T22:00:00Z</updated>
  <link rel="alternate" href="http://dwayneb.free.fr/"/>
  <link rel="self" href="http://dwayneb.free.fr/atom.xml"/>
  <author>
    <name>David Bernard</name>
    <uri>http://fr.linkedin.com/in/davidbernard31</uri>
  </author>
  <entry>
    <id>tag:dwayneb.free.fr,2013-09-18:/posts/using_gameloop_with_dartemis/</id>
    <title type="html">Using game_loop with dartemis</title>
    <published>2013-09-17T22:00:00Z</published>
    <updated>2013-09-13T17:18:45Z</updated>
    <link rel="alternate" href="http://dwayneb.free.fr/posts/using_gameloop_with_dartemis/"/>
    <content type="html">&lt;p&gt;Today, I replaced &lt;code&gt;requestAnimationFrame&lt;/code&gt; + my own TimeInfo class by &lt;a href="https://github.com/johnmccutchan/game_loop"&gt;game_loop&lt;/a&gt;, you can see the &lt;a href="https://github.com/davidB/vdrones/commit/2bd69af25ee739d5e2cd94b6dbcdef08d33f773f"&gt;commit on github&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;So how to use &lt;a href="https://github.com/johnmccutchan/game_loop"&gt;game_loop&lt;/a&gt; with &lt;a href="https://github.com/denniskaselow/dartemis"&gt;dartemis&lt;/a&gt;:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;class Game {

  final _world;
  final _renderSystem;
  final _gameLoop; 

  Game(){
    // create instance
    var container = query("#game");
    _world = new World();
    _gameLoop = new GameLoopHtml(container);
    _renderSystem = new System_RenderX(container);

    // setup instance an allow circular dependencies gameLoop &amp;lt;-&amp;gt; world'system
    _setupWorld();
    _setupGameLoop();
  }

  void _setupWorld() {
    //...
    _world.addSystem(new System_XXXX());
    _world.addSystem(new System_YYYY(_gameLoop));
    // System(s) in charge of rendering will not run when world.process()
    _world.addSystem(_renderSystem, passive: true);
    _world.initialize();
  }

  void _setupGameLoop(){
    _gameLoop.pointerLock.lockOnClick = false; // to keep mouse cursor
    _gameLoop.onUpdate = (gameLoop){
      _world.delta = gameLoop.dt * 1000.0; // world.delta in ms
      _world.process();
    };
    _gameLoop.onRender = (gameLoop){
      _renderSystem.process();
    };
  }

  void start() =&amp;gt; _gameLoop.start();
  void stop() =&amp;gt; _gameLoop.stop();
}
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Why I moved to &lt;a href="https://github.com/johnmccutchan/game_loop"&gt;game_loop&lt;/a&gt; ?&lt;/p&gt;

&lt;p&gt;I was happy with my previous solution, but I planned to move when I need some of its features like gamepad support, fullscreen, constant update time, … And today I need (for debug purpose) the easiest feature to implement: &lt;em&gt;a frame counter&lt;/em&gt;.
I spend more time to introduce &lt;a href="https://github.com/johnmccutchan/game_loop"&gt;game_loop&lt;/a&gt; than to implement the frame counter ;-) , but less time than implement it and replace it later. &lt;/p&gt;

&lt;p&gt;Currently I didn’t replace the keyboard management by the game_loop, may be later.&lt;/p&gt;

</content>
  </entry>
  <entry>
    <id>tag:dwayneb.free.fr,2011-05-29:/posts/version_flow/</id>
    <title type="html">My versionning flow</title>
    <published>2011-05-28T22:00:00Z</published>
    <updated>2011-05-29T19:46:52Z</updated>
    <link rel="alternate" href="http://dwayneb.free.fr/posts/version_flow/"/>
    <content type="html">&lt;pre&gt;&lt;code&gt;VERSION_CURRENT=1.1.0
VERSION_NEXT=1.2.0
git checkout wip
git tag v${VERSION_CURRENT}
git checkout milestones
git merge --no-ff v${VERSION_CURRENT}
# build
git push origin milestones
git checkout wip
# change version number
git commit -avm "init version ${VERSION_NEXT}"
git ush origin wip
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;In the specific case of &lt;a href="http://scala-ide.org/"&gt;ScalaIDE&lt;/a&gt; I use the following information to manage the 1.x.y versions.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;wip =&amp;gt; wip_exp_backport
build =
  cd org.scala-ide.build
  ./build-ide-local-2.8.1.final.sh
change version number =
  cd org.scala-ide.build
  ./set_version.sh ${VERSION_NEXT}-SNAPSHOT
  grep -r ${VERSION_CURRENT} ../**/pom.xml
  grep -r ${VERSION_CURRENT} ../**/MANIFEST.MF
  # build and fix any issue related to version modification
&lt;/code&gt;&lt;/pre&gt;

</content>
  </entry>
  <entry>
    <id>tag:dwayneb.free.fr,2010-11-26:/posts/tips_osgi_define_import_package/</id>
    <title type="html">Eclipse/OSGi : from Require-Bundle to Import-Package</title>
    <published>2010-11-25T23:00:00Z</published>
    <updated>2010-11-26T17:00:31Z</updated>
    <link rel="alternate" href="http://dwayneb.free.fr/posts/tips_osgi_define_import_package/"/>
    <content type="html">&lt;p&gt;Yesterday, I spend too many time to convert Require-Bundle to Import-Package into MANIFEST.MF of eclipse bundles.
For some various cause, I can’t do it with PDE, so I don’t know if there is assistant or not in PDE.
I did it manually (try and catch) : edit, build with tycho, install plugins, restart, try until I’ve got NoClassDefFoundExceptions.&lt;/p&gt;

&lt;p&gt;Until I’ve got the idea (late for the last plugin) : using a package analyzer to have the full list of package used by the bundle.
In my case I use JDepend (as I failed to download it, I use a version in my maven local repository) :&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;java -cp  ${HOME}/.m2/repository/jdepend/jdepend/2.9.1/jdepend-2.9.1.jar \
  jdepend.textui.JDepend \
  org.scala-ide.sdt.compiler.ext/target/classes
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;At the end of the report there is the list of packages :&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;--------------------------------------------------
- Package Dependency Cycles:
--------------------------------------------------


--------------------------------------------------
- Summary:
--------------------------------------------------

Name, Class Count, Abstract Class Count, Ca, Ce, A, I, D, V:

java.io,0,0,1,0,0,0,1,1
java.lang,0,0,1,0,0,0,1,1
scala,0,0,1,0,0,0,1,1
scala.collection,0,0,1,0,0,0,1,1
scala.collection.generic,0,0,1,0,0,0,1,1
scala.collection.immutable,0,0,1,0,0,0,1,1
scala.collection.mutable,0,0,1,0,0,0,1,1
scala.collection.script,0,0,1,0,0,0,1,1
scala.math,0,0,1,0,0,0,1,1
scala.reflect.generic,0,0,1,0,0,0,1,1
scala.runtime,0,0,1,0,0,0,1,1
scala.tools.nsc,0,0,1,0,0,0,1,1
scala.tools.nsc.ast,0,0,1,0,0,0,1,1
scala.tools.nsc.dependencies,0,0,1,0,0,0,1,1
scala.tools.nsc.interactive,180,13,0,22,0,07,1,0,07,1
scala.tools.nsc.io,0,0,1,0,0,0,1,1
scala.tools.nsc.reporters,0,0,1,0,0,0,1,1
scala.tools.nsc.settings,0,0,1,0,0,0,1,1
scala.tools.nsc.symtab,0,0,1,0,0,0,1,1
scala.tools.nsc.typechecker,0,0,1,0,0,0,1,1
scala.tools.nsc.util,0,0,1,0,0,0,1,1
scala.util,0,0,1,0,0,0,1,1
scala.util.control,0,0,1,0,0,0,1,1
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;So I convert &lt;/p&gt;

&lt;pre&gt;&lt;code&gt;Require-Bundle: org.scala-ide.scala.compiler
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;into &lt;/p&gt;

&lt;pre&gt;&lt;code&gt;Import-Package: scala.tools.nsc,
 scala.tools.nsc.ast,
 scala.tools.nsc.dependencies,
 scala.tools.nsc.io,
 scala.tools.nsc.reporters,
 scala.tools.nsc.settings,
 scala.tools.nsc.symtab,
 scala.tools.nsc.typechecker,
 scala.tools.nsc.util
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;(Tips to not forgot)&lt;/p&gt;
</content>
  </entry>
  <entry>
    <id>tag:dwayneb.free.fr,2010-11-03:/posts/pomodoro_technique/</id>
    <title type="html">Pomodoro technique</title>
    <published>2010-11-02T23:00:00Z</published>
    <updated>2010-11-03T10:07:25Z</updated>
    <link rel="alternate" href="http://dwayneb.free.fr/posts/pomodoro_technique/"/>
    <content type="html">&lt;p&gt;J’essaie de suivre la “pomodoro technique”, et je la trouve tres efficace quand je l’applique correctement.
Pour en savoir plus voici quelques liens :&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href="http://www.pomodorotechnique.com/"&gt;site officiel (en)&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="http://blog.staffannoteberg.com/2010/07/12/pomodoro-technique-video-from-devoxx/"&gt;video de présentation (en ~ 1H)&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="http://www.etre-meilleur.com/gestion-du-temps/la-technique-pomodoro-ou-lart-de-gerer-son-temps-grace-a-une-tomate.html"&gt;un survol en francaisl&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Il y a plein de pomodori/minuteurs informatique +/- utiles suivant l’usage et l’utilisateur. J’utilise (teste) actuellement : &lt;a href="http://code.google.com/p/pomodairo/"&gt;pomodairo&lt;/a&gt;, il a fallu un peu hacker pour que adobe air fonctionne sous mon Linux.
J’utilise aussi un gestionnaire de tâches (et sous-tâches) en ligne : &lt;a href="http://todoist.com/"&gt;todoist&lt;/a&gt; (il n’est pas spécifique à “pomodoro technique”)&lt;/p&gt;

&lt;p&gt;@+&lt;/p&gt;
</content>
  </entry>
  <entry>
    <id>tag:dwayneb.free.fr,2010-10-12:/posts/gmrun_alternative/</id>
    <title type="html">Linux : Gmrun alternatives</title>
    <published>2010-10-11T22:00:00Z</published>
    <updated>2010-10-12T21:10:10Z</updated>
    <link rel="alternate" href="http://dwayneb.free.fr/posts/gmrun_alternative/"/>
    <content type="html">&lt;h2 id="alternatives"&gt;Alternatives&lt;/h2&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href="http://do.davebsd.com/"&gt;Gnome-Do&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="http://www.launchy.net/"&gt;Launchy&lt;/a&gt; (Linux  + Windows)&lt;/li&gt;
  &lt;li&gt;&lt;a href="http://kaizer.se/wiki/kupfer/"&gt;Kupfer&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="http://bashrun.sourceforge.net/"&gt;Bashrun&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;[Gnome panel run dialog] : &lt;code&gt;gnome-panel-control --run-dialog&lt;/code&gt;&lt;/li&gt;
  &lt;li&gt;[LXPanel run dialog] : &lt;code&gt;lxpanelctl run&lt;/code&gt;&lt;/li&gt;
  &lt;li&gt;[Dmenu] : &lt;code&gt;dmenu_run&lt;/code&gt;&lt;/li&gt;
&lt;/ul&gt;
</content>
  </entry>
</feed>
