Yo !

Welcome to my private very confidential page where you will read everything i’d never tell you ! Well .. I’m Pompei2 a.k.a Pompei ! wooooow !

BTW, if you came here from google or what ever the f., This is the developer’s wiki of our project: Arkana-FTS

*this is a placeholder for some blablablabla*

Profiling Arkana-FTS with oprofiler on linux

This is a draft, it will be moved to an own page as soon as it’s complete.

On linux, there is a great tool to profile applications even though they were not compiled with profiling symbols, not even with debugging symbols! It is called oprofile and works by hooking into the kernel. It comes with most distributions, so just check your distro’s repository to install it.

Once installed, you will first need to load the kernel modules (if they aren’t loaded by default). This can be done by issuing the following command as superuser:

> opcontrol --init

When that is done, you need to start a session. You can do it by typing the following commands into a console as superuser:

> opcontrol --no-vmlinux --start --session-dir=/home/pompei2/tmpsession

This will start a daemon and immediately start writing down statistics about your system into the directory /home/pompei2/tmpsession. Whenever you want to stop that, just execute the following as superuser:

> opcontrol --shutdown

It’s time to collect some statistics! So, first start Arkana-FTS. As soon as you start it, oprofile will start collecting profiling informations about everything Arkana does. Now, we can take a look at what oprofile registered by issuing the following command as a regular user:

> opreport --exclude-dependent --demangle=smart --session-dir=/home/pompei2/tmpsession/ --symbols ./fts > out.txt

The above command will try to show only profile informations of functions that are within the executable ./fts. Everything will be written into out.txt. Here is an excerpt of the file:

CPU: Core 2, speed 800 MHz (estimated)
Counted CPU_CLK_UNHALTED events (Clock cycles when not halted) with a unit mask of 0x00 (Unhalted core cycles) count 100000
samples  %        symbol name
69335    24.3024  CEGUI::OpenGLRenderer::doRender()
53512    18.7563  aluMixData
10557     3.7003  lpFilterMC
8615      3.0196  mdct_butterfly_generic
7586      2.6589  vorbis_book_decodevv_add
6945      2.4343  mdct_backward
6667      2.3368  vorbis_synthesis_blockin
5749      2.0151  decode_packed_entry_number
5157      1.8076  render_line
4117      1.4430  aluF2S
4065      1.4248  mapping0_inverse
4021      1.4094  ov_read
3997      1.4010  mdct_bitreverse
3385      1.1865  oggpack_look
3353      1.1752  CEGUI::Window::update(float)
2794      0.9793  _Rb_tree_const_iterator<CEGUI::OpenGLRenderer::QuadInfo>::operator++()

You can notice that all the symbols from the statically linked libraries are included aswell, that is logical. The above excerpt is not! representative for Arkana-FTS’s current performance, it has been made while nothing else but the most basic GUI and Sound were active, in a testing branch. It is just supposed to give you a screenshot of what the profiler can do.

My own very private doxygen template

/// Bla
/** Bla
 *
 * \param bla blabla
 *
 * \return If successfull: ERR_OK
 * \return If failed:      An error code <0
 *
 * \note bla
 *
 * \todo bla
 *
 * \author Pompei2
 */

Drawing code test

 [diagram]

Ideen modellplanung

jetzt erstmal nur bezüglich der Menschen:

  • in dem Mann/Frau modell sollten als animationen nur gehen, rennen, sterben, nix tun (aka rumgammeln) gespeichert sein.
  • Es gibt 2 arten von objekten:
    • Attachables: die kommen an die attachpoints und werden damit bewegt, z.B. schwert, bogen, ...
    • Wearables (anziehbare): die hängen an dem skelett, z.B. brustpanzer hängt nicht nur an 1 Punkt sondern an allen knochen des oberkörpers und vlt sogar noch die ober und unterarme.
  • in jedem Objekt _können_ animationen für bestimmte skelette gespeichert sein, z.B. in einem schwert können z.B. 2 schlag animationen für das Mensch-skelett gespeichert sein, die definieren wie sich der mensch bewegt, wenn “angriff” ausgeführt wird. Dann könnte es noch zusätzlich schlag-animationen für das monster-golem-vom-mars-skellett haben um zu definieren wie der damit schlägt. Es macht auch sinn z.B. in dem objekt “magischer zauberstab” animationen für “angriffzauber” und “heilzauber” zu definieren z.B. Und der Bogen definiert halt eine andere “angriff” animation.
  • das objekt kann auch standard-anims überschreiben, z.B. läuft jemand vlt anders wenn er eine schwere panzerung an hat.
  • für die attachables muss es irgendwie kategorien geben, vlt “wieviele hände benötigt es?” da gäbe es dann z.B. “0, 1, 2” eine “um den kopf wirbelnde lichtkugel” bräuchte 0 hände, ein dolch 1 hand und ein zweihandschwert oder ein bogen bräuchte 2 hände. Jedes skelett hätte eine anzahl hände (mensch: 2) und somit wäre klar definiert in welcher kombos man machen kann... ein monster-mit-5-händen könnte natürlich ein bogen, ein zweihandschwert und ein dolch bedienen :P
offene fragen:
  • für die wearables muss es auch irgendwie kategorien geben, damit man nicht z.B. zwei brustpanzer anziehen kann, wie man das am praktischsten und flexibelsten macht weiss ich auch noch net...
  • was wäre denn ein pferd? ein wearable nicht, ein attachable das alle anims neu definiert? klingt komisch, vlt eine ganz neue kategorie? naja das ist vlt aber erstmal zukunftsmusik, aber eine gute idee zu haben wäre schon praktisch für’s vorausplanen/denken!

Game lucas vs supinya

Lucas Supinya
12.40 2.70
users/pompei2.txt · Last modified: 2010/07/19 13:48 by pompei2
chimeric.de = chi`s home Creative Commons License Valid CSS Driven by DokuWiki do yourself a favour and use a real browser - get firefox!! Recent changes RSS feed Valid XHTML 1.0