<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.xoreos.org/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=DrMcCoy</id>
	<title>xoreos Wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.xoreos.org/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=DrMcCoy"/>
	<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Special:Contributions/DrMcCoy"/>
	<updated>2026-05-02T09:19:32Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.38.6</generator>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=TODO&amp;diff=485</id>
		<title>TODO</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=TODO&amp;diff=485"/>
		<updated>2023-12-27T08:55:59Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: Update &amp;quot;projects&amp;quot; board with the classic URL&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a long rambly list of things left to do in xoreos and xoreos-tools. Anybody is welcome to tackle any of these tasks, but please also read our [[Developer_Central|general contributor overview]], including our [[Code_Formatting_Conventions|Code Formatting Conventions]], [[Commit_Guidelines|Commit Guidelines]] and [https://github.com/xoreos/xoreos/blob/master/CODE_OF_CONDUCT.md Code of Conduct]. If you plan to do any of these tasks, please also [[Contact_us|contact us]] beforehand, so we can better coordinate multiple people interested in doing the same task, and discuss how to best solve the problem. Thanks. :)&lt;br /&gt;
&lt;br /&gt;
(&#039;&#039;&#039;See also:&#039;&#039;&#039; the Kanban-like &amp;quot;Projects&amp;quot; boards on GitHub: https://github.com/orgs/xoreos/projects?type=classic)&lt;br /&gt;
&lt;br /&gt;
== Documentation ==&lt;br /&gt;
&lt;br /&gt;
=== Developer information ===&lt;br /&gt;
* Extend the developer information on the wiki&lt;br /&gt;
** Explain how to get the xoreos sources on various platforms&lt;br /&gt;
** Expand GNU/Linux compiling instructions to cover more distributions&lt;br /&gt;
** Expand Mac OS X compiling instructions&lt;br /&gt;
*** Xcode&lt;br /&gt;
*** Homebrew/MacPorts/Fink&lt;br /&gt;
*** CMake, Libraries&lt;br /&gt;
** [http://wiki.arx-libertatis.org/Developer_Information Arx Libertatis] has an extensive dev page&lt;br /&gt;
* Document file formats on the wiki?&lt;br /&gt;
** Or integrate info into XentaxWiki?&lt;br /&gt;
** Both?&lt;br /&gt;
&lt;br /&gt;
=== User information ===&lt;br /&gt;
* More user information on the wiki&lt;br /&gt;
** How to download xoreos&lt;br /&gt;
** How to install the games on various platforms&lt;br /&gt;
** [http://wiki.arx-libertatis.org/Main_Page Arx Libertatis] does that pretty well&lt;br /&gt;
&lt;br /&gt;
=== Modder information ===&lt;br /&gt;
* Link to relevant modding resources&lt;br /&gt;
* Maybe even some kind of Modder&#039;s Handbook&lt;br /&gt;
** A big overview of modding Aurora games in general&lt;br /&gt;
*** Differences and commonalities between games&lt;br /&gt;
** Linking/Grouping engine functions between games&lt;br /&gt;
&lt;br /&gt;
== Website ==&lt;br /&gt;
&lt;br /&gt;
=== Design ===&lt;br /&gt;
* Better website design?&lt;br /&gt;
** It still should be static in the end&lt;br /&gt;
*** No PHP or Rails&lt;br /&gt;
*** Very light on JavaScript&lt;br /&gt;
*** No Flash!&lt;br /&gt;
** Maybe a bit more unique, graphical&lt;br /&gt;
** For legal reasons, we shouldn&#039;t directly use art or designs from the original games&lt;br /&gt;
*** Something inspired by the art of the orginal games would fit&lt;br /&gt;
&lt;br /&gt;
=== Octopress ===&lt;br /&gt;
* Move away from Octopress?&lt;br /&gt;
** Alternative should still produce static HTML somehow&lt;br /&gt;
** Octopress works rather well. It reads Markdown, which is a plus&lt;br /&gt;
* Octopress 3.0?&lt;br /&gt;
** Not finished yet, it seems&lt;br /&gt;
&lt;br /&gt;
== Standalone(ish) fixes/improvements ==&lt;br /&gt;
&lt;br /&gt;
=== Broken NWN2 XML ===&lt;br /&gt;
* Not standards-conforming XML. Need custom XML parser; stock XML parsing libraries will just throw errors.&lt;br /&gt;
** &amp;lt;nowiki&amp;gt;&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;NWN2UI&amp;quot;&amp;gt;&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
** No single root element&lt;br /&gt;
** Attribute values not enclosed in quotes most of the time&lt;br /&gt;
** Special characters in attribute values not properly escaped&lt;br /&gt;
** Unmatched quotes on several occasions&lt;br /&gt;
* Event functions&lt;br /&gt;
* Special values like PARENT_WIDTH&lt;br /&gt;
* [https://github.com/xoreos/xoreos-tools/pull/1 Altrite is working on a broken-XML fixer]&lt;br /&gt;
&lt;br /&gt;
=== CJK glyphs in the console ===&lt;br /&gt;
* The &amp;quot;system font&amp;quot; we use for our debug console, DejaVu Sans Mono Bold, does not feature any CJK (Chinese, Japanese, Korean) glyphs&lt;br /&gt;
* Not strictly necessary, but nice to have for printing, say, Witcher area names in Asian languages&lt;br /&gt;
* We could maybe integrate CJK glyphs from the [http://fonts.jp/hanazono/ Hanazono fonts] or other suitable libre fonts&lt;br /&gt;
* We need to match the height with DejaVu Sans Mono Bold&lt;br /&gt;
* CJK glyphs tend to be more complex and therefore wider. They&#039;re usually rendered twice as wide as Latin glyphs&lt;br /&gt;
* Our console code needs to take that into account&lt;br /&gt;
&lt;br /&gt;
=== Fuzzing ===&lt;br /&gt;
* Set up fuzzing targets for everything for [https://llvm.org/docs/LibFuzzer.html libFuzzer]&lt;br /&gt;
** File readers, image decoders, etc.&lt;br /&gt;
* Can be integrated with [http://lcamtuf.coredump.cx/afl/ afl] (american fuzzy lop): https://github.com/llvm-mirror/compiler-rt/blob/master/lib/fuzzer/afl/afl_driver.cpp&lt;br /&gt;
* Integrate it with our build system somehow&lt;br /&gt;
** ./configure flag for building with fuzzing instrumentation?&lt;br /&gt;
** Needs to check that the compiler can do that&lt;br /&gt;
** make fuzzers then builds the targets?&lt;br /&gt;
* File formats previously manually fuzzed with afl:&lt;br /&gt;
** CBGT, CDPTH, DDS, NBFS, NCGR, NCLR, SBM, TGA, TPC, TXB&lt;br /&gt;
** 2DA, KEY/BIF, ERF, GFF3, GFF4, GDA, TLK, NSBTX, RIM, SMALL, SSF&lt;br /&gt;
* Continuous fuzzing via [https://github.com/google/oss-fuzz OSS-Fuzz] (currently only taking &amp;quot;important&amp;quot; projects)&lt;br /&gt;
&lt;br /&gt;
=== Script decompiler ===&lt;br /&gt;
* It might be quite useful to have a NWScript decompiler in xoreos-tools&lt;br /&gt;
* We have a script disassembler, ncsdis&lt;br /&gt;
** Which already does code flow analysis&lt;br /&gt;
* Missing:&lt;br /&gt;
** Code generation&lt;br /&gt;
** Collapsing of instruction chains into single-line NWScript code&lt;br /&gt;
*** For example, &amp;quot;int var = foo * bar + quux&amp;quot; compiles to a long chain with multiple temporaries&lt;br /&gt;
** Proper handling of structs and vectors&lt;br /&gt;
&lt;br /&gt;
=== Script compiler ===&lt;br /&gt;
* An NWScript compiler might be useful as well&lt;br /&gt;
** A script assembler might be an easy first step&lt;br /&gt;
&lt;br /&gt;
=== File format writers ===&lt;br /&gt;
* GFF3Writer, GFF4Writer&lt;br /&gt;
** Both necessary to create save games compatible with the original games&lt;br /&gt;
** Also useful for a xml2gff tool&lt;br /&gt;
* xml2tlk&lt;br /&gt;
** TalkTable_GFF::write02() and ::write05()&lt;br /&gt;
** Needs GFF4Writer&lt;br /&gt;
* Archive (ERF, RIM, KEY/BIF) packers?&lt;br /&gt;
&lt;br /&gt;
=== Config file ===&lt;br /&gt;
* Should be more preserving of the layout&lt;br /&gt;
** Especially empty lines&lt;br /&gt;
** UTF-8 Byte-Order-Mark when using native Windows editors&lt;br /&gt;
** \r is currently always stripped. Maybe preserve that too&lt;br /&gt;
*** Autodetect when \r is already used, and add it to new config lines too&lt;br /&gt;
** This basically needs a complete rewrite of the config parser&lt;br /&gt;
*** Don&#039;t just look for comments, just throw everything after &amp;quot;foo=bar&amp;quot; into the &amp;quot;comment&amp;quot; variable, including whitespace&lt;br /&gt;
*** And all whitespace before &amp;quot;foo=bar&amp;quot; into a &amp;quot;prefix&amp;quot; variable&lt;br /&gt;
** Maybe even always add BOM and \r when writing a new config file on Windows?&lt;br /&gt;
&lt;br /&gt;
=== GUI ===&lt;br /&gt;
* xoreos could use a global GUI to start games from&lt;br /&gt;
** https://github.com/ocornut/imgui?&lt;br /&gt;
* Should probably be similar to ScummVM&#039;s GUI, at least in effect&lt;br /&gt;
* Should read the config file, list all targets&lt;br /&gt;
** Press a &amp;quot;Play&amp;quot; button to play the game&lt;br /&gt;
** Press an &amp;quot;Edit&amp;quot; button to edit the entry&lt;br /&gt;
*** Dialog options to edit common settings&lt;br /&gt;
*** An additional free-form editor?&lt;br /&gt;
*** Game-specific options?&lt;br /&gt;
** A button to edit global settings (&amp;quot;xoreos&amp;quot; config domain)&lt;br /&gt;
** For the future, a way to immediately load a saved game?&lt;br /&gt;
** An &amp;quot;Add&amp;quot; button to add a game&lt;br /&gt;
*** File browser&lt;br /&gt;
**** Select directories for most game&lt;br /&gt;
**** Select file for Sonic Chronicles&lt;br /&gt;
*** View current saved games of a target?&lt;br /&gt;
* Probably implemented using OpenGL, just like, say, the console&lt;br /&gt;
* Theme-able/Skinable?&lt;br /&gt;
* Some potential stumbling blocks&lt;br /&gt;
** Displaying &amp;quot;uncommon&amp;quot; text in both game descriptions and file paths&lt;br /&gt;
*** &amp;quot;Decomposed&amp;quot; letters, i.e. base letter + combining glyphs&lt;br /&gt;
*** CJK&lt;br /&gt;
*** Arabic and other scripts where letters change depending on their place in the word&lt;br /&gt;
*** Right-to-left&lt;br /&gt;
** Shortening those strings when they don&#039;t fit in their fields is also potentially difficult&lt;br /&gt;
&lt;br /&gt;
=== Localization ===&lt;br /&gt;
* Text in exceptions?&lt;br /&gt;
** At least the user-visible ones, like &amp;quot;Failed to detect game&amp;quot;&lt;br /&gt;
** Or maybe we should clean that up and split them into &amp;quot;program logic failure&amp;quot; and &amp;quot;user failure&amp;quot;, with only the latter translated&lt;br /&gt;
* Strings for the engine loader progress bar&lt;br /&gt;
* Debug console string&lt;br /&gt;
* GUI (see above) strings&lt;br /&gt;
* [http://www.gnu.org/software/gettext/ GNU gettext] would be one solution&lt;br /&gt;
&lt;br /&gt;
=== Unit tests ===&lt;br /&gt;
* More unit tests&lt;br /&gt;
&lt;br /&gt;
=== Phaethon ===&lt;br /&gt;
* More readers&lt;br /&gt;
* Writers?&lt;br /&gt;
&lt;br /&gt;
=== Model converters ===&lt;br /&gt;
* Document the model formats&lt;br /&gt;
* Convert between the binary model formats and their ASCII equivalents&lt;br /&gt;
* Convert between the binary model formats and ones that can be opened by modelling tools&lt;br /&gt;
** 3D Studio Max&lt;br /&gt;
** Blender&lt;br /&gt;
&lt;br /&gt;
=== Full-fledged modding toolset ===&lt;br /&gt;
* Similar to the NWN, NWN2 or Witcher toolset, but portable and FLOSS&lt;br /&gt;
** Might also support other games?&lt;br /&gt;
* Out of scope for xoreos&lt;br /&gt;
** Still, such a thing would be welcome under the xoreos banner&lt;br /&gt;
* [http://sourceforge.net/projects/neveredit/ Neveredit] might still be worth a look&lt;br /&gt;
&lt;br /&gt;
== Build system ==&lt;br /&gt;
&lt;br /&gt;
=== CMake ===&lt;br /&gt;
* Current doesn&#039;t set the git version to &amp;quot;+unk&amp;quot; when git isn&#039;t found&lt;br /&gt;
* make doxygen?&lt;br /&gt;
&lt;br /&gt;
=== Autotools ===&lt;br /&gt;
* Suppress the &amp;quot;fatal: not a git repository&amp;quot; when building gitstamp without a git directory&lt;br /&gt;
* Increased modularity&lt;br /&gt;
** Disabling engines&lt;br /&gt;
** Making library dependencies optional (and disabling certain features, then)&lt;br /&gt;
*** liblzma? Only needed for the iOS version of KotOR&lt;br /&gt;
*** libxml2? Only needed for the two Dragon Age games&lt;br /&gt;
** When something is disabled, skip it, if possible&lt;br /&gt;
*** Like the videos in KotOR Mac&lt;br /&gt;
** If skipping is not possible, error out&lt;br /&gt;
&lt;br /&gt;
== Nitro ==&lt;br /&gt;
&lt;br /&gt;
* The Nintendo DS (Nitro) specific file formats should probably be moved out of src/aurora/ and into src/nitro&lt;br /&gt;
* nitrofile, cdpth, nsbtx, smallfile&lt;br /&gt;
** nsbtx needs to be split into a class accessing the textures in src/nitro/ and an archive class on top in src/aurora/&lt;br /&gt;
** This means src/aurora/ accesses src/nitro/, so libnitro.la needs to come after libaurora.la in the linking order&lt;br /&gt;
* ndsrom as well?&lt;br /&gt;
* What about nftrfont and model_sonic in src/graphics/aurora/?&lt;br /&gt;
** src/graphics/nitro/?&lt;br /&gt;
** This would have src/graphics/nitro/ access src/graphics/aurora/, so graphics/libnitro.la needs to come before graphics/libaurora.la in the linking order&lt;br /&gt;
** That would be the other way round than for src/nitro/. Too confusing?&lt;br /&gt;
&lt;br /&gt;
== Graphics ==&lt;br /&gt;
&lt;br /&gt;
=== MDL supermodels and animations ===&lt;br /&gt;
* Mostly working in NWN thanks to jbowtie&#039;s work&lt;br /&gt;
* Might need some cleanup&lt;br /&gt;
* Models should smoothly change between different animations&lt;br /&gt;
* The animation system probably needs to be a bit more complex, to allow for &amp;quot;overlaying&amp;quot; different animations onto each other. For example, for speaking while holding an object and keeping the head focused on the PC character.&lt;br /&gt;
&lt;br /&gt;
=== Lighting ===&lt;br /&gt;
* We don&#039;t yet have a proper light system&lt;br /&gt;
* I started working on it: [https://drmccoy.de/xoreos/20150809T223407.png], but my approach is seriously lacking. You can see the edges of the tiles that make up on NWN area in many cases ([https://drmccoy.de/xoreos/20150809T223507.png], [https://drmccoy.de/xoreos/20150809T223548.png])&lt;br /&gt;
** See the [https://github.com/xoreos/xoreos/tree/light light branch] in the git repository&lt;br /&gt;
** Of course, the actual glLight* stuff won&#039;t be relevant anymore as soon as shaders are there&lt;br /&gt;
** Lighting in several (ASCII?) area tiles is broken&lt;br /&gt;
*** The door in Prelude.nwm&#039;s &amp;quot;m0q1a&amp;quot; area&lt;br /&gt;
*** A water tile in Chapter2.nwm&#039;s &amp;quot;map_m2q1a&amp;quot; area&lt;br /&gt;
*** A sloped snow tile in XP2_Chapter3.nwm&#039;s &amp;quot;thecityoflostsou&amp;quot;&lt;br /&gt;
&lt;br /&gt;
=== Materials ===&lt;br /&gt;
* Materials in The Witcher are closely tied to shaders&lt;br /&gt;
&lt;br /&gt;
=== OpenGL and Shaders ===&lt;br /&gt;
* mirv_ is currently working on a graphics system overhaul, complete with shader support&lt;br /&gt;
* All Aurora games use shaders in some form&lt;br /&gt;
* NWN uses ARB shaders. We probably need to rewrite them from scratch&lt;br /&gt;
* DirectX shaders might be automatically convertible with Cg?&lt;br /&gt;
* Otherwise, look at what Wine does with the shaders, and use that as a basis?&lt;br /&gt;
* All the games, even NWN, use some form of shaders. Still totally missing from xoreos, since we have no idea how to use them in general yet. Moreover, this was before GLSL, so they&#039;re in the old assembly-like language. We probably need to rewrite them from scratch&lt;br /&gt;
* We need shaders for tinting in NWN2 (objects and area geometry) and TexturePaint nodes in Witcher&lt;br /&gt;
&lt;br /&gt;
=== SDL 1.2 ===&lt;br /&gt;
* Optionally link against SDL 1.2 instead of SDL 2&lt;br /&gt;
* Should ideally use a configure flag to select between the two&lt;br /&gt;
** Maybe a CMake flag as well, if possible&lt;br /&gt;
* Assigned to clone2727, so anybody interested in this should coordinate with him&lt;br /&gt;
&lt;br /&gt;
== Videos ==&lt;br /&gt;
&lt;br /&gt;
=== XMV/WMV ===&lt;br /&gt;
* Used in Xbox versions of KotOR/KotOR2&lt;br /&gt;
* Our WMV decoder (for XMV videos used in Xbox versions) is missing P-frames and J-frames&lt;br /&gt;
** Code exists in ffmpeg, but is connected to the MPEG-4 family mess&lt;br /&gt;
&lt;br /&gt;
=== Actimagine VX ===&lt;br /&gt;
* Used in the Nintendo DS game Sonic Chronicles&lt;br /&gt;
* https://wiki.multimedia.cx/index.php?title=Actimagine_Video_Codec&lt;br /&gt;
&lt;br /&gt;
=== Sorenson 3 ===&lt;br /&gt;
* One single video in the Mac port of KotOR2, the Aspyr logo, uses the Sorenson 3 codec&lt;br /&gt;
** ffmpeg has a decoder, but it&#039;s connected to the MPEG-4 family mess (SVQ3 is similar to H.264)&lt;br /&gt;
* ScummVM needs that too&lt;br /&gt;
** While xoreos is GPLv3+, ScummVM is GPLv2+&lt;br /&gt;
** Somebody implementing Sorenson 3 for xoreos should ideally give explicit permission to relicense it GPLv2+ for ScummVM&lt;br /&gt;
*** Of course, if the decoder is based on prior work by other people, it has to be compatible with both GPLv2+ and GPLv3+&lt;br /&gt;
&lt;br /&gt;
=== Optimizations ===&lt;br /&gt;
* Optimize our simple BitStream interface&lt;br /&gt;
** See [https://fgiesen.wordpress.com/2016/01/02/end-of-buffer-checks-in-decompressors/ this blog post]&lt;br /&gt;
** Specifically, we don&#039;t do any peeking at all&lt;br /&gt;
** It still needs to handle different memory layouts, though&lt;br /&gt;
* Likewise, our Huffman class could probably be tuned a lot&lt;br /&gt;
* Pull in fft/rdft/dct/mdct optimizations from FFmpeg?&lt;br /&gt;
* I experimented with that in a private branch and it didn&#039;t do anything for Bink performance&lt;br /&gt;
&lt;br /&gt;
== Sound ==&lt;br /&gt;
&lt;br /&gt;
=== FMOD ===&lt;br /&gt;
* Dragon Age: Origins uses FMOD for sound and music&lt;br /&gt;
* I have experimental FSB (FMOD sound bank) support working in a private branch&lt;br /&gt;
* FEV (FMOD events) format is still unknown to us&lt;br /&gt;
** Apparently, groups of event lists with events&lt;br /&gt;
** Event is everything from &amp;quot;play sound&amp;quot;, over &amp;quot;set volume&amp;quot; to &amp;quot;apply echo&amp;quot;&lt;br /&gt;
** Game areas specify the group to use for the area&lt;br /&gt;
** Scripts then probably tell FMOD to play event lists out of that group&lt;br /&gt;
&lt;br /&gt;
=== Wwise ===&lt;br /&gt;
* Dragon Age 2 uses Wwise for sound and music&lt;br /&gt;
* Should be similar in concept to FMD&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
=== Gamepad binding ===&lt;br /&gt;
* The Xbox versions of KotOR and KotOR2 don&#039;t use a mouse. We have basic support for joysticks/gamepads, but no real bindings to the engine or ideas how to handle that in general&lt;br /&gt;
* We might want to handle the controller support the new KotOR2 Steam update brought&lt;br /&gt;
** override folder contains a gamepad.txt then&lt;br /&gt;
* Also hack in controller support for a non-Steam KotOR2? And for KotOR?&lt;br /&gt;
* Controller support in Jade Empire&lt;br /&gt;
* Controller support for Sonic? It is a Nintendo DS game after all&lt;br /&gt;
* Controller support for the non-console versions of the Dragon Age games?&lt;br /&gt;
&lt;br /&gt;
== Network ==&lt;br /&gt;
* We need a network subsystem&lt;br /&gt;
** [https://www.libsdl.org/projects/SDL_net/ SDL_net]?&lt;br /&gt;
** [http://www.boost.org/doc/libs/release/libs/asio/ Boost.Asio]?&lt;br /&gt;
** More options here: http://stackoverflow.com/questions/118945/best-c-c-network-library&lt;br /&gt;
* Engines need to be split into client and server classes&lt;br /&gt;
** The original engines all still do that, even when not exposing anything to users&lt;br /&gt;
** NWN and NWN2 allow user multiplayer&lt;br /&gt;
&lt;br /&gt;
== Engines ==&lt;br /&gt;
&lt;br /&gt;
=== Script system ===&lt;br /&gt;
* ImperatorPrime had started on a script system rewrite&lt;br /&gt;
** Includes functions with real signatures&lt;br /&gt;
** Maybe switch to that, if it works&lt;br /&gt;
* Rounds, object heartbeat scripts&lt;br /&gt;
* KotOR2 and NWN2 have some extensions&lt;br /&gt;
** It seems like they don&#039;t need any extensions to the low-level bytecode stuff&lt;br /&gt;
* Witcher uses Lua scripts together with NWScript&lt;br /&gt;
* Sonic has no scripts at all, it seems&lt;br /&gt;
* Currently a script in an infinite loop locks the game thread&lt;br /&gt;
** Timeout? Asynchronous script execution?&lt;br /&gt;
&lt;br /&gt;
=== NWN ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Basics are there, but needs fleshing out&lt;br /&gt;
** Character generator is mostly working&lt;br /&gt;
* [[Pathfinding]], walkmesh&lt;br /&gt;
** &amp;quot;Moving&amp;quot; should move the PC, not the camera&lt;br /&gt;
** NPC walking&lt;br /&gt;
** Triggers, areas on the floor that calls scripts on enter/leave&lt;br /&gt;
* Models&lt;br /&gt;
** ASCII models need averaging of smooth group normals&lt;br /&gt;
* NWN objects need an inventory concept&lt;br /&gt;
** Player characters&#039; might be different&lt;br /&gt;
*** Inventory tetris&lt;br /&gt;
*** Inventory item icons&lt;br /&gt;
* Multi-page asian fonts&lt;br /&gt;
* LanguageID 0 is not necessarily &amp;quot;English&amp;quot;, but &amp;quot;The language of the game install&amp;quot;&lt;br /&gt;
** This is okay for languages with Latin characters&lt;br /&gt;
** Messes up strings in community modules with Asian languages that stuff strings in to languageID 0&lt;br /&gt;
** The original fails there too, though&lt;br /&gt;
&lt;br /&gt;
=== KotOR/KotOR2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Many are already there&lt;br /&gt;
** Updating for loading screen loading bar&lt;br /&gt;
&lt;br /&gt;
[[File:Loadingbar_upd.png|none|thumb]]&lt;br /&gt;
&lt;br /&gt;
** Button highlights&lt;br /&gt;
&lt;br /&gt;
[[File:Btn_hl.png|none|thumb|KoTOR (left) xoreos (right)]]&lt;br /&gt;
&lt;br /&gt;
** Class selection&lt;br /&gt;
*** Smokey background effect&lt;br /&gt;
*** Lighting on the character model&lt;br /&gt;
*** Scaling when hovering over different classes&lt;br /&gt;
Not hovered:&lt;br /&gt;
&lt;br /&gt;
[[File:Class_hl_inactive.png|none|thumb|KoTOR (left) xoreos (right)]]&lt;br /&gt;
&lt;br /&gt;
Hovered:&lt;br /&gt;
&lt;br /&gt;
[[File:Class_hl_active.png|none|thumb|KoTOR (left) xoreos (right)]]&lt;br /&gt;
&lt;br /&gt;
* Dialogues&lt;br /&gt;
** DLG files, similar to NWN&lt;br /&gt;
** Some extensions, like camera setup&lt;br /&gt;
** Dialogues are displayed very different than NWN&lt;br /&gt;
** KotOR2 has script extensions&lt;br /&gt;
*** Passing parameters to scripts&lt;br /&gt;
*** Call several scripts, combine with AND/OR for branching&lt;br /&gt;
* Animations&lt;br /&gt;
** Mostly working now&lt;br /&gt;
* Minigames&lt;br /&gt;
** Swoop racing&lt;br /&gt;
** Pazaak&lt;br /&gt;
** Hardcoded, mostly removed from usual game logic&lt;br /&gt;
&lt;br /&gt;
=== Jade Empire ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Main menu with options submenu is there&lt;br /&gt;
* Minigames&lt;br /&gt;
** Flyer, top-down shoot-em-up thing&lt;br /&gt;
** Hardcoded, mostly removed from usual game logic&lt;br /&gt;
* Player character&lt;br /&gt;
** Needs research&lt;br /&gt;
* Sound&lt;br /&gt;
** Uses an ASCII variant of the [http://wiki.multimedia.cx/index.php?title=XACT XACT formats]&lt;br /&gt;
*** Cues probably not as complex as FMOD/Wwise&lt;br /&gt;
*** Effects need extension of the Sound system, maybe&lt;br /&gt;
** Xbox version might use the binary format?&lt;br /&gt;
*** Sound banks could be handles as archives and indexed in the ResourceManager?&lt;br /&gt;
** [https://github.com/flibitijibibo/FACT FACT] is an implementation of XAudio, including XACT, zlib-licensed&lt;br /&gt;
&lt;br /&gt;
=== NWN2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Implemented using XML&lt;br /&gt;
** See [[#Broken NWN2 XML|Broken NWN2 XML]]&lt;br /&gt;
* Animations (Granny)&lt;br /&gt;
** [https://github.com/SkywingvL/nwn2dev-public nwn2-dev] contains some code working with Granny data&lt;br /&gt;
*** Call into the original Granny DLL to convert between binary and ASCII Granny data, though&lt;br /&gt;
** [https://github.com/berenm/xoreos-tools/tree/granny berenm started some Granny RE]&lt;br /&gt;
** Based on berenm&#039;s RE efforts, Arbos has written a tool to convert to/from MDB+GR2: https://github.com/Arbos/nwn2mdk&lt;br /&gt;
*** Probably a good starting point for integrating NWN2 animations into xoreos&lt;br /&gt;
* Facial animations (FaceFX)&lt;br /&gt;
* Trees (SpeedTree)&lt;br /&gt;
* Proper evaluation of creature model parts (equipped items)&lt;br /&gt;
* Player character&lt;br /&gt;
** Reading of PC files in creature&lt;br /&gt;
* Walkmeshes. CromFr wrote a specs document here: https://gist.github.com/CromFr/104bac52dc9191099d9d9e3dbd2c4975&lt;br /&gt;
&lt;br /&gt;
=== Sonic Chronicles ===&lt;br /&gt;
* Allow using the contents from an extracted NDS file?&lt;br /&gt;
* Menus&lt;br /&gt;
** GUI files that are GFF&lt;br /&gt;
** Actions in a state machine in GDA files?&lt;br /&gt;
* Music/Sound&lt;br /&gt;
** Music is apparently similar to MIDI, or to a tracker format?&lt;br /&gt;
** Sounds and instruments for music are in a sound_data.sadl archive&lt;br /&gt;
* Animations&lt;br /&gt;
** Bone animations, best implemented with shaders, blocked by the graphics subsystem rewrite&lt;br /&gt;
* Player character(s)&lt;br /&gt;
** Needs research&lt;br /&gt;
&lt;br /&gt;
=== The Witcher ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Apparently build using Lua&lt;br /&gt;
** System/Scripts/ has gui*.luc files&lt;br /&gt;
* Animations&lt;br /&gt;
** Needs research&lt;br /&gt;
* Player character, Geralt&lt;br /&gt;
** Needs research&lt;br /&gt;
&lt;br /&gt;
=== Dragon Age: Origins / Dragon Age 2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Scaleform_GFx Scaleform GFx]&lt;br /&gt;
** [http://social.bioware.com/wiki/datoolset/index.php/UI_Tutorial_%28draft%29 UI Tutorial] on the Dragon Age toolset wiki&lt;br /&gt;
** Flash-based!&lt;br /&gt;
** A good starting point for a reimplementation might be [https://en.wikipedia.org/wiki/Gameswf Gameswf].&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Gnash Gnash], [https://en.wikipedia.org/wiki/Lightspark Lightspark], [https://en.wikipedia.org/wiki/Swfdec Swfdec]&lt;br /&gt;
** [http://www.nowrap.de/flasm.html Flasm] can disassemble/assemble ActionScript, [http://www.nowrap.de/flare.html Flare] can decompile it&lt;br /&gt;
** [https://wwwimages2.adobe.com/content/dam/acom/en/devnet/pdf/swf-file-format-spec.pdf swf-file-format-spec.pdf] is a great reference which covers mostly every aspect of the gfx files.&lt;br /&gt;
** [https://github.com/jindrapetrik/jpexs-decompiler jpexs-decompiler] can decompile and handles scaleform specific tags.&lt;br /&gt;
* Animations&lt;br /&gt;
** Bone animations, best implemented with shaders, blocked by the graphics subsystem rewrite&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Developer_Central&amp;diff=468</id>
		<title>Developer Central</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Developer_Central&amp;diff=468"/>
		<updated>2022-07-20T13:21:03Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* Reverse engineering help */ Use Internet Archive links for the REWiki, since it seems to be dead :(&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this page is to give a link to all kinds of resources that contain information valuable to current and future developers of xoreos.&lt;br /&gt;
&lt;br /&gt;
== The source repository ==&lt;br /&gt;
&lt;br /&gt;
The main xoreos source repositories are hosted on [https://github.com/xoreos/ GitHub]. Please see the [[Git]] page on details on how the repositories are structured and how to retrieve the code.&lt;br /&gt;
&lt;br /&gt;
== Compilation ==&lt;br /&gt;
&lt;br /&gt;
See the [[Compiling xoreos]], [[Compiling xoreos-tools]] and [[Compiling Phaethon]] pages for information on how to compile our source code on various operating systems.&lt;br /&gt;
&lt;br /&gt;
== Community ==&lt;br /&gt;
&lt;br /&gt;
We strive to be a friendly and open development community. Therefore, we have adopted a [https://github.com/xoreos/xoreos/blob/master/CODE_OF_CONDUCT.md Code of Conduct] guiding us. By participating in this project you agree to abide by its terms.&lt;br /&gt;
&lt;br /&gt;
Our main place for organizing and socializing is the [[IRC channel|#xoreos channel on Libera IRC]]. You will find most of the developers idling there, happy to answer any questions you might have. If you plan to become a frequent contributor, please consider regularly joining this channel as well.&lt;br /&gt;
&lt;br /&gt;
However, there is not public log bot in #xoreos, so there is no public, permanent record. Therefore, discussions about far reaching changes in the codebase are best held on [[Mailing lists|our mailing list]]. Contributors are encouraged to subscribe to this list.&lt;br /&gt;
&lt;br /&gt;
If you intend to work on a feature, or otherwise contribute to xoreos, please notify us before-hand, so that unnecessary, accidentally doubling of work can be avoided.&lt;br /&gt;
&lt;br /&gt;
== Reporting bugs ==&lt;br /&gt;
&lt;br /&gt;
Bugs should be reported on the GitHub issue tracker. If the bug concerns xoreos itself, use the [https://github.com/xoreos/xoreos/issues one for xoreos], if the bug concerns the xoreos-tools, use the [https://github.com/xoreos/xoreos-tools/issues one for xoreos-tools]. Likewise, all the other [https://github.com/xoreos repositories] have issue tracking enabled.&lt;br /&gt;
&lt;br /&gt;
== Code style ==&lt;br /&gt;
&lt;br /&gt;
We have [[Code Formatting Conventions]] you are expected to follow. Patches and pull requests that do not follow these conventions will be rejected or at least delayed until they are cleaned up to comply.&lt;br /&gt;
&lt;br /&gt;
== Commit guidelines ==&lt;br /&gt;
&lt;br /&gt;
Please read the [[Commit Guidelines]]. We want to keep our project history clean and readable.&lt;br /&gt;
&lt;br /&gt;
== Branches ==&lt;br /&gt;
&lt;br /&gt;
Do not work directly on the master branch. Instead, use [https://www.atlassian.com/git/tutorials/comparing-workflows/feature-branch-workflow feature branches], one for each new feature you are working on. This ensures that each feature has its own, clean history that can be reviewed more easily. Once the feature has been merged into the main development tree, you are of course free to delete your feature branch again.&lt;br /&gt;
&lt;br /&gt;
== Pull Requests ==&lt;br /&gt;
&lt;br /&gt;
If you do not have push permissions to the official xoreos repositories, and especially if you&#039;re a first-time contributor, we prefer to receive your changes as a [https://help.github.com/articles/using-pull-requests pull request on GitHub]. This requires you to have/register a GitHub account, fork our repository, commit your changes to a branch and then issue a Pull Request.&lt;br /&gt;
&lt;br /&gt;
Please only add commits belonging to this one feature to the pull requests; do not intersperse them with unrelated changes. Also try to [https://git-scm.com/book/en/v2/Git-Tools-Rewriting-History actively tidy your history]: combine related commits with interactive rebasing, separate monolithic commits, etc. Feel free to force-push to your feature branch to tidy your history.&lt;br /&gt;
&lt;br /&gt;
Before and during the review process, please keep up to date with the xoreos master branch by [https://git-scm.com/book/en/v2/Git-Branching-Rebasing rebasing] your changes onto the current master.&lt;br /&gt;
&lt;br /&gt;
== Pushing to the official repositories ==&lt;br /&gt;
&lt;br /&gt;
Once we&#039;ve made sure that you understood and can follow the style and commit guidelines and you expressed interest in further contributing to xoreos, we will be happy to have you join the xoreos development team, and grant you push permissions to the official repositories. You are then expected to continue to follow these guidelines out of your own accord, without the need for intervention by other developers. If you are unsure about how a specific case interact with the guidelines, please feel free to ask.&lt;br /&gt;
&lt;br /&gt;
To avoid people accidentally working on the same feature, or otherwise stepping on each others&#039; toes, consider announcement what you are working on in the [[IRC channel]] or the [[Mailing lists|mailing list]].&lt;br /&gt;
&lt;br /&gt;
== Continuous Integration ==&lt;br /&gt;
&lt;br /&gt;
The public xoreos repositories are build by two [https://en.wikipedia.org/wiki/Continuous_integration Continuous Integration] services on every push: [https://travis-ci.org/ Travis CI] (for GNU/Linux, using both the autotools and the CMake build systems and also using both gcc and clang) and [https://www.appveyor.com/ AppVeyor] (for Windows, using Microsoft Visual Studio). If a compilation error occurs, the build failure announced is on our [https://wiki.xoreos.org/index.php?title=IRC_channel IRC channel], so that it may be fixed quickly. Pull Requests are also run through these CI services and we like to have all failures fixed before merging.&lt;br /&gt;
&lt;br /&gt;
== Unit tests ==&lt;br /&gt;
&lt;br /&gt;
The xoreos repositories also provide unit tests for many common classes. These are build and run right after the main binaries on every push, by the CI services we use. A failure in one of these unit tests leads to the build being treated as failed. That way, it&#039;s immediately obvious when we break anything.&lt;br /&gt;
&lt;br /&gt;
All xoreos developers are advised to run these unit tests themselves while writing code that touches the common code. In both of our build systems, &amp;quot;make check&amp;quot; does exactly this.&lt;br /&gt;
&lt;br /&gt;
When writing new common classes, or adding functionality to existing ones, also writing new unit tests checking the new functionality is hugely appreciated.&lt;br /&gt;
&lt;br /&gt;
== Releases ==&lt;br /&gt;
&lt;br /&gt;
A short overview on how xoreos releases work can be found on the [[Releases]] page.&lt;br /&gt;
&lt;br /&gt;
== Reverse engineering help ==&lt;br /&gt;
&lt;br /&gt;
For people starting out with reverse engineering, here are a few useful resources:&lt;br /&gt;
&lt;br /&gt;
* The [http://wiki.scummvm.org/index.php/HOWTO-Reverse_Engineering HOWTO-Reverse Engineering] page in ScummVM&#039;s wiki&lt;br /&gt;
* [https://web.archive.org/web/20180127174342/http://rewiki.regengedanken.de/wiki/Main_Page REWiki] contains a collection of game reverse engineering knowledge. They have a [https://web.archive.org/web/20180117223821/http://rewiki.regengedanken.de/wiki/Reverse_engineering_hints hints page] as well&lt;br /&gt;
* [http://wiki.xentax.com/index.php?title=Game_File_Format_Central XentaxWiki] focuses on game file formats. They too have a [http://wiki.xentax.com/index.php?title=DGTEFF guide page]&lt;br /&gt;
* For audio and video formats, there&#039;s [http://wiki.multimedia.cx/ MultimediaWiki], which is associated with the ffmpeg and libav projects&lt;br /&gt;
&lt;br /&gt;
== Modding communities ==&lt;br /&gt;
&lt;br /&gt;
A lot of information about the file formats can be gleamed from the modding communities:&lt;br /&gt;
&lt;br /&gt;
* [https://neverwintervault.org/ The Neverwinter Vault] for Neverwinter Nights and Neverwinter Nights 2&lt;br /&gt;
* [https://nwn.wiki/ Neverwinter Vault Modding Wiki]&lt;br /&gt;
* [http://nwn2.wikia.com/wiki/Main_Page NWN2 wiki] for Neverwinter Nights 2&lt;br /&gt;
* [https://deadlystream.com/ Deadly Stream] for Knights of the Old Republic and Knights of the Old Republic II&lt;br /&gt;
* [http://jadeempire-modding.wikia.com/wiki/Jade_Empire_Modding_Wiki Jade Empire Modding wiki] for Jade Empire&lt;br /&gt;
* The [http://www.datoolset.net/wiki/Main_Page Dragon Age Toolset wiki] for Dragon Age: Origins and Dragon Age II&lt;br /&gt;
* The [http://witcher.wikia.com/wiki/Category:File_Formats Witcher wiki] for The Witcher&lt;br /&gt;
* [http://sonicretro.org/ Sonic Retro] for Sonic Chronicles&lt;br /&gt;
* [https://www.nexusmods.com/ Nexus Mods]&lt;br /&gt;
* [https://lexicon.nwn.wiki/index.php?title=Main_Page NWN Lexicon]&lt;br /&gt;
&lt;br /&gt;
== To do list ==&lt;br /&gt;
&lt;br /&gt;
Our [[TODO|Main TODO list]] contains a rambly, non-exhaustive collection of things left to do.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Developer_Central&amp;diff=467</id>
		<title>Developer Central</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Developer_Central&amp;diff=467"/>
		<updated>2022-07-20T13:07:41Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* Modding communities */ Update&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this page is to give a link to all kinds of resources that contain information valuable to current and future developers of xoreos.&lt;br /&gt;
&lt;br /&gt;
== The source repository ==&lt;br /&gt;
&lt;br /&gt;
The main xoreos source repositories are hosted on [https://github.com/xoreos/ GitHub]. Please see the [[Git]] page on details on how the repositories are structured and how to retrieve the code.&lt;br /&gt;
&lt;br /&gt;
== Compilation ==&lt;br /&gt;
&lt;br /&gt;
See the [[Compiling xoreos]], [[Compiling xoreos-tools]] and [[Compiling Phaethon]] pages for information on how to compile our source code on various operating systems.&lt;br /&gt;
&lt;br /&gt;
== Community ==&lt;br /&gt;
&lt;br /&gt;
We strive to be a friendly and open development community. Therefore, we have adopted a [https://github.com/xoreos/xoreos/blob/master/CODE_OF_CONDUCT.md Code of Conduct] guiding us. By participating in this project you agree to abide by its terms.&lt;br /&gt;
&lt;br /&gt;
Our main place for organizing and socializing is the [[IRC channel|#xoreos channel on Libera IRC]]. You will find most of the developers idling there, happy to answer any questions you might have. If you plan to become a frequent contributor, please consider regularly joining this channel as well.&lt;br /&gt;
&lt;br /&gt;
However, there is not public log bot in #xoreos, so there is no public, permanent record. Therefore, discussions about far reaching changes in the codebase are best held on [[Mailing lists|our mailing list]]. Contributors are encouraged to subscribe to this list.&lt;br /&gt;
&lt;br /&gt;
If you intend to work on a feature, or otherwise contribute to xoreos, please notify us before-hand, so that unnecessary, accidentally doubling of work can be avoided.&lt;br /&gt;
&lt;br /&gt;
== Reporting bugs ==&lt;br /&gt;
&lt;br /&gt;
Bugs should be reported on the GitHub issue tracker. If the bug concerns xoreos itself, use the [https://github.com/xoreos/xoreos/issues one for xoreos], if the bug concerns the xoreos-tools, use the [https://github.com/xoreos/xoreos-tools/issues one for xoreos-tools]. Likewise, all the other [https://github.com/xoreos repositories] have issue tracking enabled.&lt;br /&gt;
&lt;br /&gt;
== Code style ==&lt;br /&gt;
&lt;br /&gt;
We have [[Code Formatting Conventions]] you are expected to follow. Patches and pull requests that do not follow these conventions will be rejected or at least delayed until they are cleaned up to comply.&lt;br /&gt;
&lt;br /&gt;
== Commit guidelines ==&lt;br /&gt;
&lt;br /&gt;
Please read the [[Commit Guidelines]]. We want to keep our project history clean and readable.&lt;br /&gt;
&lt;br /&gt;
== Branches ==&lt;br /&gt;
&lt;br /&gt;
Do not work directly on the master branch. Instead, use [https://www.atlassian.com/git/tutorials/comparing-workflows/feature-branch-workflow feature branches], one for each new feature you are working on. This ensures that each feature has its own, clean history that can be reviewed more easily. Once the feature has been merged into the main development tree, you are of course free to delete your feature branch again.&lt;br /&gt;
&lt;br /&gt;
== Pull Requests ==&lt;br /&gt;
&lt;br /&gt;
If you do not have push permissions to the official xoreos repositories, and especially if you&#039;re a first-time contributor, we prefer to receive your changes as a [https://help.github.com/articles/using-pull-requests pull request on GitHub]. This requires you to have/register a GitHub account, fork our repository, commit your changes to a branch and then issue a Pull Request.&lt;br /&gt;
&lt;br /&gt;
Please only add commits belonging to this one feature to the pull requests; do not intersperse them with unrelated changes. Also try to [https://git-scm.com/book/en/v2/Git-Tools-Rewriting-History actively tidy your history]: combine related commits with interactive rebasing, separate monolithic commits, etc. Feel free to force-push to your feature branch to tidy your history.&lt;br /&gt;
&lt;br /&gt;
Before and during the review process, please keep up to date with the xoreos master branch by [https://git-scm.com/book/en/v2/Git-Branching-Rebasing rebasing] your changes onto the current master.&lt;br /&gt;
&lt;br /&gt;
== Pushing to the official repositories ==&lt;br /&gt;
&lt;br /&gt;
Once we&#039;ve made sure that you understood and can follow the style and commit guidelines and you expressed interest in further contributing to xoreos, we will be happy to have you join the xoreos development team, and grant you push permissions to the official repositories. You are then expected to continue to follow these guidelines out of your own accord, without the need for intervention by other developers. If you are unsure about how a specific case interact with the guidelines, please feel free to ask.&lt;br /&gt;
&lt;br /&gt;
To avoid people accidentally working on the same feature, or otherwise stepping on each others&#039; toes, consider announcement what you are working on in the [[IRC channel]] or the [[Mailing lists|mailing list]].&lt;br /&gt;
&lt;br /&gt;
== Continuous Integration ==&lt;br /&gt;
&lt;br /&gt;
The public xoreos repositories are build by two [https://en.wikipedia.org/wiki/Continuous_integration Continuous Integration] services on every push: [https://travis-ci.org/ Travis CI] (for GNU/Linux, using both the autotools and the CMake build systems and also using both gcc and clang) and [https://www.appveyor.com/ AppVeyor] (for Windows, using Microsoft Visual Studio). If a compilation error occurs, the build failure announced is on our [https://wiki.xoreos.org/index.php?title=IRC_channel IRC channel], so that it may be fixed quickly. Pull Requests are also run through these CI services and we like to have all failures fixed before merging.&lt;br /&gt;
&lt;br /&gt;
== Unit tests ==&lt;br /&gt;
&lt;br /&gt;
The xoreos repositories also provide unit tests for many common classes. These are build and run right after the main binaries on every push, by the CI services we use. A failure in one of these unit tests leads to the build being treated as failed. That way, it&#039;s immediately obvious when we break anything.&lt;br /&gt;
&lt;br /&gt;
All xoreos developers are advised to run these unit tests themselves while writing code that touches the common code. In both of our build systems, &amp;quot;make check&amp;quot; does exactly this.&lt;br /&gt;
&lt;br /&gt;
When writing new common classes, or adding functionality to existing ones, also writing new unit tests checking the new functionality is hugely appreciated.&lt;br /&gt;
&lt;br /&gt;
== Releases ==&lt;br /&gt;
&lt;br /&gt;
A short overview on how xoreos releases work can be found on the [[Releases]] page.&lt;br /&gt;
&lt;br /&gt;
== Reverse engineering help ==&lt;br /&gt;
&lt;br /&gt;
For people starting out with reverse engineering, here are a few useful resources:&lt;br /&gt;
&lt;br /&gt;
* The [http://wiki.scummvm.org/index.php/HOWTO-Reverse_Engineering HOWTO-Reverse Engineering] page in ScummVM&#039;s wiki&lt;br /&gt;
* [http://rewiki.awiki.org/wiki/Main_Page REWiki] contains a collection of game reverse engineering knowledge. They have a [http://rewiki.awiki.org/wiki/Reverse_engineering_hints hints page] as well&lt;br /&gt;
* [http://wiki.xentax.com/index.php?title=Game_File_Format_Central XentaxWiki] focuses on game file formats. They too have a [http://wiki.xentax.com/index.php?title=DGTEFF guide page]&lt;br /&gt;
* For audio and video formats, there&#039;s [http://wiki.multimedia.cx/ MultimediaWiki], which is associated with the ffmpeg and libav projects&lt;br /&gt;
&lt;br /&gt;
== Modding communities ==&lt;br /&gt;
&lt;br /&gt;
A lot of information about the file formats can be gleamed from the modding communities:&lt;br /&gt;
&lt;br /&gt;
* [https://neverwintervault.org/ The Neverwinter Vault] for Neverwinter Nights and Neverwinter Nights 2&lt;br /&gt;
* [https://nwn.wiki/ Neverwinter Vault Modding Wiki]&lt;br /&gt;
* [http://nwn2.wikia.com/wiki/Main_Page NWN2 wiki] for Neverwinter Nights 2&lt;br /&gt;
* [https://deadlystream.com/ Deadly Stream] for Knights of the Old Republic and Knights of the Old Republic II&lt;br /&gt;
* [http://jadeempire-modding.wikia.com/wiki/Jade_Empire_Modding_Wiki Jade Empire Modding wiki] for Jade Empire&lt;br /&gt;
* The [http://www.datoolset.net/wiki/Main_Page Dragon Age Toolset wiki] for Dragon Age: Origins and Dragon Age II&lt;br /&gt;
* The [http://witcher.wikia.com/wiki/Category:File_Formats Witcher wiki] for The Witcher&lt;br /&gt;
* [http://sonicretro.org/ Sonic Retro] for Sonic Chronicles&lt;br /&gt;
* [https://www.nexusmods.com/ Nexus Mods]&lt;br /&gt;
* [https://lexicon.nwn.wiki/index.php?title=Main_Page NWN Lexicon]&lt;br /&gt;
&lt;br /&gt;
== To do list ==&lt;br /&gt;
&lt;br /&gt;
Our [[TODO|Main TODO list]] contains a rambly, non-exhaustive collection of things left to do.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Migrating_IRC_to_Libera&amp;diff=465</id>
		<title>Migrating IRC to Libera</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Migrating_IRC_to_Libera&amp;diff=465"/>
		<updated>2021-05-24T10:35:25Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: Add an info page about moving to Libera, mostly copied from MediaWiki&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The #xoreos IRC channel is migrating to the Libera Chat IRC network.&lt;br /&gt;
&lt;br /&gt;
== Creating an account ==&lt;br /&gt;
Add the Libera Chat network at &amp;lt;code&amp;gt;irc.libera.chat&amp;lt;/code&amp;gt; to your IRC client. Read https://libera.chat/guides/connect for details.&lt;br /&gt;
&lt;br /&gt;
You will need to register your nick name with NickServ again. Details at https://libera.chat/guides/registration.&lt;br /&gt;
&lt;br /&gt;
After creating your account, it is recommended to do the following to provide greater security of your account:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;/msg nickserv set enforce on&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
It is also recommended that once you create your account you also make an edit to your [[Special:MyPage|user page]] confirming that you are the owner of the account on Libera Chat (to avoid impersonation attempts).&lt;br /&gt;
&lt;br /&gt;
=== Cloaks ===&lt;br /&gt;
If you&#039;re a contributor to xoreos, you&#039;re eligble for a xoreos/ cloak, which will hide your IP address on IRC and show your affiliation. After you&#039;ve registered with NickServ, talk to DrMcCoy, either on #xoreos or using a privmsg.&lt;br /&gt;
&lt;br /&gt;
=== Differences from Freenode ===&lt;br /&gt;
&lt;br /&gt;
Libera Chat has a more modern [[:w:Transport Layer Security|TLS]] stack than Freenode; most importantly older versions of TLS (specifically 1.0 and 1.1) are not supported on Libera Chat, so you might need to update your IRC client if you regularly connect with TLS enabled.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Developer_Central&amp;diff=464</id>
		<title>Developer Central</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Developer_Central&amp;diff=464"/>
		<updated>2021-05-23T21:10:49Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: Moved IRC channel to Libera&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this page is to give a link to all kinds of resources that contain information valuable to current and future developers of xoreos.&lt;br /&gt;
&lt;br /&gt;
== The source repository ==&lt;br /&gt;
&lt;br /&gt;
The main xoreos source repositories are hosted on [https://github.com/xoreos/ GitHub]. Please see the [[Git]] page on details on how the repositories are structured and how to retrieve the code.&lt;br /&gt;
&lt;br /&gt;
== Compilation ==&lt;br /&gt;
&lt;br /&gt;
See the [[Compiling xoreos]], [[Compiling xoreos-tools]] and [[Compiling Phaethon]] pages for information on how to compile our source code on various operating systems.&lt;br /&gt;
&lt;br /&gt;
== Community ==&lt;br /&gt;
&lt;br /&gt;
We strive to be a friendly and open development community. Therefore, we have adopted a [https://github.com/xoreos/xoreos/blob/master/CODE_OF_CONDUCT.md Code of Conduct] guiding us. By participating in this project you agree to abide by its terms.&lt;br /&gt;
&lt;br /&gt;
Our main place for organizing and socializing is the [[IRC channel|#xoreos channel on Libera IRC]]. You will find most of the developers idling there, happy to answer any questions you might have. If you plan to become a frequent contributor, please consider regularly joining this channel as well.&lt;br /&gt;
&lt;br /&gt;
However, there is not public log bot in #xoreos, so there is no public, permanent record. Therefore, discussions about far reaching changes in the codebase are best held on [[Mailing lists|our mailing list]]. Contributors are encouraged to subscribe to this list.&lt;br /&gt;
&lt;br /&gt;
If you intend to work on a feature, or otherwise contribute to xoreos, please notify us before-hand, so that unnecessary, accidentally doubling of work can be avoided.&lt;br /&gt;
&lt;br /&gt;
== Reporting bugs ==&lt;br /&gt;
&lt;br /&gt;
Bugs should be reported on the GitHub issue tracker. If the bug concerns xoreos itself, use the [https://github.com/xoreos/xoreos/issues one for xoreos], if the bug concerns the xoreos-tools, use the [https://github.com/xoreos/xoreos-tools/issues one for xoreos-tools]. Likewise, all the other [https://github.com/xoreos repositories] have issue tracking enabled.&lt;br /&gt;
&lt;br /&gt;
== Code style ==&lt;br /&gt;
&lt;br /&gt;
We have [[Code Formatting Conventions]] you are expected to follow. Patches and pull requests that do not follow these conventions will be rejected or at least delayed until they are cleaned up to comply.&lt;br /&gt;
&lt;br /&gt;
== Commit guidelines ==&lt;br /&gt;
&lt;br /&gt;
Please read the [[Commit Guidelines]]. We want to keep our project history clean and readable.&lt;br /&gt;
&lt;br /&gt;
== Branches ==&lt;br /&gt;
&lt;br /&gt;
Do not work directly on the master branch. Instead, use [https://www.atlassian.com/git/tutorials/comparing-workflows/feature-branch-workflow feature branches], one for each new feature you are working on. This ensures that each feature has its own, clean history that can be reviewed more easily. Once the feature has been merged into the main development tree, you are of course free to delete your feature branch again.&lt;br /&gt;
&lt;br /&gt;
== Pull Requests ==&lt;br /&gt;
&lt;br /&gt;
If you do not have push permissions to the official xoreos repositories, and especially if you&#039;re a first-time contributor, we prefer to receive your changes as a [https://help.github.com/articles/using-pull-requests pull request on GitHub]. This requires you to have/register a GitHub account, fork our repository, commit your changes to a branch and then issue a Pull Request.&lt;br /&gt;
&lt;br /&gt;
Please only add commits belonging to this one feature to the pull requests; do not intersperse them with unrelated changes. Also try to [https://git-scm.com/book/en/v2/Git-Tools-Rewriting-History actively tidy your history]: combine related commits with interactive rebasing, separate monolithic commits, etc. Feel free to force-push to your feature branch to tidy your history.&lt;br /&gt;
&lt;br /&gt;
Before and during the review process, please keep up to date with the xoreos master branch by [https://git-scm.com/book/en/v2/Git-Branching-Rebasing rebasing] your changes onto the current master.&lt;br /&gt;
&lt;br /&gt;
== Pushing to the official repositories ==&lt;br /&gt;
&lt;br /&gt;
Once we&#039;ve made sure that you understood and can follow the style and commit guidelines and you expressed interest in further contributing to xoreos, we will be happy to have you join the xoreos development team, and grant you push permissions to the official repositories. You are then expected to continue to follow these guidelines out of your own accord, without the need for intervention by other developers. If you are unsure about how a specific case interact with the guidelines, please feel free to ask.&lt;br /&gt;
&lt;br /&gt;
To avoid people accidentally working on the same feature, or otherwise stepping on each others&#039; toes, consider announcement what you are working on in the [[IRC channel]] or the [[Mailing lists|mailing list]].&lt;br /&gt;
&lt;br /&gt;
== Continuous Integration ==&lt;br /&gt;
&lt;br /&gt;
The public xoreos repositories are build by two [https://en.wikipedia.org/wiki/Continuous_integration Continuous Integration] services on every push: [https://travis-ci.org/ Travis CI] (for GNU/Linux, using both the autotools and the CMake build systems and also using both gcc and clang) and [https://www.appveyor.com/ AppVeyor] (for Windows, using Microsoft Visual Studio). If a compilation error occurs, the build failure announced is on our [https://wiki.xoreos.org/index.php?title=IRC_channel IRC channel], so that it may be fixed quickly. Pull Requests are also run through these CI services and we like to have all failures fixed before merging.&lt;br /&gt;
&lt;br /&gt;
== Unit tests ==&lt;br /&gt;
&lt;br /&gt;
The xoreos repositories also provide unit tests for many common classes. These are build and run right after the main binaries on every push, by the CI services we use. A failure in one of these unit tests leads to the build being treated as failed. That way, it&#039;s immediately obvious when we break anything.&lt;br /&gt;
&lt;br /&gt;
All xoreos developers are advised to run these unit tests themselves while writing code that touches the common code. In both of our build systems, &amp;quot;make check&amp;quot; does exactly this.&lt;br /&gt;
&lt;br /&gt;
When writing new common classes, or adding functionality to existing ones, also writing new unit tests checking the new functionality is hugely appreciated.&lt;br /&gt;
&lt;br /&gt;
== Releases ==&lt;br /&gt;
&lt;br /&gt;
A short overview on how xoreos releases work can be found on the [[Releases]] page.&lt;br /&gt;
&lt;br /&gt;
== Reverse engineering help ==&lt;br /&gt;
&lt;br /&gt;
For people starting out with reverse engineering, here are a few useful resources:&lt;br /&gt;
&lt;br /&gt;
* The [http://wiki.scummvm.org/index.php/HOWTO-Reverse_Engineering HOWTO-Reverse Engineering] page in ScummVM&#039;s wiki&lt;br /&gt;
* [http://rewiki.awiki.org/wiki/Main_Page REWiki] contains a collection of game reverse engineering knowledge. They have a [http://rewiki.awiki.org/wiki/Reverse_engineering_hints hints page] as well&lt;br /&gt;
* [http://wiki.xentax.com/index.php?title=Game_File_Format_Central XentaxWiki] focuses on game file formats. They too have a [http://wiki.xentax.com/index.php?title=DGTEFF guide page]&lt;br /&gt;
* For audio and video formats, there&#039;s [http://wiki.multimedia.cx/ MultimediaWiki], which is associated with the ffmpeg and libav projects&lt;br /&gt;
&lt;br /&gt;
== Modding communities ==&lt;br /&gt;
&lt;br /&gt;
A lot of information about the file formats can be gleamed from the modding communities:&lt;br /&gt;
&lt;br /&gt;
* [https://neverwintervault.org/ The Neverwinter Vault] for Neverwinter Nights and Neverwinter Nights 2&lt;br /&gt;
* [http://nwn2.wikia.com/wiki/Main_Page NWN2 wiki] for Neverwinter Nights 2&lt;br /&gt;
* [https://deadlystream.com/ Deadly Stream] for Knights of the Old Republic and Knights of the Old Republic II&lt;br /&gt;
* [http://jadeempire-modding.wikia.com/wiki/Jade_Empire_Modding_Wiki Jade Empire Modding wiki] for Jade Empire&lt;br /&gt;
* The [http://www.datoolset.net/wiki/Main_Page Dragon Age Toolset wiki] for Dragon Age: Origins and Dragon Age II&lt;br /&gt;
* The [http://witcher.wikia.com/wiki/Category:File_Formats Witcher wiki] for The Witcher&lt;br /&gt;
* [http://sonicretro.org/ Sonic Retro] for Sonic Chronicles&lt;br /&gt;
* [https://www.nexusmods.com/ Nexus Mods]&lt;br /&gt;
* [https://nwnlexicon.com/index.php?title=Main_Page NWN Lexicon]&lt;br /&gt;
&lt;br /&gt;
== To do list ==&lt;br /&gt;
&lt;br /&gt;
Our [[TODO|Main TODO list]] contains a rambly, non-exhaustive collection of things left to do.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=IRC_channel&amp;diff=463</id>
		<title>IRC channel</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=IRC_channel&amp;diff=463"/>
		<updated>2021-05-23T21:10:46Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: Moved IRC channel to Libera&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;For all kinds of live discussions we use [irc://irc.libera.chat/xoreos #xoreos] @ [https://libera.chat/ Libera IRC] channel. All xoreos developers get an operator status there, so if you have some questions, talk to them. There are several notes about usage of this medium:&lt;br /&gt;
&lt;br /&gt;
* IRC is not the best place for informing everyone about some important development conclusions. I.e. when you discussed something and came up with a solution, it&#039;s best to e-mail results to [[Mailing lists#xoreos-devel|xoreos-devel]]. That is, don&#039;t expect everyone to know that you uttered something at #xoreos.&lt;br /&gt;
* All developers who want to get operator status should register with &#039;&#039;&#039;&#039;&#039;NickServ&#039;&#039;&#039;&#039;&#039;. Assistance with registration is provided [https://libera.chat/guides/registration here].&lt;br /&gt;
* Most people on Libera have so-called anti-spam feature turned on. That is, you will not be able to PM them unless you registered with &#039;&#039;&#039;&#039;&#039;NickServ&#039;&#039;&#039;&#039;&#039;&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Compiling_Phaethon&amp;diff=462</id>
		<title>Compiling Phaethon</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Compiling_Phaethon&amp;diff=462"/>
		<updated>2020-08-26T13:29:47Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* CMake */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page gives a few tips and pointers on how to compile Phaethon on various platforms.&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
==Compiler and build system==&lt;br /&gt;
&lt;br /&gt;
Phaethon is written in C++, so a C++ compiler, like [https://gcc.gnu.org/ GCC] or [http://clang.llvm.org/ clang] is required. Phaethon follows the C++14 standard. It has two build systems: [https://en.wikipedia.org/wiki/GNU_build_system Autotools] ([https://www.gnu.org/software/autoconf/ Autoconf], [https://www.gnu.org/software/automake/ Automake] and [https://www.gnu.org/software/libtool/ Libtool]) and [https://en.wikipedia.org/wiki/CMake CMake]. Use whichever you feel more comfortable with.&lt;br /&gt;
&lt;br /&gt;
===GNU/Linux===&lt;br /&gt;
&lt;br /&gt;
On Debian-based distributions (including Ubuntu), you should be able to install the required compiler and build system packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;apt-get install libc6-dev g++ make autoconf automake libtool gettext&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install the necessary packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo pacman -S base-devel cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On other distributions, it should work similarily.&lt;br /&gt;
&lt;br /&gt;
===Windows===&lt;br /&gt;
&lt;br /&gt;
Since Visual Studio does not work with autotools, you have to use the CMake build system if you want to compile xoreos with Visual Studio. If you&#039;re using [http://www.mingw.org/ MinGW], however, you&#039;re free to choose either build system.&lt;br /&gt;
&lt;br /&gt;
On Windows, it is recommended that instead of Visual Studio, you use [https://msys2.github.io/ MSYS2] together with [https://mingw-w64.org/ Mingw-w64] (which can produce both 32-bit and 64-bit binaries). MSYS2 provides a package manager, with which you can install xoreos&#039; library dependencies very easily.&lt;br /&gt;
&lt;br /&gt;
You can install the 32-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-i686-toolchain mingw-w64-i686-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can install the 64-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-x86_64-toolchain mingw-w64-x86_64-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Libraries==&lt;br /&gt;
&lt;br /&gt;
Phaethon uses the following libraries to function:&lt;br /&gt;
&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Iconv iconv]&lt;br /&gt;
* [http://www.zlib.net/ zlib] (&amp;gt;= 1.2.3.4)&lt;br /&gt;
* [http://tukaani.org/xz/ liblzma] (&amp;gt;= 5.0.5)&lt;br /&gt;
* [http://www.boost.org/ Boost] (&amp;gt;= 1.53.0)&lt;br /&gt;
** Boost.Utility&lt;br /&gt;
** Boost.StringAlgo&lt;br /&gt;
** Boost.System&lt;br /&gt;
** Boost.Filesystem&lt;br /&gt;
** Boost.Date_Time&lt;br /&gt;
** Boost.Chrono&lt;br /&gt;
** Boost.Uuid&lt;br /&gt;
** Boost.Smart_Ptr&lt;br /&gt;
** Boost.ScopeExit&lt;br /&gt;
** Boost.Locale&lt;br /&gt;
* [https://www.qt.io/ Qt] (&amp;gt;= 5.7.1)&lt;br /&gt;
** Qt5Core&lt;br /&gt;
** Qt5Gui&lt;br /&gt;
** Qt5Widgets&lt;br /&gt;
** Qt5Concurrent&lt;br /&gt;
* [https://en.wikipedia.org/wiki/OpenAL OpenAL] (&amp;gt;= 1.12) (&#039;&#039;&#039;See below&#039;&#039;&#039;)&lt;br /&gt;
* [http://www.underbit.com/products/mad/ MAD] (&amp;gt;= 0.15.1b)&lt;br /&gt;
* [https://www.xiph.org/downloads/ libogg] (&amp;gt;= 1.2.0)&lt;br /&gt;
* [https://www.xiph.org/downloads/ libvorbis] (&amp;gt;= 1.3.1)&lt;br /&gt;
&lt;br /&gt;
On Debian-based GNU/Linux distribution (including Ubuntu), you should be able to install these libraries and their development packages with&lt;br /&gt;
&lt;br /&gt;
 sudo apt-get install zlib1g-dev liblzma-dev libboost-all-dev \&lt;br /&gt;
     libopenal-dev libmad0-dev libogg-dev libvorbis-dev  \&lt;br /&gt;
     qtbase5-dev, libqt5gui5, libqt5widgets5&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install these dependencies with&lt;br /&gt;
&lt;br /&gt;
 sudo pacman -S zlib xz boost boost-libs openal libmad libogg \&lt;br /&gt;
     libvorbis qt5-base&lt;br /&gt;
&lt;br /&gt;
Other GNU/Linux distributions should work similarily.&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 32-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-i686-zlib mingw-w64-i686-xz \&lt;br /&gt;
     mingw-w64-i686-boost mingw-w64-i686-openal mingw-w64-i686-libmad \&lt;br /&gt;
     mingw-w64-i686-libogg mingw-w64-i686-libvorbis mingw-w64-i686-qt-creator&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 64-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-x86_64-zlib mingw-w64-x86_64-xz \&lt;br /&gt;
     mingw-w64-x86_64-boost mingw-w64-x86_64-openal mingw-w64-x86_64-libmad \&lt;br /&gt;
     mingw-w64-x86_64-libogg mingw-w64-x86_64-libvorbis mingw-w64-x86_64-qt-creator&lt;br /&gt;
&lt;br /&gt;
Windows users not using MSYS2 will have to visit each website manually and download a precompiled version, or, if not available, download the source and compile the library themselves.&lt;br /&gt;
&lt;br /&gt;
=== A note on OpenAL ===&lt;br /&gt;
&lt;br /&gt;
On Mac OS X, we&#039;re using Apple&#039;s OpenAL implementation, so OpenAL does not need to be installed separately there.&lt;br /&gt;
&lt;br /&gt;
On both GNU/Linux and Microsoft Windows, we require [http://kcat.strangesoft.net/openal.html OpenAL Soft]. There is a propriety OpenAL implementation by Creative Labs, Inc. for Microsoft Windows, which can be found at [http://openal.org/ http://openal.org/], but it&#039;s unfortunately old, outdated and abandoned. We do not recommend its use.&lt;br /&gt;
&lt;br /&gt;
Likewise, on NetBSD and other systems using pkgsrc, you should use [http://pkgsrc.se/audio/openal-soft openal-soft] instead of [http://pkgsrc.se/audio/openal openal].&lt;br /&gt;
&lt;br /&gt;
==Compiling Phaethon==&lt;br /&gt;
&lt;br /&gt;
Make sure you have your compiler, build system and libraries installed correctly. Then open a terminal and change into the directory of your sources.&lt;br /&gt;
&lt;br /&gt;
===autotools===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;./autogen.sh &amp;amp;&amp;amp; ./configure &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binaries can then be found in the src subdirectory.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional ./configure flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* --with-werror &amp;amp;nbsp;&lt;br /&gt;
|| Compile with -Werror&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --without-warnings &amp;amp;nbsp;&lt;br /&gt;
|| Compile without the extra warnings enabled&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --with-lto &amp;amp;nbsp;&lt;br /&gt;
|| Compile with link-time optimization&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===CMake ===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;cmake . &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binary can be found in the bin subdirectory, called &amp;quot;phaethon&amp;quot; or, on Windows, &amp;quot;phaethon.exe&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
This builds Phaethon without any optimizations, so you might want to use&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;cmake -DCMAKE_BUILD_TYPE=Release . &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
(optimized, no debug information) or&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo . &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
(optimized, with debug information) instead.&lt;br /&gt;
&lt;br /&gt;
Please read [http://www.cmake.org/runningcmake/ Running CMake] on the CMake website for in-depth information on invoking CMake.&lt;br /&gt;
&lt;br /&gt;
==Unit tests==&lt;br /&gt;
&lt;br /&gt;
On both build systems,&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;make check&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
compiles and runs our unit tests.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Compiling_xoreos-tools&amp;diff=461</id>
		<title>Compiling xoreos-tools</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Compiling_xoreos-tools&amp;diff=461"/>
		<updated>2020-08-26T13:29:44Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* CMake */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page gives a few tips and pointers on how to compile xoreos-tools on various platforms.&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
==Compiler and build system==&lt;br /&gt;
&lt;br /&gt;
xoreos-tools is written in C++, so a C++ compiler, like [https://gcc.gnu.org/ GCC] or [http://clang.llvm.org/ clang] is required. xoreos-tools follows the C++14 standard. It has two build systems: [https://en.wikipedia.org/wiki/GNU_build_system Autotools] ([https://www.gnu.org/software/autoconf/ Autoconf], [https://www.gnu.org/software/automake/ Automake] and [https://www.gnu.org/software/libtool/ Libtool]) and [https://en.wikipedia.org/wiki/CMake CMake]. Use whichever you feel more comfortable with.&lt;br /&gt;
&lt;br /&gt;
===GNU/Linux===&lt;br /&gt;
&lt;br /&gt;
On Debian-based distributions (including Ubuntu), you should be able to install the required compiler and build system packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;apt-get install libc6-dev g++ make autoconf automake libtool gettext&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install the necessary packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo pacman -S base-devel cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On other distributions, it should work similarily.&lt;br /&gt;
&lt;br /&gt;
===Windows===&lt;br /&gt;
&lt;br /&gt;
Since Visual Studio does not work with autotools, you have to use the CMake build system if you want to compile xoreos with Visual Studio. If you&#039;re using [http://www.mingw.org/ MinGW], however, you&#039;re free to choose either build system.&lt;br /&gt;
&lt;br /&gt;
On Windows, it is recommended that instead of Visual Studio, you use [https://msys2.github.io/ MSYS2] together with [https://mingw-w64.org/ Mingw-w64] (which can produce both 32-bit and 64-bit binaries). MSYS2 provides a package manager, with which you can install xoreos&#039; library dependencies very easily.&lt;br /&gt;
&lt;br /&gt;
You can install the 32-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-i686-toolchain mingw-w64-i686-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can install the 64-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-x86_64-toolchain mingw-w64-x86_64-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Libraries==&lt;br /&gt;
&lt;br /&gt;
xoreos-tools uses the following libraries to function:&lt;br /&gt;
&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Iconv iconv]&lt;br /&gt;
* [http://www.zlib.net/ zlib] (&amp;gt;= 1.2.3.4)&lt;br /&gt;
* [http://tukaani.org/xz/ liblzma] (&amp;gt;= 5.0.5)&lt;br /&gt;
* [http://www.xmlsoft.org/ libxml2] (&amp;gt;= 2.8.0)&lt;br /&gt;
* [http://www.boost.org/ Boost] (&amp;gt;= 1.53.0)&lt;br /&gt;
** Boost.Utility&lt;br /&gt;
** Boost.StringAlgo&lt;br /&gt;
** Boost.System&lt;br /&gt;
** Boost.Filesystem&lt;br /&gt;
** Boost.Uuid&lt;br /&gt;
** Boost.Smart_Ptr&lt;br /&gt;
** Boost.ScopeExit&lt;br /&gt;
** Boost.Locale&lt;br /&gt;
&lt;br /&gt;
On Debian-based GNU/Linux distribution (including Ubuntu), you should be able to install these libraries and their development packages with&lt;br /&gt;
&lt;br /&gt;
 apt-get install zlib1g-dev liblzma-dev libxml2-dev libboost-all-dev&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install these dependencies with&lt;br /&gt;
&lt;br /&gt;
 sudo pacman -S zlib xz libxml2 boost boost-libs&lt;br /&gt;
&lt;br /&gt;
Other GNU/Linux distributions should work similarily.&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 32-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-i686-zlib mingw-w64-i686-xz mingw-w64-i686-libxml2 mingw-w64-i686-boost&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 64-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-x86_64-zlib mingw-w64-x86_64-xz mingw-w64-x86_64-libxml2 mingw-w64-x86_64-boost&lt;br /&gt;
&lt;br /&gt;
Windows users not using MSYS2 will have to visit each website manually and download a precompiled version, or, if not available, download the source and compile the library themselves.&lt;br /&gt;
&lt;br /&gt;
==Compiling xoreos-tools==&lt;br /&gt;
&lt;br /&gt;
Make sure you have your compiler, build system and libraries installed correctly. Then open a terminal and change into the directory of your sources.&lt;br /&gt;
&lt;br /&gt;
===autotools===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;./autogen.sh &amp;amp;&amp;amp; ./configure &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binaries can then be found in the src subdirectory.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional ./configure flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* --with-werror &amp;amp;nbsp;&lt;br /&gt;
|| Compile with -Werror&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --without-warnings &amp;amp;nbsp;&lt;br /&gt;
|| Compile without the extra warnings enabled&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --with-lto &amp;amp;nbsp;&lt;br /&gt;
|| Compile with link-time optimization&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===CMake ===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;cmake . &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binaries can then be found in the bin subdirectory.&lt;br /&gt;
&lt;br /&gt;
This builds xoreos-tools without any optimizations, so you might want to use&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;cmake -DCMAKE_BUILD_TYPE=Release . &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
(optimized, no debug information) or&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo . &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
(optimized, with debug information) instead.&lt;br /&gt;
&lt;br /&gt;
Please read [http://www.cmake.org/runningcmake/ Running CMake] on the CMake website for in-depth information on invoking CMake.&lt;br /&gt;
&lt;br /&gt;
==Unit tests==&lt;br /&gt;
&lt;br /&gt;
On both build systems,&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;make check&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
compiles and runs our unit tests.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Compiling_xoreos&amp;diff=460</id>
		<title>Compiling xoreos</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Compiling_xoreos&amp;diff=460"/>
		<updated>2020-08-26T13:29:39Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* CMake */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page gives a few tips and pointers on how to compile xoreos on various platforms.&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
==Compiler and build system==&lt;br /&gt;
&lt;br /&gt;
xoreos is written in C++, so a C++ compiler, like [https://gcc.gnu.org/ GCC] or [http://clang.llvm.org/ clang] is required. xoreos follows the C++14 standard. It has two build systems: [https://en.wikipedia.org/wiki/GNU_build_system Autotools] ([https://www.gnu.org/software/autoconf/ Autoconf], [https://www.gnu.org/software/automake/ Automake] and [https://www.gnu.org/software/libtool/ Libtool]) and [https://en.wikipedia.org/wiki/CMake CMake]. Use whichever you feel more comfortable with.&lt;br /&gt;
&lt;br /&gt;
===GNU/Linux===&lt;br /&gt;
&lt;br /&gt;
On Debian-based distributions (including Ubuntu), you should be able to install the required compiler and build system packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo apt-get install libc6-dev g++ make autoconf automake libtool gettext cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install the necessary packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo pacman -S base-devel cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On other distributions, it should work similarily.&lt;br /&gt;
&lt;br /&gt;
===Mac OS X===&lt;br /&gt;
&lt;br /&gt;
Due to the dependency on SDL2 (see below), you need at least Mac OS X 10.5 if you use a precompiled SDL2 library, and at least Mac OS X 10.7 if you&#039;re compiling SDL2 yourself.&lt;br /&gt;
&lt;br /&gt;
===Windows===&lt;br /&gt;
&lt;br /&gt;
Since Visual Studio does not work with autotools, you have to use the CMake build system if you want to compile xoreos with Visual Studio. If you&#039;re using [http://www.mingw.org/ MinGW], however, you&#039;re free to choose either build system.&lt;br /&gt;
&lt;br /&gt;
On Windows, it is recommended that instead of Visual Studio, you use [https://msys2.github.io/ MSYS2] together with [https://mingw-w64.org/ Mingw-w64] (which can produce both 32-bit and 64-bit binaries). MSYS2 provides a package manager, with which you can install xoreos&#039; library dependencies very easily.&lt;br /&gt;
&lt;br /&gt;
You can install the 32-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-i686-toolchain mingw-w64-i686-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can install the 64-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-x86_64-toolchain mingw-w64-x86_64-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Libraries==&lt;br /&gt;
&lt;br /&gt;
xoreos uses the following libraries to function:&lt;br /&gt;
&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Iconv iconv]&lt;br /&gt;
* [http://www.zlib.net/ zlib] (&amp;gt;= 1.2.3.4)&lt;br /&gt;
* [http://tukaani.org/xz/ liblzma] (&amp;gt;= 5.0.5)&lt;br /&gt;
* [http://www.xmlsoft.org/ libxml2] (&amp;gt;= 2.8.0)&lt;br /&gt;
* [http://www.boost.org/ Boost] (&amp;gt;= 1.53.0)&lt;br /&gt;
** Boost.Utility&lt;br /&gt;
** Boost.StringAlgo&lt;br /&gt;
** Boost.System&lt;br /&gt;
** Boost.Filesystem&lt;br /&gt;
** Boost.Date_Time&lt;br /&gt;
** Boost.Uuid&lt;br /&gt;
** Boost.Smart_Ptr&lt;br /&gt;
** Boost.ScopeExit&lt;br /&gt;
** Boost.Locale&lt;br /&gt;
* [https://en.wikipedia.org/wiki/OpenGL OpenGL] (&amp;gt;= 2.1)&lt;br /&gt;
* [https://www.libsdl.org/ SDL2] (&amp;gt;= 2.0.4)&lt;br /&gt;
* [http://www.freetype.org/ FreeType 2] (&amp;gt;= 2.4.0 (libtool number &amp;gt;= 11.0.5))&lt;br /&gt;
* [https://en.wikipedia.org/wiki/OpenAL OpenAL] (&amp;gt;= 1.12) (&#039;&#039;&#039;See below&#039;&#039;&#039;)&lt;br /&gt;
* [http://www.underbit.com/products/mad/ MAD] (&amp;gt;= 0.15.1b)&lt;br /&gt;
* [https://www.xiph.org/downloads/ libogg] (&amp;gt;= 1.2.0)&lt;br /&gt;
* [https://www.xiph.org/downloads/ libvorbis] (&amp;gt;= 1.3.1)&lt;br /&gt;
* [http://www.audiocoding.com/faad2.html libfaad] (&amp;gt;= 2.7)&lt;br /&gt;
* [https://www.xvid.org/ libxvidcore] (&amp;gt;= 1.2.2)&lt;br /&gt;
* [https://www.webmproject.org/code/ libvpx] (&amp;gt;= 1.6.0)&lt;br /&gt;
&lt;br /&gt;
On Debian-based GNU/Linux distribution (including Ubuntu), you should be able to install these libraries and their development packages with&lt;br /&gt;
&lt;br /&gt;
 sudo apt-get install zlib1g-dev liblzma-dev libxml2-dev libboost-all-dev libsdl2-dev \&lt;br /&gt;
     libfreetype6-dev libopenal-dev libmad0-dev libogg-dev libvorbis-dev libfaad-dev \&lt;br /&gt;
     libxvidcore-dev libvpx-dev&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install these dependencies with&lt;br /&gt;
&lt;br /&gt;
 sudo pacman -S zlib xz libxml2 boost boost-libs sdl2 freetype2 openal libmad libogg \&lt;br /&gt;
     libvorbis faad2 xvidcore libvpx&lt;br /&gt;
&lt;br /&gt;
Other GNU/Linux distributions should work similarily.&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 32-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-i686-zlib mingw-w64-i686-xz mingw-w64-i686-libxml2 \&lt;br /&gt;
     mingw-w64-i686-boost mingw-w64-i686-SDL2 mingw-w64-i686-freetype \&lt;br /&gt;
     mingw-w64-i686-openal mingw-w64-i686-libmad mingw-w64-i686-libogg \&lt;br /&gt;
     mingw-w64-i686-libvorbis  mingw-w64-i686-faad2 mingw-w64-i686-xvidcore \&lt;br /&gt;
     mingw-w64-i686-libvpx&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 64-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-x86_64-zlib mingw-w64-x86_64-xz mingw-w64-x86_64-libxml2 \&lt;br /&gt;
     mingw-w64-x86_64-boost mingw-w64-x86_64-SDL2 mingw-w64-x86_64-freetype \&lt;br /&gt;
     mingw-w64-x86_64-openal mingw-w64-x86_64-libmad mingw-w64-x86_64-libogg \&lt;br /&gt;
     mingw-w64-x86_64-libvorbis  mingw-w64-x86_64-faad2 mingw-w64-x86_64-xvidcore \&lt;br /&gt;
     mingw-w64-x86_64-libvpx&lt;br /&gt;
&lt;br /&gt;
Windows users not using MSYS2 will have to visit each website manually and download a precompiled version, or, if not available, download the source and compile the library themselves. Alternatively, vcpkg can be used to install most of these libraries.&lt;br /&gt;
&lt;br /&gt;
=== A note on OpenAL ===&lt;br /&gt;
&lt;br /&gt;
On Mac OS X, we&#039;re using Apple&#039;s OpenAL implementation, so OpenAL does not need to be installed separately there.&lt;br /&gt;
&lt;br /&gt;
On both GNU/Linux and Microsoft Windows, we require [http://kcat.strangesoft.net/openal.html OpenAL Soft]. There is a propriety OpenAL implementation by Creative Labs, Inc. for Microsoft Windows, which can be found at [http://openal.org/ http://openal.org/], but it&#039;s unfortunately old, outdated and abandoned. We do not recommend its use.&lt;br /&gt;
&lt;br /&gt;
Likewise, on NetBSD and other systems using pkgsrc, you should use [http://pkgsrc.se/audio/openal-soft openal-soft] instead of [http://pkgsrc.se/audio/openal openal].&lt;br /&gt;
&lt;br /&gt;
==Compiling xoreos==&lt;br /&gt;
&lt;br /&gt;
Make sure you have your compiler, build system and libraries installed correctly. Then open a terminal and change into the directory of your sources.&lt;br /&gt;
&lt;br /&gt;
===autotools===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;./autogen.sh &amp;amp;&amp;amp; ./configure &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binary can be found in the src subdirectory, called &amp;quot;xoreos&amp;quot; or, on Windows, &amp;quot;xoreos.exe&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional ./configure flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* --with-werror &amp;amp;nbsp;&lt;br /&gt;
|| Compile with -Werror&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --without-warnings &amp;amp;nbsp;&lt;br /&gt;
|| Compile without the extra warnings enabled&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --with-lto &amp;amp;nbsp;&lt;br /&gt;
|| Compile with link-time optimization&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --disable-external-glew &amp;amp;nbsp;&lt;br /&gt;
|| Always compile against the internal GLEW libraries&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
===CMake ===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;cmake . &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binary can be found in the bin subdirectory, called &amp;quot;xoreos&amp;quot; or, on Windows, &amp;quot;xoreos.exe&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
This builds xoreos without any optimizations, so you might want to use&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;cmake -DCMAKE_BUILD_TYPE=Release . &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
(optimized, no debug information) or&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo . &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
(optimized, with debug information) instead.&lt;br /&gt;
&lt;br /&gt;
Please read [http://www.cmake.org/runningcmake/ Running CMake] on the CMake website for in-depth information on invoking CMake.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional cmake flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* -DBoost_USE_STATIC_LIBS=on &amp;amp;nbsp;&lt;br /&gt;
|| Link Boost statically instead of dynamically&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* -DGLEW_INTERNAL=on &amp;amp;nbsp;&lt;br /&gt;
|| Always use internal GLEW library&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note&#039;&#039;&#039;: The CMake&#039;s stock FindBoost.cmake doesn&#039;t correctly detect dependencies when linking statically. In this case, xoreos might fail to link, missing symbols for ICU, when linking Boost statically.&lt;br /&gt;
&lt;br /&gt;
Moreover, if you&#039;re running GNU/Linux and have wrapper scripts installed that force the building of &amp;quot;hardened&amp;quot; binaries (often called &amp;quot;hardening-wrapper&amp;quot;, but differs between Linux distributions), compiling xoreos might fail during the linking stage, when using statically linking Boost libraries. This is due to those static Boost libraries being incompatible with the compiler option &amp;quot;-fPIE&amp;quot;, which is often added by hardening wrapper scripts. A workaround is to disable -fPIE for this compilation (which is distribution-specific).&lt;br /&gt;
&lt;br /&gt;
==Unit tests==&lt;br /&gt;
&lt;br /&gt;
On both build systems,&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;make check&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
compiles and runs our unit tests.&lt;br /&gt;
&lt;br /&gt;
==Running xoreos==&lt;br /&gt;
&lt;br /&gt;
Please have a look at the [[Running xoreos]] page.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Compiling_xoreos-tools&amp;diff=459</id>
		<title>Compiling xoreos-tools</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Compiling_xoreos-tools&amp;diff=459"/>
		<updated>2020-08-10T19:11:31Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* Compiler and build system */ Bump C++ standard to C++14&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page gives a few tips and pointers on how to compile xoreos-tools on various platforms.&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
==Compiler and build system==&lt;br /&gt;
&lt;br /&gt;
xoreos-tools is written in C++, so a C++ compiler, like [https://gcc.gnu.org/ GCC] or [http://clang.llvm.org/ clang] is required. xoreos-tools follows the C++14 standard. It has two build systems: [https://en.wikipedia.org/wiki/GNU_build_system Autotools] ([https://www.gnu.org/software/autoconf/ Autoconf], [https://www.gnu.org/software/automake/ Automake] and [https://www.gnu.org/software/libtool/ Libtool]) and [https://en.wikipedia.org/wiki/CMake CMake]. Use whichever you feel more comfortable with.&lt;br /&gt;
&lt;br /&gt;
===GNU/Linux===&lt;br /&gt;
&lt;br /&gt;
On Debian-based distributions (including Ubuntu), you should be able to install the required compiler and build system packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;apt-get install libc6-dev g++ make autoconf automake libtool gettext&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install the necessary packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo pacman -S base-devel cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On other distributions, it should work similarily.&lt;br /&gt;
&lt;br /&gt;
===Windows===&lt;br /&gt;
&lt;br /&gt;
Since Visual Studio does not work with autotools, you have to use the CMake build system if you want to compile xoreos with Visual Studio. If you&#039;re using [http://www.mingw.org/ MinGW], however, you&#039;re free to choose either build system.&lt;br /&gt;
&lt;br /&gt;
On Windows, it is recommended that instead of Visual Studio, you use [https://msys2.github.io/ MSYS2] together with [https://mingw-w64.org/ Mingw-w64] (which can produce both 32-bit and 64-bit binaries). MSYS2 provides a package manager, with which you can install xoreos&#039; library dependencies very easily.&lt;br /&gt;
&lt;br /&gt;
You can install the 32-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-i686-toolchain mingw-w64-i686-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can install the 64-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-x86_64-toolchain mingw-w64-x86_64-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Libraries==&lt;br /&gt;
&lt;br /&gt;
xoreos-tools uses the following libraries to function:&lt;br /&gt;
&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Iconv iconv]&lt;br /&gt;
* [http://www.zlib.net/ zlib] (&amp;gt;= 1.2.3.4)&lt;br /&gt;
* [http://tukaani.org/xz/ liblzma] (&amp;gt;= 5.0.5)&lt;br /&gt;
* [http://www.xmlsoft.org/ libxml2] (&amp;gt;= 2.8.0)&lt;br /&gt;
* [http://www.boost.org/ Boost] (&amp;gt;= 1.53.0)&lt;br /&gt;
** Boost.Utility&lt;br /&gt;
** Boost.StringAlgo&lt;br /&gt;
** Boost.System&lt;br /&gt;
** Boost.Filesystem&lt;br /&gt;
** Boost.Uuid&lt;br /&gt;
** Boost.Smart_Ptr&lt;br /&gt;
** Boost.ScopeExit&lt;br /&gt;
** Boost.Locale&lt;br /&gt;
&lt;br /&gt;
On Debian-based GNU/Linux distribution (including Ubuntu), you should be able to install these libraries and their development packages with&lt;br /&gt;
&lt;br /&gt;
 apt-get install zlib1g-dev liblzma-dev libxml2-dev libboost-all-dev&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install these dependencies with&lt;br /&gt;
&lt;br /&gt;
 sudo pacman -S zlib xz libxml2 boost boost-libs&lt;br /&gt;
&lt;br /&gt;
Other GNU/Linux distributions should work similarily.&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 32-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-i686-zlib mingw-w64-i686-xz mingw-w64-i686-libxml2 mingw-w64-i686-boost&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 64-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-x86_64-zlib mingw-w64-x86_64-xz mingw-w64-x86_64-libxml2 mingw-w64-x86_64-boost&lt;br /&gt;
&lt;br /&gt;
Windows users not using MSYS2 will have to visit each website manually and download a precompiled version, or, if not available, download the source and compile the library themselves.&lt;br /&gt;
&lt;br /&gt;
==Compiling xoreos-tools==&lt;br /&gt;
&lt;br /&gt;
Make sure you have your compiler, build system and libraries installed correctly. Then open a terminal and change into the directory of your sources.&lt;br /&gt;
&lt;br /&gt;
===autotools===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;./autogen.sh &amp;amp;&amp;amp; ./configure &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binaries can then be found in the src subdirectory.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional ./configure flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* --with-werror &amp;amp;nbsp;&lt;br /&gt;
|| Compile with -Werror&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --without-warnings &amp;amp;nbsp;&lt;br /&gt;
|| Compile without the extra warnings enabled&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --with-lto &amp;amp;nbsp;&lt;br /&gt;
|| Compile with link-time optimization&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===CMake ===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;cmake . &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binaries can then be found in the bin subdirectory.&lt;br /&gt;
&lt;br /&gt;
Please read [http://www.cmake.org/runningcmake/ Running CMake] on the CMake website for in-depth information on invoking CMake.&lt;br /&gt;
&lt;br /&gt;
==Unit tests==&lt;br /&gt;
&lt;br /&gt;
On both build systems,&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;make check&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
compiles and runs our unit tests.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Compiling_xoreos&amp;diff=458</id>
		<title>Compiling xoreos</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Compiling_xoreos&amp;diff=458"/>
		<updated>2020-08-10T19:11:29Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* Compiler and build system */ Bump C++ standard to C++14&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page gives a few tips and pointers on how to compile xoreos on various platforms.&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
==Compiler and build system==&lt;br /&gt;
&lt;br /&gt;
xoreos is written in C++, so a C++ compiler, like [https://gcc.gnu.org/ GCC] or [http://clang.llvm.org/ clang] is required. xoreos follows the C++14 standard. It has two build systems: [https://en.wikipedia.org/wiki/GNU_build_system Autotools] ([https://www.gnu.org/software/autoconf/ Autoconf], [https://www.gnu.org/software/automake/ Automake] and [https://www.gnu.org/software/libtool/ Libtool]) and [https://en.wikipedia.org/wiki/CMake CMake]. Use whichever you feel more comfortable with.&lt;br /&gt;
&lt;br /&gt;
===GNU/Linux===&lt;br /&gt;
&lt;br /&gt;
On Debian-based distributions (including Ubuntu), you should be able to install the required compiler and build system packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo apt-get install libc6-dev g++ make autoconf automake libtool gettext cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install the necessary packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo pacman -S base-devel cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On other distributions, it should work similarily.&lt;br /&gt;
&lt;br /&gt;
===Mac OS X===&lt;br /&gt;
&lt;br /&gt;
Due to the dependency on SDL2 (see below), you need at least Mac OS X 10.5 if you use a precompiled SDL2 library, and at least Mac OS X 10.7 if you&#039;re compiling SDL2 yourself.&lt;br /&gt;
&lt;br /&gt;
===Windows===&lt;br /&gt;
&lt;br /&gt;
Since Visual Studio does not work with autotools, you have to use the CMake build system if you want to compile xoreos with Visual Studio. If you&#039;re using [http://www.mingw.org/ MinGW], however, you&#039;re free to choose either build system.&lt;br /&gt;
&lt;br /&gt;
On Windows, it is recommended that instead of Visual Studio, you use [https://msys2.github.io/ MSYS2] together with [https://mingw-w64.org/ Mingw-w64] (which can produce both 32-bit and 64-bit binaries). MSYS2 provides a package manager, with which you can install xoreos&#039; library dependencies very easily.&lt;br /&gt;
&lt;br /&gt;
You can install the 32-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-i686-toolchain mingw-w64-i686-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can install the 64-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-x86_64-toolchain mingw-w64-x86_64-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Libraries==&lt;br /&gt;
&lt;br /&gt;
xoreos uses the following libraries to function:&lt;br /&gt;
&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Iconv iconv]&lt;br /&gt;
* [http://www.zlib.net/ zlib] (&amp;gt;= 1.2.3.4)&lt;br /&gt;
* [http://tukaani.org/xz/ liblzma] (&amp;gt;= 5.0.5)&lt;br /&gt;
* [http://www.xmlsoft.org/ libxml2] (&amp;gt;= 2.8.0)&lt;br /&gt;
* [http://www.boost.org/ Boost] (&amp;gt;= 1.53.0)&lt;br /&gt;
** Boost.Utility&lt;br /&gt;
** Boost.StringAlgo&lt;br /&gt;
** Boost.System&lt;br /&gt;
** Boost.Filesystem&lt;br /&gt;
** Boost.Date_Time&lt;br /&gt;
** Boost.Uuid&lt;br /&gt;
** Boost.Smart_Ptr&lt;br /&gt;
** Boost.ScopeExit&lt;br /&gt;
** Boost.Locale&lt;br /&gt;
* [https://en.wikipedia.org/wiki/OpenGL OpenGL] (&amp;gt;= 2.1)&lt;br /&gt;
* [https://www.libsdl.org/ SDL2] (&amp;gt;= 2.0.4)&lt;br /&gt;
* [http://www.freetype.org/ FreeType 2] (&amp;gt;= 2.4.0 (libtool number &amp;gt;= 11.0.5))&lt;br /&gt;
* [https://en.wikipedia.org/wiki/OpenAL OpenAL] (&amp;gt;= 1.12) (&#039;&#039;&#039;See below&#039;&#039;&#039;)&lt;br /&gt;
* [http://www.underbit.com/products/mad/ MAD] (&amp;gt;= 0.15.1b)&lt;br /&gt;
* [https://www.xiph.org/downloads/ libogg] (&amp;gt;= 1.2.0)&lt;br /&gt;
* [https://www.xiph.org/downloads/ libvorbis] (&amp;gt;= 1.3.1)&lt;br /&gt;
* [http://www.audiocoding.com/faad2.html libfaad] (&amp;gt;= 2.7)&lt;br /&gt;
* [https://www.xvid.org/ libxvidcore] (&amp;gt;= 1.2.2)&lt;br /&gt;
* [https://www.webmproject.org/code/ libvpx] (&amp;gt;= 1.6.0)&lt;br /&gt;
&lt;br /&gt;
On Debian-based GNU/Linux distribution (including Ubuntu), you should be able to install these libraries and their development packages with&lt;br /&gt;
&lt;br /&gt;
 sudo apt-get install zlib1g-dev liblzma-dev libxml2-dev libboost-all-dev libsdl2-dev \&lt;br /&gt;
     libfreetype6-dev libopenal-dev libmad0-dev libogg-dev libvorbis-dev libfaad-dev \&lt;br /&gt;
     libxvidcore-dev libvpx-dev&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install these dependencies with&lt;br /&gt;
&lt;br /&gt;
 sudo pacman -S zlib xz libxml2 boost boost-libs sdl2 freetype2 openal libmad libogg \&lt;br /&gt;
     libvorbis faad2 xvidcore libvpx&lt;br /&gt;
&lt;br /&gt;
Other GNU/Linux distributions should work similarily.&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 32-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-i686-zlib mingw-w64-i686-xz mingw-w64-i686-libxml2 \&lt;br /&gt;
     mingw-w64-i686-boost mingw-w64-i686-SDL2 mingw-w64-i686-freetype \&lt;br /&gt;
     mingw-w64-i686-openal mingw-w64-i686-libmad mingw-w64-i686-libogg \&lt;br /&gt;
     mingw-w64-i686-libvorbis  mingw-w64-i686-faad2 mingw-w64-i686-xvidcore \&lt;br /&gt;
     mingw-w64-i686-libvpx&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 64-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-x86_64-zlib mingw-w64-x86_64-xz mingw-w64-x86_64-libxml2 \&lt;br /&gt;
     mingw-w64-x86_64-boost mingw-w64-x86_64-SDL2 mingw-w64-x86_64-freetype \&lt;br /&gt;
     mingw-w64-x86_64-openal mingw-w64-x86_64-libmad mingw-w64-x86_64-libogg \&lt;br /&gt;
     mingw-w64-x86_64-libvorbis  mingw-w64-x86_64-faad2 mingw-w64-x86_64-xvidcore \&lt;br /&gt;
     mingw-w64-x86_64-libvpx&lt;br /&gt;
&lt;br /&gt;
Windows users not using MSYS2 will have to visit each website manually and download a precompiled version, or, if not available, download the source and compile the library themselves. Alternatively, vcpkg can be used to install most of these libraries.&lt;br /&gt;
&lt;br /&gt;
=== A note on OpenAL ===&lt;br /&gt;
&lt;br /&gt;
On Mac OS X, we&#039;re using Apple&#039;s OpenAL implementation, so OpenAL does not need to be installed separately there.&lt;br /&gt;
&lt;br /&gt;
On both GNU/Linux and Microsoft Windows, we require [http://kcat.strangesoft.net/openal.html OpenAL Soft]. There is a propriety OpenAL implementation by Creative Labs, Inc. for Microsoft Windows, which can be found at [http://openal.org/ http://openal.org/], but it&#039;s unfortunately old, outdated and abandoned. We do not recommend its use.&lt;br /&gt;
&lt;br /&gt;
Likewise, on NetBSD and other systems using pkgsrc, you should use [http://pkgsrc.se/audio/openal-soft openal-soft] instead of [http://pkgsrc.se/audio/openal openal].&lt;br /&gt;
&lt;br /&gt;
==Compiling xoreos==&lt;br /&gt;
&lt;br /&gt;
Make sure you have your compiler, build system and libraries installed correctly. Then open a terminal and change into the directory of your sources.&lt;br /&gt;
&lt;br /&gt;
===autotools===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;./autogen.sh &amp;amp;&amp;amp; ./configure &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binary can be found in the src subdirectory, called &amp;quot;xoreos&amp;quot; or, on Windows, &amp;quot;xoreos.exe&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional ./configure flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* --with-werror &amp;amp;nbsp;&lt;br /&gt;
|| Compile with -Werror&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --without-warnings &amp;amp;nbsp;&lt;br /&gt;
|| Compile without the extra warnings enabled&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --with-lto &amp;amp;nbsp;&lt;br /&gt;
|| Compile with link-time optimization&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --disable-external-glew &amp;amp;nbsp;&lt;br /&gt;
|| Always compile against the internal GLEW libraries&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
===CMake ===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;cmake . &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binary can be found in the bin subdirectory, called &amp;quot;xoreos&amp;quot; or, on Windows, &amp;quot;xoreos.exe&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Please read [http://www.cmake.org/runningcmake/ Running CMake] on the CMake website for in-depth information on invoking CMake.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional cmake flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* -DBoost_USE_STATIC_LIBS=on &amp;amp;nbsp;&lt;br /&gt;
|| Link Boost statically instead of dynamically&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* -DGLEW_INTERNAL=on &amp;amp;nbsp;&lt;br /&gt;
|| Always use internal GLEW library&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note&#039;&#039;&#039;: The CMake&#039;s stock FindBoost.cmake doesn&#039;t correctly detect dependencies when linking statically. In this case, xoreos might fail to link, missing symbols for ICU, when linking Boost statically.&lt;br /&gt;
&lt;br /&gt;
Moreover, if you&#039;re running GNU/Linux and have wrapper scripts installed that force the building of &amp;quot;hardened&amp;quot; binaries (often called &amp;quot;hardening-wrapper&amp;quot;, but differs between Linux distributions), compiling xoreos might fail during the linking stage, when using statically linking Boost libraries. This is due to those static Boost libraries being incompatible with the compiler option &amp;quot;-fPIE&amp;quot;, which is often added by hardening wrapper scripts. A workaround is to disable -fPIE for this compilation (which is distribution-specific).&lt;br /&gt;
&lt;br /&gt;
==Unit tests==&lt;br /&gt;
&lt;br /&gt;
On both build systems,&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;make check&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
compiles and runs our unit tests.&lt;br /&gt;
&lt;br /&gt;
==Running xoreos==&lt;br /&gt;
&lt;br /&gt;
Please have a look at the [[Running xoreos]] page.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Compiling_xoreos&amp;diff=457</id>
		<title>Compiling xoreos</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Compiling_xoreos&amp;diff=457"/>
		<updated>2020-08-10T12:35:46Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* Libraries */ Bump SDL dependency to 2.0.4&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page gives a few tips and pointers on how to compile xoreos on various platforms.&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
==Compiler and build system==&lt;br /&gt;
&lt;br /&gt;
xoreos is written in C++, so a C++ compiler, like [https://gcc.gnu.org/ GCC] or [http://clang.llvm.org/ clang] is required. xoreos follows the C++11 standard. It has two build systems: [https://en.wikipedia.org/wiki/GNU_build_system Autotools] ([https://www.gnu.org/software/autoconf/ Autoconf], [https://www.gnu.org/software/automake/ Automake] and [https://www.gnu.org/software/libtool/ Libtool]) and [https://en.wikipedia.org/wiki/CMake CMake]. Use whichever you feel more comfortable with.&lt;br /&gt;
&lt;br /&gt;
===GNU/Linux===&lt;br /&gt;
&lt;br /&gt;
On Debian-based distributions (including Ubuntu), you should be able to install the required compiler and build system packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo apt-get install libc6-dev g++ make autoconf automake libtool gettext cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install the necessary packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo pacman -S base-devel cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On other distributions, it should work similarily.&lt;br /&gt;
&lt;br /&gt;
===Mac OS X===&lt;br /&gt;
&lt;br /&gt;
Due to the dependency on SDL2 (see below), you need at least Mac OS X 10.5 if you use a precompiled SDL2 library, and at least Mac OS X 10.7 if you&#039;re compiling SDL2 yourself.&lt;br /&gt;
&lt;br /&gt;
===Windows===&lt;br /&gt;
&lt;br /&gt;
Since Visual Studio does not work with autotools, you have to use the CMake build system if you want to compile xoreos with Visual Studio. If you&#039;re using [http://www.mingw.org/ MinGW], however, you&#039;re free to choose either build system.&lt;br /&gt;
&lt;br /&gt;
On Windows, it is recommended that instead of Visual Studio, you use [https://msys2.github.io/ MSYS2] together with [https://mingw-w64.org/ Mingw-w64] (which can produce both 32-bit and 64-bit binaries). MSYS2 provides a package manager, with which you can install xoreos&#039; library dependencies very easily.&lt;br /&gt;
&lt;br /&gt;
You can install the 32-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-i686-toolchain mingw-w64-i686-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can install the 64-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-x86_64-toolchain mingw-w64-x86_64-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Libraries==&lt;br /&gt;
&lt;br /&gt;
xoreos uses the following libraries to function:&lt;br /&gt;
&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Iconv iconv]&lt;br /&gt;
* [http://www.zlib.net/ zlib] (&amp;gt;= 1.2.3.4)&lt;br /&gt;
* [http://tukaani.org/xz/ liblzma] (&amp;gt;= 5.0.5)&lt;br /&gt;
* [http://www.xmlsoft.org/ libxml2] (&amp;gt;= 2.8.0)&lt;br /&gt;
* [http://www.boost.org/ Boost] (&amp;gt;= 1.53.0)&lt;br /&gt;
** Boost.Utility&lt;br /&gt;
** Boost.StringAlgo&lt;br /&gt;
** Boost.System&lt;br /&gt;
** Boost.Filesystem&lt;br /&gt;
** Boost.Date_Time&lt;br /&gt;
** Boost.Uuid&lt;br /&gt;
** Boost.Smart_Ptr&lt;br /&gt;
** Boost.ScopeExit&lt;br /&gt;
** Boost.Locale&lt;br /&gt;
* [https://en.wikipedia.org/wiki/OpenGL OpenGL] (&amp;gt;= 2.1)&lt;br /&gt;
* [https://www.libsdl.org/ SDL2] (&amp;gt;= 2.0.4)&lt;br /&gt;
* [http://www.freetype.org/ FreeType 2] (&amp;gt;= 2.4.0 (libtool number &amp;gt;= 11.0.5))&lt;br /&gt;
* [https://en.wikipedia.org/wiki/OpenAL OpenAL] (&amp;gt;= 1.12) (&#039;&#039;&#039;See below&#039;&#039;&#039;)&lt;br /&gt;
* [http://www.underbit.com/products/mad/ MAD] (&amp;gt;= 0.15.1b)&lt;br /&gt;
* [https://www.xiph.org/downloads/ libogg] (&amp;gt;= 1.2.0)&lt;br /&gt;
* [https://www.xiph.org/downloads/ libvorbis] (&amp;gt;= 1.3.1)&lt;br /&gt;
* [http://www.audiocoding.com/faad2.html libfaad] (&amp;gt;= 2.7)&lt;br /&gt;
* [https://www.xvid.org/ libxvidcore] (&amp;gt;= 1.2.2)&lt;br /&gt;
* [https://www.webmproject.org/code/ libvpx] (&amp;gt;= 1.6.0)&lt;br /&gt;
&lt;br /&gt;
On Debian-based GNU/Linux distribution (including Ubuntu), you should be able to install these libraries and their development packages with&lt;br /&gt;
&lt;br /&gt;
 sudo apt-get install zlib1g-dev liblzma-dev libxml2-dev libboost-all-dev libsdl2-dev \&lt;br /&gt;
     libfreetype6-dev libopenal-dev libmad0-dev libogg-dev libvorbis-dev libfaad-dev \&lt;br /&gt;
     libxvidcore-dev libvpx-dev&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install these dependencies with&lt;br /&gt;
&lt;br /&gt;
 sudo pacman -S zlib xz libxml2 boost boost-libs sdl2 freetype2 openal libmad libogg \&lt;br /&gt;
     libvorbis faad2 xvidcore libvpx&lt;br /&gt;
&lt;br /&gt;
Other GNU/Linux distributions should work similarily.&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 32-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-i686-zlib mingw-w64-i686-xz mingw-w64-i686-libxml2 \&lt;br /&gt;
     mingw-w64-i686-boost mingw-w64-i686-SDL2 mingw-w64-i686-freetype \&lt;br /&gt;
     mingw-w64-i686-openal mingw-w64-i686-libmad mingw-w64-i686-libogg \&lt;br /&gt;
     mingw-w64-i686-libvorbis  mingw-w64-i686-faad2 mingw-w64-i686-xvidcore \&lt;br /&gt;
     mingw-w64-i686-libvpx&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 64-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-x86_64-zlib mingw-w64-x86_64-xz mingw-w64-x86_64-libxml2 \&lt;br /&gt;
     mingw-w64-x86_64-boost mingw-w64-x86_64-SDL2 mingw-w64-x86_64-freetype \&lt;br /&gt;
     mingw-w64-x86_64-openal mingw-w64-x86_64-libmad mingw-w64-x86_64-libogg \&lt;br /&gt;
     mingw-w64-x86_64-libvorbis  mingw-w64-x86_64-faad2 mingw-w64-x86_64-xvidcore \&lt;br /&gt;
     mingw-w64-x86_64-libvpx&lt;br /&gt;
&lt;br /&gt;
Windows users not using MSYS2 will have to visit each website manually and download a precompiled version, or, if not available, download the source and compile the library themselves. Alternatively, vcpkg can be used to install most of these libraries.&lt;br /&gt;
&lt;br /&gt;
=== A note on OpenAL ===&lt;br /&gt;
&lt;br /&gt;
On Mac OS X, we&#039;re using Apple&#039;s OpenAL implementation, so OpenAL does not need to be installed separately there.&lt;br /&gt;
&lt;br /&gt;
On both GNU/Linux and Microsoft Windows, we require [http://kcat.strangesoft.net/openal.html OpenAL Soft]. There is a propriety OpenAL implementation by Creative Labs, Inc. for Microsoft Windows, which can be found at [http://openal.org/ http://openal.org/], but it&#039;s unfortunately old, outdated and abandoned. We do not recommend its use.&lt;br /&gt;
&lt;br /&gt;
Likewise, on NetBSD and other systems using pkgsrc, you should use [http://pkgsrc.se/audio/openal-soft openal-soft] instead of [http://pkgsrc.se/audio/openal openal].&lt;br /&gt;
&lt;br /&gt;
==Compiling xoreos==&lt;br /&gt;
&lt;br /&gt;
Make sure you have your compiler, build system and libraries installed correctly. Then open a terminal and change into the directory of your sources.&lt;br /&gt;
&lt;br /&gt;
===autotools===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;./autogen.sh &amp;amp;&amp;amp; ./configure &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binary can be found in the src subdirectory, called &amp;quot;xoreos&amp;quot; or, on Windows, &amp;quot;xoreos.exe&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional ./configure flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* --with-werror &amp;amp;nbsp;&lt;br /&gt;
|| Compile with -Werror&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --without-warnings &amp;amp;nbsp;&lt;br /&gt;
|| Compile without the extra warnings enabled&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --with-lto &amp;amp;nbsp;&lt;br /&gt;
|| Compile with link-time optimization&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --disable-external-glew &amp;amp;nbsp;&lt;br /&gt;
|| Always compile against the internal GLEW libraries&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
===CMake ===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;cmake . &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binary can be found in the bin subdirectory, called &amp;quot;xoreos&amp;quot; or, on Windows, &amp;quot;xoreos.exe&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Please read [http://www.cmake.org/runningcmake/ Running CMake] on the CMake website for in-depth information on invoking CMake.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional cmake flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* -DBoost_USE_STATIC_LIBS=on &amp;amp;nbsp;&lt;br /&gt;
|| Link Boost statically instead of dynamically&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* -DGLEW_INTERNAL=on &amp;amp;nbsp;&lt;br /&gt;
|| Always use internal GLEW library&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note&#039;&#039;&#039;: The CMake&#039;s stock FindBoost.cmake doesn&#039;t correctly detect dependencies when linking statically. In this case, xoreos might fail to link, missing symbols for ICU, when linking Boost statically.&lt;br /&gt;
&lt;br /&gt;
Moreover, if you&#039;re running GNU/Linux and have wrapper scripts installed that force the building of &amp;quot;hardened&amp;quot; binaries (often called &amp;quot;hardening-wrapper&amp;quot;, but differs between Linux distributions), compiling xoreos might fail during the linking stage, when using statically linking Boost libraries. This is due to those static Boost libraries being incompatible with the compiler option &amp;quot;-fPIE&amp;quot;, which is often added by hardening wrapper scripts. A workaround is to disable -fPIE for this compilation (which is distribution-specific).&lt;br /&gt;
&lt;br /&gt;
==Unit tests==&lt;br /&gt;
&lt;br /&gt;
On both build systems,&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;make check&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
compiles and runs our unit tests.&lt;br /&gt;
&lt;br /&gt;
==Running xoreos==&lt;br /&gt;
&lt;br /&gt;
Please have a look at the [[Running xoreos]] page.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Compiling_Phaethon&amp;diff=456</id>
		<title>Compiling Phaethon</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Compiling_Phaethon&amp;diff=456"/>
		<updated>2020-05-18T10:41:53Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* Libraries */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page gives a few tips and pointers on how to compile Phaethon on various platforms.&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
==Compiler and build system==&lt;br /&gt;
&lt;br /&gt;
Phaethon is written in C++, so a C++ compiler, like [https://gcc.gnu.org/ GCC] or [http://clang.llvm.org/ clang] is required. Phaethon follows the C++14 standard. It has two build systems: [https://en.wikipedia.org/wiki/GNU_build_system Autotools] ([https://www.gnu.org/software/autoconf/ Autoconf], [https://www.gnu.org/software/automake/ Automake] and [https://www.gnu.org/software/libtool/ Libtool]) and [https://en.wikipedia.org/wiki/CMake CMake]. Use whichever you feel more comfortable with.&lt;br /&gt;
&lt;br /&gt;
===GNU/Linux===&lt;br /&gt;
&lt;br /&gt;
On Debian-based distributions (including Ubuntu), you should be able to install the required compiler and build system packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;apt-get install libc6-dev g++ make autoconf automake libtool gettext&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install the necessary packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo pacman -S base-devel cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On other distributions, it should work similarily.&lt;br /&gt;
&lt;br /&gt;
===Windows===&lt;br /&gt;
&lt;br /&gt;
Since Visual Studio does not work with autotools, you have to use the CMake build system if you want to compile xoreos with Visual Studio. If you&#039;re using [http://www.mingw.org/ MinGW], however, you&#039;re free to choose either build system.&lt;br /&gt;
&lt;br /&gt;
On Windows, it is recommended that instead of Visual Studio, you use [https://msys2.github.io/ MSYS2] together with [https://mingw-w64.org/ Mingw-w64] (which can produce both 32-bit and 64-bit binaries). MSYS2 provides a package manager, with which you can install xoreos&#039; library dependencies very easily.&lt;br /&gt;
&lt;br /&gt;
You can install the 32-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-i686-toolchain mingw-w64-i686-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can install the 64-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-x86_64-toolchain mingw-w64-x86_64-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Libraries==&lt;br /&gt;
&lt;br /&gt;
Phaethon uses the following libraries to function:&lt;br /&gt;
&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Iconv iconv]&lt;br /&gt;
* [http://www.zlib.net/ zlib] (&amp;gt;= 1.2.3.4)&lt;br /&gt;
* [http://tukaani.org/xz/ liblzma] (&amp;gt;= 5.0.5)&lt;br /&gt;
* [http://www.boost.org/ Boost] (&amp;gt;= 1.53.0)&lt;br /&gt;
** Boost.Utility&lt;br /&gt;
** Boost.StringAlgo&lt;br /&gt;
** Boost.System&lt;br /&gt;
** Boost.Filesystem&lt;br /&gt;
** Boost.Date_Time&lt;br /&gt;
** Boost.Chrono&lt;br /&gt;
** Boost.Uuid&lt;br /&gt;
** Boost.Smart_Ptr&lt;br /&gt;
** Boost.ScopeExit&lt;br /&gt;
** Boost.Locale&lt;br /&gt;
* [https://www.qt.io/ Qt] (&amp;gt;= 5.7.1)&lt;br /&gt;
** Qt5Core&lt;br /&gt;
** Qt5Gui&lt;br /&gt;
** Qt5Widgets&lt;br /&gt;
** Qt5Concurrent&lt;br /&gt;
* [https://en.wikipedia.org/wiki/OpenAL OpenAL] (&amp;gt;= 1.12) (&#039;&#039;&#039;See below&#039;&#039;&#039;)&lt;br /&gt;
* [http://www.underbit.com/products/mad/ MAD] (&amp;gt;= 0.15.1b)&lt;br /&gt;
* [https://www.xiph.org/downloads/ libogg] (&amp;gt;= 1.2.0)&lt;br /&gt;
* [https://www.xiph.org/downloads/ libvorbis] (&amp;gt;= 1.3.1)&lt;br /&gt;
&lt;br /&gt;
On Debian-based GNU/Linux distribution (including Ubuntu), you should be able to install these libraries and their development packages with&lt;br /&gt;
&lt;br /&gt;
 sudo apt-get install zlib1g-dev liblzma-dev libboost-all-dev \&lt;br /&gt;
     libopenal-dev libmad0-dev libogg-dev libvorbis-dev  \&lt;br /&gt;
     qtbase5-dev, libqt5gui5, libqt5widgets5&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install these dependencies with&lt;br /&gt;
&lt;br /&gt;
 sudo pacman -S zlib xz boost boost-libs openal libmad libogg \&lt;br /&gt;
     libvorbis qt5-base&lt;br /&gt;
&lt;br /&gt;
Other GNU/Linux distributions should work similarily.&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 32-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-i686-zlib mingw-w64-i686-xz \&lt;br /&gt;
     mingw-w64-i686-boost mingw-w64-i686-openal mingw-w64-i686-libmad \&lt;br /&gt;
     mingw-w64-i686-libogg mingw-w64-i686-libvorbis mingw-w64-i686-qt-creator&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 64-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-x86_64-zlib mingw-w64-x86_64-xz \&lt;br /&gt;
     mingw-w64-x86_64-boost mingw-w64-x86_64-openal mingw-w64-x86_64-libmad \&lt;br /&gt;
     mingw-w64-x86_64-libogg mingw-w64-x86_64-libvorbis mingw-w64-x86_64-qt-creator&lt;br /&gt;
&lt;br /&gt;
Windows users not using MSYS2 will have to visit each website manually and download a precompiled version, or, if not available, download the source and compile the library themselves.&lt;br /&gt;
&lt;br /&gt;
=== A note on OpenAL ===&lt;br /&gt;
&lt;br /&gt;
On Mac OS X, we&#039;re using Apple&#039;s OpenAL implementation, so OpenAL does not need to be installed separately there.&lt;br /&gt;
&lt;br /&gt;
On both GNU/Linux and Microsoft Windows, we require [http://kcat.strangesoft.net/openal.html OpenAL Soft]. There is a propriety OpenAL implementation by Creative Labs, Inc. for Microsoft Windows, which can be found at [http://openal.org/ http://openal.org/], but it&#039;s unfortunately old, outdated and abandoned. We do not recommend its use.&lt;br /&gt;
&lt;br /&gt;
Likewise, on NetBSD and other systems using pkgsrc, you should use [http://pkgsrc.se/audio/openal-soft openal-soft] instead of [http://pkgsrc.se/audio/openal openal].&lt;br /&gt;
&lt;br /&gt;
==Compiling Phaethon==&lt;br /&gt;
&lt;br /&gt;
Make sure you have your compiler, build system and libraries installed correctly. Then open a terminal and change into the directory of your sources.&lt;br /&gt;
&lt;br /&gt;
===autotools===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;./autogen.sh &amp;amp;&amp;amp; ./configure &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binaries can then be found in the src subdirectory.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional ./configure flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* --with-werror &amp;amp;nbsp;&lt;br /&gt;
|| Compile with -Werror&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --without-warnings &amp;amp;nbsp;&lt;br /&gt;
|| Compile without the extra warnings enabled&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --with-lto &amp;amp;nbsp;&lt;br /&gt;
|| Compile with link-time optimization&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===CMake ===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;cmake . &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binaries can then be found in the bin subdirectory.&lt;br /&gt;
&lt;br /&gt;
Please read [http://www.cmake.org/runningcmake/ Running CMake] on the CMake website for in-depth information on invoking CMake.&lt;br /&gt;
&lt;br /&gt;
==Unit tests==&lt;br /&gt;
&lt;br /&gt;
On both build systems,&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;make check&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
compiles and runs our unit tests.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Compiling_xoreos-tools&amp;diff=455</id>
		<title>Compiling xoreos-tools</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Compiling_xoreos-tools&amp;diff=455"/>
		<updated>2020-05-18T10:41:39Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* Libraries */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page gives a few tips and pointers on how to compile xoreos-tools on various platforms.&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
==Compiler and build system==&lt;br /&gt;
&lt;br /&gt;
xoreos-tools is written in C++, so a C++ compiler, like [https://gcc.gnu.org/ GCC] or [http://clang.llvm.org/ clang] is required. xoreos-tools follows the C++11 standard. It has two build systems: [https://en.wikipedia.org/wiki/GNU_build_system Autotools] ([https://www.gnu.org/software/autoconf/ Autoconf], [https://www.gnu.org/software/automake/ Automake] and [https://www.gnu.org/software/libtool/ Libtool]) and [https://en.wikipedia.org/wiki/CMake CMake]. Use whichever you feel more comfortable with.&lt;br /&gt;
&lt;br /&gt;
===GNU/Linux===&lt;br /&gt;
&lt;br /&gt;
On Debian-based distributions (including Ubuntu), you should be able to install the required compiler and build system packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;apt-get install libc6-dev g++ make autoconf automake libtool gettext&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install the necessary packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo pacman -S base-devel cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On other distributions, it should work similarily.&lt;br /&gt;
&lt;br /&gt;
===Windows===&lt;br /&gt;
&lt;br /&gt;
Since Visual Studio does not work with autotools, you have to use the CMake build system if you want to compile xoreos with Visual Studio. If you&#039;re using [http://www.mingw.org/ MinGW], however, you&#039;re free to choose either build system.&lt;br /&gt;
&lt;br /&gt;
On Windows, it is recommended that instead of Visual Studio, you use [https://msys2.github.io/ MSYS2] together with [https://mingw-w64.org/ Mingw-w64] (which can produce both 32-bit and 64-bit binaries). MSYS2 provides a package manager, with which you can install xoreos&#039; library dependencies very easily.&lt;br /&gt;
&lt;br /&gt;
You can install the 32-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-i686-toolchain mingw-w64-i686-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can install the 64-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-x86_64-toolchain mingw-w64-x86_64-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Libraries==&lt;br /&gt;
&lt;br /&gt;
xoreos-tools uses the following libraries to function:&lt;br /&gt;
&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Iconv iconv]&lt;br /&gt;
* [http://www.zlib.net/ zlib] (&amp;gt;= 1.2.3.4)&lt;br /&gt;
* [http://tukaani.org/xz/ liblzma] (&amp;gt;= 5.0.5)&lt;br /&gt;
* [http://www.xmlsoft.org/ libxml2] (&amp;gt;= 2.8.0)&lt;br /&gt;
* [http://www.boost.org/ Boost] (&amp;gt;= 1.53.0)&lt;br /&gt;
** Boost.Utility&lt;br /&gt;
** Boost.StringAlgo&lt;br /&gt;
** Boost.System&lt;br /&gt;
** Boost.Filesystem&lt;br /&gt;
** Boost.Uuid&lt;br /&gt;
** Boost.Smart_Ptr&lt;br /&gt;
** Boost.ScopeExit&lt;br /&gt;
** Boost.Locale&lt;br /&gt;
&lt;br /&gt;
On Debian-based GNU/Linux distribution (including Ubuntu), you should be able to install these libraries and their development packages with&lt;br /&gt;
&lt;br /&gt;
 apt-get install zlib1g-dev liblzma-dev libxml2-dev libboost-all-dev&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install these dependencies with&lt;br /&gt;
&lt;br /&gt;
 sudo pacman -S zlib xz libxml2 boost boost-libs&lt;br /&gt;
&lt;br /&gt;
Other GNU/Linux distributions should work similarily.&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 32-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-i686-zlib mingw-w64-i686-xz mingw-w64-i686-libxml2 mingw-w64-i686-boost&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 64-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-x86_64-zlib mingw-w64-x86_64-xz mingw-w64-x86_64-libxml2 mingw-w64-x86_64-boost&lt;br /&gt;
&lt;br /&gt;
Windows users not using MSYS2 will have to visit each website manually and download a precompiled version, or, if not available, download the source and compile the library themselves.&lt;br /&gt;
&lt;br /&gt;
==Compiling xoreos-tools==&lt;br /&gt;
&lt;br /&gt;
Make sure you have your compiler, build system and libraries installed correctly. Then open a terminal and change into the directory of your sources.&lt;br /&gt;
&lt;br /&gt;
===autotools===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;./autogen.sh &amp;amp;&amp;amp; ./configure &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binaries can then be found in the src subdirectory.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional ./configure flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* --with-werror &amp;amp;nbsp;&lt;br /&gt;
|| Compile with -Werror&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --without-warnings &amp;amp;nbsp;&lt;br /&gt;
|| Compile without the extra warnings enabled&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --with-lto &amp;amp;nbsp;&lt;br /&gt;
|| Compile with link-time optimization&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===CMake ===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;cmake . &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binaries can then be found in the bin subdirectory.&lt;br /&gt;
&lt;br /&gt;
Please read [http://www.cmake.org/runningcmake/ Running CMake] on the CMake website for in-depth information on invoking CMake.&lt;br /&gt;
&lt;br /&gt;
==Unit tests==&lt;br /&gt;
&lt;br /&gt;
On both build systems,&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;make check&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
compiles and runs our unit tests.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Compiling_xoreos&amp;diff=454</id>
		<title>Compiling xoreos</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Compiling_xoreos&amp;diff=454"/>
		<updated>2020-05-18T10:41:30Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* Libraries */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page gives a few tips and pointers on how to compile xoreos on various platforms.&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
==Compiler and build system==&lt;br /&gt;
&lt;br /&gt;
xoreos is written in C++, so a C++ compiler, like [https://gcc.gnu.org/ GCC] or [http://clang.llvm.org/ clang] is required. xoreos follows the C++11 standard. It has two build systems: [https://en.wikipedia.org/wiki/GNU_build_system Autotools] ([https://www.gnu.org/software/autoconf/ Autoconf], [https://www.gnu.org/software/automake/ Automake] and [https://www.gnu.org/software/libtool/ Libtool]) and [https://en.wikipedia.org/wiki/CMake CMake]. Use whichever you feel more comfortable with.&lt;br /&gt;
&lt;br /&gt;
===GNU/Linux===&lt;br /&gt;
&lt;br /&gt;
On Debian-based distributions (including Ubuntu), you should be able to install the required compiler and build system packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo apt-get install libc6-dev g++ make autoconf automake libtool gettext cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install the necessary packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo pacman -S base-devel cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On other distributions, it should work similarily.&lt;br /&gt;
&lt;br /&gt;
===Mac OS X===&lt;br /&gt;
&lt;br /&gt;
Due to the dependency on SDL2 (see below), you need at least Mac OS X 10.5 if you use a precompiled SDL2 library, and at least Mac OS X 10.7 if you&#039;re compiling SDL2 yourself.&lt;br /&gt;
&lt;br /&gt;
===Windows===&lt;br /&gt;
&lt;br /&gt;
Since Visual Studio does not work with autotools, you have to use the CMake build system if you want to compile xoreos with Visual Studio. If you&#039;re using [http://www.mingw.org/ MinGW], however, you&#039;re free to choose either build system.&lt;br /&gt;
&lt;br /&gt;
On Windows, it is recommended that instead of Visual Studio, you use [https://msys2.github.io/ MSYS2] together with [https://mingw-w64.org/ Mingw-w64] (which can produce both 32-bit and 64-bit binaries). MSYS2 provides a package manager, with which you can install xoreos&#039; library dependencies very easily.&lt;br /&gt;
&lt;br /&gt;
You can install the 32-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-i686-toolchain mingw-w64-i686-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can install the 64-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-x86_64-toolchain mingw-w64-x86_64-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Libraries==&lt;br /&gt;
&lt;br /&gt;
xoreos uses the following libraries to function:&lt;br /&gt;
&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Iconv iconv]&lt;br /&gt;
* [http://www.zlib.net/ zlib] (&amp;gt;= 1.2.3.4)&lt;br /&gt;
* [http://tukaani.org/xz/ liblzma] (&amp;gt;= 5.0.5)&lt;br /&gt;
* [http://www.xmlsoft.org/ libxml2] (&amp;gt;= 2.8.0)&lt;br /&gt;
* [http://www.boost.org/ Boost] (&amp;gt;= 1.53.0)&lt;br /&gt;
** Boost.Utility&lt;br /&gt;
** Boost.StringAlgo&lt;br /&gt;
** Boost.System&lt;br /&gt;
** Boost.Filesystem&lt;br /&gt;
** Boost.Date_Time&lt;br /&gt;
** Boost.Uuid&lt;br /&gt;
** Boost.Smart_Ptr&lt;br /&gt;
** Boost.ScopeExit&lt;br /&gt;
** Boost.Locale&lt;br /&gt;
* [https://en.wikipedia.org/wiki/OpenGL OpenGL] (&amp;gt;= 2.1)&lt;br /&gt;
* [https://www.libsdl.org/ SDL2] (&amp;gt;= 2.0.0)&lt;br /&gt;
* [http://www.freetype.org/ FreeType 2] (&amp;gt;= 2.4.0 (libtool number &amp;gt;= 11.0.5))&lt;br /&gt;
* [https://en.wikipedia.org/wiki/OpenAL OpenAL] (&amp;gt;= 1.12) (&#039;&#039;&#039;See below&#039;&#039;&#039;)&lt;br /&gt;
* [http://www.underbit.com/products/mad/ MAD] (&amp;gt;= 0.15.1b)&lt;br /&gt;
* [https://www.xiph.org/downloads/ libogg] (&amp;gt;= 1.2.0)&lt;br /&gt;
* [https://www.xiph.org/downloads/ libvorbis] (&amp;gt;= 1.3.1)&lt;br /&gt;
* [http://www.audiocoding.com/faad2.html libfaad] (&amp;gt;= 2.7)&lt;br /&gt;
* [https://www.xvid.org/ libxvidcore] (&amp;gt;= 1.2.2)&lt;br /&gt;
* [https://www.webmproject.org/code/ libvpx] (&amp;gt;= 1.6.0)&lt;br /&gt;
&lt;br /&gt;
On Debian-based GNU/Linux distribution (including Ubuntu), you should be able to install these libraries and their development packages with&lt;br /&gt;
&lt;br /&gt;
 sudo apt-get install zlib1g-dev liblzma-dev libxml2-dev libboost-all-dev libsdl2-dev \&lt;br /&gt;
     libfreetype6-dev libopenal-dev libmad0-dev libogg-dev libvorbis-dev libfaad-dev \&lt;br /&gt;
     libxvidcore-dev libvpx-dev&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install these dependencies with&lt;br /&gt;
&lt;br /&gt;
 sudo pacman -S zlib xz libxml2 boost boost-libs sdl2 freetype2 openal libmad libogg \&lt;br /&gt;
     libvorbis faad2 xvidcore libvpx&lt;br /&gt;
&lt;br /&gt;
Other GNU/Linux distributions should work similarily.&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 32-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-i686-zlib mingw-w64-i686-xz mingw-w64-i686-libxml2 \&lt;br /&gt;
     mingw-w64-i686-boost mingw-w64-i686-SDL2 mingw-w64-i686-freetype \&lt;br /&gt;
     mingw-w64-i686-openal mingw-w64-i686-libmad mingw-w64-i686-libogg \&lt;br /&gt;
     mingw-w64-i686-libvorbis  mingw-w64-i686-faad2 mingw-w64-i686-xvidcore \&lt;br /&gt;
     mingw-w64-i686-libvpx&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 64-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-x86_64-zlib mingw-w64-x86_64-xz mingw-w64-x86_64-libxml2 \&lt;br /&gt;
     mingw-w64-x86_64-boost mingw-w64-x86_64-SDL2 mingw-w64-x86_64-freetype \&lt;br /&gt;
     mingw-w64-x86_64-openal mingw-w64-x86_64-libmad mingw-w64-x86_64-libogg \&lt;br /&gt;
     mingw-w64-x86_64-libvorbis  mingw-w64-x86_64-faad2 mingw-w64-x86_64-xvidcore \&lt;br /&gt;
     mingw-w64-x86_64-libvpx&lt;br /&gt;
&lt;br /&gt;
Windows users not using MSYS2 will have to visit each website manually and download a precompiled version, or, if not available, download the source and compile the library themselves. Alternatively, vcpkg can be used to install most of these libraries.&lt;br /&gt;
&lt;br /&gt;
=== A note on OpenAL ===&lt;br /&gt;
&lt;br /&gt;
On Mac OS X, we&#039;re using Apple&#039;s OpenAL implementation, so OpenAL does not need to be installed separately there.&lt;br /&gt;
&lt;br /&gt;
On both GNU/Linux and Microsoft Windows, we require [http://kcat.strangesoft.net/openal.html OpenAL Soft]. There is a propriety OpenAL implementation by Creative Labs, Inc. for Microsoft Windows, which can be found at [http://openal.org/ http://openal.org/], but it&#039;s unfortunately old, outdated and abandoned. We do not recommend its use.&lt;br /&gt;
&lt;br /&gt;
Likewise, on NetBSD and other systems using pkgsrc, you should use [http://pkgsrc.se/audio/openal-soft openal-soft] instead of [http://pkgsrc.se/audio/openal openal].&lt;br /&gt;
&lt;br /&gt;
==Compiling xoreos==&lt;br /&gt;
&lt;br /&gt;
Make sure you have your compiler, build system and libraries installed correctly. Then open a terminal and change into the directory of your sources.&lt;br /&gt;
&lt;br /&gt;
===autotools===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;./autogen.sh &amp;amp;&amp;amp; ./configure &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binary can be found in the src subdirectory, called &amp;quot;xoreos&amp;quot; or, on Windows, &amp;quot;xoreos.exe&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional ./configure flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* --with-werror &amp;amp;nbsp;&lt;br /&gt;
|| Compile with -Werror&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --without-warnings &amp;amp;nbsp;&lt;br /&gt;
|| Compile without the extra warnings enabled&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --with-lto &amp;amp;nbsp;&lt;br /&gt;
|| Compile with link-time optimization&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --disable-external-glew &amp;amp;nbsp;&lt;br /&gt;
|| Always compile against the internal GLEW libraries&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
===CMake ===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;cmake . &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binary can be found in the bin subdirectory, called &amp;quot;xoreos&amp;quot; or, on Windows, &amp;quot;xoreos.exe&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Please read [http://www.cmake.org/runningcmake/ Running CMake] on the CMake website for in-depth information on invoking CMake.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional cmake flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* -DBoost_USE_STATIC_LIBS=on &amp;amp;nbsp;&lt;br /&gt;
|| Link Boost statically instead of dynamically&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* -DGLEW_INTERNAL=on &amp;amp;nbsp;&lt;br /&gt;
|| Always use internal GLEW library&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note&#039;&#039;&#039;: The CMake&#039;s stock FindBoost.cmake doesn&#039;t correctly detect dependencies when linking statically. In this case, xoreos might fail to link, missing symbols for ICU, when linking Boost statically.&lt;br /&gt;
&lt;br /&gt;
Moreover, if you&#039;re running GNU/Linux and have wrapper scripts installed that force the building of &amp;quot;hardened&amp;quot; binaries (often called &amp;quot;hardening-wrapper&amp;quot;, but differs between Linux distributions), compiling xoreos might fail during the linking stage, when using statically linking Boost libraries. This is due to those static Boost libraries being incompatible with the compiler option &amp;quot;-fPIE&amp;quot;, which is often added by hardening wrapper scripts. A workaround is to disable -fPIE for this compilation (which is distribution-specific).&lt;br /&gt;
&lt;br /&gt;
==Unit tests==&lt;br /&gt;
&lt;br /&gt;
On both build systems,&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;make check&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
compiles and runs our unit tests.&lt;br /&gt;
&lt;br /&gt;
==Running xoreos==&lt;br /&gt;
&lt;br /&gt;
Please have a look at the [[Running xoreos]] page.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Compiling_xoreos-tools&amp;diff=453</id>
		<title>Compiling xoreos-tools</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Compiling_xoreos-tools&amp;diff=453"/>
		<updated>2020-05-17T17:42:29Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* Libraries */ Update&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page gives a few tips and pointers on how to compile xoreos-tools on various platforms.&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
==Compiler and build system==&lt;br /&gt;
&lt;br /&gt;
xoreos-tools is written in C++, so a C++ compiler, like [https://gcc.gnu.org/ GCC] or [http://clang.llvm.org/ clang] is required. xoreos-tools follows the C++11 standard. It has two build systems: [https://en.wikipedia.org/wiki/GNU_build_system Autotools] ([https://www.gnu.org/software/autoconf/ Autoconf], [https://www.gnu.org/software/automake/ Automake] and [https://www.gnu.org/software/libtool/ Libtool]) and [https://en.wikipedia.org/wiki/CMake CMake]. Use whichever you feel more comfortable with.&lt;br /&gt;
&lt;br /&gt;
===GNU/Linux===&lt;br /&gt;
&lt;br /&gt;
On Debian-based distributions (including Ubuntu), you should be able to install the required compiler and build system packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;apt-get install libc6-dev g++ make autoconf automake libtool gettext&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install the necessary packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo pacman -S base-devel cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On other distributions, it should work similarily.&lt;br /&gt;
&lt;br /&gt;
===Windows===&lt;br /&gt;
&lt;br /&gt;
Since Visual Studio does not work with autotools, you have to use the CMake build system if you want to compile xoreos with Visual Studio. If you&#039;re using [http://www.mingw.org/ MinGW], however, you&#039;re free to choose either build system.&lt;br /&gt;
&lt;br /&gt;
On Windows, it is recommended that instead of Visual Studio, you use [https://msys2.github.io/ MSYS2] together with [https://mingw-w64.org/ Mingw-w64] (which can produce both 32-bit and 64-bit binaries). MSYS2 provides a package manager, with which you can install xoreos&#039; library dependencies very easily.&lt;br /&gt;
&lt;br /&gt;
You can install the 32-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-i686-toolchain mingw-w64-i686-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can install the 64-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-x86_64-toolchain mingw-w64-x86_64-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Libraries==&lt;br /&gt;
&lt;br /&gt;
xoreos-tools uses the following libraries to function:&lt;br /&gt;
&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Iconv iconv]&lt;br /&gt;
* [http://www.zlib.net/ zlib] (&amp;gt;= 1.2.3.4)&lt;br /&gt;
* [http://tukaani.org/xz/ liblzma] (&amp;gt;= 5.0.5)&lt;br /&gt;
* [http://www.xmlsoft.org/ libxml2] (&amp;gt;= 2.8.0)&lt;br /&gt;
* [http://www.boost.org/ Boost] (&amp;gt;= 1.53.0)&lt;br /&gt;
** Boost.Utility&lt;br /&gt;
** Boost.StringAlgo&lt;br /&gt;
** Boost.System&lt;br /&gt;
** Boost.Filesystem&lt;br /&gt;
** Boost.Hash&lt;br /&gt;
** Boost.Function&lt;br /&gt;
** Boost.Uuid&lt;br /&gt;
** Boost.Smart_Ptr&lt;br /&gt;
** Boost.ScopeExit&lt;br /&gt;
** Boost.Locale&lt;br /&gt;
&lt;br /&gt;
On Debian-based GNU/Linux distribution (including Ubuntu), you should be able to install these libraries and their development packages with&lt;br /&gt;
&lt;br /&gt;
 apt-get install zlib1g-dev liblzma-dev libxml2-dev libboost-all-dev&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install these dependencies with&lt;br /&gt;
&lt;br /&gt;
 sudo pacman -S zlib xz libxml2 boost boost-libs&lt;br /&gt;
&lt;br /&gt;
Other GNU/Linux distributions should work similarily.&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 32-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-i686-zlib mingw-w64-i686-xz mingw-w64-i686-libxml2 mingw-w64-i686-boost&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 64-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-x86_64-zlib mingw-w64-x86_64-xz mingw-w64-x86_64-libxml2 mingw-w64-x86_64-boost&lt;br /&gt;
&lt;br /&gt;
Windows users not using MSYS2 will have to visit each website manually and download a precompiled version, or, if not available, download the source and compile the library themselves.&lt;br /&gt;
&lt;br /&gt;
==Compiling xoreos-tools==&lt;br /&gt;
&lt;br /&gt;
Make sure you have your compiler, build system and libraries installed correctly. Then open a terminal and change into the directory of your sources.&lt;br /&gt;
&lt;br /&gt;
===autotools===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;./autogen.sh &amp;amp;&amp;amp; ./configure &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binaries can then be found in the src subdirectory.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional ./configure flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* --with-werror &amp;amp;nbsp;&lt;br /&gt;
|| Compile with -Werror&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --without-warnings &amp;amp;nbsp;&lt;br /&gt;
|| Compile without the extra warnings enabled&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --with-lto &amp;amp;nbsp;&lt;br /&gt;
|| Compile with link-time optimization&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===CMake ===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;cmake . &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binaries can then be found in the bin subdirectory.&lt;br /&gt;
&lt;br /&gt;
Please read [http://www.cmake.org/runningcmake/ Running CMake] on the CMake website for in-depth information on invoking CMake.&lt;br /&gt;
&lt;br /&gt;
==Unit tests==&lt;br /&gt;
&lt;br /&gt;
On both build systems,&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;make check&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
compiles and runs our unit tests.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Compiling_Phaethon&amp;diff=452</id>
		<title>Compiling Phaethon</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Compiling_Phaethon&amp;diff=452"/>
		<updated>2020-05-17T17:38:05Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* Libraries */ Update&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page gives a few tips and pointers on how to compile Phaethon on various platforms.&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
==Compiler and build system==&lt;br /&gt;
&lt;br /&gt;
Phaethon is written in C++, so a C++ compiler, like [https://gcc.gnu.org/ GCC] or [http://clang.llvm.org/ clang] is required. Phaethon follows the C++14 standard. It has two build systems: [https://en.wikipedia.org/wiki/GNU_build_system Autotools] ([https://www.gnu.org/software/autoconf/ Autoconf], [https://www.gnu.org/software/automake/ Automake] and [https://www.gnu.org/software/libtool/ Libtool]) and [https://en.wikipedia.org/wiki/CMake CMake]. Use whichever you feel more comfortable with.&lt;br /&gt;
&lt;br /&gt;
===GNU/Linux===&lt;br /&gt;
&lt;br /&gt;
On Debian-based distributions (including Ubuntu), you should be able to install the required compiler and build system packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;apt-get install libc6-dev g++ make autoconf automake libtool gettext&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install the necessary packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo pacman -S base-devel cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On other distributions, it should work similarily.&lt;br /&gt;
&lt;br /&gt;
===Windows===&lt;br /&gt;
&lt;br /&gt;
Since Visual Studio does not work with autotools, you have to use the CMake build system if you want to compile xoreos with Visual Studio. If you&#039;re using [http://www.mingw.org/ MinGW], however, you&#039;re free to choose either build system.&lt;br /&gt;
&lt;br /&gt;
On Windows, it is recommended that instead of Visual Studio, you use [https://msys2.github.io/ MSYS2] together with [https://mingw-w64.org/ Mingw-w64] (which can produce both 32-bit and 64-bit binaries). MSYS2 provides a package manager, with which you can install xoreos&#039; library dependencies very easily.&lt;br /&gt;
&lt;br /&gt;
You can install the 32-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-i686-toolchain mingw-w64-i686-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can install the 64-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-x86_64-toolchain mingw-w64-x86_64-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Libraries==&lt;br /&gt;
&lt;br /&gt;
Phaethon uses the following libraries to function:&lt;br /&gt;
&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Iconv iconv]&lt;br /&gt;
* [http://www.zlib.net/ zlib] (&amp;gt;= 1.2.3.4)&lt;br /&gt;
* [http://tukaani.org/xz/ liblzma] (&amp;gt;= 5.0.5)&lt;br /&gt;
* [http://www.boost.org/ Boost] (&amp;gt;= 1.53.0)&lt;br /&gt;
** Boost.Utility&lt;br /&gt;
** Boost.StringAlgo&lt;br /&gt;
** Boost.System&lt;br /&gt;
** Boost.Filesystem&lt;br /&gt;
** Boost.Unordered&lt;br /&gt;
** Boost.Hash&lt;br /&gt;
** Boost.Date_Time&lt;br /&gt;
** Boost.Chrono&lt;br /&gt;
** Boost.Function&lt;br /&gt;
** Boost.Uuid&lt;br /&gt;
** Boost.Smart_Ptr&lt;br /&gt;
** Boost.ScopeExit&lt;br /&gt;
** Boost.Locale&lt;br /&gt;
* [https://www.qt.io/ Qt] (&amp;gt;= 5.7.1)&lt;br /&gt;
** Qt5Core&lt;br /&gt;
** Qt5Gui&lt;br /&gt;
** Qt5Widgets&lt;br /&gt;
** Qt5Concurrent&lt;br /&gt;
* [https://en.wikipedia.org/wiki/OpenAL OpenAL] (&amp;gt;= 1.12) (&#039;&#039;&#039;See below&#039;&#039;&#039;)&lt;br /&gt;
* [http://www.underbit.com/products/mad/ MAD] (&amp;gt;= 0.15.1b)&lt;br /&gt;
* [https://www.xiph.org/downloads/ libogg] (&amp;gt;= 1.2.0)&lt;br /&gt;
* [https://www.xiph.org/downloads/ libvorbis] (&amp;gt;= 1.3.1)&lt;br /&gt;
&lt;br /&gt;
On Debian-based GNU/Linux distribution (including Ubuntu), you should be able to install these libraries and their development packages with&lt;br /&gt;
&lt;br /&gt;
 sudo apt-get install zlib1g-dev liblzma-dev libboost-all-dev \&lt;br /&gt;
     libopenal-dev libmad0-dev libogg-dev libvorbis-dev  \&lt;br /&gt;
     qtbase5-dev, libqt5gui5, libqt5widgets5&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install these dependencies with&lt;br /&gt;
&lt;br /&gt;
 sudo pacman -S zlib xz boost boost-libs openal libmad libogg \&lt;br /&gt;
     libvorbis qt5-base&lt;br /&gt;
&lt;br /&gt;
Other GNU/Linux distributions should work similarily.&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 32-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-i686-zlib mingw-w64-i686-xz \&lt;br /&gt;
     mingw-w64-i686-boost mingw-w64-i686-openal mingw-w64-i686-libmad \&lt;br /&gt;
     mingw-w64-i686-libogg mingw-w64-i686-libvorbis mingw-w64-i686-qt-creator&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 64-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-x86_64-zlib mingw-w64-x86_64-xz \&lt;br /&gt;
     mingw-w64-x86_64-boost mingw-w64-x86_64-openal mingw-w64-x86_64-libmad \&lt;br /&gt;
     mingw-w64-x86_64-libogg mingw-w64-x86_64-libvorbis mingw-w64-x86_64-qt-creator&lt;br /&gt;
&lt;br /&gt;
Windows users not using MSYS2 will have to visit each website manually and download a precompiled version, or, if not available, download the source and compile the library themselves.&lt;br /&gt;
&lt;br /&gt;
=== A note on OpenAL ===&lt;br /&gt;
&lt;br /&gt;
On Mac OS X, we&#039;re using Apple&#039;s OpenAL implementation, so OpenAL does not need to be installed separately there.&lt;br /&gt;
&lt;br /&gt;
On both GNU/Linux and Microsoft Windows, we require [http://kcat.strangesoft.net/openal.html OpenAL Soft]. There is a propriety OpenAL implementation by Creative Labs, Inc. for Microsoft Windows, which can be found at [http://openal.org/ http://openal.org/], but it&#039;s unfortunately old, outdated and abandoned. We do not recommend its use.&lt;br /&gt;
&lt;br /&gt;
Likewise, on NetBSD and other systems using pkgsrc, you should use [http://pkgsrc.se/audio/openal-soft openal-soft] instead of [http://pkgsrc.se/audio/openal openal].&lt;br /&gt;
&lt;br /&gt;
==Compiling Phaethon==&lt;br /&gt;
&lt;br /&gt;
Make sure you have your compiler, build system and libraries installed correctly. Then open a terminal and change into the directory of your sources.&lt;br /&gt;
&lt;br /&gt;
===autotools===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;./autogen.sh &amp;amp;&amp;amp; ./configure &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binaries can then be found in the src subdirectory.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional ./configure flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* --with-werror &amp;amp;nbsp;&lt;br /&gt;
|| Compile with -Werror&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --without-warnings &amp;amp;nbsp;&lt;br /&gt;
|| Compile without the extra warnings enabled&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --with-lto &amp;amp;nbsp;&lt;br /&gt;
|| Compile with link-time optimization&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===CMake ===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;cmake . &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binaries can then be found in the bin subdirectory.&lt;br /&gt;
&lt;br /&gt;
Please read [http://www.cmake.org/runningcmake/ Running CMake] on the CMake website for in-depth information on invoking CMake.&lt;br /&gt;
&lt;br /&gt;
==Unit tests==&lt;br /&gt;
&lt;br /&gt;
On both build systems,&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;make check&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
compiles and runs our unit tests.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Compiling_xoreos&amp;diff=451</id>
		<title>Compiling xoreos</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Compiling_xoreos&amp;diff=451"/>
		<updated>2020-05-17T17:18:42Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* Libraries */ Update Boost dependencies&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page gives a few tips and pointers on how to compile xoreos on various platforms.&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
==Compiler and build system==&lt;br /&gt;
&lt;br /&gt;
xoreos is written in C++, so a C++ compiler, like [https://gcc.gnu.org/ GCC] or [http://clang.llvm.org/ clang] is required. xoreos follows the C++11 standard. It has two build systems: [https://en.wikipedia.org/wiki/GNU_build_system Autotools] ([https://www.gnu.org/software/autoconf/ Autoconf], [https://www.gnu.org/software/automake/ Automake] and [https://www.gnu.org/software/libtool/ Libtool]) and [https://en.wikipedia.org/wiki/CMake CMake]. Use whichever you feel more comfortable with.&lt;br /&gt;
&lt;br /&gt;
===GNU/Linux===&lt;br /&gt;
&lt;br /&gt;
On Debian-based distributions (including Ubuntu), you should be able to install the required compiler and build system packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo apt-get install libc6-dev g++ make autoconf automake libtool gettext cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install the necessary packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo pacman -S base-devel cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On other distributions, it should work similarily.&lt;br /&gt;
&lt;br /&gt;
===Mac OS X===&lt;br /&gt;
&lt;br /&gt;
Due to the dependency on SDL2 (see below), you need at least Mac OS X 10.5 if you use a precompiled SDL2 library, and at least Mac OS X 10.7 if you&#039;re compiling SDL2 yourself.&lt;br /&gt;
&lt;br /&gt;
===Windows===&lt;br /&gt;
&lt;br /&gt;
Since Visual Studio does not work with autotools, you have to use the CMake build system if you want to compile xoreos with Visual Studio. If you&#039;re using [http://www.mingw.org/ MinGW], however, you&#039;re free to choose either build system.&lt;br /&gt;
&lt;br /&gt;
On Windows, it is recommended that instead of Visual Studio, you use [https://msys2.github.io/ MSYS2] together with [https://mingw-w64.org/ Mingw-w64] (which can produce both 32-bit and 64-bit binaries). MSYS2 provides a package manager, with which you can install xoreos&#039; library dependencies very easily.&lt;br /&gt;
&lt;br /&gt;
You can install the 32-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-i686-toolchain mingw-w64-i686-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can install the 64-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-x86_64-toolchain mingw-w64-x86_64-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Libraries==&lt;br /&gt;
&lt;br /&gt;
xoreos uses the following libraries to function:&lt;br /&gt;
&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Iconv iconv]&lt;br /&gt;
* [http://www.zlib.net/ zlib] (&amp;gt;= 1.2.3.4)&lt;br /&gt;
* [http://tukaani.org/xz/ liblzma] (&amp;gt;= 5.0.5)&lt;br /&gt;
* [http://www.xmlsoft.org/ libxml2] (&amp;gt;= 2.8.0)&lt;br /&gt;
* [http://www.boost.org/ Boost] (&amp;gt;= 1.53.0)&lt;br /&gt;
** Boost.Utility&lt;br /&gt;
** Boost.StringAlgo&lt;br /&gt;
** Boost.System&lt;br /&gt;
** Boost.Filesystem&lt;br /&gt;
** Boost.Unordered&lt;br /&gt;
** Boost.Hash&lt;br /&gt;
** Boost.Date_Time&lt;br /&gt;
** Boost.Function&lt;br /&gt;
** Boost.Uuid&lt;br /&gt;
** Boost.Smart_Ptr&lt;br /&gt;
** Boost.ScopeExit&lt;br /&gt;
** Boost.Locale&lt;br /&gt;
* [https://en.wikipedia.org/wiki/OpenGL OpenGL] (&amp;gt;= 2.1)&lt;br /&gt;
* [https://www.libsdl.org/ SDL2] (&amp;gt;= 2.0.0)&lt;br /&gt;
* [http://www.freetype.org/ FreeType 2] (&amp;gt;= 2.4.0 (libtool number &amp;gt;= 11.0.5))&lt;br /&gt;
* [https://en.wikipedia.org/wiki/OpenAL OpenAL] (&amp;gt;= 1.12) (&#039;&#039;&#039;See below&#039;&#039;&#039;)&lt;br /&gt;
* [http://www.underbit.com/products/mad/ MAD] (&amp;gt;= 0.15.1b)&lt;br /&gt;
* [https://www.xiph.org/downloads/ libogg] (&amp;gt;= 1.2.0)&lt;br /&gt;
* [https://www.xiph.org/downloads/ libvorbis] (&amp;gt;= 1.3.1)&lt;br /&gt;
* [http://www.audiocoding.com/faad2.html libfaad] (&amp;gt;= 2.7)&lt;br /&gt;
* [https://www.xvid.org/ libxvidcore] (&amp;gt;= 1.2.2)&lt;br /&gt;
* [https://www.webmproject.org/code/ libvpx] (&amp;gt;= 1.6.0)&lt;br /&gt;
&lt;br /&gt;
On Debian-based GNU/Linux distribution (including Ubuntu), you should be able to install these libraries and their development packages with&lt;br /&gt;
&lt;br /&gt;
 sudo apt-get install zlib1g-dev liblzma-dev libxml2-dev libboost-all-dev libsdl2-dev \&lt;br /&gt;
     libfreetype6-dev libopenal-dev libmad0-dev libogg-dev libvorbis-dev libfaad-dev \&lt;br /&gt;
     libxvidcore-dev libvpx-dev&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install these dependencies with&lt;br /&gt;
&lt;br /&gt;
 sudo pacman -S zlib xz libxml2 boost boost-libs sdl2 freetype2 openal libmad libogg \&lt;br /&gt;
     libvorbis faad2 xvidcore libvpx&lt;br /&gt;
&lt;br /&gt;
Other GNU/Linux distributions should work similarily.&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 32-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-i686-zlib mingw-w64-i686-xz mingw-w64-i686-libxml2 \&lt;br /&gt;
     mingw-w64-i686-boost mingw-w64-i686-SDL2 mingw-w64-i686-freetype \&lt;br /&gt;
     mingw-w64-i686-openal mingw-w64-i686-libmad mingw-w64-i686-libogg \&lt;br /&gt;
     mingw-w64-i686-libvorbis  mingw-w64-i686-faad2 mingw-w64-i686-xvidcore \&lt;br /&gt;
     mingw-w64-i686-libvpx&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 64-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-x86_64-zlib mingw-w64-x86_64-xz mingw-w64-x86_64-libxml2 \&lt;br /&gt;
     mingw-w64-x86_64-boost mingw-w64-x86_64-SDL2 mingw-w64-x86_64-freetype \&lt;br /&gt;
     mingw-w64-x86_64-openal mingw-w64-x86_64-libmad mingw-w64-x86_64-libogg \&lt;br /&gt;
     mingw-w64-x86_64-libvorbis  mingw-w64-x86_64-faad2 mingw-w64-x86_64-xvidcore \&lt;br /&gt;
     mingw-w64-x86_64-libvpx&lt;br /&gt;
&lt;br /&gt;
Windows users not using MSYS2 will have to visit each website manually and download a precompiled version, or, if not available, download the source and compile the library themselves. Alternatively, vcpkg can be used to install most of these libraries.&lt;br /&gt;
&lt;br /&gt;
=== A note on OpenAL ===&lt;br /&gt;
&lt;br /&gt;
On Mac OS X, we&#039;re using Apple&#039;s OpenAL implementation, so OpenAL does not need to be installed separately there.&lt;br /&gt;
&lt;br /&gt;
On both GNU/Linux and Microsoft Windows, we require [http://kcat.strangesoft.net/openal.html OpenAL Soft]. There is a propriety OpenAL implementation by Creative Labs, Inc. for Microsoft Windows, which can be found at [http://openal.org/ http://openal.org/], but it&#039;s unfortunately old, outdated and abandoned. We do not recommend its use.&lt;br /&gt;
&lt;br /&gt;
Likewise, on NetBSD and other systems using pkgsrc, you should use [http://pkgsrc.se/audio/openal-soft openal-soft] instead of [http://pkgsrc.se/audio/openal openal].&lt;br /&gt;
&lt;br /&gt;
==Compiling xoreos==&lt;br /&gt;
&lt;br /&gt;
Make sure you have your compiler, build system and libraries installed correctly. Then open a terminal and change into the directory of your sources.&lt;br /&gt;
&lt;br /&gt;
===autotools===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;./autogen.sh &amp;amp;&amp;amp; ./configure &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binary can be found in the src subdirectory, called &amp;quot;xoreos&amp;quot; or, on Windows, &amp;quot;xoreos.exe&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional ./configure flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* --with-werror &amp;amp;nbsp;&lt;br /&gt;
|| Compile with -Werror&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --without-warnings &amp;amp;nbsp;&lt;br /&gt;
|| Compile without the extra warnings enabled&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --with-lto &amp;amp;nbsp;&lt;br /&gt;
|| Compile with link-time optimization&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --disable-external-glew &amp;amp;nbsp;&lt;br /&gt;
|| Always compile against the internal GLEW libraries&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
===CMake ===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;cmake . &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binary can be found in the bin subdirectory, called &amp;quot;xoreos&amp;quot; or, on Windows, &amp;quot;xoreos.exe&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Please read [http://www.cmake.org/runningcmake/ Running CMake] on the CMake website for in-depth information on invoking CMake.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional cmake flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* -DBoost_USE_STATIC_LIBS=on &amp;amp;nbsp;&lt;br /&gt;
|| Link Boost statically instead of dynamically&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* -DGLEW_INTERNAL=on &amp;amp;nbsp;&lt;br /&gt;
|| Always use internal GLEW library&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note&#039;&#039;&#039;: The CMake&#039;s stock FindBoost.cmake doesn&#039;t correctly detect dependencies when linking statically. In this case, xoreos might fail to link, missing symbols for ICU, when linking Boost statically.&lt;br /&gt;
&lt;br /&gt;
Moreover, if you&#039;re running GNU/Linux and have wrapper scripts installed that force the building of &amp;quot;hardened&amp;quot; binaries (often called &amp;quot;hardening-wrapper&amp;quot;, but differs between Linux distributions), compiling xoreos might fail during the linking stage, when using statically linking Boost libraries. This is due to those static Boost libraries being incompatible with the compiler option &amp;quot;-fPIE&amp;quot;, which is often added by hardening wrapper scripts. A workaround is to disable -fPIE for this compilation (which is distribution-specific).&lt;br /&gt;
&lt;br /&gt;
==Unit tests==&lt;br /&gt;
&lt;br /&gt;
On both build systems,&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;make check&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
compiles and runs our unit tests.&lt;br /&gt;
&lt;br /&gt;
==Running xoreos==&lt;br /&gt;
&lt;br /&gt;
Please have a look at the [[Running xoreos]] page.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Compiling_xoreos-tools&amp;diff=442</id>
		<title>Compiling xoreos-tools</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Compiling_xoreos-tools&amp;diff=442"/>
		<updated>2019-02-10T14:20:10Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: Fix typo&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page gives a few tips and pointers on how to compile xoreos-tools on various platforms.&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
==Compiler and build system==&lt;br /&gt;
&lt;br /&gt;
xoreos-tools is written in C++, so a C++ compiler, like [https://gcc.gnu.org/ GCC] or [http://clang.llvm.org/ clang] is required. xoreos-tools follows the C++11 standard. It has two build systems: [https://en.wikipedia.org/wiki/GNU_build_system Autotools] ([https://www.gnu.org/software/autoconf/ Autoconf], [https://www.gnu.org/software/automake/ Automake] and [https://www.gnu.org/software/libtool/ Libtool]) and [https://en.wikipedia.org/wiki/CMake CMake]. Use whichever you feel more comfortable with.&lt;br /&gt;
&lt;br /&gt;
===GNU/Linux===&lt;br /&gt;
&lt;br /&gt;
On Debian-based distributions (including Ubuntu), you should be able to install the required compiler and build system packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;apt-get install libc6-dev g++ make autoconf automake libtool gettext&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install the necessary packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo pacman -S base-devel cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On other distributions, it should work similarily.&lt;br /&gt;
&lt;br /&gt;
===Windows===&lt;br /&gt;
&lt;br /&gt;
Since Visual Studio does not work with autotools, you have to use the CMake build system if you want to compile xoreos with Visual Studio. If you&#039;re using [http://www.mingw.org/ MinGW], however, you&#039;re free to choose either build system.&lt;br /&gt;
&lt;br /&gt;
On Windows, it is recommended that instead of Visual Studio, you use [https://msys2.github.io/ MSYS2] together with [https://mingw-w64.org/ Mingw-w64] (which can produce both 32-bit and 64-bit binaries). MSYS2 provides a package manager, with which you can install xoreos&#039; library dependencies very easily.&lt;br /&gt;
&lt;br /&gt;
You can install the 32-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-i686-toolchain mingw-w64-i686-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can install the 64-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-x86_64-toolchain mingw-w64-x86_64-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Libraries==&lt;br /&gt;
&lt;br /&gt;
xoreos-tools uses the following libraries to function:&lt;br /&gt;
&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Iconv iconv]&lt;br /&gt;
* [http://www.zlib.net/ zlib] (&amp;gt;= 1.2.3.4)&lt;br /&gt;
* [http://www.xmlsoft.org/ libxml2] (&amp;gt;= 2.8.0)&lt;br /&gt;
* [http://www.boost.org/ Boost] (&amp;gt;= 1.53.0)&lt;br /&gt;
** Boost.Utility&lt;br /&gt;
** Boost.StringAlgo&lt;br /&gt;
** Boost.System&lt;br /&gt;
** Boost.Filesystem&lt;br /&gt;
** Boost.Regex&lt;br /&gt;
** Boost.Hash&lt;br /&gt;
** Boost.Function&lt;br /&gt;
** Boost.Bind&lt;br /&gt;
** Boost.Uuid&lt;br /&gt;
** Boost.Smart_Ptr&lt;br /&gt;
** Boost.ScopeExit&lt;br /&gt;
** Boost.Atomic&lt;br /&gt;
** Boost.Locale&lt;br /&gt;
&lt;br /&gt;
On Debian-based GNU/Linux distribution (including Ubuntu), you should be able to install these libraries and their development packages with&lt;br /&gt;
&lt;br /&gt;
 apt-get install zlib1g-dev libxml2-dev libboost-all-dev&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install these dependencies with&lt;br /&gt;
&lt;br /&gt;
 sudo pacman -S zlib libxml2 boost boost-libs&lt;br /&gt;
&lt;br /&gt;
Other GNU/Linux distributions should work similarily.&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 32-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-i686-zlib mingw-w64-i686-libxml2 mingw-w64-i686-boost&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 64-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-x86_64-zlib mingw-w64-x86_64-libxml2 mingw-w64-x86_64-boost&lt;br /&gt;
&lt;br /&gt;
Windows users not using MSYS2 will have to visit each website manually and download a precompiled version, or, if not available, download the source and compile the library themselves.&lt;br /&gt;
&lt;br /&gt;
==Compiling xoreos-tools==&lt;br /&gt;
&lt;br /&gt;
Make sure you have your compiler, build system and libraries installed correctly. Then open a terminal and change into the directory of your sources.&lt;br /&gt;
&lt;br /&gt;
===autotools===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;./autogen.sh &amp;amp;&amp;amp; ./configure &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binaries can then be found in the src subdirectory.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional ./configure flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* --with-werror &amp;amp;nbsp;&lt;br /&gt;
|| Compile with -Werror&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --without-warnings &amp;amp;nbsp;&lt;br /&gt;
|| Compile without the extra warnings enabled&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --with-lto &amp;amp;nbsp;&lt;br /&gt;
|| Compile with link-time optimization&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===CMake ===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;cmake . &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binaries can then be found in the bin subdirectory.&lt;br /&gt;
&lt;br /&gt;
Please read [http://www.cmake.org/runningcmake/ Running CMake] on the CMake website for in-depth information on invoking CMake.&lt;br /&gt;
&lt;br /&gt;
==Unit tests==&lt;br /&gt;
&lt;br /&gt;
On both build systems,&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;make check&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
compiles and runs our unit tests.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Developer_Central&amp;diff=441</id>
		<title>Developer Central</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Developer_Central&amp;diff=441"/>
		<updated>2019-02-10T14:20:09Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: Link the Compiling Phaethon page in Developer Central&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this page is to give a link to all kinds of resources that contain information valuable to current and future developers of xoreos.&lt;br /&gt;
&lt;br /&gt;
== The source repository ==&lt;br /&gt;
&lt;br /&gt;
The main xoreos source repositories are hosted on [https://github.com/xoreos/ GitHub]. Please see the [[Git]] page on details on how the repositories are structured and how to retrieve the code.&lt;br /&gt;
&lt;br /&gt;
== Compilation ==&lt;br /&gt;
&lt;br /&gt;
See the [[Compiling xoreos]], [[Compiling xoreos-tools]] and [[Compiling Phaethon]] pages for information on how to compile our source code on various operating systems.&lt;br /&gt;
&lt;br /&gt;
== Community ==&lt;br /&gt;
&lt;br /&gt;
We strive to be a friendly and open development community. Therefore, we have adopted a [https://github.com/xoreos/xoreos/blob/master/CODE_OF_CONDUCT.md Code of Conduct] guiding us. By participating in this project you agree to abide by its terms.&lt;br /&gt;
&lt;br /&gt;
Our main place for organizing and socializing is the [[IRC channel|#xoreos channel on Freenode IRC]]. You will find most of the developers idling there, happy to answer any questions you might have. If you plan to become a frequent contributor, please consider regularly joining this channel as well.&lt;br /&gt;
&lt;br /&gt;
However, there is not public log bot in #xoreos, so there is no public, permanent record. Therefore, discussions about far reaching changes in the codebase are best held on [[Mailing lists|our mailing list]]. Contributors are encouraged to subscribe to this list.&lt;br /&gt;
&lt;br /&gt;
If you intend to work on a feature, or otherwise contribute to xoreos, please notify us before-hand, so that unnecessary, accidentally doubling of work can be avoided.&lt;br /&gt;
&lt;br /&gt;
== Reporting bugs ==&lt;br /&gt;
&lt;br /&gt;
Bugs should be reported on the GitHub issue tracker. If the bug concerns xoreos itself, use the [https://github.com/xoreos/xoreos/issues one for xoreos], if the bug concerns the xoreos-tools, use the [https://github.com/xoreos/xoreos-tools/issues one for xoreos-tools]. Likewise, all the other [https://github.com/xoreos repositories] have issue tracking enabled.&lt;br /&gt;
&lt;br /&gt;
== Code style ==&lt;br /&gt;
&lt;br /&gt;
We have [[Code Formatting Conventions]] you are expected to follow. Patches and pull requests that do not follow these conventions will be rejected or at least delayed until they are cleaned up to comply.&lt;br /&gt;
&lt;br /&gt;
== Commit guidelines ==&lt;br /&gt;
&lt;br /&gt;
Please read the [[Commit Guidelines]]. We want to keep our project history clean and readable.&lt;br /&gt;
&lt;br /&gt;
== Branches ==&lt;br /&gt;
&lt;br /&gt;
Do not work directly on the master branch. Instead, use [https://www.atlassian.com/git/tutorials/comparing-workflows/feature-branch-workflow feature branches], one for each new feature you are working on. This ensures that each feature has its own, clean history that can be reviewed more easily. Once the feature has been merged into the main development tree, you are of course free to delete your feature branch again.&lt;br /&gt;
&lt;br /&gt;
== Pull Requests ==&lt;br /&gt;
&lt;br /&gt;
If you do not have push permissions to the official xoreos repositories, and especially if you&#039;re a first-time contributor, we prefer to receive your changes as a [https://help.github.com/articles/using-pull-requests pull request on GitHub]. This requires you to have/register a GitHub account, fork our repository, commit your changes to a branch and then issue a Pull Request.&lt;br /&gt;
&lt;br /&gt;
Please only add commits belonging to this one feature to the pull requests; do not intersperse them with unrelated changes. Also try to [https://git-scm.com/book/en/v2/Git-Tools-Rewriting-History actively tidy your history]: combine related commits with interactive rebasing, separate monolithic commits, etc. Feel free to force-push to your feature branch to tidy your history.&lt;br /&gt;
&lt;br /&gt;
Before and during the review process, please keep up to date with the xoreos master branch by [https://git-scm.com/book/en/v2/Git-Branching-Rebasing rebasing] your changes onto the current master.&lt;br /&gt;
&lt;br /&gt;
== Pushing to the official repositories ==&lt;br /&gt;
&lt;br /&gt;
Once we&#039;ve made sure that you understood and can follow the style and commit guidelines and you expressed interest in further contributing to xoreos, we will be happy to have you join the xoreos development team, and grant you push permissions to the official repositories. You are then expected to continue to follow these guidelines out of your own accord, without the need for intervention by other developers. If you are unsure about how a specific case interact with the guidelines, please feel free to ask.&lt;br /&gt;
&lt;br /&gt;
To avoid people accidentally working on the same feature, or otherwise stepping on each others&#039; toes, consider announcement what you are working on in the [[IRC channel]] or the [[Mailing lists|mailing list]].&lt;br /&gt;
&lt;br /&gt;
== Continuous Integration ==&lt;br /&gt;
&lt;br /&gt;
The public xoreos repositories are build by two [https://en.wikipedia.org/wiki/Continuous_integration Continuous Integration] services on every push: [https://travis-ci.org/ Travis CI] (for GNU/Linux, using both the autotools and the CMake build systems and also using both gcc and clang) and [https://www.appveyor.com/ AppVeyor] (for Windows, using Microsoft Visual Studio). If a compilation error occurs, the build failure announced is on our [https://wiki.xoreos.org/index.php?title=IRC_channel IRC channel], so that it may be fixed quickly. Pull Requests are also run through these CI services and we like to have all failures fixed before merging.&lt;br /&gt;
&lt;br /&gt;
== Unit tests ==&lt;br /&gt;
&lt;br /&gt;
The xoreos repositories also provide unit tests for many common classes. These are build and run right after the main binaries on every push, by the CI services we use. A failure in one of these unit tests leads to the build being treated as failed. That way, it&#039;s immediately obvious when we break anything.&lt;br /&gt;
&lt;br /&gt;
All xoreos developers are advised to run these unit tests themselves while writing code that touches the common code. In both of our build systems, &amp;quot;make check&amp;quot; does exactly this.&lt;br /&gt;
&lt;br /&gt;
When writing new common classes, or adding functionality to existing ones, also writing new unit tests checking the new functionality is hugely appreciated.&lt;br /&gt;
&lt;br /&gt;
== Releases ==&lt;br /&gt;
&lt;br /&gt;
A short overview on how xoreos releases work can be found on the [[Releases]] page.&lt;br /&gt;
&lt;br /&gt;
== Reverse engineering help ==&lt;br /&gt;
&lt;br /&gt;
For people starting out with reverse engineering, here are a few useful resources:&lt;br /&gt;
&lt;br /&gt;
* The [http://wiki.scummvm.org/index.php/HOWTO-Reverse_Engineering HOWTO-Reverse Engineering] page in ScummVM&#039;s wiki&lt;br /&gt;
* [http://rewiki.awiki.org/wiki/Main_Page REWiki] contains a collection of game reverse engineering knowledge. They have a [http://rewiki.awiki.org/wiki/Reverse_engineering_hints hints page] as well&lt;br /&gt;
* [http://wiki.xentax.com/index.php?title=Game_File_Format_Central XentaxWiki] focuses on game file formats. They too have a [http://wiki.xentax.com/index.php?title=DGTEFF guide page]&lt;br /&gt;
* For audio and video formats, there&#039;s [http://wiki.multimedia.cx/ MultimediaWiki], which is associated with the ffmpeg and libav projects&lt;br /&gt;
&lt;br /&gt;
== Modding communities ==&lt;br /&gt;
&lt;br /&gt;
A lot of information about the file formats can be gleamed from the modding communities:&lt;br /&gt;
&lt;br /&gt;
* [https://neverwintervault.org/ The Neverwinter Vault] for Neverwinter Nights and Neverwinter Nights 2&lt;br /&gt;
* [http://nwn2.wikia.com/wiki/Main_Page NWN2 wiki] for Neverwinter Nights 2&lt;br /&gt;
* [https://deadlystream.com/ Deadly Stream] for Knights of the Old Republic and Knights of the Old Republic II&lt;br /&gt;
* [http://jadeempire-modding.wikia.com/wiki/Jade_Empire_Modding_Wiki Jade Empire Modding wiki] for Jade Empire&lt;br /&gt;
* The [http://www.datoolset.net/wiki/Main_Page Dragon Age Toolset wiki] for Dragon Age: Origins and Dragon Age II&lt;br /&gt;
* The [http://witcher.wikia.com/wiki/Category:File_Formats Witcher wiki] for The Witcher&lt;br /&gt;
* [http://sonicretro.org/ Sonic Retro] for Sonic Chronicles&lt;br /&gt;
* [https://www.nexusmods.com/ Nexus Mods]&lt;br /&gt;
* [https://nwnlexicon.com/index.php?title=Main_Page NWN Lexicon]&lt;br /&gt;
&lt;br /&gt;
== To do list ==&lt;br /&gt;
&lt;br /&gt;
Our [[TODO|Main TODO list]] contains a rambly, non-exhaustive collection of things left to do.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Compiling_Phaethon&amp;diff=440</id>
		<title>Compiling Phaethon</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Compiling_Phaethon&amp;diff=440"/>
		<updated>2019-02-10T14:20:09Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: Add a page explaining how to compile Phaethon&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page gives a few tips and pointers on how to compile Phaethon on various platforms.&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
==Compiler and build system==&lt;br /&gt;
&lt;br /&gt;
Phaethon is written in C++, so a C++ compiler, like [https://gcc.gnu.org/ GCC] or [http://clang.llvm.org/ clang] is required. Phaethon follows the C++14 standard. It has two build systems: [https://en.wikipedia.org/wiki/GNU_build_system Autotools] ([https://www.gnu.org/software/autoconf/ Autoconf], [https://www.gnu.org/software/automake/ Automake] and [https://www.gnu.org/software/libtool/ Libtool]) and [https://en.wikipedia.org/wiki/CMake CMake]. Use whichever you feel more comfortable with.&lt;br /&gt;
&lt;br /&gt;
===GNU/Linux===&lt;br /&gt;
&lt;br /&gt;
On Debian-based distributions (including Ubuntu), you should be able to install the required compiler and build system packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;apt-get install libc6-dev g++ make autoconf automake libtool gettext&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install the necessary packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo pacman -S base-devel cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On other distributions, it should work similarily.&lt;br /&gt;
&lt;br /&gt;
===Windows===&lt;br /&gt;
&lt;br /&gt;
Since Visual Studio does not work with autotools, you have to use the CMake build system if you want to compile xoreos with Visual Studio. If you&#039;re using [http://www.mingw.org/ MinGW], however, you&#039;re free to choose either build system.&lt;br /&gt;
&lt;br /&gt;
On Windows, it is recommended that instead of Visual Studio, you use [https://msys2.github.io/ MSYS2] together with [https://mingw-w64.org/ Mingw-w64] (which can produce both 32-bit and 64-bit binaries). MSYS2 provides a package manager, with which you can install xoreos&#039; library dependencies very easily.&lt;br /&gt;
&lt;br /&gt;
You can install the 32-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-i686-toolchain mingw-w64-i686-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can install the 64-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-x86_64-toolchain mingw-w64-x86_64-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Libraries==&lt;br /&gt;
&lt;br /&gt;
Phaethon uses the following libraries to function:&lt;br /&gt;
&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Iconv iconv]&lt;br /&gt;
* [http://www.zlib.net/ zlib] (&amp;gt;= 1.2.3.4)&lt;br /&gt;
* [http://tukaani.org/xz/ liblzma] (&amp;gt;= 5.0.5)&lt;br /&gt;
* [http://www.xmlsoft.org/ libxml2] (&amp;gt;= 2.8.0)&lt;br /&gt;
* [http://www.boost.org/ Boost] (&amp;gt;= 1.53.0)&lt;br /&gt;
** Boost.Utility&lt;br /&gt;
** Boost.StringAlgo&lt;br /&gt;
** Boost.System&lt;br /&gt;
** Boost.Filesystem&lt;br /&gt;
** Boost.Regex&lt;br /&gt;
** Boost.Unordered&lt;br /&gt;
** Boost.Hash&lt;br /&gt;
** Boost.Date_Time&lt;br /&gt;
** Boost.Chrono&lt;br /&gt;
** Boost.Function&lt;br /&gt;
** Boost.Bind&lt;br /&gt;
** Boost.Uuid&lt;br /&gt;
** Boost.Smart_Ptr&lt;br /&gt;
** Boost.ScopeExit&lt;br /&gt;
** Boost.Atomic&lt;br /&gt;
** Boost.Locale&lt;br /&gt;
** Boost.Thread&lt;br /&gt;
* [https://www.qt.io/ Qt] (&amp;gt;= 5.7.1)&lt;br /&gt;
** Qt5Core&lt;br /&gt;
** Qt5Gui&lt;br /&gt;
** Qt5Widgets&lt;br /&gt;
** Qt5Concurrent&lt;br /&gt;
* [https://en.wikipedia.org/wiki/OpenAL OpenAL] (&amp;gt;= 1.12) (&#039;&#039;&#039;See below&#039;&#039;&#039;)&lt;br /&gt;
* [http://www.underbit.com/products/mad/ MAD] (&amp;gt;= 0.15.1b)&lt;br /&gt;
* [https://www.xiph.org/downloads/ libogg] (&amp;gt;= 1.2.0)&lt;br /&gt;
* [https://www.xiph.org/downloads/ libvorbis] (&amp;gt;= 1.3.1)&lt;br /&gt;
&lt;br /&gt;
On Debian-based GNU/Linux distribution (including Ubuntu), you should be able to install these libraries and their development packages with&lt;br /&gt;
&lt;br /&gt;
 sudo apt-get install zlib1g-dev liblzma-dev libxml2-dev libboost-all-dev \&lt;br /&gt;
     libopenal-dev libmad0-dev libogg-dev libvorbis-dev  \&lt;br /&gt;
     qtbase5-dev, libqt5gui5, libqt5widgets5&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install these dependencies with&lt;br /&gt;
&lt;br /&gt;
 sudo pacman -S zlib xz libxml2 boost boost-libs openal libmad libogg \&lt;br /&gt;
     libvorbis qt5-base&lt;br /&gt;
&lt;br /&gt;
Other GNU/Linux distributions should work similarily.&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 32-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-i686-zlib mingw-w64-i686-xz mingw-w64-i686-libxml2 \&lt;br /&gt;
     mingw-w64-i686-boost mingw-w64-i686-openal mingw-w64-i686-libmad \&lt;br /&gt;
     mingw-w64-i686-libogg mingw-w64-i686-libvorbis mingw-w64-i686-qt-creator&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 64-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-x86_64-zlib mingw-w64-x86_64-xz mingw-w64-x86_64-libxml2 \&lt;br /&gt;
     mingw-w64-x86_64-boost mingw-w64-x86_64-openal mingw-w64-x86_64-libmad \&lt;br /&gt;
     mingw-w64-x86_64-libogg mingw-w64-x86_64-libvorbis mingw-w64-x86_64-qt-creator&lt;br /&gt;
&lt;br /&gt;
Windows users not using MSYS2 will have to visit each website manually and download a precompiled version, or, if not available, download the source and compile the library themselves.&lt;br /&gt;
&lt;br /&gt;
=== A note on OpenAL ===&lt;br /&gt;
&lt;br /&gt;
On Mac OS X, we&#039;re using Apple&#039;s OpenAL implementation, so OpenAL does not need to be installed separately there.&lt;br /&gt;
&lt;br /&gt;
On both GNU/Linux and Microsoft Windows, we require [http://kcat.strangesoft.net/openal.html OpenAL Soft]. There is a propriety OpenAL implementation by Creative Labs, Inc. for Microsoft Windows, which can be found at [http://openal.org/ http://openal.org/], but it&#039;s unfortunately old, outdated and abandoned. We do not recommend its use.&lt;br /&gt;
&lt;br /&gt;
Likewise, on NetBSD and other systems using pkgsrc, you should use [http://pkgsrc.se/audio/openal-soft openal-soft] instead of [http://pkgsrc.se/audio/openal openal].&lt;br /&gt;
&lt;br /&gt;
==Compiling Phaethon==&lt;br /&gt;
&lt;br /&gt;
Make sure you have your compiler, build system and libraries installed correctly. Then open a terminal and change into the directory of your sources.&lt;br /&gt;
&lt;br /&gt;
===autotools===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;./autogen.sh &amp;amp;&amp;amp; ./configure &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binaries can then be found in the src subdirectory.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional ./configure flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* --with-werror &amp;amp;nbsp;&lt;br /&gt;
|| Compile with -Werror&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --without-warnings &amp;amp;nbsp;&lt;br /&gt;
|| Compile without the extra warnings enabled&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --with-lto &amp;amp;nbsp;&lt;br /&gt;
|| Compile with link-time optimization&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===CMake ===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;cmake . &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binaries can then be found in the bin subdirectory.&lt;br /&gt;
&lt;br /&gt;
Please read [http://www.cmake.org/runningcmake/ Running CMake] on the CMake website for in-depth information on invoking CMake.&lt;br /&gt;
&lt;br /&gt;
==Unit tests==&lt;br /&gt;
&lt;br /&gt;
On both build systems,&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;make check&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
compiles and runs our unit tests.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Compiling_xoreos&amp;diff=437</id>
		<title>Compiling xoreos</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Compiling_xoreos&amp;diff=437"/>
		<updated>2019-01-11T18:23:23Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: Add libvpx to our library dependencies&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page gives a few tips and pointers on how to compile xoreos on various platforms.&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
==Compiler and build system==&lt;br /&gt;
&lt;br /&gt;
xoreos is written in C++, so a C++ compiler, like [https://gcc.gnu.org/ GCC] or [http://clang.llvm.org/ clang] is required. xoreos follows the C++11 standard. It has two build systems: [https://en.wikipedia.org/wiki/GNU_build_system Autotools] ([https://www.gnu.org/software/autoconf/ Autoconf], [https://www.gnu.org/software/automake/ Automake] and [https://www.gnu.org/software/libtool/ Libtool]) and [https://en.wikipedia.org/wiki/CMake CMake]. Use whichever you feel more comfortable with.&lt;br /&gt;
&lt;br /&gt;
===GNU/Linux===&lt;br /&gt;
&lt;br /&gt;
On Debian-based distributions (including Ubuntu), you should be able to install the required compiler and build system packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo apt-get install libc6-dev g++ make autoconf automake libtool gettext cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install the necessary packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo pacman -S base-devel cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On other distributions, it should work similarily.&lt;br /&gt;
&lt;br /&gt;
===Mac OS X===&lt;br /&gt;
&lt;br /&gt;
Due to the dependency on SDL2 (see below), you need at least Mac OS X 10.5 if you use a precompiled SDL2 library, and at least Mac OS X 10.7 if you&#039;re compiling SDL2 yourself.&lt;br /&gt;
&lt;br /&gt;
===Windows===&lt;br /&gt;
&lt;br /&gt;
Since Visual Studio does not work with autotools, you have to use the CMake build system if you want to compile xoreos with Visual Studio. If you&#039;re using [http://www.mingw.org/ MinGW], however, you&#039;re free to choose either build system.&lt;br /&gt;
&lt;br /&gt;
On Windows, it is recommended that instead of Visual Studio, you use [https://msys2.github.io/ MSYS2] together with [https://mingw-w64.org/ Mingw-w64] (which can produce both 32-bit and 64-bit binaries). MSYS2 provides a package manager, with which you can install xoreos&#039; library dependencies very easily.&lt;br /&gt;
&lt;br /&gt;
You can install the 32-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-i686-toolchain mingw-w64-i686-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can install the 64-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-x86_64-toolchain mingw-w64-x86_64-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Libraries==&lt;br /&gt;
&lt;br /&gt;
xoreos uses the following libraries to function:&lt;br /&gt;
&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Iconv iconv]&lt;br /&gt;
* [http://www.zlib.net/ zlib] (&amp;gt;= 1.2.3.4)&lt;br /&gt;
* [http://tukaani.org/xz/ liblzma] (&amp;gt;= 5.0.5)&lt;br /&gt;
* [http://www.xmlsoft.org/ libxml2] (&amp;gt;= 2.8.0)&lt;br /&gt;
* [http://www.boost.org/ Boost] (&amp;gt;= 1.53.0)&lt;br /&gt;
** Boost.Utility&lt;br /&gt;
** Boost.StringAlgo&lt;br /&gt;
** Boost.System&lt;br /&gt;
** Boost.Filesystem&lt;br /&gt;
** Boost.Regex&lt;br /&gt;
** Boost.Unordered&lt;br /&gt;
** Boost.Hash&lt;br /&gt;
** Boost.Date_Time&lt;br /&gt;
** Boost.Function&lt;br /&gt;
** Boost.Bind&lt;br /&gt;
** Boost.Uuid&lt;br /&gt;
** Boost.Smart_Ptr&lt;br /&gt;
** Boost.ScopeExit&lt;br /&gt;
** Boost.Atomic&lt;br /&gt;
** Boost.Locale&lt;br /&gt;
* [https://en.wikipedia.org/wiki/OpenGL OpenGL] (&amp;gt;= 2.1)&lt;br /&gt;
* [https://www.libsdl.org/ SDL2] (&amp;gt;= 2.0.0)&lt;br /&gt;
* [http://www.freetype.org/ FreeType 2] (&amp;gt;= 2.4.0 (libtool number &amp;gt;= 11.0.5))&lt;br /&gt;
* [https://en.wikipedia.org/wiki/OpenAL OpenAL] (&amp;gt;= 1.12) (&#039;&#039;&#039;See below&#039;&#039;&#039;)&lt;br /&gt;
* [http://www.underbit.com/products/mad/ MAD] (&amp;gt;= 0.15.1b)&lt;br /&gt;
* [https://www.xiph.org/downloads/ libogg] (&amp;gt;= 1.2.0)&lt;br /&gt;
* [https://www.xiph.org/downloads/ libvorbis] (&amp;gt;= 1.3.1)&lt;br /&gt;
* [http://www.audiocoding.com/faad2.html libfaad] (&amp;gt;= 2.7)&lt;br /&gt;
* [https://www.xvid.org/ libxvidcore] (&amp;gt;= 1.2.2)&lt;br /&gt;
* [https://www.webmproject.org/code/ libvpx] (&amp;gt;= 1.6.0)&lt;br /&gt;
&lt;br /&gt;
On Debian-based GNU/Linux distribution (including Ubuntu), you should be able to install these libraries and their development packages with&lt;br /&gt;
&lt;br /&gt;
 sudo apt-get install zlib1g-dev liblzma-dev libxml2-dev libboost-all-dev libsdl2-dev \&lt;br /&gt;
     libfreetype6-dev libopenal-dev libmad0-dev libogg-dev libvorbis-dev libfaad-dev \&lt;br /&gt;
     libxvidcore-dev libvpx-dev&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install these dependencies with&lt;br /&gt;
&lt;br /&gt;
 sudo pacman -S zlib xz libxml2 boost boost-libs sdl2 freetype2 openal libmad libogg \&lt;br /&gt;
     libvorbis faad2 xvidcore libvpx&lt;br /&gt;
&lt;br /&gt;
Other GNU/Linux distributions should work similarily.&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 32-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-i686-zlib mingw-w64-i686-xz mingw-w64-i686-libxml2 \&lt;br /&gt;
     mingw-w64-i686-boost mingw-w64-i686-SDL2 mingw-w64-i686-freetype \&lt;br /&gt;
     mingw-w64-i686-openal mingw-w64-i686-libmad mingw-w64-i686-libogg \&lt;br /&gt;
     mingw-w64-i686-libvorbis  mingw-w64-i686-faad2 mingw-w64-i686-xvidcore \&lt;br /&gt;
     mingw-w64-i686-libvpx&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 64-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-x86_64-zlib mingw-w64-x86_64-xz mingw-w64-x86_64-libxml2 \&lt;br /&gt;
     mingw-w64-x86_64-boost mingw-w64-x86_64-SDL2 mingw-w64-x86_64-freetype \&lt;br /&gt;
     mingw-w64-x86_64-openal mingw-w64-x86_64-libmad mingw-w64-x86_64-libogg \&lt;br /&gt;
     mingw-w64-x86_64-libvorbis  mingw-w64-x86_64-faad2 mingw-w64-x86_64-xvidcore \&lt;br /&gt;
     mingw-w64-x86_64-libvpx&lt;br /&gt;
&lt;br /&gt;
Windows users not using MSYS2 will have to visit each website manually and download a precompiled version, or, if not available, download the source and compile the library themselves.&lt;br /&gt;
&lt;br /&gt;
===  Guide for Visual Studio 2017 users ===&lt;br /&gt;
&lt;br /&gt;
* Download source from https://github.com/win-iconv/win-iconv and build the library using CMake&lt;br /&gt;
* Download https://zlib.net/zlib1211.zip, extract and build the library using CMake&lt;br /&gt;
* Download https://tukaani.org/xz/xz-5.2.4.tar.gz, extract and build the library using the solution file in windows/vs2017&lt;br /&gt;
* Download ftp://xmlsoft.org/libxml2/libxml2-2.9.8.tar.gz, extract and build the library by following instructions in win32/Readme.txt&lt;br /&gt;
* Download and install precompiled Boost libraries from https://sourceforge.net/projects/boost/files/boost-binaries/1.67.0/&lt;br /&gt;
* Download and extract https://www.libsdl.org/release/SDL2-devel-2.0.8-VC.zip&lt;br /&gt;
* Download https://download.savannah.gnu.org/releases/freetype/ft291.zip and build the library using CMake&lt;br /&gt;
* Download and extract http://kcat.strangesoft.net/openal-binaries/openal-soft-1.18.2-bin.zip&lt;br /&gt;
* Download ftp://ftp.mars.org/pub/mpeg/libmad-0.15.1b.tar.gz and build the library using the project file in msvc++. To build a 64-bit library, create a new configuration and replace preprocessor definition FPM_INTEL with FPM_64BIT&lt;br /&gt;
* Download http://downloads.xiph.org/releases/ogg/libogg-1.3.3.zip, extract and build both dynamic and static libraries using solution files in win32/VS2015&lt;br /&gt;
* Download http://downloads.xiph.org/releases/vorbis/libvorbis-1.3.6.zip, extract and build both dynamic and static libraries using solution files in win32/VS2010&lt;br /&gt;
* Download https://vorboss.dl.sourceforge.net/project/faac/faad2-src/faad2-2.8.0/faad2-2.8.8.tar.gz, extract and build projects &#039;&#039;&#039;libfaad&#039;&#039;&#039; and &#039;&#039;&#039;libfaad2_dll&#039;&#039;&#039; using the solution file in project/msvc. To build 64-bit libraries, create a new configuration&lt;br /&gt;
* Download source from https://github.com/seedhartha/xvidcore and build the library using CMake (requires NASM to be installed and present in PATH)&lt;br /&gt;
* Build xoreos using CMake&lt;br /&gt;
&lt;br /&gt;
To build a project using CMake, create a folder named &#039;&#039;&#039;build&#039;&#039;&#039; in a root directory of a project and from there invoke&lt;br /&gt;
&lt;br /&gt;
  cmake .. -G &amp;quot;Visual Studio 15 2017&amp;quot;&lt;br /&gt;
&lt;br /&gt;
or, for 64-bit&lt;br /&gt;
&lt;br /&gt;
  cmake .. -G &amp;quot;Visual Studio 15 2017 Win64&amp;quot;&lt;br /&gt;
&lt;br /&gt;
Open CMakeCache.txt in your favorite text editor and fill in missing information as needed. Then run cmake again. Project&#039;s solution file should be created at this point.&lt;br /&gt;
&lt;br /&gt;
=== A note on OpenAL ===&lt;br /&gt;
&lt;br /&gt;
On Mac OS X, we&#039;re using Apple&#039;s OpenAL implementation, so OpenAL does not need to be installed separately there.&lt;br /&gt;
&lt;br /&gt;
On both GNU/Linux and Microsoft Windows, we require [http://kcat.strangesoft.net/openal.html OpenAL Soft]. There is a propriety OpenAL implementation by Creative Labs, Inc. for Microsoft Windows, which can be found at [http://openal.org/ http://openal.org/], but it&#039;s unfortunately old, outdated and abandoned. We do not recommend its use.&lt;br /&gt;
&lt;br /&gt;
Likewise, on NetBSD and other systems using pkgsrc, you should use [http://pkgsrc.se/audio/openal-soft openal-soft] instead of [http://pkgsrc.se/audio/openal openal].&lt;br /&gt;
&lt;br /&gt;
==Compiling xoreos==&lt;br /&gt;
&lt;br /&gt;
Make sure you have your compiler, build system and libraries installed correctly. Then open a terminal and change into the directory of your sources.&lt;br /&gt;
&lt;br /&gt;
===autotools===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;./autogen.sh &amp;amp;&amp;amp; ./configure &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binary can be found in the src subdirectory, called &amp;quot;xoreos&amp;quot; or, on Windows, &amp;quot;xoreos.exe&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional ./configure flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* --with-werror &amp;amp;nbsp;&lt;br /&gt;
|| Compile with -Werror&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --without-warnings &amp;amp;nbsp;&lt;br /&gt;
|| Compile without the extra warnings enabled&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --with-lto &amp;amp;nbsp;&lt;br /&gt;
|| Compile with link-time optimization&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --disable-external-glew &amp;amp;nbsp;&lt;br /&gt;
|| Always compile against the internal GLEW libraries&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
===CMake ===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;cmake . &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binary can be found in the bin subdirectory, called &amp;quot;xoreos&amp;quot; or, on Windows, &amp;quot;xoreos.exe&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Please read [http://www.cmake.org/runningcmake/ Running CMake] on the CMake website for in-depth information on invoking CMake.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional cmake flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* -DBoost_USE_STATIC_LIBS=on &amp;amp;nbsp;&lt;br /&gt;
|| Link Boost statically instead of dynamically&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* -DGLEW_INTERNAL=on &amp;amp;nbsp;&lt;br /&gt;
|| Always use internal GLEW library&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note&#039;&#039;&#039;: The CMake&#039;s stock FindBoost.cmake doesn&#039;t correctly detect dependencies when linking statically. In this case, xoreos might fail to link, missing symbols for ICU, when linking Boost statically.&lt;br /&gt;
&lt;br /&gt;
Moreover, if you&#039;re running GNU/Linux and have wrapper scripts installed that force the building of &amp;quot;hardened&amp;quot; binaries (often called &amp;quot;hardening-wrapper&amp;quot;, but differs between Linux distributions), compiling xoreos might fail during the linking stage, when using statically linking Boost libraries. This is due to those static Boost libraries being incompatible with the compiler option &amp;quot;-fPIE&amp;quot;, which is often added by hardening wrapper scripts. A workaround is to disable -fPIE for this compilation (which is distribution-specific).&lt;br /&gt;
&lt;br /&gt;
==Unit tests==&lt;br /&gt;
&lt;br /&gt;
On both build systems,&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;make check&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
compiles and runs our unit tests.&lt;br /&gt;
&lt;br /&gt;
==Running xoreos==&lt;br /&gt;
&lt;br /&gt;
Please have a look at the [[Running xoreos]] page.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Compiling_xoreos&amp;diff=436</id>
		<title>Compiling xoreos</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Compiling_xoreos&amp;diff=436"/>
		<updated>2019-01-11T18:18:31Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* Compiler and build system */ C++03 -&amp;gt; C++11&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page gives a few tips and pointers on how to compile xoreos on various platforms.&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
==Compiler and build system==&lt;br /&gt;
&lt;br /&gt;
xoreos is written in C++, so a C++ compiler, like [https://gcc.gnu.org/ GCC] or [http://clang.llvm.org/ clang] is required. xoreos follows the C++11 standard. It has two build systems: [https://en.wikipedia.org/wiki/GNU_build_system Autotools] ([https://www.gnu.org/software/autoconf/ Autoconf], [https://www.gnu.org/software/automake/ Automake] and [https://www.gnu.org/software/libtool/ Libtool]) and [https://en.wikipedia.org/wiki/CMake CMake]. Use whichever you feel more comfortable with.&lt;br /&gt;
&lt;br /&gt;
===GNU/Linux===&lt;br /&gt;
&lt;br /&gt;
On Debian-based distributions (including Ubuntu), you should be able to install the required compiler and build system packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo apt-get install libc6-dev g++ make autoconf automake libtool gettext cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install the necessary packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo pacman -S base-devel cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On other distributions, it should work similarily.&lt;br /&gt;
&lt;br /&gt;
===Mac OS X===&lt;br /&gt;
&lt;br /&gt;
Due to the dependency on SDL2 (see below), you need at least Mac OS X 10.5 if you use a precompiled SDL2 library, and at least Mac OS X 10.7 if you&#039;re compiling SDL2 yourself.&lt;br /&gt;
&lt;br /&gt;
===Windows===&lt;br /&gt;
&lt;br /&gt;
Since Visual Studio does not work with autotools, you have to use the CMake build system if you want to compile xoreos with Visual Studio. If you&#039;re using [http://www.mingw.org/ MinGW], however, you&#039;re free to choose either build system.&lt;br /&gt;
&lt;br /&gt;
On Windows, it is recommended that instead of Visual Studio, you use [https://msys2.github.io/ MSYS2] together with [https://mingw-w64.org/ Mingw-w64] (which can produce both 32-bit and 64-bit binaries). MSYS2 provides a package manager, with which you can install xoreos&#039; library dependencies very easily.&lt;br /&gt;
&lt;br /&gt;
You can install the 32-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-i686-toolchain mingw-w64-i686-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can install the 64-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-x86_64-toolchain mingw-w64-x86_64-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Libraries==&lt;br /&gt;
&lt;br /&gt;
xoreos uses the following libraries to function:&lt;br /&gt;
&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Iconv iconv]&lt;br /&gt;
* [http://www.zlib.net/ zlib] (&amp;gt;= 1.2.3.4)&lt;br /&gt;
* [http://tukaani.org/xz/ liblzma] (&amp;gt;= 5.0.5)&lt;br /&gt;
* [http://www.xmlsoft.org/ libxml2] (&amp;gt;= 2.8.0)&lt;br /&gt;
* [http://www.boost.org/ Boost] (&amp;gt;= 1.53.0)&lt;br /&gt;
** Boost.Utility&lt;br /&gt;
** Boost.StringAlgo&lt;br /&gt;
** Boost.System&lt;br /&gt;
** Boost.Filesystem&lt;br /&gt;
** Boost.Regex&lt;br /&gt;
** Boost.Unordered&lt;br /&gt;
** Boost.Hash&lt;br /&gt;
** Boost.Date_Time&lt;br /&gt;
** Boost.Function&lt;br /&gt;
** Boost.Bind&lt;br /&gt;
** Boost.Uuid&lt;br /&gt;
** Boost.Smart_Ptr&lt;br /&gt;
** Boost.ScopeExit&lt;br /&gt;
** Boost.Atomic&lt;br /&gt;
** Boost.Locale&lt;br /&gt;
* [https://en.wikipedia.org/wiki/OpenGL OpenGL] (&amp;gt;= 2.1)&lt;br /&gt;
* [https://www.libsdl.org/ SDL2] (&amp;gt;= 2.0.0)&lt;br /&gt;
* [http://www.freetype.org/ FreeType 2] (&amp;gt;= 2.4.0 (libtool number &amp;gt;= 11.0.5))&lt;br /&gt;
* [https://en.wikipedia.org/wiki/OpenAL OpenAL] (&amp;gt;= 1.12) (&#039;&#039;&#039;See below&#039;&#039;&#039;)&lt;br /&gt;
* [http://www.underbit.com/products/mad/ MAD] (&amp;gt;= 0.15.1b)&lt;br /&gt;
* [https://www.xiph.org/downloads/ libogg] (&amp;gt;= 1.2.0)&lt;br /&gt;
* [https://www.xiph.org/downloads/ libvorbis] (&amp;gt;= 1.3.1)&lt;br /&gt;
* [http://www.audiocoding.com/faad2.html libfaad] (&amp;gt;= 2.7)&lt;br /&gt;
* [https://www.xvid.org/ libxvidcore] (&amp;gt;= 1.2.2)&lt;br /&gt;
&lt;br /&gt;
On Debian-based GNU/Linux distribution (including Ubuntu), you should be able to install these libraries and their development packages with&lt;br /&gt;
&lt;br /&gt;
 sudo apt-get install zlib1g-dev liblzma-dev libxml2-dev libboost-all-dev libsdl2-dev \&lt;br /&gt;
     libfreetype6-dev libopenal-dev libmad0-dev libogg-dev libvorbis-dev libfaad-dev \&lt;br /&gt;
     libxvidcore-dev&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install these dependencies with&lt;br /&gt;
&lt;br /&gt;
 sudo pacman -S zlib xz libxml2 boost boost-libs sdl2 freetype2 openal libmad libogg \&lt;br /&gt;
     libvorbis faad2 xvidcore&lt;br /&gt;
&lt;br /&gt;
Other GNU/Linux distributions should work similarily.&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 32-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-i686-zlib mingw-w64-i686-xz mingw-w64-i686-libxml2 \&lt;br /&gt;
     mingw-w64-i686-boost mingw-w64-i686-SDL2 mingw-w64-i686-freetype \&lt;br /&gt;
     mingw-w64-i686-openal mingw-w64-i686-libmad mingw-w64-i686-libogg \&lt;br /&gt;
     mingw-w64-i686-libvorbis  mingw-w64-i686-faad2 mingw-w64-i686-xvidcore&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 64-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-x86_64-zlib mingw-w64-x86_64-xz mingw-w64-x86_64-libxml2 \&lt;br /&gt;
     mingw-w64-x86_64-boost mingw-w64-x86_64-SDL2 mingw-w64-x86_64-freetype \&lt;br /&gt;
     mingw-w64-x86_64-openal mingw-w64-x86_64-libmad mingw-w64-x86_64-libogg \&lt;br /&gt;
     mingw-w64-x86_64-libvorbis  mingw-w64-x86_64-faad2 mingw-w64-x86_64-xvidcore&lt;br /&gt;
&lt;br /&gt;
Windows users not using MSYS2 will have to visit each website manually and download a precompiled version, or, if not available, download the source and compile the library themselves.&lt;br /&gt;
&lt;br /&gt;
===  Guide for Visual Studio 2017 users ===&lt;br /&gt;
&lt;br /&gt;
* Download source from https://github.com/win-iconv/win-iconv and build the library using CMake&lt;br /&gt;
* Download https://zlib.net/zlib1211.zip, extract and build the library using CMake&lt;br /&gt;
* Download https://tukaani.org/xz/xz-5.2.4.tar.gz, extract and build the library using the solution file in windows/vs2017&lt;br /&gt;
* Download ftp://xmlsoft.org/libxml2/libxml2-2.9.8.tar.gz, extract and build the library by following instructions in win32/Readme.txt&lt;br /&gt;
* Download and install precompiled Boost libraries from https://sourceforge.net/projects/boost/files/boost-binaries/1.67.0/&lt;br /&gt;
* Download and extract https://www.libsdl.org/release/SDL2-devel-2.0.8-VC.zip&lt;br /&gt;
* Download https://download.savannah.gnu.org/releases/freetype/ft291.zip and build the library using CMake&lt;br /&gt;
* Download and extract http://kcat.strangesoft.net/openal-binaries/openal-soft-1.18.2-bin.zip&lt;br /&gt;
* Download ftp://ftp.mars.org/pub/mpeg/libmad-0.15.1b.tar.gz and build the library using the project file in msvc++. To build a 64-bit library, create a new configuration and replace preprocessor definition FPM_INTEL with FPM_64BIT&lt;br /&gt;
* Download http://downloads.xiph.org/releases/ogg/libogg-1.3.3.zip, extract and build both dynamic and static libraries using solution files in win32/VS2015&lt;br /&gt;
* Download http://downloads.xiph.org/releases/vorbis/libvorbis-1.3.6.zip, extract and build both dynamic and static libraries using solution files in win32/VS2010&lt;br /&gt;
* Download https://vorboss.dl.sourceforge.net/project/faac/faad2-src/faad2-2.8.0/faad2-2.8.8.tar.gz, extract and build projects &#039;&#039;&#039;libfaad&#039;&#039;&#039; and &#039;&#039;&#039;libfaad2_dll&#039;&#039;&#039; using the solution file in project/msvc. To build 64-bit libraries, create a new configuration&lt;br /&gt;
* Download source from https://github.com/seedhartha/xvidcore and build the library using CMake (requires NASM to be installed and present in PATH)&lt;br /&gt;
* Build xoreos using CMake&lt;br /&gt;
&lt;br /&gt;
To build a project using CMake, create a folder named &#039;&#039;&#039;build&#039;&#039;&#039; in a root directory of a project and from there invoke&lt;br /&gt;
&lt;br /&gt;
  cmake .. -G &amp;quot;Visual Studio 15 2017&amp;quot;&lt;br /&gt;
&lt;br /&gt;
or, for 64-bit&lt;br /&gt;
&lt;br /&gt;
  cmake .. -G &amp;quot;Visual Studio 15 2017 Win64&amp;quot;&lt;br /&gt;
&lt;br /&gt;
Open CMakeCache.txt in your favorite text editor and fill in missing information as needed. Then run cmake again. Project&#039;s solution file should be created at this point.&lt;br /&gt;
&lt;br /&gt;
=== A note on OpenAL ===&lt;br /&gt;
&lt;br /&gt;
On Mac OS X, we&#039;re using Apple&#039;s OpenAL implementation, so OpenAL does not need to be installed separately there.&lt;br /&gt;
&lt;br /&gt;
On both GNU/Linux and Microsoft Windows, we require [http://kcat.strangesoft.net/openal.html OpenAL Soft]. There is a propriety OpenAL implementation by Creative Labs, Inc. for Microsoft Windows, which can be found at [http://openal.org/ http://openal.org/], but it&#039;s unfortunately old, outdated and abandoned. We do not recommend its use.&lt;br /&gt;
&lt;br /&gt;
Likewise, on NetBSD and other systems using pkgsrc, you should use [http://pkgsrc.se/audio/openal-soft openal-soft] instead of [http://pkgsrc.se/audio/openal openal].&lt;br /&gt;
&lt;br /&gt;
==Compiling xoreos==&lt;br /&gt;
&lt;br /&gt;
Make sure you have your compiler, build system and libraries installed correctly. Then open a terminal and change into the directory of your sources.&lt;br /&gt;
&lt;br /&gt;
===autotools===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;./autogen.sh &amp;amp;&amp;amp; ./configure &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binary can be found in the src subdirectory, called &amp;quot;xoreos&amp;quot; or, on Windows, &amp;quot;xoreos.exe&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional ./configure flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* --with-werror &amp;amp;nbsp;&lt;br /&gt;
|| Compile with -Werror&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --without-warnings &amp;amp;nbsp;&lt;br /&gt;
|| Compile without the extra warnings enabled&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --with-lto &amp;amp;nbsp;&lt;br /&gt;
|| Compile with link-time optimization&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --disable-external-glew &amp;amp;nbsp;&lt;br /&gt;
|| Always compile against the internal GLEW libraries&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
===CMake ===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;cmake . &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binary can be found in the bin subdirectory, called &amp;quot;xoreos&amp;quot; or, on Windows, &amp;quot;xoreos.exe&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Please read [http://www.cmake.org/runningcmake/ Running CMake] on the CMake website for in-depth information on invoking CMake.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional cmake flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* -DBoost_USE_STATIC_LIBS=on &amp;amp;nbsp;&lt;br /&gt;
|| Link Boost statically instead of dynamically&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* -DGLEW_INTERNAL=on &amp;amp;nbsp;&lt;br /&gt;
|| Always use internal GLEW library&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note&#039;&#039;&#039;: The CMake&#039;s stock FindBoost.cmake doesn&#039;t correctly detect dependencies when linking statically. In this case, xoreos might fail to link, missing symbols for ICU, when linking Boost statically.&lt;br /&gt;
&lt;br /&gt;
Moreover, if you&#039;re running GNU/Linux and have wrapper scripts installed that force the building of &amp;quot;hardened&amp;quot; binaries (often called &amp;quot;hardening-wrapper&amp;quot;, but differs between Linux distributions), compiling xoreos might fail during the linking stage, when using statically linking Boost libraries. This is due to those static Boost libraries being incompatible with the compiler option &amp;quot;-fPIE&amp;quot;, which is often added by hardening wrapper scripts. A workaround is to disable -fPIE for this compilation (which is distribution-specific).&lt;br /&gt;
&lt;br /&gt;
==Unit tests==&lt;br /&gt;
&lt;br /&gt;
On both build systems,&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;make check&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
compiles and runs our unit tests.&lt;br /&gt;
&lt;br /&gt;
==Running xoreos==&lt;br /&gt;
&lt;br /&gt;
Please have a look at the [[Running xoreos]] page.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Binary_XACT_SoundBank&amp;diff=435</id>
		<title>Binary XACT SoundBank</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Binary_XACT_SoundBank&amp;diff=435"/>
		<updated>2019-01-06T11:29:24Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is the binary version of the XACT SoundBank (XSB), version 11, as used by Jade Empire on the original Xbox. The Windows PC version of Jade Empire uses an ASCII variant, which contains the same information.&lt;br /&gt;
&lt;br /&gt;
Conceptually, it&#039;s very similar to later XSB versions that are used by Microsoft&#039;s XNA toolset.&lt;br /&gt;
&lt;br /&gt;
On the top-level, a SoundBank consists of cues and sounds. A sound is a collection of tracks, which each contain a list of events and a list of wave variations, while a cue consists of a list of references to sounds.&lt;br /&gt;
&lt;br /&gt;
Both the cue variation and the wave variation can be selected using different methods. For example, they could be played in order, or randomly. Or they could be explicitly selected by game.&lt;br /&gt;
&lt;br /&gt;
== A structural example ==&lt;br /&gt;
&lt;br /&gt;
* Sounds&lt;br /&gt;
** Sound 0&lt;br /&gt;
*** Track 0&lt;br /&gt;
**** Event list&lt;br /&gt;
***** PLAY&lt;br /&gt;
***** LOOP&lt;br /&gt;
***** VOLUME&lt;br /&gt;
***** PITCH&lt;br /&gt;
**** Wave variations&lt;br /&gt;
***** Sound 23 out of WaveBank &amp;amp;quot;foobar&amp;amp;quot;&lt;br /&gt;
***** Sound 24 out of WaveBank &amp;amp;quot;foobar&amp;amp;quot;&lt;br /&gt;
***** Sound 12 out of WaveBank &amp;amp;quot;quux&amp;amp;quot;&lt;br /&gt;
** Sound 1&lt;br /&gt;
*** Track 0&lt;br /&gt;
**** Event list&lt;br /&gt;
***** PLAY&lt;br /&gt;
**** Wave variations&lt;br /&gt;
***** Sound 24 out of WaveBank &amp;amp;quot;foobar&amp;amp;quot;&lt;br /&gt;
*** Track 1&lt;br /&gt;
**** Event list&lt;br /&gt;
***** PLAY&lt;br /&gt;
**** Wave variations&lt;br /&gt;
***** Sound 25 out of WaveBank &amp;amp;quot;foobar&amp;amp;quot;&lt;br /&gt;
* Cues&lt;br /&gt;
** Cue 0&lt;br /&gt;
*** Cue variations&lt;br /&gt;
**** Sound 0&lt;br /&gt;
**** Sound 1&lt;br /&gt;
** Cue 1&lt;br /&gt;
*** Cue variations&lt;br /&gt;
**** Sound 0&lt;br /&gt;
** Cue 2&lt;br /&gt;
*** Cue variations&lt;br /&gt;
**** Sound 1&lt;br /&gt;
&lt;br /&gt;
== Structures ==&lt;br /&gt;
&lt;br /&gt;
All numerical values are little-endian.&lt;br /&gt;
&lt;br /&gt;
=== Header ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| FourCC, &amp;amp;quot;SDBK&amp;amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Version, 11 (0B 00)&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| CRC&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to WaveBank array&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to crossfade parameters array&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to 3D parameters array&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| XSB flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x1A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of sounds (soundCount)&lt;br /&gt;
|-&lt;br /&gt;
| 0x1E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of cues (cueCount)&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x22&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of WaveBanks&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x28&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 16&lt;br /&gt;
| SoundBank name&lt;br /&gt;
|-&lt;br /&gt;
| 0x38&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| cueCount * 20&lt;br /&gt;
| Cue entries&lt;br /&gt;
|-&lt;br /&gt;
| 0x38 + cueCount * 20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| soundCount * 20&lt;br /&gt;
| Sound entries&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== WaveBank entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 16&lt;br /&gt;
| WaveBank file name (without extension)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Cue entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x02&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Sound index (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to name (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to cue variations (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Index into the crossfade parameters array&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Interactive transitions (see below)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Sound index: 0xFFFF if the cue has only one variations.&lt;br /&gt;
&lt;br /&gt;
Offset to name: 0xFFFFFFFF if the cue has no name. Should be ignored if XSB_FLAG_NO_CUE_NAMES is set.&lt;br /&gt;
&lt;br /&gt;
Offset to cue variations: 0xFFFFFFFF if the cue has no variations&lt;br /&gt;
&lt;br /&gt;
Interactive transitions: AAAAAAAAAAAAAAAAAAAAAAAABBBBB???&lt;br /&gt;
&lt;br /&gt;
* A, 24 bits: Offset to the interactive transition definitions&lt;br /&gt;
* B, 5 bits: Trigger variable&lt;br /&gt;
&lt;br /&gt;
=== Sound entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset or indices (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Volume and LFE volume (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Pitch&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Number of tracks&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Layer&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Category&lt;br /&gt;
|-&lt;br /&gt;
| 0x0B&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Index into the 3D parameters array&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Priority&lt;br /&gt;
|-&lt;br /&gt;
| 0x0F&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| I3DL2 volume in 2.56th dB&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Parametric EQ gain in 8192th dB&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| EQ Q and EQ frequency (see below)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Offset or indices: Offset to non-trivial entry, or 2 bytes of wave index and 2 bytes of wavebank index.&lt;br /&gt;
&lt;br /&gt;
Volume and LFE volume: AAAAAAABBBBBBBBB&lt;br /&gt;
&lt;br /&gt;
* A, 7 bits: LFE volume. VolumeLFE = -A * 0.5&lt;br /&gt;
* B, 9 bits: volume: Volume = -B * 0.16&lt;br /&gt;
&lt;br /&gt;
EQ Q and EQ frequency: AAAAAAAAAAAAABBB&lt;br /&gt;
&lt;br /&gt;
* A, 13 bits: EQ frequency&lt;br /&gt;
* B, 3 bits: EQ Q coefficient. Q = 1 / 2^B&lt;br /&gt;
&lt;br /&gt;
=== Simple sound track ===&lt;br /&gt;
&lt;br /&gt;
One track, one PLAY event, multiple wave variations.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Variation parameters (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| variationCount * 4&lt;br /&gt;
| Variation entry (see below)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Variation parameters: AABBBBBBBBBBBBBCCCCDDDDDDDDDDDDD&lt;br /&gt;
&lt;br /&gt;
* A, 2 bits: Flags&lt;br /&gt;
* B, 13 bits: Current variation&lt;br /&gt;
* C, 4 bits: Variation selection method&lt;br /&gt;
* D, 13 bits: Number of variations (variationCount)&lt;br /&gt;
&lt;br /&gt;
Variation entry: 2 bytes of wave index and 2 bytes of wavebank index.&lt;br /&gt;
&lt;br /&gt;
=== Complex sound tracks ===&lt;br /&gt;
&lt;br /&gt;
Multiple tracks or more than just a simple PLAY event.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Number of events&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Offset to event list&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Variation table ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Variation parameters (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| variationCount * 8&lt;br /&gt;
| Variation entry&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Variation parameters: AABBBBBBBBBBBBBCCCCDDDDDDDDDDDDD&lt;br /&gt;
&lt;br /&gt;
* A, 2 bits: Flags&lt;br /&gt;
* B, 13 bits: Current variation&lt;br /&gt;
* C, 4 bits: Variation selection method&lt;br /&gt;
* D, 13 bits: Number of variations (variationCount)&lt;br /&gt;
&lt;br /&gt;
=== Event list entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| ....&lt;br /&gt;
|align=&amp;quot;right&amp;quot;|&lt;br /&gt;
&lt;br /&gt;
| Parameters&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a PLAY event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x00)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x04)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Loop count&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset or indices (see below)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Offset or indices: If XSB_PLAY_EVENT_FLAG_COMPLEX in Flags is set, this is an offset to a wave variation list (see &amp;amp;quot;Simple sound track&amp;amp;quot; above). Otherwise, this is 2 bytes of a sound index followed by 2 bytes of bank index.&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a PLAY_COMPLEX event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x01)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Loop count&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset or indices (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Pitch variation, lower bound&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Pitch variation, upper bound&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Volume variation, lower bound&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Volume variation, upper bound&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Maximum variable sound delay in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x16&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Offset or indices: If XSB_PLAY_EVENT_FLAG_COMPLEX in Flags is set, this is an offset to a wave variation list (see &amp;amp;quot;Simple sound track&amp;amp;quot; above). Otherwise, this is 2 bytes of a sound index followed by 2 bytes of bank index.&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a PITCH event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x04)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x08)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of fade steps&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Pitch, lower bound or starting value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Pitch, upper bound or starting value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Fade duration in milliseconds&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a VOLUME event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x05)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x08)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of fade steps&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Volume, lower bound or starting value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Volume, upper bound or starting value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Fade duration in milliseconds&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a LOWPASS event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x07)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x0C)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Sweep step count&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Cut-off frequency start&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Cut-off frequency end&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Sweep duration&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Resonance start&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Resonance end&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a LFO_PITCH event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x08)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x04)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Delta&lt;br /&gt;
|-&lt;br /&gt;
| 0x0B&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Pitch modulation&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a LFO_MULTI event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x09)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x08)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Delta&lt;br /&gt;
|-&lt;br /&gt;
| 0x0B&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Pitch modulation&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Filter modulation&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Amplitude modulation&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0F&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a ENVELOPE_AMPLITUDE event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x0A)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x0C)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Delay in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Attack in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Hold in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Decay in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Release in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Sustain power&lt;br /&gt;
|-&lt;br /&gt;
| 0x13&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a ENVELOPE_PITCH event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x0B)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Delay in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Attack in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Hold in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Decay in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Release in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Sustain power&lt;br /&gt;
|-&lt;br /&gt;
| 0x13&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x15&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x16&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Pitch scale&lt;br /&gt;
|-&lt;br /&gt;
| 0x17&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Filter cut-off&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a LOOP event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x0C)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x00)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of loops (see below)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Number of loops: 0xFFFF for looping indefinitely.&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a MARKER event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x0E)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x00)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Marker occurrences&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Marker value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Repeat duration in milliseconds&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a MIXBINS event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x20)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 0&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 0&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 2&lt;br /&gt;
|-&lt;br /&gt;
| 0x11&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 2&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 3&lt;br /&gt;
|-&lt;br /&gt;
| 0x15&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x16&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 3&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 4&lt;br /&gt;
|-&lt;br /&gt;
| 0x19&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x1A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 4&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 5&lt;br /&gt;
|-&lt;br /&gt;
| 0x1D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x1E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 5&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 6&lt;br /&gt;
|-&lt;br /&gt;
| 0x21&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x22&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 6&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 7&lt;br /&gt;
|-&lt;br /&gt;
| 0x25&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x26&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 7&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for an ENVIRONMENT_REVERB event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x11)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x30)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Room effect attenuation&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| High-frequency room effect attenuation&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Roll-off factor for the room effect&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Decay time&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| High-frequency to low-frequency decay time ratio&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| (Early) Reflection attenuation&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| (Early) Reflection delay&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| (Late) Reverb attenuation&lt;br /&gt;
|-&lt;br /&gt;
| 0x28&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| (Late) Reverb delay&lt;br /&gt;
|-&lt;br /&gt;
| 0x2C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Diffusion, echo density in (late) reverb decay&lt;br /&gt;
|-&lt;br /&gt;
| 0x30&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Density, modal density in (late) reverb decay&lt;br /&gt;
|-&lt;br /&gt;
| 0x34&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Reference high frequency&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a MIXBINSPAN event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x14)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Speaker configuration (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Angle and flag (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 0&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 0&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x11&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 2&lt;br /&gt;
|-&lt;br /&gt;
| 0x15&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x16&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 2&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 3&lt;br /&gt;
|-&lt;br /&gt;
| 0x19&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x1A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 3&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Speaker configuration: 0 for 5 channels, 1 for 4 channels&lt;br /&gt;
&lt;br /&gt;
Angle and flags: 00000ABBBBBBBBBCCCCCCCCC&lt;br /&gt;
&lt;br /&gt;
* A, 1 bit: If set, use 3D mix bins&lt;br /&gt;
* B, 9 bits: end angle&lt;br /&gt;
* C, 9 bits: start angle&lt;br /&gt;
&lt;br /&gt;
=== Variation entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Sound index&lt;br /&gt;
|-&lt;br /&gt;
| 0x02&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Weight minimum&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Weight maximum&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== 3D parameters entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Inside cone angle&lt;br /&gt;
|-&lt;br /&gt;
| 0x02&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Outside cone angle&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Cone outside volume&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Minimum distance&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Maximum distance&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Distance factor&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Rolloff factor&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Doppler factor&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Mode&lt;br /&gt;
|-&lt;br /&gt;
| 0x1D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Crossfade parameters entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Fade-in time in 10^-7 seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Initial volume&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Type (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x07&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Fade-in step count&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Fade-out time in 10^-7 seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Final volume&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Type (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x0F&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Fade-out step count&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Type: AAAA????&lt;br /&gt;
&lt;br /&gt;
* A, 4 bits: 0 for disabled, 1 for linear, 2 for logarithmic&lt;br /&gt;
&lt;br /&gt;
=== Interactive transitions array ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Number of transitions (transitionCount)&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| transitionCount * 24&lt;br /&gt;
| Transition entry&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
In general, there&#039;s one transition per sound combination (excluding the cases where to and from are the same), plus one set for silence to each sound, plus one set for each sound to silence.&lt;br /&gt;
&lt;br /&gt;
I.e. for N sounds, there&#039;s N^2 - N + 2N, or N^2 + N in shorter, transitions.&lt;br /&gt;
&lt;br /&gt;
The order is as follows:&lt;br /&gt;
&lt;br /&gt;
* Silence -&amp;amp;gt; N_0&lt;br /&gt;
* Silence -&amp;amp;gt; N_1&lt;br /&gt;
* Silence -&amp;amp;gt; N_2&lt;br /&gt;
* ...&lt;br /&gt;
* N_0 -&amp;amp;gt; Silence&lt;br /&gt;
* N_0 -&amp;amp;gt; N_1&lt;br /&gt;
* N_0 -&amp;amp;gt; N_2&lt;br /&gt;
* ...&lt;br /&gt;
* N_1 -&amp;amp;gt; Silence&lt;br /&gt;
* N_1 -&amp;amp;gt; N_0&lt;br /&gt;
* N_1 -&amp;amp;gt; N_2&lt;br /&gt;
* ...&lt;br /&gt;
&lt;br /&gt;
=== Interactive transition entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Flags (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x02&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Transitional sound index&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Source fade-out duration in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Destination fade-in duration in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Source marker, low&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Source marker, high&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Destination marker, low&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Destination marker, high&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Flags: 00000AAAABBBCCCC&lt;br /&gt;
&lt;br /&gt;
* A, 4 bits: Transition destination&lt;br /&gt;
* B, 3 bits: Transition effect&lt;br /&gt;
* C, 4 bits: Transition source&lt;br /&gt;
&lt;br /&gt;
== Flags ==&lt;br /&gt;
&lt;br /&gt;
=== XSB flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;26%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;9%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;64%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_FLAG_NO_CUE_NAMES&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0001&lt;br /&gt;
| If set, cues in the XSB file have no human-readable name&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Cue flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_CUE_FLAG_SEQUENTIAL&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0001&lt;br /&gt;
| If set, cue for sequential playback&lt;br /&gt;
|-&lt;br /&gt;
| XSB_CUE_FLAG_CROSSFADE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0002&lt;br /&gt;
| If set, enable crossfade&lt;br /&gt;
|-&lt;br /&gt;
| XSB_CUE_FLAG_STOPONSTARVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0004&lt;br /&gt;
| If set, stop on starvation&lt;br /&gt;
|-&lt;br /&gt;
| XSB_CUE_FLAG_INTERACTIVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0008&lt;br /&gt;
| If set, the cue is interactive&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Sound flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;25%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;8%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;65%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_3D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x01&lt;br /&gt;
| If set, the sound has 3D parameters&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_GAINBOOST&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x02&lt;br /&gt;
| If set, the sound has a gain boost of 6dB applied&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_EQ&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| If set, the sound has parametric EQ enabled&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_TRIVIAL&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x08&lt;br /&gt;
| Trivial sound: one track, one PLAY event, one wave variation&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_SIMPLE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Simple sound: one track, one PLAY event, multiple wave variations&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_LINGER&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| If set, the sound should linger in an interactive cue&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== PLAY event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;41%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;10%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;48%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PLAY_EVENT_FLAG_COMPLEX&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Complex wave variations definition&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PLAY_EVENT_FLAG_LOOPVARIATION&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x40&lt;br /&gt;
| Select new wave variation on each loop&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== PITCH event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PITCH_EVENT_FLAG_VARIATION&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Enable variation&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PITCH_EVENT_FLAG_RELATIVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Use relative values&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PITCH_EVENT_FLAG_FADE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| Enable fade&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== VOLUME event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VOLUME_EVENT_FLAG_VARIATION&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Enable variation&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VOLUME_EVENT_FLAG_RELATIVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Use relative values&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VOLUME_EVENT_FLAG_FADE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| Enable fade&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== LOWPASS event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_LOWPASS_EVENT_FLAG_RANDOM&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Random values&lt;br /&gt;
|-&lt;br /&gt;
| XSB_LOWPASS_EVENT_FLAG_RELATIVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Use relative values&lt;br /&gt;
|-&lt;br /&gt;
| XSB_LOWPASS_EVENT_FLAG_SWEEP&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| Sweep cut-off frequencies&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== MARKER event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_MARKER_EVENT_FLAG_REPEAT&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| Repeat marker&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Enums ==&lt;br /&gt;
&lt;br /&gt;
=== Event types ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;34%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;8%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;56%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_PLAY&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x00&lt;br /&gt;
| Play a wave, from start to finish&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_PLAY_COMPLEX&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x01&lt;br /&gt;
| Play a wave, with parameters&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_STOP&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x03&lt;br /&gt;
| Stop playing&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_PITCH&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Set the pitch&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_VOLUME&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x05&lt;br /&gt;
| Set the volume&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LOWPASS&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x07&lt;br /&gt;
| Low-pass filter&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LFO_PITCH&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x08&lt;br /&gt;
| Low-frequency oscillator on the pitch&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LFO_MULTI&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x09&lt;br /&gt;
| Low-frequency oscillator on the pitch and amplitude&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_ENVELOPE_AMPLITUDE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0A&lt;br /&gt;
| DAHDSR envelope on the amplitude&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_ENVELOPE_PITCH&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0B&lt;br /&gt;
| DAHDSR envelope on the pitch&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LOOP&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0C&lt;br /&gt;
| Loop a wave&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_MARKER&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0E&lt;br /&gt;
| Marker&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_DISABLED&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0F&lt;br /&gt;
| A disabled event&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_MIXBINS&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Set a separate volume for each channel&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_ENVIRONMENT_REVERB&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x11&lt;br /&gt;
| Environmental reverb&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_MIXBINSPAN&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x12&lt;br /&gt;
| Set channel volumes according to a listener orientation&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Variation selection methods ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;44%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;9%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;45%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_RANDOM_NOREPEATS&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x00&lt;br /&gt;
| Random, but no immediate repeats&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_ORDERED&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x01&lt;br /&gt;
| One after the other, in order&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_SHUFFLE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x02&lt;br /&gt;
| Random, no repeats at all&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_PARAMETER&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x03&lt;br /&gt;
| Game-controlled&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_RANDOM&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Completely random&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_ORDERED_FROMRANDOM&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x05&lt;br /&gt;
| Start with a random entry, then in order&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Transition source ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;41%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;9%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;48%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_SOURCE_IMMEDIATE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x00&lt;br /&gt;
| Immediately&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_SOURCE_MARKER&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x01&lt;br /&gt;
| From a marker with a given range&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_SOURCE_RANDOM_MARKER&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x02&lt;br /&gt;
| From a random marker within a given range&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_SOURCE_END_LOOP&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| End of loop&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_SOURCE_END_SOUND&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x08&lt;br /&gt;
| End of sound&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Transition destination ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;45%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;9%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;45%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_DESTINATION_BEGINNING&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x00&lt;br /&gt;
| To the beginning&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_DESTINATION_ALIGNED_TIME&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x01&lt;br /&gt;
| To the same time&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_DESTINATION_ALIGNED_MARKER&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x02&lt;br /&gt;
| To the same marker&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_DESTINATION_MARKER&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| To a marker with a given range&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_DESTINATION_RANDOM_MARKER&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x08&lt;br /&gt;
| To a random marker within a given range&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Transition effect ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;45%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;9%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;45%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_EFFECT_NONE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x00&lt;br /&gt;
| No effect&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_EFFECT_CROSSFADE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x01&lt;br /&gt;
| Crossfade&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_EFFECT_SOUND&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x02&lt;br /&gt;
| Use a transitional sound&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_EFFECT_SOUND_FADE_TO&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x03&lt;br /&gt;
| Fade into a transitional sound&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_EFFECT_SOUND_FADE_FROM&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x06&lt;br /&gt;
| Fade from a transitional sound&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_EFFECT_SOUND_FADE_TOFROM&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x07&lt;br /&gt;
| Fade into and from a transitional sound&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Binary_XACT_SoundBank&amp;diff=434</id>
		<title>Binary XACT SoundBank</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Binary_XACT_SoundBank&amp;diff=434"/>
		<updated>2019-01-06T00:56:46Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is the binary version of the XACT SoundBank (XSB), version 11, as used by Jade Empire on the original Xbox. The Windows PC version of Jade Empire uses an ASCII variant, which contains the same information.&lt;br /&gt;
&lt;br /&gt;
Conceptually, it&#039;s very similar to later XSB versions that are used by Microsoft&#039;s XNA toolset.&lt;br /&gt;
&lt;br /&gt;
On the top-level, a SoundBank consists of cues and sounds. A sound is a collection of tracks, which each contain a list of events and a list of wave variations, while a cue consists of a list of references to sounds.&lt;br /&gt;
&lt;br /&gt;
Both the cue variation and the wave variation can be selected using different methods. For example, they could be played in order, or randomly. Or they could be explicitly selected by game.&lt;br /&gt;
&lt;br /&gt;
== A structural example ==&lt;br /&gt;
&lt;br /&gt;
* Sounds&lt;br /&gt;
** Sound 0&lt;br /&gt;
*** Track 0&lt;br /&gt;
**** Event list&lt;br /&gt;
***** PLAY&lt;br /&gt;
***** LOOP&lt;br /&gt;
***** VOLUME&lt;br /&gt;
***** PITCH&lt;br /&gt;
**** Wave variations&lt;br /&gt;
***** Sound 23 out of WaveBank &amp;amp;quot;foobar&amp;amp;quot;&lt;br /&gt;
***** Sound 24 out of WaveBank &amp;amp;quot;foobar&amp;amp;quot;&lt;br /&gt;
***** Sound 12 out of WaveBank &amp;amp;quot;quux&amp;amp;quot;&lt;br /&gt;
** Sound 1&lt;br /&gt;
*** Track 0&lt;br /&gt;
**** Event list&lt;br /&gt;
***** PLAY&lt;br /&gt;
**** Wave variations&lt;br /&gt;
***** Sound 24 out of WaveBank &amp;amp;quot;foobar&amp;amp;quot;&lt;br /&gt;
*** Track 1&lt;br /&gt;
**** Event list&lt;br /&gt;
***** PLAY&lt;br /&gt;
**** Wave variations&lt;br /&gt;
***** Sound 25 out of WaveBank &amp;amp;quot;foobar&amp;amp;quot;&lt;br /&gt;
* Cues&lt;br /&gt;
** Cue 0&lt;br /&gt;
*** Cue variations&lt;br /&gt;
**** Sound 0&lt;br /&gt;
**** Sound 1&lt;br /&gt;
** Cue 1&lt;br /&gt;
*** Cue variations&lt;br /&gt;
**** Sound 0&lt;br /&gt;
** Cue 2&lt;br /&gt;
*** Cue variations&lt;br /&gt;
**** Sound 1&lt;br /&gt;
&lt;br /&gt;
== Structures ==&lt;br /&gt;
&lt;br /&gt;
All numerical values are little-endian.&lt;br /&gt;
&lt;br /&gt;
=== Header ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| FourCC, &amp;amp;quot;SDBK&amp;amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Version, 11 (0B 00)&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| CRC&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to WaveBank array&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to crossfade parameters array&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to 3D parameters array&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| XSB flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x1A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of sounds (soundCount)&lt;br /&gt;
|-&lt;br /&gt;
| 0x1E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of cues (cueCount)&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x22&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of WaveBanks&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x28&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 16&lt;br /&gt;
| SoundBank name&lt;br /&gt;
|-&lt;br /&gt;
| 0x38&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| cueCount * 20&lt;br /&gt;
| Cue entries&lt;br /&gt;
|-&lt;br /&gt;
| 0x38 + cueCount * 20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| soundCount * 20&lt;br /&gt;
| Sound entries&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== WaveBank entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 16&lt;br /&gt;
| WaveBank file name (without extension)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Cue entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x02&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Sound index (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to name (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to cue variations (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Index into the crossfade parameters array&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Interactive transitions (see below)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Sound index: 0xFFFF if the cue has only one variations.&lt;br /&gt;
&lt;br /&gt;
Offset to name: 0xFFFFFFFF if the cue has no name. Should be ignored if XSB_FLAG_NO_CUE_NAMES is set.&lt;br /&gt;
&lt;br /&gt;
Offset to cue variations: 0xFFFFFFFF if the cue has no variations&lt;br /&gt;
&lt;br /&gt;
Interactive transitions: AAAAAAAAAAAAAAAAAAAAAAAABBBBB???&lt;br /&gt;
&lt;br /&gt;
* A, 24 bits: Offset to the interactive transition definitions&lt;br /&gt;
* B, 5 bits: Trigger variable&lt;br /&gt;
&lt;br /&gt;
=== Sound entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset or indices (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Volume and LFE volume (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Pitch&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Number of tracks&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Layer&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Category&lt;br /&gt;
|-&lt;br /&gt;
| 0x0B&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Index into the 3D parameters array&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Priority&lt;br /&gt;
|-&lt;br /&gt;
| 0x0F&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| I3DL2 volume in 2.56th dB&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Parametric EQ gain in 8192th dB&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| EQ Q and EQ frequency (see below)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Offset or indices: Offset to non-trivial entry, or 2 bytes of wave index and 2 bytes of wavebank index.&lt;br /&gt;
&lt;br /&gt;
Volume and LFE volume: AAAAAAABBBBBBBBB&lt;br /&gt;
&lt;br /&gt;
* A, 7 bits: LFE volume. VolumeLFE = -A * 0.5&lt;br /&gt;
* B, 9 bits: volume: Volume = -B * 0.16&lt;br /&gt;
&lt;br /&gt;
EQ Q and EQ frequency: AAAAAAAAAAAAABBB&lt;br /&gt;
&lt;br /&gt;
* A, 13 bits: EQ frequency&lt;br /&gt;
* B, 3 bits: EQ Q coefficient. Q = 1 / 2^B&lt;br /&gt;
&lt;br /&gt;
=== Simple sound track ===&lt;br /&gt;
&lt;br /&gt;
One track, one PLAY event, multiple wave variations.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Variation parameters (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| variationCount * 4&lt;br /&gt;
| Variation entry (see below)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Variation parameters: AABBBBBBBBBBBBBCCCCDDDDDDDDDDDDD&lt;br /&gt;
&lt;br /&gt;
* A, 2 bits: Flags&lt;br /&gt;
* B, 13 bits: Current variation&lt;br /&gt;
* C, 4 bits: Variation selection method&lt;br /&gt;
* D, 13 bits: Number of variations (variationCount)&lt;br /&gt;
&lt;br /&gt;
Variation entry: 2 bytes of wave index and 2 bytes of wavebank index.&lt;br /&gt;
&lt;br /&gt;
=== Complex sound tracks ===&lt;br /&gt;
&lt;br /&gt;
Multiple tracks or more than just a simple PLAY event.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Number of events&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Offset to event list&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Variation table ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Variation parameters (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| variationCount * 8&lt;br /&gt;
| Variation entry&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Variation parameters: AABBBBBBBBBBBBBCCCCDDDDDDDDDDDDD&lt;br /&gt;
&lt;br /&gt;
* A, 2 bits: Flags&lt;br /&gt;
* B, 13 bits: Current variation&lt;br /&gt;
* C, 4 bits: Variation selection method&lt;br /&gt;
* D, 13 bits: Number of variations (variationCount)&lt;br /&gt;
&lt;br /&gt;
=== Event list entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| ....&lt;br /&gt;
|align=&amp;quot;right&amp;quot;|&lt;br /&gt;
&lt;br /&gt;
| Parameters&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a PLAY event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x00)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x04)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Loop count&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset or indices (see below)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Offset or indices: If XSB_PLAY_EVENT_FLAG_COMPLEX in Flags is set, this is an offset to a wave variation list (see &amp;amp;quot;Simple sound track&amp;amp;quot; above). Otherwise, this is 2 bytes of a sound index followed by 2 bytes of bank index.&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a PLAY_COMPLEX event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x01)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Loop count&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset or indices (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Pitch variation, lower bound&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Pitch variation, upper bound&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Volume variation, lower bound&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Volume variation, upper bound&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Maximum variable sound delay in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x16&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Offset or indices: If XSB_PLAY_EVENT_FLAG_COMPLEX in Flags is set, this is an offset to a wave variation list (see &amp;amp;quot;Simple sound track&amp;amp;quot; above). Otherwise, this is 2 bytes of a sound index followed by 2 bytes of bank index.&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a PITCH event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x04)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x08)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of fade steps&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Pitch, lower bound or starting value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Pitch, upper bound or starting value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Fade duration in milliseconds&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a VOLUME event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x05)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x08)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of fade steps&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Volume, lower bound or starting value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Volume, upper bound or starting value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Fade duration in milliseconds&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a LOWPASS event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x07)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x0C)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Sweep step count&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Cut-off frequency start&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Cut-off frequency end&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Sweep duration&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Resonance start&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Resonance end&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a LFO_PITCH event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x08)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x04)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Delta&lt;br /&gt;
|-&lt;br /&gt;
| 0x0B&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Pitch modulation&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a LFO_MULTI event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x09)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x08)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Delta&lt;br /&gt;
|-&lt;br /&gt;
| 0x0B&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Pitch modulation&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Filter modulation&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Amplitude modulation&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0F&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a ENVELOPE_AMPLITUDE event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x0A)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x0C)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Delay in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Attack in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Hold in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Decay in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Release in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Sustain power&lt;br /&gt;
|-&lt;br /&gt;
| 0x13&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a ENVELOPE_PITCH event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x0B)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Delay in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Attack in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Hold in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Decay in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Release in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Sustain power&lt;br /&gt;
|-&lt;br /&gt;
| 0x13&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x15&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x16&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Pitch scale&lt;br /&gt;
|-&lt;br /&gt;
| 0x17&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Filter cut-off&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a LOOP event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x0C)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x00)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of loops (see below)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Number of loops: 0xFFFF for looping indefinitely.&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a MARKER event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x0E)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x00)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Marker occurrences&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Marker value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Repeat duration in milliseconds&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a MIXBINS event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x20)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 0&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 0&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 2&lt;br /&gt;
|-&lt;br /&gt;
| 0x11&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 2&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 3&lt;br /&gt;
|-&lt;br /&gt;
| 0x15&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x16&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 3&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 4&lt;br /&gt;
|-&lt;br /&gt;
| 0x19&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x1A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 4&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 5&lt;br /&gt;
|-&lt;br /&gt;
| 0x1D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x1E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 5&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 6&lt;br /&gt;
|-&lt;br /&gt;
| 0x21&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x22&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 6&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 7&lt;br /&gt;
|-&lt;br /&gt;
| 0x25&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x26&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 7&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for an ENVIRONMENT_REVERB event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x11)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x30)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Room effect attenuation&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| High-frequency room effect attenuation&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Roll-off factor for the room effect&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Decay time&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| High-frequency to low-frequency decay time ratio&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| (Early) Reflection attenuation&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| (Early) Reflection delay&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| (Late) Reverb attenuation&lt;br /&gt;
|-&lt;br /&gt;
| 0x28&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| (Late) Reverb delay&lt;br /&gt;
|-&lt;br /&gt;
| 0x2C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Diffusion, echo density in (late) reverb decay&lt;br /&gt;
|-&lt;br /&gt;
| 0x30&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Density, modal density in (late) reverb decay&lt;br /&gt;
|-&lt;br /&gt;
| 0x34&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Reference high frequency&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a MIXBINSPAN event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x14)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Speaker configuration (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Angle and flag (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 0&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 0&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x11&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 2&lt;br /&gt;
|-&lt;br /&gt;
| 0x15&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x16&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 2&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 3&lt;br /&gt;
|-&lt;br /&gt;
| 0x19&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x1A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 3&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Speaker configuration: 0 for 5 channels, 1 for 4 channels&lt;br /&gt;
&lt;br /&gt;
Angle and flags: 00000ABBBBBBBBBCCCCCCCCC&lt;br /&gt;
&lt;br /&gt;
* A, 1 bit: If set, use 3D mix bins&lt;br /&gt;
* B, 9 bits: end angle&lt;br /&gt;
* C, 9 bits: start angle&lt;br /&gt;
&lt;br /&gt;
=== Variation entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Sound index&lt;br /&gt;
|-&lt;br /&gt;
| 0x02&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Weight minimum&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Weight maximum&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== 3D parameters entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Inside cone angle&lt;br /&gt;
|-&lt;br /&gt;
| 0x02&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Outside cone angle&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Cone outside volume&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Minimum distance&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Maximum distance&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Distance factor&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Rolloff factor&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Doppler factor&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Mode&lt;br /&gt;
|-&lt;br /&gt;
| 0x1D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Crossfade parameters entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Fade-in time in 10^-7 seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Initial volume&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Type (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x07&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Fade-in step count&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Fade-out time in 10^-7 seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Final volume&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Type (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x0F&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Fade-out step count&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Type: AAAA????&lt;br /&gt;
&lt;br /&gt;
* A, 4 bits: 0 for disabled, 1 for linear, 2 for logarithmic&lt;br /&gt;
&lt;br /&gt;
=== Interactive transitions array ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Number of transitions (transitionCount)&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| transitionCount * 24&lt;br /&gt;
| Transition entry&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
In general, there&#039;s one transition per sound combination (excluding the cases where to and from are the same), plus one set for silence to each sound, plus one set for each sound to silence.&lt;br /&gt;
&lt;br /&gt;
I.e. for N sounds, there&#039;s N^2 - N + 2N, or N^2 + N in shorter, transitions.&lt;br /&gt;
&lt;br /&gt;
The order is as follows:&lt;br /&gt;
&lt;br /&gt;
* Silence -&amp;amp;gt; N_0&lt;br /&gt;
* Silence -&amp;amp;gt; N_1&lt;br /&gt;
* Silence -&amp;amp;gt; N_2&lt;br /&gt;
* ...&lt;br /&gt;
* N_0 -&amp;amp;gt; Silence&lt;br /&gt;
* N_0 -&amp;amp;gt; N_1&lt;br /&gt;
* N_0 -&amp;amp;gt; N_2&lt;br /&gt;
* ...&lt;br /&gt;
* N_1 -&amp;amp;gt; Silence&lt;br /&gt;
* N_1 -&amp;amp;gt; N_0&lt;br /&gt;
* N_1 -&amp;amp;gt; N_2&lt;br /&gt;
* ...&lt;br /&gt;
&lt;br /&gt;
=== Interactive transition entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Flags (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x02&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Transitional sound index&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Source fade-out duration in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Destination fade-in duration in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Source marker, low&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Source marker, high&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Destination marker, low&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Destination marker, high&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Flags: 00000AAAABBBCCCC&lt;br /&gt;
&lt;br /&gt;
* A, 4 bits: Transition source&lt;br /&gt;
* B, 3 bits: Transition effect&lt;br /&gt;
* C, 4 bits: Transition destination&lt;br /&gt;
&lt;br /&gt;
== Flags ==&lt;br /&gt;
&lt;br /&gt;
=== XSB flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;26%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;9%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;64%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_FLAG_NO_CUE_NAMES&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0001&lt;br /&gt;
| If set, cues in the XSB file have no human-readable name&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Cue flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_CUE_FLAG_SEQUENTIAL&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0001&lt;br /&gt;
| If set, cue for sequential playback&lt;br /&gt;
|-&lt;br /&gt;
| XSB_CUE_FLAG_CROSSFADE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0002&lt;br /&gt;
| If set, enable crossfade&lt;br /&gt;
|-&lt;br /&gt;
| XSB_CUE_FLAG_STOPONSTARVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0004&lt;br /&gt;
| If set, stop on starvation&lt;br /&gt;
|-&lt;br /&gt;
| XSB_CUE_FLAG_INTERACTIVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0008&lt;br /&gt;
| If set, the cue is interactive&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Sound flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;25%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;8%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;65%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_3D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x01&lt;br /&gt;
| If set, the sound has 3D parameters&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_GAINBOOST&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x02&lt;br /&gt;
| If set, the sound has a gain boost of 6dB applied&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_EQ&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| If set, the sound has parametric EQ enabled&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_TRIVIAL&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x08&lt;br /&gt;
| Trivial sound: one track, one PLAY event, one wave variation&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_SIMPLE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Simple sound: one track, one PLAY event, multiple wave variations&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_LINGER&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| If set, the sound should linger in an interactive cue&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== PLAY event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;41%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;10%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;48%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PLAY_EVENT_FLAG_COMPLEX&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Complex wave variations definition&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PLAY_EVENT_FLAG_LOOPVARIATION&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x40&lt;br /&gt;
| Select new wave variation on each loop&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== PITCH event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PITCH_EVENT_FLAG_VARIATION&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Enable variation&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PITCH_EVENT_FLAG_RELATIVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Use relative values&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PITCH_EVENT_FLAG_FADE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| Enable fade&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== VOLUME event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VOLUME_EVENT_FLAG_VARIATION&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Enable variation&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VOLUME_EVENT_FLAG_RELATIVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Use relative values&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VOLUME_EVENT_FLAG_FADE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| Enable fade&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== LOWPASS event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_LOWPASS_EVENT_FLAG_RANDOM&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Random values&lt;br /&gt;
|-&lt;br /&gt;
| XSB_LOWPASS_EVENT_FLAG_RELATIVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Use relative values&lt;br /&gt;
|-&lt;br /&gt;
| XSB_LOWPASS_EVENT_FLAG_SWEEP&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| Sweep cut-off frequencies&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== MARKER event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_MARKER_EVENT_FLAG_REPEAT&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| Repeat marker&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Enums ==&lt;br /&gt;
&lt;br /&gt;
=== Event types ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;34%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;8%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;56%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_PLAY&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x00&lt;br /&gt;
| Play a wave, from start to finish&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_PLAY_COMPLEX&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x01&lt;br /&gt;
| Play a wave, with parameters&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_STOP&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x03&lt;br /&gt;
| Stop playing&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_PITCH&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Set the pitch&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_VOLUME&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x05&lt;br /&gt;
| Set the volume&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LOWPASS&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x07&lt;br /&gt;
| Low-pass filter&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LFO_PITCH&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x08&lt;br /&gt;
| Low-frequency oscillator on the pitch&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LFO_MULTI&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x09&lt;br /&gt;
| Low-frequency oscillator on the pitch and amplitude&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_ENVELOPE_AMPLITUDE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0A&lt;br /&gt;
| DAHDSR envelope on the amplitude&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_ENVELOPE_PITCH&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0B&lt;br /&gt;
| DAHDSR envelope on the pitch&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LOOP&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0C&lt;br /&gt;
| Loop a wave&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_MARKER&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0E&lt;br /&gt;
| Marker&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_DISABLED&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0F&lt;br /&gt;
| A disabled event&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_MIXBINS&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Set a separate volume for each channel&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_ENVIRONMENT_REVERB&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x11&lt;br /&gt;
| Environmental reverb&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_MIXBINSPAN&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x12&lt;br /&gt;
| Set channel volumes according to a listener orientation&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Variation selection methods ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;44%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;9%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;45%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_RANDOM_NOREPEATS&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x00&lt;br /&gt;
| Random, but no immediate repeats&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_ORDERED&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x01&lt;br /&gt;
| One after the other, in order&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_SHUFFLE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x02&lt;br /&gt;
| Random, no repeats at all&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_PARAMETER&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x03&lt;br /&gt;
| Game-controlled&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_RANDOM&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Completely random&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_ORDERED_FROMRANDOM&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x05&lt;br /&gt;
| Start with a random entry, then in order&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Transition source ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;41%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;9%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;48%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_SOURCE_IMMEDIATE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x00&lt;br /&gt;
| Immediately&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_SOURCE_MARKER&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x01&lt;br /&gt;
| From a marker with a given range&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_SOURCE_RANDOM_MARKER&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x02&lt;br /&gt;
| From a random marker within a given range&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_SOURCE_END_LOOP&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| End of loop&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_SOURCE_END_SOUND&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x08&lt;br /&gt;
| End of sound&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Transition destination ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;45%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;9%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;45%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_DESTINATION_BEGINNING&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x00&lt;br /&gt;
| To the beginning&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_DESTINATION_ALIGNED_TIME&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x01&lt;br /&gt;
| To the same time&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_DESTINATION_ALIGNED_MARKER&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x02&lt;br /&gt;
| To the same marker&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_DESTINATION_MARKER&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| To a marker with a given range&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_DESTINATION_RANDOM_MARKER&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x08&lt;br /&gt;
| To a random marker within a given range&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Transition effect ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;45%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;9%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;45%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_EFFECT_NONE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x00&lt;br /&gt;
| No effect&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_EFFECT_CROSSFADE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x01&lt;br /&gt;
| Crossfade&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_EFFECT_SOUND&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x02&lt;br /&gt;
| Use a transitional sound&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_EFFECT_SOUND_FADE_TO&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x03&lt;br /&gt;
| Fade into a transitional sound&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_EFFECT_SOUND_FADE_FROM&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x06&lt;br /&gt;
| Fade from a transitional sound&lt;br /&gt;
|-&lt;br /&gt;
| XSB_TRANSITION_EFFECT_SOUND_FADE_TOFROM&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x07&lt;br /&gt;
| Fade into and from a transitional sound&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Binary_XACT_SoundBank&amp;diff=433</id>
		<title>Binary XACT SoundBank</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Binary_XACT_SoundBank&amp;diff=433"/>
		<updated>2019-01-05T16:08:25Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is the binary version of the XACT SoundBank (XSB), version 11, as used by Jade Empire on the original Xbox. The Windows PC version of Jade Empire uses an ASCII variant, which contains the same information.&lt;br /&gt;
&lt;br /&gt;
Conceptually, it&#039;s very similar to later XSB versions that are used by Microsoft&#039;s XNA toolset.&lt;br /&gt;
&lt;br /&gt;
On the top-level, a SoundBank consists of cues and sounds. A sound is a collection of tracks, which each contain a list of events and a list of wave variations, while a cue consists of a list of references to sounds.&lt;br /&gt;
&lt;br /&gt;
Both the cue variation and the wave variation can be selected using different methods. For example, they could be played in order, or randomly. Or they could be explicitly selected by game.&lt;br /&gt;
&lt;br /&gt;
== A structural example ==&lt;br /&gt;
&lt;br /&gt;
* Sounds&lt;br /&gt;
** Sound 0&lt;br /&gt;
*** Track 0&lt;br /&gt;
**** Event list&lt;br /&gt;
***** PLAY&lt;br /&gt;
***** LOOP&lt;br /&gt;
***** VOLUME&lt;br /&gt;
***** PITCH&lt;br /&gt;
**** Wave variations&lt;br /&gt;
***** Sound 23 out of WaveBank &amp;amp;quot;foobar&amp;amp;quot;&lt;br /&gt;
***** Sound 24 out of WaveBank &amp;amp;quot;foobar&amp;amp;quot;&lt;br /&gt;
***** Sound 12 out of WaveBank &amp;amp;quot;quux&amp;amp;quot;&lt;br /&gt;
** Sound 1&lt;br /&gt;
*** Track 0&lt;br /&gt;
**** Event list&lt;br /&gt;
***** PLAY&lt;br /&gt;
**** Wave variations&lt;br /&gt;
***** Sound 24 out of WaveBank &amp;amp;quot;foobar&amp;amp;quot;&lt;br /&gt;
*** Track 1&lt;br /&gt;
**** Event list&lt;br /&gt;
***** PLAY&lt;br /&gt;
**** Wave variations&lt;br /&gt;
***** Sound 25 out of WaveBank &amp;amp;quot;foobar&amp;amp;quot;&lt;br /&gt;
* Cues&lt;br /&gt;
** Cue 0&lt;br /&gt;
*** Cue variations&lt;br /&gt;
**** Sound 0&lt;br /&gt;
**** Sound 1&lt;br /&gt;
** Cue 1&lt;br /&gt;
*** Cue variations&lt;br /&gt;
**** Sound 0&lt;br /&gt;
** Cue 2&lt;br /&gt;
*** Cue variations&lt;br /&gt;
**** Sound 1&lt;br /&gt;
&lt;br /&gt;
== Structures ==&lt;br /&gt;
&lt;br /&gt;
All numerical values are little-endian.&lt;br /&gt;
&lt;br /&gt;
=== Header ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| FourCC, &amp;amp;quot;SDBK&amp;amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Version, 11 (0B 00)&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| CRC&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to WaveBank array&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to 3D parameters array&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| XSB flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x1A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of sounds (soundCount)&lt;br /&gt;
|-&lt;br /&gt;
| 0x1E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of cues (cueCount)&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x22&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of WaveBanks&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x28&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 16&lt;br /&gt;
| SoundBank name&lt;br /&gt;
|-&lt;br /&gt;
| 0x38&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| cueCount * 20&lt;br /&gt;
| Cue entries&lt;br /&gt;
|-&lt;br /&gt;
| 0x38 + cueCount * 20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| soundCount * 20&lt;br /&gt;
| Sound entries&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== WaveBank entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 16&lt;br /&gt;
| WaveBank file name (without extension)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Cue entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x02&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Sound index (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to name (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to cue variations (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Sound index: 0xFFFF if the cue has only one variations.&lt;br /&gt;
&lt;br /&gt;
Offset to name: 0xFFFFFFFF if the cue has no name. Should be ignored if XSB_FLAG_NO_CUE_NAMES is set.&lt;br /&gt;
&lt;br /&gt;
Offset to cue variations: 0xFFFFFFFF if the cue has no variations&lt;br /&gt;
&lt;br /&gt;
=== Sound entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset or indices (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Volume and LFE volume (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Pitch&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Number of tracks&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Layer&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Category&lt;br /&gt;
|-&lt;br /&gt;
| 0x0B&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Index into the 3D parameters array&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Priority&lt;br /&gt;
|-&lt;br /&gt;
| 0x0F&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| I3DL2 volume in 2.56th dB&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Parametric EQ gain in 8192th dB&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| EQ Q and EQ frequency (see below)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Offset or indices: Offset to non-trivial entry, or 2 bytes of wave index and 2 bytes of wavebank index.&lt;br /&gt;
&lt;br /&gt;
Volume and LFE volume: AAAAAAABBBBBBBBB&lt;br /&gt;
&lt;br /&gt;
* A, 7 bits: LFE volume. VolumeLFE = -A * 0.5&lt;br /&gt;
* B, 9 bits: volume: Volume = -B * 0.16&lt;br /&gt;
&lt;br /&gt;
EQ Q and EQ frequency: AAAAAAAAAAAAABBB&lt;br /&gt;
&lt;br /&gt;
* A, 13 bits: EQ frequency&lt;br /&gt;
* B, 3 bits: EQ Q coefficient. Q = 1 / 2^B&lt;br /&gt;
&lt;br /&gt;
=== Simple sound track (one track, one event (PLAY), multiple wave variations) ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Variation parameters (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| variationCount * 4&lt;br /&gt;
| Variation entry (see below)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Variation parameters: AABBBBBBBBBBBBBCCCCDDDDDDDDDDDDD&lt;br /&gt;
&lt;br /&gt;
* A, 2 bits: Flags&lt;br /&gt;
* B, 13 bits: Current variation&lt;br /&gt;
* C, 4 bits: Variation selection method&lt;br /&gt;
* D, 13 bits: Number of variations (variationCount)&lt;br /&gt;
&lt;br /&gt;
Variation entry: 2 bytes of wave index and 2 bytes of wavebank index.&lt;br /&gt;
&lt;br /&gt;
=== Complex sound tracks (multiple tracks or more than just a simple PLAY event) ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Number of events&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Offset to event list&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Variation table ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Variation parameters (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| variationCount * 8&lt;br /&gt;
| Variation entry&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Variation parameters: AABBBBBBBBBBBBBCCCCDDDDDDDDDDDDD&lt;br /&gt;
&lt;br /&gt;
* A, 2 bits: Flags&lt;br /&gt;
* B, 13 bits: Current variation&lt;br /&gt;
* C, 4 bits: Variation selection method&lt;br /&gt;
* D, 13 bits: Number of variations (variationCount)&lt;br /&gt;
&lt;br /&gt;
=== Event list entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| ....&lt;br /&gt;
|align=&amp;quot;right&amp;quot;|&lt;br /&gt;
&lt;br /&gt;
| Parameters&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a PLAY event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x00)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x04)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset or indices (see below)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Offset or indices: If XSB_PLAY_EVENT_FLAG_COMPLEX in Flags is set, this is an offset to a wave variation list (see &amp;amp;quot;Simple sound track&amp;amp;quot; above). Otherwise, this is 2 bytes of a sound index followed by 2 bytes of bank index.&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a PLAY_COMPLEX event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x01)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset or indices (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Pitch variation, lower bound&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Pitch variation, upper bound&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Volume variation, lower bound&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Volume variation, upper bound&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Maximum variable sound delay in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x16&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Offset or indices: If XSB_PLAY_EVENT_FLAG_COMPLEX in Flags is set, this is an offset to a wave variation list (see &amp;amp;quot;Simple sound track&amp;amp;quot; above). Otherwise, this is 2 bytes of a sound index followed by 2 bytes of bank index.&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a PITCH event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x04)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x08)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of fade steps&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Pitch, lower bound or starting value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Pitch, upper bound or starting value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Fade duration in milliseconds&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a VOLUME event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x05)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x08)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of fade steps&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Volume, lower bound or starting value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Volume, upper bound or starting value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Fade duration in milliseconds&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a LOWPASS event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x07)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x0C)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Sweep step count&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Cut-off frequency start&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Cut-off frequency end&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Sweep duration&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Resonance start&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Resonance end&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a LFO_PITCH event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x08)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x04)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Delta&lt;br /&gt;
|-&lt;br /&gt;
| 0x0B&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Pitch modulation&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a LFO_MULTI event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x09)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x08)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Delta&lt;br /&gt;
|-&lt;br /&gt;
| 0x0B&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Pitch modulation&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Filter modulation&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Amplitude modulation&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0F&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a ENVELOPE_AMPLITUDE event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x0A)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x0C)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Delay in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Attack in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Hold in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Decay in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Release in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Sustain power&lt;br /&gt;
|-&lt;br /&gt;
| 0x13&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a ENVELOPE_PITCH event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x0B)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Delay in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Attack in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Hold in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Decay in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Release in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Sustain power&lt;br /&gt;
|-&lt;br /&gt;
| 0x13&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x15&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x16&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Pitch scale&lt;br /&gt;
|-&lt;br /&gt;
| 0x17&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Filter cut-off&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a LOOP event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x0C)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x00)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of loops (see below)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Number of loops: 0xFFFF for looping indefinitely.&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a MARKER event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x0E)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x00)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Marker occurrences&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Marker value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Repeat duration in milliseconds&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a MIXBINS event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x20)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 0&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 0&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 2&lt;br /&gt;
|-&lt;br /&gt;
| 0x11&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 2&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 3&lt;br /&gt;
|-&lt;br /&gt;
| 0x15&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x16&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 3&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 4&lt;br /&gt;
|-&lt;br /&gt;
| 0x19&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x1A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 4&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 5&lt;br /&gt;
|-&lt;br /&gt;
| 0x1D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x1E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 5&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 6&lt;br /&gt;
|-&lt;br /&gt;
| 0x21&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x22&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 6&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 7&lt;br /&gt;
|-&lt;br /&gt;
| 0x25&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x26&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 7&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for an ENVIRONMENT_REVERB event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x11)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x30)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Room effect attenuation&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| High-frequency room effect attenuation&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Roll-off factor for the room effect&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Decay time&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| High-frequency to low-frequency decay time ratio&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| (Early) Reflection attenuation&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| (Early) Reflection delay&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| (Late) Reverb attenuation&lt;br /&gt;
|-&lt;br /&gt;
| 0x28&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| (Late) Reverb delay&lt;br /&gt;
|-&lt;br /&gt;
| 0x2C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Diffusion, echo density in (late) reverb decay&lt;br /&gt;
|-&lt;br /&gt;
| 0x30&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Density, modal density in (late) reverb decay&lt;br /&gt;
|-&lt;br /&gt;
| 0x34&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Reference high frequency&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a MIXBINSPAN event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x14)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Speaker configuration (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Angle and flag (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 0&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 0&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x11&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 2&lt;br /&gt;
|-&lt;br /&gt;
| 0x15&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x16&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 2&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 3&lt;br /&gt;
|-&lt;br /&gt;
| 0x19&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x1A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 3&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Speaker configuration: 0 for 5 channels, 1 for 4 channels&lt;br /&gt;
&lt;br /&gt;
Angle and flags: 00000ABBBBBBBBBCCCCCCCCC&lt;br /&gt;
&lt;br /&gt;
* A, 1 bit: If set, use 3D mix bins&lt;br /&gt;
* B, 9 bits: end angle&lt;br /&gt;
* C, 9 bits: start angle&lt;br /&gt;
&lt;br /&gt;
=== Variation entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Sound index&lt;br /&gt;
|-&lt;br /&gt;
| 0x02&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Weight minimum&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Weight maximum&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== 3D parameters entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Inside cone angle&lt;br /&gt;
|-&lt;br /&gt;
| 0x02&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Outside cone angle&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Cone outside volume&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Minimum distance&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Maximum distance&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Distance factor&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Rolloff factor&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Doppler factor&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Mode&lt;br /&gt;
|-&lt;br /&gt;
| 0x1D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Flags ==&lt;br /&gt;
&lt;br /&gt;
=== XSB flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;26%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;9%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;64%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_FLAG_NO_CUE_NAMES&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0001&lt;br /&gt;
| If set, cues in the XSB file have no human-readable name&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Cue flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_CUE_FLAG_INTERACTIVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0008&lt;br /&gt;
| If set, the cue is interactive&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Sound flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;25%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;8%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;65%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_3D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x01&lt;br /&gt;
| If set, the sound has 3D parameters&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_GAINBOOST&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x02&lt;br /&gt;
| If set, the sound has a gain boost of 6dB applied&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_EQ&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| If set, the sound has parametric EQ enabled&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_TRIVIAL&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x08&lt;br /&gt;
| Trivial sound: one track, one PLAY event, one wave variation&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_SIMPLE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Simple sound: one track, one PLAY event, multiple wave variations&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== PLAY event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PLAY_EVENT_FLAG_COMPLEX&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Complex wave variations definition&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== PITCH event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PITCH_EVENT_FLAG_VARIATION&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Enable variation&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PITCH_EVENT_FLAG_RELATIVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Use relative values&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PITCH_EVENT_FLAG_FADE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| Enable fade&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== VOLUME event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VOLUME_EVENT_FLAG_VARIATION&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Enable variation&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VOLUME_EVENT_FLAG_RELATIVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Use relative values&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VOLUME_EVENT_FLAG_FADE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| Enable fade&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== LOWPASS event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_LOWPASS_EVENT_FLAG_RANDOM&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Random values&lt;br /&gt;
|-&lt;br /&gt;
| XSB_LOWPASS_EVENT_FLAG_RELATIVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Use relative values&lt;br /&gt;
|-&lt;br /&gt;
| XSB_LOWPASS_EVENT_FLAG_SWEEP&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| Sweep cut-off frequencies&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== MARKER event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_MARKER_EVENT_FLAG_REPEAT&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| Repeat marker&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Enums ==&lt;br /&gt;
&lt;br /&gt;
=== Event types ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;34%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;8%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;56%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_PLAY&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x00&lt;br /&gt;
| Play a wave, from start to finish&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_PLAY_COMPLEX&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x01&lt;br /&gt;
| Play a wave, with parameters&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_STOP&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x03&lt;br /&gt;
| Stop playing&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_PITCH&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Set the pitch&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_VOLUME&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x05&lt;br /&gt;
| Set the volume&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LOWPASS&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x07&lt;br /&gt;
| Low-pass filter&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LFO_PITCH&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x08&lt;br /&gt;
| Low-frequency oscillator on the pitch&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LFO_MULTI&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x09&lt;br /&gt;
| Low-frequency oscillator on the pitch and amplitude&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_ENVELOPE_AMPLITUDE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0A&lt;br /&gt;
| DAHDSR envelope on the amplitude&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_ENVELOPE_PITCH&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0B&lt;br /&gt;
| DAHDSR envelope on the pitch&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LOOP&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0C&lt;br /&gt;
| Loop a wave&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_MARKER&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0E&lt;br /&gt;
| Marker&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_DISABLED&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0F&lt;br /&gt;
| A disabled event&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_MIXBINS&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Set a separate volume for each channel&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_ENVIRONMENT_REVERB&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x11&lt;br /&gt;
| Environmental reverb&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_MIXBINSPAN&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x12&lt;br /&gt;
| Set channel volumes according to a listener orientation&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Variation selection methods ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;44%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;9%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;45%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_RANDOM_NOREPEATS&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x00&lt;br /&gt;
| Random, but no immediate repeats&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_ORDERED&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x01&lt;br /&gt;
| One after the other, in order&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_SHUFFLE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x02&lt;br /&gt;
| Random, no repeats at all&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_PARAMETER&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x03&lt;br /&gt;
| Game-controlled&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_RANDOM&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Completely random&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_ORDERED_FROMRANDOM&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x05&lt;br /&gt;
| Start with a random entry, then in order&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Binary_XACT_SoundBank&amp;diff=432</id>
		<title>Binary XACT SoundBank</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Binary_XACT_SoundBank&amp;diff=432"/>
		<updated>2019-01-05T16:06:03Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is the binary version of the XACT SoundBank (XSB), version 11, as used by Jade Empire on the original Xbox. The Windows PC version of Jade Empire uses an ASCII variant, which contains the same information.&lt;br /&gt;
&lt;br /&gt;
Conceptually, it&#039;s very similar to later XSB versions that are used by Microsoft&#039;s XNA toolset.&lt;br /&gt;
&lt;br /&gt;
On the top-level, a SoundBank consists of cues and sounds. A sound is a collection of tracks, which each contain a list of events and a list of wave variations, while a cue consists of a list of references to sounds.&lt;br /&gt;
&lt;br /&gt;
Both the cue variation and the wave variation can be selected using different methods. For example, they could be played in order, or randomly. Or they could be explicitly selected by game.&lt;br /&gt;
&lt;br /&gt;
== A structural example ==&lt;br /&gt;
&lt;br /&gt;
* Sounds&lt;br /&gt;
** Sound 0&lt;br /&gt;
*** Track 0&lt;br /&gt;
**** Event list&lt;br /&gt;
***** PLAY&lt;br /&gt;
***** LOOP&lt;br /&gt;
***** VOLUME&lt;br /&gt;
***** PITCH&lt;br /&gt;
**** Wave variations&lt;br /&gt;
***** Sound 23 out of WaveBank &amp;amp;quot;foobar&amp;amp;quot;&lt;br /&gt;
***** Sound 24 out of WaveBank &amp;amp;quot;foobar&amp;amp;quot;&lt;br /&gt;
***** Sound 12 out of WaveBank &amp;amp;quot;quux&amp;amp;quot;&lt;br /&gt;
** Sound 1&lt;br /&gt;
*** Track 0&lt;br /&gt;
**** Event list&lt;br /&gt;
***** PLAY&lt;br /&gt;
**** Wave variations&lt;br /&gt;
***** Sound 24 out of WaveBank &amp;amp;quot;foobar&amp;amp;quot;&lt;br /&gt;
*** Track 1&lt;br /&gt;
**** Event list&lt;br /&gt;
***** PLAY&lt;br /&gt;
**** Wave variations&lt;br /&gt;
***** Sound 25 out of WaveBank &amp;amp;quot;foobar&amp;amp;quot;&lt;br /&gt;
* Cues&lt;br /&gt;
** Cue 0&lt;br /&gt;
*** Cue variations&lt;br /&gt;
**** Sound 0&lt;br /&gt;
**** Sound 1&lt;br /&gt;
** Cue 1&lt;br /&gt;
*** Cue variations&lt;br /&gt;
**** Sound 0&lt;br /&gt;
** Cue 2&lt;br /&gt;
*** Cue variations&lt;br /&gt;
**** Sound 1&lt;br /&gt;
&lt;br /&gt;
== Structures ==&lt;br /&gt;
&lt;br /&gt;
All numerical values are little-endian.&lt;br /&gt;
&lt;br /&gt;
=== Header ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| FourCC, &amp;amp;quot;SDBK&amp;amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Version, 11 (0B 00)&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| CRC&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to WaveBank array&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to 3D parameters array&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| XSB flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x1A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of sounds (soundCount)&lt;br /&gt;
|-&lt;br /&gt;
| 0x1E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of cues (cueCount)&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x22&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of WaveBanks&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x28&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 16&lt;br /&gt;
| SoundBank name&lt;br /&gt;
|-&lt;br /&gt;
| 0x38&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| cueCount * 20&lt;br /&gt;
| Cue entries&lt;br /&gt;
|-&lt;br /&gt;
| 0x38 + cueCount * 20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| soundCount * 20&lt;br /&gt;
| Sound entries&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== WaveBank entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 16&lt;br /&gt;
| WaveBank file name (without extension)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Cue entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x02&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Sound index (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to name (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to cue variations (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Sound index: 0xFFFF if the cue has only one variations.&lt;br /&gt;
&lt;br /&gt;
Offset to name: 0xFFFFFFFF if the cue has no name. Should be ignored if XSB_FLAG_NO_CUE_NAMES is set.&lt;br /&gt;
&lt;br /&gt;
Offset to cue variations: 0xFFFFFFFF if the cue has no variations&lt;br /&gt;
&lt;br /&gt;
=== Sound entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset or indices (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Volume and LFE volume (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Pitch&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Number of tracks&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Layer&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Category&lt;br /&gt;
|-&lt;br /&gt;
| 0x0B&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Index into the 3D parameters array&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Priority&lt;br /&gt;
|-&lt;br /&gt;
| 0x0F&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| I3DL2 volume in 2.56th dB&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Parametric EQ gain in 8192th dB&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| EQ Q and EQ frequency (see below)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Offset or indices: Offset to non-trivial entry, or 2 bytes of wave index and 2 bytes of wavebank index.&lt;br /&gt;
&lt;br /&gt;
Volume and LFE volume: AAAAAAABBBBBBBBB&lt;br /&gt;
&lt;br /&gt;
* A, 7 bits: LFE volume. VolumeLFE = -A * 0.5&lt;br /&gt;
* B, 9 bits: volume: Volume = -B * 0.16&lt;br /&gt;
&lt;br /&gt;
EQ Q and EQ frequency: AAAAAAAAAAAAABBB&lt;br /&gt;
&lt;br /&gt;
* A, 13 bits: EQ frequency&lt;br /&gt;
* B, 3 bits: EQ Q coefficient. Q = 1 / 2^B&lt;br /&gt;
&lt;br /&gt;
=== Simple sound track (one track, one event (PLAY), multiple wave variations) ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Variation parameters (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| variationCount * 4&lt;br /&gt;
| Variation entry (see below)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Variation parameters: AABBBBBBBBBBBBBCCCCDDDDDDDDDDDDD&lt;br /&gt;
&lt;br /&gt;
* A, 2 bits: Flags&lt;br /&gt;
* B, 13 bits: Current variation&lt;br /&gt;
* C, 4 bits: Variation selection method&lt;br /&gt;
* D, 13 bits: Number of variations (variationCount)&lt;br /&gt;
&lt;br /&gt;
Variation entry: 2 bytes of wave index and 2 bytes of wavebank index.&lt;br /&gt;
&lt;br /&gt;
=== Complex sound tracks (multiple tracks or more than just a simple PLAY event) ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Number of events&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Offset to event list&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Variation table ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Variation parameters (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| variationCount * 8&lt;br /&gt;
| Variation entry&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Variation parameters: AABBBBBBBBBBBBBCCCCDDDDDDDDDDDDD&lt;br /&gt;
&lt;br /&gt;
* A, 2 bits: Flags&lt;br /&gt;
* B, 13 bits: Current variation&lt;br /&gt;
* C, 4 bits: Variation selection method&lt;br /&gt;
* D, 13 bits: Number of variations (variationCount)&lt;br /&gt;
&lt;br /&gt;
=== Event list entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| ....&lt;br /&gt;
|align=&amp;quot;right&amp;quot;|&lt;br /&gt;
&lt;br /&gt;
| Parameters&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a PLAY event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x00)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x04)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset or indices (see below)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Offset or indices: If XSB_PLAY_EVENT_FLAG_COMPLEX in Flags is set, this is an offset to a wave variation list (see &amp;amp;quot;Simple sound track&amp;amp;quot; above). Otherwise, this is 2 bytes of a sound index followed by 2 bytes of bank index.&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a PLAY_COMPLEX event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x01)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset or indices (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| pitch variation, lower bound&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| pitch variation, upper bound&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Volume variation, lower bound&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Volume variation, upper bound&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Maximum variable sound delay in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x16&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Offset or indices: If XSB_PLAY_EVENT_FLAG_COMPLEX in Flags is set, this is an offset to a wave variation list (see &amp;amp;quot;Simple sound track&amp;amp;quot; above). Otherwise, this is 2 bytes of a sound index followed by 2 bytes of bank index.&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a PITCH event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x04)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x08)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of fade steps&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| pitch, lower bound or starting value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| pitch, upper bound or starting value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Fade duration in milliseconds&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a VOLUME event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x05)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x08)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of fade steps&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| volume, lower bound or starting value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| volume, upper bound or starting value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Fade duration in milliseconds&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a LOWPASS event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x07)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x0C)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Sweep step count&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Cut-off frequency start&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Cut-off frequency end&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Sweep duration&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Resonance start&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Resonance end&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a LFO_PITCH event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x08)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x04)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Delta&lt;br /&gt;
|-&lt;br /&gt;
| 0x0B&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Pitch modulation&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a LFO_MULTI event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x09)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x08)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Delta&lt;br /&gt;
|-&lt;br /&gt;
| 0x0B&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Pitch modulation&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Filter modulation&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Amplitude modulation&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0F&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a ENVELOPE_AMPLITUDE event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x0A)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x0C)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Delay in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Attack in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Hold in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Decay in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Release in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Sustain power&lt;br /&gt;
|-&lt;br /&gt;
| 0x13&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a ENVELOPE_PITCH event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x0B)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Delay in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Attack in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Hold in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Decay in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Release in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Sustain power&lt;br /&gt;
|-&lt;br /&gt;
| 0x13&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x15&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x16&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Pitch scale&lt;br /&gt;
|-&lt;br /&gt;
| 0x17&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Filter cut-off&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a LOOP event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x0C)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x00)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of loops (see below)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Number of loops: 0xFFFF for looping indefinitely.&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a MARKER event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x0E)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x00)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Marker occurrences&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Marker value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Repeat duration in milliseconds&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a MIXBINS event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x20)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 0&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 0&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 2&lt;br /&gt;
|-&lt;br /&gt;
| 0x11&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 2&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 3&lt;br /&gt;
|-&lt;br /&gt;
| 0x15&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x16&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 3&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 4&lt;br /&gt;
|-&lt;br /&gt;
| 0x19&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x1A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 4&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 5&lt;br /&gt;
|-&lt;br /&gt;
| 0x1D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x1E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 5&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 6&lt;br /&gt;
|-&lt;br /&gt;
| 0x21&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x22&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 6&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 7&lt;br /&gt;
|-&lt;br /&gt;
| 0x25&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x26&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 7&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for an ENVIRONMENT_REVERB event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x11)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x30)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Room effect attenuation&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| High-frequency room effect attenuation&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Roll-off factor for the room effect&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Decay time&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| High-frequency to low-frequency decay time ratio&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| (Early) Reflection attenuation&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| (Early) Reflection delay&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| (Late) Reverb attenuation&lt;br /&gt;
|-&lt;br /&gt;
| 0x28&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| (Late) Reverb delay&lt;br /&gt;
|-&lt;br /&gt;
| 0x2C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Diffusion, echo density in (late) reverb decay&lt;br /&gt;
|-&lt;br /&gt;
| 0x30&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Density, modal density in (late) reverb decay&lt;br /&gt;
|-&lt;br /&gt;
| 0x34&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Reference high frequency&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a MIXBINSPAN event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x14)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Speaker configuration (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Angle and flag (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 0&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 0&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x11&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 2&lt;br /&gt;
|-&lt;br /&gt;
| 0x15&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x16&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 2&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 3&lt;br /&gt;
|-&lt;br /&gt;
| 0x19&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x1A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 3&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Speaker configuration: 0 for 5 channels, 1 for 4 channels&lt;br /&gt;
&lt;br /&gt;
Angle and flags: 00000ABBBBBBBBBCCCCCCCCC&lt;br /&gt;
&lt;br /&gt;
* A, 1 bit: If set, use 3D mix bins&lt;br /&gt;
* B, 9 bits: end angle&lt;br /&gt;
* C, 9 bits: start angle&lt;br /&gt;
&lt;br /&gt;
=== Variation entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Sound index&lt;br /&gt;
|-&lt;br /&gt;
| 0x02&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Weight minimum&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Weight maximum&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== 3D parameters entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Inside cone angle&lt;br /&gt;
|-&lt;br /&gt;
| 0x02&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Outside cone angle&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Cone outside volume&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| minimum distance&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| maximum distance&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Distance factor&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Rolloff factor&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Doppler factor&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Mode&lt;br /&gt;
|-&lt;br /&gt;
| 0x1D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Flags ==&lt;br /&gt;
&lt;br /&gt;
=== XSB flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;26%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;9%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;64%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_FLAG_NO_CUE_NAMES&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0001&lt;br /&gt;
| If set, cues in the XSB file have no human-readable name&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Cue flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_CUE_FLAG_INTERACTIVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0008&lt;br /&gt;
| If set, the cue is interactive&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Sound flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;25%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;8%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;65%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_3D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x01&lt;br /&gt;
| If set, the sound has 3D parameters&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_GAINBOOST&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x02&lt;br /&gt;
| If set, the sound has a gain boost of 6dB applied&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_EQ&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| If set, the sound has parametric EQ enabled&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_TRIVIAL&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x08&lt;br /&gt;
| Trivial sound: one track, one PLAY event, one wave variation&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_SIMPLE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Simple sound: one track, one PLAY event, multiple wave variations&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== PLAY event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PLAY_EVENT_FLAG_COMPLEX&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Complex wave variations definition&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== PITCH event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PITCH_EVENT_FLAG_VARIATION&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Enable variation&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PITCH_EVENT_FLAG_RELATIVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Use relative values&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PITCH_EVENT_FLAG_FADE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| Enable fade&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== VOLUME event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VOLUME_EVENT_FLAG_VARIATION&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Enable variation&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VOLUME_EVENT_FLAG_RELATIVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Use relative values&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VOLUME_EVENT_FLAG_FADE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| Enable fade&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== LOWPASS event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_LOWPASS_EVENT_FLAG_RANDOM&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Random values&lt;br /&gt;
|-&lt;br /&gt;
| XSB_LOWPASS_EVENT_FLAG_RELATIVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Use relative values&lt;br /&gt;
|-&lt;br /&gt;
| XSB_LOWPASS_EVENT_FLAG_SWEEP&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| Sweep cut-off frequencies&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== MARKER event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_MARKER_EVENT_FLAG_REPEAT&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| Repeat marker&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Enums ==&lt;br /&gt;
&lt;br /&gt;
=== Event types ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;34%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;8%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;56%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_PLAY&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x00&lt;br /&gt;
| Play a wave, from start to finish&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_PLAY_COMPLEX&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x01&lt;br /&gt;
| Play a wave, with parameters&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_STOP&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x03&lt;br /&gt;
| Stop playing&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_PITCH&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Set the pitch&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_VOLUME&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x05&lt;br /&gt;
| Set the volume&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LOWPASS&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x07&lt;br /&gt;
| Low-pass filter&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LFO_PITCH&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x08&lt;br /&gt;
| Low-frequency oscillator on the pitch&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LFO_MULTI&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x09&lt;br /&gt;
| Low-frequency oscillator on the pitch and amplitude&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_ENVELOPE_AMPLITUDE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0A&lt;br /&gt;
| DAHDSR envelope on the amplitude&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_ENVELOPE_PITCH&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0B&lt;br /&gt;
| DAHDSR envelope on the pitch&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LOOP&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0C&lt;br /&gt;
| Loop a wave&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_MARKER&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0E&lt;br /&gt;
| Marker&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_DISABLED&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0F&lt;br /&gt;
| A disabled event&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_MIXBINS&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Set a separate volume for each channel&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_ENVIRONMENT_REVERB&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x11&lt;br /&gt;
| Environmental reverb&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_MIXBINSPAN&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x12&lt;br /&gt;
| Set channel volumes according to a listener orientation&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Variation selection methods ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;44%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;9%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;45%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_RANDOM_NOREPEATS&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x00&lt;br /&gt;
| Random, but no immediate repeats&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_ORDERED&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x01&lt;br /&gt;
| One after the other, in order&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_SHUFFLE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x02&lt;br /&gt;
| Random, no repeats at all&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_PARAMETER&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x03&lt;br /&gt;
| Game-controlled&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_RANDOM&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Completely random&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_ORDERED_FROMRANDOM&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x05&lt;br /&gt;
| Start with a random entry, then in order&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Binary_XACT_SoundBank&amp;diff=431</id>
		<title>Binary XACT SoundBank</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Binary_XACT_SoundBank&amp;diff=431"/>
		<updated>2019-01-05T15:55:08Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is the binary version of the XACT SoundBank (XSB), version 11, as used by Jade Empire on the original Xbox. The Windows PC version of Jade Empire uses an ASCII variant, which contains the same information.&lt;br /&gt;
&lt;br /&gt;
Conceptually, it&#039;s very similar to later XSB versions that are used by Microsoft&#039;s XNA toolset.&lt;br /&gt;
&lt;br /&gt;
On the top-level, a SoundBank consists of cues and sounds. A sound is a collection of tracks, which each contain a list of events and a list of wave variations, while a cue consists of a list of references to sounds.&lt;br /&gt;
&lt;br /&gt;
Both the cue variation and the wave variation can be selected using different methods. For example, they could be played in order, or randomly. Or they could be explicitly selected by game.&lt;br /&gt;
&lt;br /&gt;
== A structural example ==&lt;br /&gt;
&lt;br /&gt;
* Sounds&lt;br /&gt;
** Sound 0&lt;br /&gt;
*** Track 0&lt;br /&gt;
**** Event list&lt;br /&gt;
***** PLAY&lt;br /&gt;
***** LOOP&lt;br /&gt;
***** VOLUME&lt;br /&gt;
***** PITCH&lt;br /&gt;
**** Wave variations&lt;br /&gt;
***** Sound 23 out of WaveBank &amp;amp;quot;foobar&amp;amp;quot;&lt;br /&gt;
***** Sound 24 out of WaveBank &amp;amp;quot;foobar&amp;amp;quot;&lt;br /&gt;
***** Sound 12 out of WaveBank &amp;amp;quot;quux&amp;amp;quot;&lt;br /&gt;
** Sound 1&lt;br /&gt;
*** Track 0&lt;br /&gt;
**** Event list&lt;br /&gt;
***** PLAY&lt;br /&gt;
**** Wave variations&lt;br /&gt;
***** Sound 24 out of WaveBank &amp;amp;quot;foobar&amp;amp;quot;&lt;br /&gt;
*** Track 1&lt;br /&gt;
**** Event list&lt;br /&gt;
***** PLAY&lt;br /&gt;
**** Wave variations&lt;br /&gt;
***** Sound 25 out of WaveBank &amp;amp;quot;foobar&amp;amp;quot;&lt;br /&gt;
* Cues&lt;br /&gt;
** Cue 0&lt;br /&gt;
*** Cue variations&lt;br /&gt;
**** Sound 0&lt;br /&gt;
**** Sound 1&lt;br /&gt;
** Cue 1&lt;br /&gt;
*** Cue variations&lt;br /&gt;
**** Sound 0&lt;br /&gt;
** Cue 2&lt;br /&gt;
*** Cue variations&lt;br /&gt;
**** Sound 1&lt;br /&gt;
&lt;br /&gt;
== Structures ==&lt;br /&gt;
&lt;br /&gt;
All numerical values are little-endian.&lt;br /&gt;
&lt;br /&gt;
=== Header ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| FourCC, &amp;amp;quot;SDBK&amp;amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Version, 11 (0B 00)&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| CRC&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to WaveBank array&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to 3D parameters array&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| XSB flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x1A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of sounds (soundCount)&lt;br /&gt;
|-&lt;br /&gt;
| 0x1E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of cues (cueCount)&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x22&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of WaveBanks&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x28&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 16&lt;br /&gt;
| SoundBank name&lt;br /&gt;
|-&lt;br /&gt;
| 0x38&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| cueCount * 20&lt;br /&gt;
| Cue entries&lt;br /&gt;
|-&lt;br /&gt;
| 0x38 + cueCount * 20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| soundCount * 20&lt;br /&gt;
| Sound entries&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== WaveBank entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 16&lt;br /&gt;
| WaveBank file name (without extension)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Cue entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x02&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Sound index (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to name (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to cue variations (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Sound index: 0xFFFF if the cue has only one variations.&lt;br /&gt;
&lt;br /&gt;
Offset to name: 0xFFFFFFFF if the cue has no name. Should be ignored if XSB_FLAG_NO_CUE_NAMES is set.&lt;br /&gt;
&lt;br /&gt;
Offset to cue variations: 0xFFFFFFFF if the cue has no variations&lt;br /&gt;
&lt;br /&gt;
=== Sound entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset or indices (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Volume&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Pitch&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Number of tracks&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Layer&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Category&lt;br /&gt;
|-&lt;br /&gt;
| 0x0B&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Index into the 3D parameters array&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Priority&lt;br /&gt;
|-&lt;br /&gt;
| 0x0F&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| 3D volume&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| EQ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| EQ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Offset or indices: Offset to non-trivial entry, or 2 bytes of wave index and 2 bytes of wavebank index.&lt;br /&gt;
&lt;br /&gt;
=== Simple sound track (one track, one event (PLAY), multiple wave variations) ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Variation parameters (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| variationCount * 4&lt;br /&gt;
| Variation entry (see below)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Variation parameters: AABBBBBBBBBBBBBCCCCDDDDDDDDDDDDD&lt;br /&gt;
&lt;br /&gt;
* A, 2 bits: Flags&lt;br /&gt;
* B, 13 bits: Current variation&lt;br /&gt;
* C, 4 bits: Variation selection method&lt;br /&gt;
* D, 13 bits: Number of variations (variationCount)&lt;br /&gt;
&lt;br /&gt;
Variation entry: 2 bytes of wave index and 2 bytes of wavebank index.&lt;br /&gt;
&lt;br /&gt;
=== Complex sound tracks (multiple tracks or more than just a simple PLAY event) ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Number of events&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Offset to event list&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Variation table ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Variation parameters (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| variationCount * 8&lt;br /&gt;
| Variation entry&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Variation parameters: AABBBBBBBBBBBBBCCCCDDDDDDDDDDDDD&lt;br /&gt;
&lt;br /&gt;
* A, 2 bits: Flags&lt;br /&gt;
* B, 13 bits: Current variation&lt;br /&gt;
* C, 4 bits: Variation selection method&lt;br /&gt;
* D, 13 bits: Number of variations (variationCount)&lt;br /&gt;
&lt;br /&gt;
=== Event list entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| ....&lt;br /&gt;
|align=&amp;quot;right&amp;quot;|&lt;br /&gt;
&lt;br /&gt;
| Parameters&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a PLAY event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x00)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x04)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset or indices (see below)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Offset or indices: If XSB_PLAY_EVENT_FLAG_COMPLEX in Flags is set, this is an offset to a wave variation list (see &amp;amp;quot;Simple sound track&amp;amp;quot; above). Otherwise, this is 2 bytes of a sound index followed by 2 bytes of bank index.&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a PLAY_COMPLEX event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x01)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset or indices (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| pitch variation, lower bound&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| pitch variation, upper bound&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Volume variation, lower bound&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Volume variation, upper bound&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Maximum variable sound delay in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x16&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Offset or indices: If XSB_PLAY_EVENT_FLAG_COMPLEX in Flags is set, this is an offset to a wave variation list (see &amp;amp;quot;Simple sound track&amp;amp;quot; above). Otherwise, this is 2 bytes of a sound index followed by 2 bytes of bank index.&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a PITCH event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x04)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x08)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of fade steps&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| pitch, lower bound or starting value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| pitch, upper bound or starting value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Fade duration in milliseconds&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a VOLUME event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x05)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x08)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of fade steps&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| volume, lower bound or starting value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| volume, upper bound or starting value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Fade duration in milliseconds&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a LOWPASS event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x07)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x0C)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Sweep step count&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Cut-off frequency start&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Cut-off frequency end&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Sweep duration&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Resonance start&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Resonance end&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a LFO_PITCH event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x08)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x04)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Delta&lt;br /&gt;
|-&lt;br /&gt;
| 0x0B&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Pitch modulation&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a LFO_MULTI event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x09)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x08)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Delta&lt;br /&gt;
|-&lt;br /&gt;
| 0x0B&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Pitch modulation&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Filter modulation&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Amplitude modulation&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0F&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a ENVELOPE_AMPLITUDE event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x0A)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x0C)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Delay in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Attack in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Hold in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Decay in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Release in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Sustain power&lt;br /&gt;
|-&lt;br /&gt;
| 0x13&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a ENVELOPE_PITCH event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x0B)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Delay in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Attack in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Hold in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Decay in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Release in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Sustain power&lt;br /&gt;
|-&lt;br /&gt;
| 0x13&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x15&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x16&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Pitch scale&lt;br /&gt;
|-&lt;br /&gt;
| 0x17&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Filter cut-off&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a LOOP event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x0C)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x00)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of loops (see below)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Number of loops: 0xFFFF for looping indefinitely.&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a MARKER event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x0E)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x00)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Marker occurrences&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Marker value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Repeat duration in milliseconds&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a MIXBINS event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x20)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 0&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 0&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 2&lt;br /&gt;
|-&lt;br /&gt;
| 0x11&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 2&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 3&lt;br /&gt;
|-&lt;br /&gt;
| 0x15&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x16&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 3&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 4&lt;br /&gt;
|-&lt;br /&gt;
| 0x19&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x1A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 4&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 5&lt;br /&gt;
|-&lt;br /&gt;
| 0x1D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x1E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 5&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 6&lt;br /&gt;
|-&lt;br /&gt;
| 0x21&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x22&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 6&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 7&lt;br /&gt;
|-&lt;br /&gt;
| 0x25&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x26&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 7&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for an ENVIRONMENT_REVERB event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x11)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x30)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Room effect attenuation&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| High-frequency room effect attenuation&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Roll-off factor for the room effect&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Decay time&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| High-frequency to low-frequency decay time ratio&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| (Early) Reflection attenuation&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| (Early) Reflection delay&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| (Late) Reverb attenuation&lt;br /&gt;
|-&lt;br /&gt;
| 0x28&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| (Late) Reverb delay&lt;br /&gt;
|-&lt;br /&gt;
| 0x2C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Diffusion, echo density in (late) reverb decay&lt;br /&gt;
|-&lt;br /&gt;
| 0x30&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Density, modal density in (late) reverb decay&lt;br /&gt;
|-&lt;br /&gt;
| 0x34&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Reference high frequency&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a MIXBINSPAN event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x14)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Speaker configuration (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Angle and flag (see below)&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 0&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 0&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x11&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 2&lt;br /&gt;
|-&lt;br /&gt;
| 0x15&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x16&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 2&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 3&lt;br /&gt;
|-&lt;br /&gt;
| 0x19&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x1A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 3&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Speaker configuration: 0 for 5 channels, 1 for 4 channels&lt;br /&gt;
&lt;br /&gt;
Angle and flags: 00000ABBBBBBBBBCCCCCCCCC&lt;br /&gt;
&lt;br /&gt;
* A, 1 bit: If set, use 3D mix bins&lt;br /&gt;
* B, 9 bits: end angle&lt;br /&gt;
* C, 9 bits: start angle&lt;br /&gt;
&lt;br /&gt;
=== Variation entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Sound index&lt;br /&gt;
|-&lt;br /&gt;
| 0x02&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Weight minimum&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Weight maximum&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== 3D parameters entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Inside cone angle&lt;br /&gt;
|-&lt;br /&gt;
| 0x02&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Outside cone angle&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Cone outside volume&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| minimum distance&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| maximum distance&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Distance factor&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Rolloff factor&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Doppler factor&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Mode&lt;br /&gt;
|-&lt;br /&gt;
| 0x1D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Flags ==&lt;br /&gt;
&lt;br /&gt;
=== XSB flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;26%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;9%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;64%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_FLAG_NO_CUE_NAMES&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0001&lt;br /&gt;
| If set, cues in the XSB file have no human-readable name&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Cue flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_CUE_FLAG_INTERACTIVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0008&lt;br /&gt;
| If set, the cue is interactive&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Sound flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;25%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;8%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;65%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_3D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x01&lt;br /&gt;
| If set, the sound has 3D parameters&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_GAINBOOST&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x02&lt;br /&gt;
| If set, the sound has a gain boost of 6dB applied&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_EQ&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| If set, the sound has parametric EQ enabled&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_TRIVIAL&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x08&lt;br /&gt;
| Trivial sound: one track, one PLAY event, one wave variation&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_SIMPLE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Simple sound: one track, one PLAY event, multiple wave variations&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== PLAY event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PLAY_EVENT_FLAG_COMPLEX&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Complex wave variations definition&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== PITCH event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PITCH_EVENT_FLAG_VARIATION&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Enable variation&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PITCH_EVENT_FLAG_RELATIVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Use relative values&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PITCH_EVENT_FLAG_FADE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| Enable fade&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== VOLUME event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VOLUME_EVENT_FLAG_VARIATION&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Enable variation&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VOLUME_EVENT_FLAG_RELATIVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Use relative values&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VOLUME_EVENT_FLAG_FADE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| Enable fade&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== LOWPASS event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_LOWPASS_EVENT_FLAG_RANDOM&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Random values&lt;br /&gt;
|-&lt;br /&gt;
| XSB_LOWPASS_EVENT_FLAG_RELATIVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Use relative values&lt;br /&gt;
|-&lt;br /&gt;
| XSB_LOWPASS_EVENT_FLAG_SWEEP&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| Sweep cut-off frequencies&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== MARKER event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_MARKER_EVENT_FLAG_REPEAT&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| Repeat marker&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Enums ==&lt;br /&gt;
&lt;br /&gt;
=== Event types ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;34%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;8%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;56%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_PLAY&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x00&lt;br /&gt;
| Play a wave, from start to finish&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_PLAY_COMPLEX&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x01&lt;br /&gt;
| Play a wave, with parameters&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_STOP&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x03&lt;br /&gt;
| Stop playing&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_PITCH&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Set the pitch&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_VOLUME&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x05&lt;br /&gt;
| Set the volume&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LOWPASS&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x07&lt;br /&gt;
| Low-pass filter&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LFO_PITCH&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x08&lt;br /&gt;
| Low-frequency oscillator on the pitch&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LFO_MULTI&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x09&lt;br /&gt;
| Low-frequency oscillator on the pitch and amplitude&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_ENVELOPE_AMPLITUDE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0A&lt;br /&gt;
| DAHDSR envelope on the amplitude&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_ENVELOPE_PITCH&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0B&lt;br /&gt;
| DAHDSR envelope on the pitch&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LOOP&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0C&lt;br /&gt;
| Loop a wave&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_MARKER&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0E&lt;br /&gt;
| Marker&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_DISABLED&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0F&lt;br /&gt;
| A disabled event&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_MIXBINS&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Set a separate volume for each channel&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_ENVIRONMENT_REVERB&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x11&lt;br /&gt;
| Environmental reverb&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_MIXBINSPAN&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x12&lt;br /&gt;
| Set channel volumes according to a listener orientation&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Variation selection methods ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;44%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;9%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;45%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_RANDOM_NOREPEATS&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x00&lt;br /&gt;
| Random, but no immediate repeats&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_ORDERED&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x01&lt;br /&gt;
| One after the other, in order&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_SHUFFLE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x02&lt;br /&gt;
| Random, no repeats at all&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_PARAMETER&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x03&lt;br /&gt;
| Game-controlled&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_RANDOM&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Completely random&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_ORDERED_FROMRANDOM&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x05&lt;br /&gt;
| Start with a random entry, then in order&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Binary_XACT_SoundBank&amp;diff=430</id>
		<title>Binary XACT SoundBank</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Binary_XACT_SoundBank&amp;diff=430"/>
		<updated>2019-01-05T15:22:30Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is the binary version of the XACT SoundBank (XSB), version 11, as used by Jade Empire on the original Xbox. The Windows PC version of Jade Empire uses an ASCII variant, which contains the same information.&lt;br /&gt;
&lt;br /&gt;
Conceptually, it&#039;s very similar to later XSB versions that are used by Microsoft&#039;s XNA toolset.&lt;br /&gt;
&lt;br /&gt;
On the top-level, a SoundBank consists of cues and sounds. A sound is a collection of tracks, which each contain a list of events and a list of wave variations, while a cue consists of a list of references to sounds.&lt;br /&gt;
&lt;br /&gt;
== A structural example ==&lt;br /&gt;
&lt;br /&gt;
* Sounds&lt;br /&gt;
** Sound 0&lt;br /&gt;
*** Track 0&lt;br /&gt;
**** Event list&lt;br /&gt;
***** PLAY&lt;br /&gt;
***** LOOP&lt;br /&gt;
***** VOLUME&lt;br /&gt;
***** PITCH&lt;br /&gt;
**** Wave variations&lt;br /&gt;
***** Sound 23 out of WaveBank &amp;amp;quot;foobar&amp;amp;quot;&lt;br /&gt;
***** Sound 24 out of WaveBank &amp;amp;quot;foobar&amp;amp;quot;&lt;br /&gt;
***** Sound 12 out of WaveBank &amp;amp;quot;quux&amp;amp;quot;&lt;br /&gt;
** Sound 1&lt;br /&gt;
*** Track 0&lt;br /&gt;
**** Event list&lt;br /&gt;
***** PLAY&lt;br /&gt;
**** Wave variations&lt;br /&gt;
***** Sound 24 out of WaveBank &amp;amp;quot;foobar&amp;amp;quot;&lt;br /&gt;
*** Track 1&lt;br /&gt;
**** Event list&lt;br /&gt;
***** PLAY&lt;br /&gt;
**** Wave variations&lt;br /&gt;
***** Sound 25 out of WaveBank &amp;amp;quot;foobar&amp;amp;quot;&lt;br /&gt;
* Cues&lt;br /&gt;
** Cue 0&lt;br /&gt;
*** Cue variations&lt;br /&gt;
**** Sound 0&lt;br /&gt;
**** Sound 1&lt;br /&gt;
** Cue 1&lt;br /&gt;
*** Cue variations&lt;br /&gt;
**** Sound 0&lt;br /&gt;
** Cue 2&lt;br /&gt;
*** Cue variations&lt;br /&gt;
**** Sound 1&lt;br /&gt;
&lt;br /&gt;
Both the cue variation and the wave variation can be selected using different methods. For example, they could be played in order, or randomly. Or they could be explicitly selected by game.&lt;br /&gt;
&lt;br /&gt;
== Structures ==&lt;br /&gt;
&lt;br /&gt;
All numerical values are little-endian.&lt;br /&gt;
&lt;br /&gt;
=== Header ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| FourCC, &amp;amp;quot;SDBK&amp;amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Version, 11 (0B 00)&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| CRC&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to WaveBank array&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to 3D parameters array&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| XSB flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x1A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of sounds (soundCount)&lt;br /&gt;
|-&lt;br /&gt;
| 0x1E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of cues (cueCount)&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x22&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of WaveBanks&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x28&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 16&lt;br /&gt;
| SoundBank name&lt;br /&gt;
|-&lt;br /&gt;
| 0x38&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| cueCount * 20&lt;br /&gt;
| Cue entries&lt;br /&gt;
|-&lt;br /&gt;
| 0x38 + cueCount * 20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| soundCount * 20&lt;br /&gt;
| Sound entries&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== WaveBank entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 16&lt;br /&gt;
| WaveBank file name (without extension)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Cue entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;10%&amp;quot;| Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;5%&amp;quot;| Size&lt;br /&gt;
!width=&amp;quot;85%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x02&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Sound index, if the cue has only one variation. 0xFFFF otherwise&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to name. 0xFFFFFFFF if the cue has no name. Should be ignored if XSB_FLAG_NO_CUE_NAMES is set&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to cue variations. 0xFFFFFFFF if the cue has no variations&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Sound entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;10%&amp;quot;| Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;5%&amp;quot;| Size&lt;br /&gt;
!width=&amp;quot;85%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Offset to non-trivial entry, or 2 bytes of wave index and 2 bytes of wavebank index&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Volume&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Pitch&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Number of tracks&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Layer&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Category&lt;br /&gt;
|-&lt;br /&gt;
| 0x0B&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Index into the 3D parameters array&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Priority&lt;br /&gt;
|-&lt;br /&gt;
| 0x0F&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| 3D volume&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| EQ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| EQ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Simple sound track ===&lt;br /&gt;
&lt;br /&gt;
One track, one event (PLAY), multiple wave variations.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;10%&amp;quot;| Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;20%&amp;quot;| Size&lt;br /&gt;
!width=&amp;quot;80%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4 ||&lt;br /&gt;
* 13 bits: Number of variations (variationCount)&lt;br /&gt;
* 4 bits: Variation selection method&lt;br /&gt;
* 13 bits: Current variation&lt;br /&gt;
* 2 bits: Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| variationCount * 4&lt;br /&gt;
| Variation entry (2 bytes of wave index and 2 bytes of wavebank index)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Complex sound tracks ===&lt;br /&gt;
&lt;br /&gt;
Multiple tracks or more than just a simple PLAY even.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Number of events&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Offset to event list&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Variation table ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4 ||&lt;br /&gt;
* 13 bits: Number of variations (variationCount)&lt;br /&gt;
* 4 bits: Variation selection method&lt;br /&gt;
* 13 bits: Current variation&lt;br /&gt;
* 2 bits: Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| variationCount * 8&lt;br /&gt;
| Variation entry&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Event list entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| ....&lt;br /&gt;
|align=&amp;quot;right&amp;quot;|&lt;br /&gt;
&lt;br /&gt;
| Parameters&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a PLAY event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x00)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x04)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| If XSB_PLAY_EVENT_FLAG_COMPLEX in Flags is set, this is an offset to a wave variation list (see &amp;amp;quot;Simple sound track&amp;amp;quot; above). Otherwise, this is 2 bytes of a sound index followed by 2 bytes of bank index&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a PLAY_COMPLEX event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;10%&amp;quot;| Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;5%&amp;quot;| Size&lt;br /&gt;
!width=&amp;quot;85%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x01)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| If XSB_PLAY_EVENT_FLAG_COMPLEX in Flags is set, this is an offset to a wave variation list (see &amp;amp;quot;Simple sound track&amp;amp;quot; above). Otherwise, this is 2 bytes of a sound index followed by 2 bytes of bank index&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| pitch variation, lower bound&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| pitch variation, upper bound&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Volume variation, lower bound&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Volume variation, upper bound&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Maximum variable sound delay in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x16&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| (Part of the?) Decay time parameter of the Environmental Reverb event (?!?)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a PITCH event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x04)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x08)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of fade steps&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| pitch, lower bound or starting value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| pitch, upper bound or starting value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Fade duration in milliseconds&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a VOLUME event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x05)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x08)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of fade steps&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| volume, lower bound or starting value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| volume, upper bound or starting value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Fade duration in milliseconds&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a LOWPASS event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x07)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x0C)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Sweep step count&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Cut-off frequency start&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Cut-off frequency end&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Sweep duration&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Resonance start&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Resonance end&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a LFO_PITCH event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x08)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x04)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Delta&lt;br /&gt;
|-&lt;br /&gt;
| 0x0B&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Pitch modulation&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a LFO_MULTI event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x09)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x08)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Delta&lt;br /&gt;
|-&lt;br /&gt;
| 0x0B&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Pitch modulation&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Filter modulation&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Amplitude modulation&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0F&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a ENVELOPE_AMPLITUDE event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x0A)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x0C)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Delay in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Attack in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Hold in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Decay in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Release in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Sustain power&lt;br /&gt;
|-&lt;br /&gt;
| 0x13&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a ENVELOPE_PITCH event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x0B)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Delay in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Attack in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Hold in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Decay in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Release in seconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Sustain power&lt;br /&gt;
|-&lt;br /&gt;
| 0x13&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x15&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x16&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Pitch scale&lt;br /&gt;
|-&lt;br /&gt;
| 0x17&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Filter cut-off&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a LOOP event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x0C)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x00)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Number of loops. 0xFFFF for looping indefinitely&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a MARKER event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x0E)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x00)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Marker occurrences&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Marker value&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Repeat duration in milliseconds&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a MIXBINS event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x20)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 0&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 0&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 2&lt;br /&gt;
|-&lt;br /&gt;
| 0x11&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 2&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 3&lt;br /&gt;
|-&lt;br /&gt;
| 0x15&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x16&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 3&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 4&lt;br /&gt;
|-&lt;br /&gt;
| 0x19&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x1A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 4&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 5&lt;br /&gt;
|-&lt;br /&gt;
| 0x1D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x1E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 5&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 6&lt;br /&gt;
|-&lt;br /&gt;
| 0x21&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x22&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 6&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 7&lt;br /&gt;
|-&lt;br /&gt;
| 0x25&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x26&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 7&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for an ENVIRONMENT_REVERB event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x11)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x30)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Room effect attenuation&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| High-frequency room effect attenuation&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Roll-off factor for the room effect&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Decay time&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| High-frequency to low-frequency decay time ratio&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| (Early) Reflection attenuation&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| (Early) Reflection delay&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| (Late) Reverb attenuation&lt;br /&gt;
|-&lt;br /&gt;
| 0x28&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| (Late) Reverb delay&lt;br /&gt;
|-&lt;br /&gt;
| 0x2C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Diffusion, echo density in (late) reverb decay&lt;br /&gt;
|-&lt;br /&gt;
| 0x30&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Density, modal density in (late) reverb decay&lt;br /&gt;
|-&lt;br /&gt;
| 0x34&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Reference high frequency&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Event list entry for a MIXBINSPAN event ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;10%&amp;quot;| Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;5%&amp;quot;| Size&lt;br /&gt;
!width=&amp;quot;85%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Event type (= 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| Timestamp in milliseconds&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Parameter size in bytes (= 0x14)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Speaker configuration (0: 5-channels, 1: 4-channels)&lt;br /&gt;
|-&lt;br /&gt;
| 0x09&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 3&lt;br /&gt;
| 00000 A BBBBBBBBB CCCCCCCCC (A = 3D, B = end angle, C = start angle)&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 0&lt;br /&gt;
|-&lt;br /&gt;
| 0x0D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 0&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x11&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x12&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 1&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 2&lt;br /&gt;
|-&lt;br /&gt;
| 0x15&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x16&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 2&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Channel index 3&lt;br /&gt;
|-&lt;br /&gt;
| 0x19&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x1A&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Channel volume 3&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Variation entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Sound index&lt;br /&gt;
|-&lt;br /&gt;
| 0x02&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Weight minimum&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Weight maximum&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== 3D parameters entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Inside cone angle&lt;br /&gt;
|-&lt;br /&gt;
| 0x02&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Outside cone angle&lt;br /&gt;
|-&lt;br /&gt;
| 0x04&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| Cone outside volume&lt;br /&gt;
|-&lt;br /&gt;
| 0x06&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 2&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| minimum distance&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| maximum distance&lt;br /&gt;
|-&lt;br /&gt;
| 0x10&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Distance factor&lt;br /&gt;
|-&lt;br /&gt;
| 0x14&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Rolloff factor&lt;br /&gt;
|-&lt;br /&gt;
| 0x18&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| Doppler factor&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 1&lt;br /&gt;
| Mode&lt;br /&gt;
|-&lt;br /&gt;
| 0x1D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x20&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x24&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 4&lt;br /&gt;
| ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Flags ==&lt;br /&gt;
&lt;br /&gt;
=== XSB flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;30%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;5%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;65%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_FLAG_NO_CUE_NAMES&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0001&lt;br /&gt;
| If set, cues in the XSB file have no human-readable name&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Cue flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_CUE_FLAG_INTERACTIVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0008&lt;br /&gt;
| If set, the cue is interactive&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Sound flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;30%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;5%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;65%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_3D&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x01&lt;br /&gt;
| If set, the sound has 3D parameters&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_GAINBOOST&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x02&lt;br /&gt;
| If set, the sound has a gain boost of 6dB applied&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_EQ&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| If set, the sound has parametric EQ enabled&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_TRIVIAL&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x08&lt;br /&gt;
| If set, the sound only has one track, one event (PLAY) and one wave variation&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_SIMPLE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| If set, the sound only has one track, one event (PLAY), but multiple wave variations&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== PLAY event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PLAY_EVENT_FLAG_COMPLEX&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Complex wave variations definition&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== PITCH event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PITCH_EVENT_FLAG_VARIATION&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Enable variation&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PITCH_EVENT_FLAG_RELATIVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Use relative values&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PITCH_EVENT_FLAG_FADE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| Enable fade&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== VOLUME event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VOLUME_EVENT_FLAG_VARIATION&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Enable variation&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VOLUME_EVENT_FLAG_RELATIVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Use relative values&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VOLUME_EVENT_FLAG_FADE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| Enable fade&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== LOWPASS event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_LOWPASS_EVENT_FLAG_RANDOM&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Random values&lt;br /&gt;
|-&lt;br /&gt;
| XSB_LOWPASS_EVENT_FLAG_RELATIVE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Use relative values&lt;br /&gt;
|-&lt;br /&gt;
| XSB_LOWPASS_EVENT_FLAG_SWEEP&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| Sweep cut-off frequencies&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== MARKER event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot;| Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_MARKER_EVENT_FLAG_REPEAT&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x20&lt;br /&gt;
| Repeat marker&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Enums ==&lt;br /&gt;
&lt;br /&gt;
=== Event types ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;30%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;5%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;65%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_PLAY&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x00&lt;br /&gt;
| Play a wave, from start to finish&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_PLAY_COMPLEX&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x01&lt;br /&gt;
| Play a wave, with parameters&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_STOP&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x03&lt;br /&gt;
| Stop playing&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_PITCH&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Set the pitch&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_VOLUME&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x05&lt;br /&gt;
| Set the volume&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LOWPASS&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x07&lt;br /&gt;
| Low-pass filter&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LFO_PITCH&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x08&lt;br /&gt;
| Low-frequency oscillator on the pitch&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LFO_MULTI&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x09&lt;br /&gt;
| Low-frequency oscillator on the pitch and amplitude&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_ENVELOPE_AMPLITUDE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0A&lt;br /&gt;
| DAHDSR envelope on the amplitude&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_ENVELOPE_PITCH&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0B&lt;br /&gt;
| DAHDSR envelope on the pitch&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LOOP&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0C&lt;br /&gt;
| Loop a wave&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_MARKER&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0E&lt;br /&gt;
| Marker&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_DISABLED&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x0F&lt;br /&gt;
| A disabled event&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_MIXBINS&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x10&lt;br /&gt;
| Set a separate volume for each channel&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_ENVIRONMENT_REVERB&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x11&lt;br /&gt;
| Environmental reverb&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_MIXBINSPAN&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x12&lt;br /&gt;
| Set channel volumes according to a listener orientation&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Variation selection methods ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!width=&amp;quot;30%&amp;quot;| Name&lt;br /&gt;
!align=&amp;quot;right&amp;quot; width=&amp;quot;5%&amp;quot;| Value&lt;br /&gt;
!width=&amp;quot;65%&amp;quot;| Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_RANDOM_NOREPEATS&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x00&lt;br /&gt;
| Random, but no immediate repeats&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_ORDERED&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x01&lt;br /&gt;
| One after the other, in order&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_SHUFFLE&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x02&lt;br /&gt;
| Random, no repeats at all&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_PARAMETER&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x03&lt;br /&gt;
| Game-controlled&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_RANDOM&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x04&lt;br /&gt;
| Completely random&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_ORDERED_FROMRANDOM&lt;br /&gt;
|align=&amp;quot;right&amp;quot;| 0x05&lt;br /&gt;
| Start with a random entry, then in order&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Jade_Empire/Research&amp;diff=429</id>
		<title>Jade Empire/Research</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Jade_Empire/Research&amp;diff=429"/>
		<updated>2018-12-28T23:55:19Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* Audio */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
== Archives ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
! Type&lt;br /&gt;
! Documentation&lt;br /&gt;
! Status&lt;br /&gt;
|-&lt;br /&gt;
|chitin.key&amp;lt;br/&amp;gt;artcreatures.bif&amp;lt;br/&amp;gt;audio.bif&amp;lt;br/&amp;gt;designer.bif&lt;br /&gt;
|indexed Key Biff&lt;br /&gt;
| style=&amp;quot;text-align: center;&amp;quot; |[https://github.com/xoreos/xoreos-docs/raw/master/specs/bioware/KeyBIF_Format.pdf KeyBIF_Format.pdf]&lt;br /&gt;
| style=&amp;quot;background-color: green;&amp;quot; |supported&lt;br /&gt;
|-&lt;br /&gt;
|*.rim&lt;br /&gt;
|Rim file&lt;br /&gt;
|&lt;br /&gt;
| style=&amp;quot;background-color: green;&amp;quot; |supported&lt;br /&gt;
|-&lt;br /&gt;
|*.mod&lt;br /&gt;
|ERF file&lt;br /&gt;
| style=&amp;quot;text-align: center;&amp;quot; |[https://github.com/xoreos/xoreos-docs/raw/master/specs/bioware/ERF_Format.pdf ERF_Format.pdf]&lt;br /&gt;
| style=&amp;quot;background-color: green;&amp;quot; |supported&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Resource files ==&lt;br /&gt;
&lt;br /&gt;
=== Areas, Rooms and Placeables ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Extension&lt;br /&gt;
! Type ID&lt;br /&gt;
! Type description/Usage&lt;br /&gt;
!Format&lt;br /&gt;
! Documentation&lt;br /&gt;
! Status&lt;br /&gt;
|-&lt;br /&gt;
|are || 2012 || static area information || gff || [https://github.com/xoreos/xoreos-docs/raw/master/specs/bioware/AreaFile_Format.pdf AreaFile_Format.pdf]&lt;br /&gt;
| style=&amp;quot;background-color: yellow;&amp;quot; | only layout value used&lt;br /&gt;
|-&lt;br /&gt;
|sav || 2057 || objects descriptions in area || gff ||&lt;br /&gt;
| style=&amp;quot;background-color: yellow;&amp;quot; | partially loaded&lt;br /&gt;
|-&lt;br /&gt;
|lyt || 3000 || area rooms layout || text || &lt;br /&gt;
| style=&amp;quot;background-color: yellow;&amp;quot; |&lt;br /&gt;
|-&lt;br /&gt;
|vis || 3001 || area rooms visibility graph || text || &lt;br /&gt;
| style=&amp;quot;background-color: yellow;&amp;quot; |&lt;br /&gt;
|-&lt;br /&gt;
|hex || 3015 || area hexgrid definition || text ||  &lt;br /&gt;
| style=&amp;quot;background-color: red;&amp;quot; | unsupported&lt;br /&gt;
|-&lt;br /&gt;
|art || 3023 || area environment properties || ini file || &lt;br /&gt;
| style=&amp;quot;background-color: red;&amp;quot; | unsupported&lt;br /&gt;
|-&lt;br /&gt;
|cwa || 3025 || crowd attributes || gff || &lt;br /&gt;
| style=&amp;quot;background-color: red;&amp;quot; | unsupported&lt;br /&gt;
|-&lt;br /&gt;
|pla || 2043 || placeable definition || gff ||&lt;br /&gt;
| style=&amp;quot;background-color: yellow;&amp;quot; |&lt;br /&gt;
|-&lt;br /&gt;
|pwk || 2053 || placeable walk mesh definition || text ||&lt;br /&gt;
| style=&amp;quot;background-color: red;&amp;quot; | unsupported&lt;br /&gt;
|-&lt;br /&gt;
|fsm || 3022 || placeable state data || gff ||&lt;br /&gt;
| style=&amp;quot;background-color: yellow;&amp;quot; |&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Models, Textures and Materials ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Extension&lt;br /&gt;
! Type ID&lt;br /&gt;
! Type description/Usage&lt;br /&gt;
! Format&lt;br /&gt;
! Documentation&lt;br /&gt;
! Status&lt;br /&gt;
|-&lt;br /&gt;
|bmp || 1 || bitmap image || binary || ||&lt;br /&gt;
|-&lt;br /&gt;
|tga || 3 || targa image || binary || ||&lt;br /&gt;
|-&lt;br /&gt;
|mdl || 2002 || model definition || binary || ||&lt;br /&gt;
|-&lt;br /&gt;
|mdx || 3008 || model raw data || binary || ||&lt;br /&gt;
|-&lt;br /&gt;
|txi || 2022|| texture information || text || ||&lt;br /&gt;
|-&lt;br /&gt;
|txb || 3006 || texture data || binary || ||&lt;br /&gt;
|-&lt;br /&gt;
|tpc || 3007 || texture data || binary || ||&lt;br /&gt;
|-&lt;br /&gt;
|mat || 2069 || material definition || text || ||&lt;br /&gt;
|-&lt;br /&gt;
|mab || 3011 || material definition || binary || ||&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Scripting and Triggers ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Extension&lt;br /&gt;
! Type ID&lt;br /&gt;
! Type description/Usage&lt;br /&gt;
! Format&lt;br /&gt;
! Documentation&lt;br /&gt;
! Status&lt;br /&gt;
|-&lt;br /&gt;
|nss || 2009 || nwscript source script || text || || not used&lt;br /&gt;
|-&lt;br /&gt;
|ncs || 2010 || compiled script || binary || ||&lt;br /&gt;
|-&lt;br /&gt;
|ndb || 2064 || script debug info || binary || || not used&lt;br /&gt;
|-&lt;br /&gt;
|trg || 2031 || trigger definition || gff || [https://github.com/xoreos/xoreos-docs/raw/master/specs/bioware/Trigger_Format.pdf Trigger_Format.pdf] ||&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Quests, Texts and Dialogues ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Extension&lt;br /&gt;
! Type ID&lt;br /&gt;
! Type description/Usage&lt;br /&gt;
! Format&lt;br /&gt;
! Documentation&lt;br /&gt;
! Status&lt;br /&gt;
|-&lt;br /&gt;
|tlk || 2018 || string definitions || talk table || [https://github.com/xoreos/xoreos-docs/raw/master/specs/bioware/TalkTable_Format.pdf TalkTable_Format.pdf] ||&lt;br /&gt;
|-&lt;br /&gt;
|dlg || 2029 || dialog definition || gff || [https://github.com/xoreos/xoreos-docs/raw/master/specs/bioware/Conversation_Format.pdf Conversation_Format.pdf] ||&lt;br /&gt;
|-&lt;br /&gt;
|qst || 2084 || quest definition || gff ||&lt;br /&gt;
|-&lt;br /&gt;
|bip || 3028 || lipsynch data || binary || ||&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GUI ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Extension&lt;br /&gt;
! Type ID&lt;br /&gt;
! Type description/Usage&lt;br /&gt;
! Format&lt;br /&gt;
! Documentation&lt;br /&gt;
! Status&lt;br /&gt;
|-&lt;br /&gt;
|gui || 2047 || dialog definition || gff || ||&lt;br /&gt;
|-&lt;br /&gt;
|abc || 24003 || font definition || binary || ||&lt;br /&gt;
|-&lt;br /&gt;
|sbm || 24004 || font bitmap || binary || ||&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Static Properties ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Extension&lt;br /&gt;
! Type ID&lt;br /&gt;
! Type description/Usage&lt;br /&gt;
! Format&lt;br /&gt;
! Documentation&lt;br /&gt;
! Status&lt;br /&gt;
|-&lt;br /&gt;
|ini || 7 || ini file || text || ||&lt;br /&gt;
|-&lt;br /&gt;
|txt || 10 || sound info(*_xwb.txt und *_xsb.txt) und mini game data (mg*.txt) || text || ||&lt;br /&gt;
|-&lt;br /&gt;
|2da || 2017 || static data tables || 2da || [https://github.com/xoreos/xoreos-docs/raw/master/specs/bioware/2DA_Format.pdf 2DA_Format.pdf] ||&lt;br /&gt;
|-&lt;br /&gt;
|gff || 2037 || generic gff file || gff || ||&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Others ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Extension&lt;br /&gt;
! Type ID&lt;br /&gt;
! Type description/Usage&lt;br /&gt;
! Format&lt;br /&gt;
! Documentation&lt;br /&gt;
! Status&lt;br /&gt;
|-&lt;br /&gt;
|ttc || 2073 || minigame resources || binary || ||&lt;br /&gt;
|-&lt;br /&gt;
|bik || 2063 || prerendered video || bink || ||&lt;br /&gt;
|-&lt;br /&gt;
|ogg || 2078 || prerendered audio || ogg/vorbis || ||&lt;br /&gt;
|-&lt;br /&gt;
|sto || 3013 || store definition || gff || [https://github.com/xoreos/xoreos-docs/raw/master/specs/bioware/Store_Format.pdf Store_Format.pdf] ||&lt;br /&gt;
|-&lt;br /&gt;
|amp || 3024 || brightening control || binary || ||&lt;br /&gt;
|-&lt;br /&gt;
|cre || 2026 || creature definition || gff || ||&lt;br /&gt;
|-&lt;br /&gt;
|pso || 24001 || pixel shader object || binary || ||&lt;br /&gt;
|-&lt;br /&gt;
|vso || 24002 || vertex shader object|| binary || ||&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Unknown ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Extension&lt;br /&gt;
! Type ID&lt;br /&gt;
! Type description/Usage&lt;br /&gt;
! Documentation&lt;br /&gt;
! Status&lt;br /&gt;
|-&lt;br /&gt;
|wma || 11 || wma file || ||&lt;br /&gt;
|-&lt;br /&gt;
|pvd || 24005 || pvd file || ||&lt;br /&gt;
|-&lt;br /&gt;
|pk || 24009 || pk file || ||&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== 2DA files ==&lt;br /&gt;
&lt;br /&gt;
=== 2DA lists ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
! Usage&lt;br /&gt;
! Status&lt;br /&gt;
|-&lt;br /&gt;
| 2das.2da || indexed list of all 2da files including excel generation info || style=&amp;quot;background-color: green;&amp;quot; | supported&lt;br /&gt;
|-&lt;br /&gt;
| scriptlist.2da || foreign key reference to 2das.2da whose index is used by scripts || style=&amp;quot;background-color: green;&amp;quot; | supported&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GUI ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
! Usage&lt;br /&gt;
! Status&lt;br /&gt;
|-&lt;br /&gt;
| books.2da || contains info to all the bookstands you can read in the game || style=&amp;quot;background-color: red;&amp;quot; | unsupported&lt;br /&gt;
|-&lt;br /&gt;
| jdk_players.2da || stats of all player characters (demo content) || style=&amp;quot;background-color: red;&amp;quot; | unsupported&lt;br /&gt;
|-&lt;br /&gt;
| players.2da || stats of all player characters || style=&amp;quot;background-color: red;&amp;quot; | unsupported&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Styles ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
! Usage&lt;br /&gt;
! Status&lt;br /&gt;
|-&lt;br /&gt;
| areaofeffect.2da || area effects || style=&amp;quot;background-color: red;&amp;quot; | unsupported&lt;br /&gt;
|-&lt;br /&gt;
| spells.2da || spell effects || style=&amp;quot;background-color: red;&amp;quot; | unsupported&lt;br /&gt;
|-&lt;br /&gt;
| styleadvance.2da || level up data || style=&amp;quot;background-color: red;&amp;quot; | unsupported&lt;br /&gt;
|-&lt;br /&gt;
| stylecost.2da || transformation style costs || style=&amp;quot;background-color: red;&amp;quot; | unsupported&lt;br /&gt;
|-&lt;br /&gt;
| styledata.2da || style 2da table references || style=&amp;quot;background-color: red;&amp;quot; | unsupported&lt;br /&gt;
|-&lt;br /&gt;
| stylepoints.2da || style points per level || style=&amp;quot;background-color: red;&amp;quot; | unsupported&lt;br /&gt;
|-&lt;br /&gt;
| stylesuperlist.2da || style numbers and models || style=&amp;quot;background-color: red;&amp;quot; | unsupported&lt;br /&gt;
|-&lt;br /&gt;
| styletypes.2da || gui icons || style=&amp;quot;background-color: red;&amp;quot; | unsupported&lt;br /&gt;
|-&lt;br /&gt;
| transformation.2da || tranformation style numbers || style=&amp;quot;background-color: red;&amp;quot; | unsupported&lt;br /&gt;
|-&lt;br /&gt;
| *as.2da || style animation and sound table || style=&amp;quot;background-color: red;&amp;quot; | unsupported&lt;br /&gt;
|-&lt;br /&gt;
| *cs.2da || style cutscene movement table || style=&amp;quot;background-color: red;&amp;quot; | unsupported&lt;br /&gt;
|-&lt;br /&gt;
| *lv.2da || style level up table || style=&amp;quot;background-color: red;&amp;quot; | unsupported&lt;br /&gt;
|-&lt;br /&gt;
| *mv.2da || style movement table || style=&amp;quot;background-color: red;&amp;quot; | unsupported&lt;br /&gt;
|-&lt;br /&gt;
| centipede.2da || special centipede style data || style=&amp;quot;background-color: red;&amp;quot; | unsupported&lt;br /&gt;
|-&lt;br /&gt;
| drunken.2da || special drunken style data || style=&amp;quot;background-color: red;&amp;quot; | unsupported&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== GUI ==&lt;br /&gt;
&lt;br /&gt;
* Layout defined in the .gui resources in Gff3 format&lt;br /&gt;
* lti_&amp;lt;dialogname&amp;gt; layouts have been created for the PC version for mouse control&lt;br /&gt;
* Fullscreen dialogs are of size 640x480&lt;br /&gt;
* coordinate system is 2D, (0,0) is the upper left corner&lt;br /&gt;
* GUI is stretched to screen size&lt;br /&gt;
&lt;br /&gt;
== Models ==&lt;br /&gt;
&lt;br /&gt;
=== Vertex layout ===&lt;br /&gt;
&lt;br /&gt;
The vertex layout is described in a mesh node&#039;s mesh header and if included the skin header.&lt;br /&gt;
&lt;br /&gt;
The mesh header contains information to draw the model or part of it.&lt;br /&gt;
&lt;br /&gt;
The skin header contains bone information to animate the model.&lt;br /&gt;
&lt;br /&gt;
[https://gist.github.com/farmboy0/87d9d6b88613ccd899b8 model description (WIP)]&lt;br /&gt;
&lt;br /&gt;
== Audio ==&lt;br /&gt;
&lt;br /&gt;
Audio files and properties are described via XACT wave banks and sound banks.&lt;br /&gt;
&lt;br /&gt;
Wave bank are simple lists of sound files that are referenced by their position in the list.&lt;br /&gt;
&lt;br /&gt;
Sound banks describe sounds and sound cues. Sounds contain references to wave bank entries as well as their play properties, while sound cues&lt;br /&gt;
are used to group different sounds together with information about how to choose between them when playing a sound cue.&lt;br /&gt;
&lt;br /&gt;
In the Xbox version, the wave banks and sound banks are in their original binary format (XWB and [https://wiki.xoreos.org/index.php?title=Binary_XACT_SoundBank XSB]). In the Windows PC version, they are stored in an ASCII format, as described below.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Sound bank files are organized like this:&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;Sound bank name&amp;gt;&lt;br /&gt;
 &amp;lt;Number of Categories&amp;gt;&lt;br /&gt;
 &amp;lt;Categories, one per line&amp;gt;&lt;br /&gt;
 &amp;lt;Number of sounds&amp;gt;&lt;br /&gt;
 &amp;lt;Sounds, variable amount of lines per sound&amp;gt;&lt;br /&gt;
 &amp;lt;Number of sound cues&amp;gt;&lt;br /&gt;
 &amp;lt;Sound cues, variable amount of lines per sound cue&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Each sound looks like this:&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;Sound description line&amp;gt;&lt;br /&gt;
 &amp;lt;Play properties, at most one of each of the following lines: 3D AEG LOOP LPF MARKER MFLFO PEQ PITCH PLAY VOLUME&amp;gt;&lt;br /&gt;
 &amp;lt;Number of wave bank entries&amp;gt;&lt;br /&gt;
 &amp;lt;One line per Wave bank entry&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Each sound cue looks like this:&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;Sound cue description&amp;gt;&lt;br /&gt;
 &amp;lt;Number of sound entries&amp;gt;&lt;br /&gt;
 &amp;lt;One line per sound entry&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;for music sound cues also these lines:&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;Number of transition lines = number sound entries * (number sound entries + 1)&amp;gt;&lt;br /&gt;
 &amp;lt;transition lines describe the transition between 2 sounds in the same cue since only one sound will play (except for some overlap between sounds)&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Sounds ===&lt;br /&gt;
&lt;br /&gt;
==== sound description line ====&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Line Token&lt;br /&gt;
! 1&lt;br /&gt;
! 2&lt;br /&gt;
! 3&lt;br /&gt;
! 4&lt;br /&gt;
! 5&lt;br /&gt;
! 6&lt;br /&gt;
! 7&lt;br /&gt;
! 8&lt;br /&gt;
! 9&lt;br /&gt;
! 10&lt;br /&gt;
! 11&lt;br /&gt;
|-&lt;br /&gt;
| Example || &amp;quot;al_nat_pool&amp;quot; || &amp;quot;1&amp;quot; || 1 || 1 || -2425 || -1 || -770 || 0 || 1 || 0 || 0&lt;br /&gt;
|-&lt;br /&gt;
| Description || sound name || note probably describing category || 0 or 1, boolean || 0 or 1, boolean || -6400 - 0 || -4975 - 450 || -1898 - 2400 || 0 or 127 || 0 or 1, boolean || -1500 - 0 || -6400 - 0&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== 3D properties ====&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Line Token&lt;br /&gt;
! 1&lt;br /&gt;
! 2&lt;br /&gt;
! 3&lt;br /&gt;
! 4&lt;br /&gt;
! 5&lt;br /&gt;
! 6&lt;br /&gt;
! 7&lt;br /&gt;
! 8&lt;br /&gt;
! 9&lt;br /&gt;
! 10&lt;br /&gt;
! 11&lt;br /&gt;
|-&lt;br /&gt;
| Example || 3D || 0 || 360 || 360 || 0 || 6.000000 || 27.000000 || 1.000000 || 7.000000 || 1.000000 || 0&lt;br /&gt;
|-&lt;br /&gt;
| Description || prop id || always 0 || always 360 || always 360 || always 0 || 1.000000 - 500.000000 || 10.000000 - 1000000000.000000 || always 1.000000 || 0.000000 - 363.000000 || 1.000000, 5.000000 or 10.000000 || 0, 0.750000, 0.782780, 0.803270 or 1.000000&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Sound cues ===&lt;br /&gt;
&lt;br /&gt;
==== sound cue line ====&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Line Token&lt;br /&gt;
! 1&lt;br /&gt;
! 2&lt;br /&gt;
! 3&lt;br /&gt;
! 4&lt;br /&gt;
! 5&lt;br /&gt;
|-&lt;br /&gt;
| Example || &amp;quot;j08_cut_drag_e&amp;quot; || 0 || 0 || 0 || 0&lt;br /&gt;
|-&lt;br /&gt;
| Description || sound cue name || 0, 1, 2, 3 or 4 play variation type || 0 or 1, boolean || always 0 || 0 or 1, boolean&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== sound entry line ====&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Line Token&lt;br /&gt;
! 1&lt;br /&gt;
! 2&lt;br /&gt;
! 3&lt;br /&gt;
! 4&lt;br /&gt;
|-&lt;br /&gt;
| Example || &amp;quot;j08_cut_drag_e&amp;quot; || 37 || 0 || 0&lt;br /&gt;
|-&lt;br /&gt;
| Description || sound name || sound list index || value depends on variation type || value depends on variation type&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Binary_XACT_SoundBank&amp;diff=428</id>
		<title>Binary XACT SoundBank</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Binary_XACT_SoundBank&amp;diff=428"/>
		<updated>2018-12-28T23:52:08Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: Created page with &amp;quot;This is the binary version of the XACT SoundBank (XSB), version 11, as used by Jade Empire on the original Xbox. The Windows PC version of Jade Empire uses an ASCII variant, w...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is the binary version of the XACT SoundBank (XSB), version 11, as used by Jade Empire on the original Xbox. The Windows PC version of Jade Empire uses an ASCII variant, which contains the same information.&lt;br /&gt;
&lt;br /&gt;
Conceptually, it&#039;s very similar to later XSB versions that are used by Microsoft&#039;s XNA toolset.&lt;br /&gt;
&lt;br /&gt;
On the top-level, a SoundBank consists of cues and sounds. A sound is a collection of tracks, which each contain a list of events and a list of wave variations, while a cue consists of a list of references to sounds.&lt;br /&gt;
&lt;br /&gt;
A structural example:&lt;br /&gt;
&lt;br /&gt;
* Sounds&lt;br /&gt;
** Sound 0&lt;br /&gt;
*** Track 0&lt;br /&gt;
**** Event list&lt;br /&gt;
***** PLAY&lt;br /&gt;
***** LOOP&lt;br /&gt;
***** VOLUME&lt;br /&gt;
***** PITCH&lt;br /&gt;
**** Wave variations&lt;br /&gt;
***** Sound 23 out of WaveBank &amp;quot;foobar&amp;quot;&lt;br /&gt;
***** Sound 24 out of WaveBank &amp;quot;foobar&amp;quot;&lt;br /&gt;
***** Sound 12 out of WaveBank &amp;quot;quux&amp;quot;&lt;br /&gt;
** Sound 1&lt;br /&gt;
*** Track 0&lt;br /&gt;
**** Event list&lt;br /&gt;
***** PLAY&lt;br /&gt;
**** Wave variations&lt;br /&gt;
***** Sound 24 out of WaveBank &amp;quot;foobar&amp;quot;&lt;br /&gt;
*** Track 1&lt;br /&gt;
**** Event list&lt;br /&gt;
***** PLAY&lt;br /&gt;
**** Wave variations&lt;br /&gt;
***** Sound 25 out of WaveBank &amp;quot;foobar&amp;quot;&lt;br /&gt;
* Cues&lt;br /&gt;
** Cue 0&lt;br /&gt;
*** Cue variations&lt;br /&gt;
**** Sound 0&lt;br /&gt;
**** Sound 1&lt;br /&gt;
** Cue 1&lt;br /&gt;
*** Cue variations&lt;br /&gt;
**** Sound 0&lt;br /&gt;
** Cue 2&lt;br /&gt;
*** Cue variations&lt;br /&gt;
**** Sound 1&lt;br /&gt;
&lt;br /&gt;
Both the cue variation and the wave variation can be selected using different methods. For example, they could be played in order, or randomly. Or they could be explicitly selected by game.&lt;br /&gt;
&lt;br /&gt;
== Structures ==&lt;br /&gt;
&lt;br /&gt;
All numerical values are little-endian.&lt;br /&gt;
&lt;br /&gt;
=== Header ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
! Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
|0x00 || 4 || FourCC, &amp;quot;SDBK&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|0x04 || 2 || Version, 11 (0B 00)&lt;br /&gt;
|-&lt;br /&gt;
|0x06 || 2 || CRC&lt;br /&gt;
|-&lt;br /&gt;
|0x08 || 4 || Offset to WaveBank array&lt;br /&gt;
|-&lt;br /&gt;
|0x0C || 4 || Offset to ?&lt;br /&gt;
|-&lt;br /&gt;
|0x10 || 4 || Offset to 3D parameters array&lt;br /&gt;
|-&lt;br /&gt;
|0x14 || 4 || Offset to ?&lt;br /&gt;
|-&lt;br /&gt;
|0x18 || 2 || XSB flags&lt;br /&gt;
|-&lt;br /&gt;
|0x1A || 2 || Number of ?&lt;br /&gt;
|-&lt;br /&gt;
|0x1C || 2 || Number of sounds (soundCount)&lt;br /&gt;
|-&lt;br /&gt;
|0x1E || 2 || Number of cues (cueCount)&lt;br /&gt;
|-&lt;br /&gt;
|0x20 || 2 || Number of ?&lt;br /&gt;
|-&lt;br /&gt;
|0x22 || 2 || Number of WaveBanks&lt;br /&gt;
|-&lt;br /&gt;
|0x24 || 4 || ?&lt;br /&gt;
|-&lt;br /&gt;
|0x28 || 16 || SoundBank name&lt;br /&gt;
|-&lt;br /&gt;
|0x38 || cueCount * 20 || Cue entries&lt;br /&gt;
|-&lt;br /&gt;
|0x38 + cueCount * 20 || soundCount * 20 || Sound entries&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== WaveBank entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
! Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00 || 16 || WaveBank file name (without extension)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Cue entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
! Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00 || 2 || Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x02 || 2 || Sound index, if the cue has only one variation. 0xFFFF otherwise&lt;br /&gt;
|-&lt;br /&gt;
| 0x04 || 4 || Offset to name. 0xFFFFFFFF if the cue has no name. Should be ignored if XSB_FLAG_NO_CUE_NAMES is set&lt;br /&gt;
|-&lt;br /&gt;
| 0x08 || 4 || Offset to variations. 0xFFFFFFFF if the sound has no variations&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C || 4 || ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x10 || 4 || ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Sound entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
! Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00 || 4 || Offset to non-trivial entry, or 2 bytes of wave index and 2 bytes of wavebank index&lt;br /&gt;
|-&lt;br /&gt;
| 0x04 || 2 || Volume&lt;br /&gt;
|-&lt;br /&gt;
| 0x06 || 2 || Pitch&lt;br /&gt;
|-&lt;br /&gt;
| 0x08 || 1 || Number of tracks&lt;br /&gt;
|-&lt;br /&gt;
| 0x09 || 1 || Layer&lt;br /&gt;
|-&lt;br /&gt;
| 0x0A || 1 || Category&lt;br /&gt;
|-&lt;br /&gt;
| 0x0B || 1 || Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C || 2 || Index into the 3D parameters array&lt;br /&gt;
|-&lt;br /&gt;
| 0x0E || 1 || Priority&lt;br /&gt;
|-&lt;br /&gt;
| 0x0F || 1 || 3D volume&lt;br /&gt;
|-&lt;br /&gt;
| 0x10 || 2 || EQ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x12 || 2 || EQ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Simple sound track (one track, one event (PLAY), multiple wave variations) ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
! Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00 || 4 ||&lt;br /&gt;
* 13 bits: Number of variations (variationCount)&lt;br /&gt;
* 4 bits: Variation selection method&lt;br /&gt;
* 13 bits: Current variation&lt;br /&gt;
* 2 bits: Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x04 || variationCount * 4 || Variation entry (2 bytes of wave index and 2 bytes of wavebank index)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Complex sound tracks (multiple tracks or more than just a simple PLAY event) ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
! Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00 || 1 || Number of events&lt;br /&gt;
|-&lt;br /&gt;
| 0x01 || 3 || Offset to event list&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Variation table ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
! Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00 || 4 ||&lt;br /&gt;
* 13 bits: Number of variations (variationCount)&lt;br /&gt;
* 4 bits: Variation selection method&lt;br /&gt;
* 13 bits: Current variation&lt;br /&gt;
* 2 bits: Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x04 || variationCount * 8 || Variation entry&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Event list entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
! Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00 || 1 || Event type&lt;br /&gt;
|-&lt;br /&gt;
| 0x01 || 3 || ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x04 || 1 || Parameter size in bytes&lt;br /&gt;
|-&lt;br /&gt;
| 0x05 || 1 || Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06 || 2 || ?&lt;br /&gt;
|-&lt;br /&gt;
| .... || || Parameters&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Event list entry for a PLAY or PLAY_COMPLEX event ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
! Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00 || 1 || Event type (= 0x00 or 0x01)&lt;br /&gt;
|-&lt;br /&gt;
| 0x01 || 3 || ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x04 || 1 || Parameter size in bytes (= 0x04 or 0x10)&lt;br /&gt;
|-&lt;br /&gt;
| 0x05 || 1 || Flags&lt;br /&gt;
|-&lt;br /&gt;
| 0x06 || 2 || ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08 || 4 || If XSB_PLAY_EVENT_FLAG_COMPLEX in Flags is set, this is an offset to a wave variation list (see &amp;quot;Simple sound track&amp;quot; above). Otherwise, this is 2 bytes of a sound index followed by 2 bytes of bank index.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Variation entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
! Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00 || 2 || Sound index&lt;br /&gt;
|-&lt;br /&gt;
| 0x02 || 2 || ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x04 || 2 || Weight minimum&lt;br /&gt;
|-&lt;br /&gt;
| 0x06 || 2 || Weight maximum&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== 3D parameters entry ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Offset&lt;br /&gt;
! Size&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| 0x00 || 2 || Inside cone angle&lt;br /&gt;
|-&lt;br /&gt;
| 0x02 || 2 || Outside cone angle&lt;br /&gt;
|-&lt;br /&gt;
| 0x04 || 2 || Cone outside volume&lt;br /&gt;
|-&lt;br /&gt;
| 0x06 || 2 || ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x08 || 4 || minimum distance&lt;br /&gt;
|-&lt;br /&gt;
| 0x0C || 4 || maximum distance&lt;br /&gt;
|-&lt;br /&gt;
| 0x10 || 4 || Distance factor&lt;br /&gt;
|-&lt;br /&gt;
| 0x14 || 4 || Rolloff factor&lt;br /&gt;
|-&lt;br /&gt;
| 0x18 || 4 || Doppler factor&lt;br /&gt;
|-&lt;br /&gt;
| 0x1C || 1 || Mode&lt;br /&gt;
|-&lt;br /&gt;
| 0x1D || 4 || ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x20 || 4 || ?&lt;br /&gt;
|-&lt;br /&gt;
| 0x24 || 4 || ?&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Flags ==&lt;br /&gt;
&lt;br /&gt;
=== XSB flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
! Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_FLAG_NO_CUE_NAMES || 0x0001 || If set, cues in the XSB file have no human-readable name&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Cue flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
! Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_CUE_FLAG_INTERACTIVE || 0x0008 || If set, the cue is interactive&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Sound flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
! Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_3D      ||   0x01 || If set, the sound has 3D parameters&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_TRIVIAL ||   0x08 || If set, the sound only has one track, one event (PLAY) and one wave variation&lt;br /&gt;
|-&lt;br /&gt;
| XSB_SOUND_FLAG_SIMPLE  ||   0x10 || If set, the sound only has one track, one event (PLAY), but multiple wave variations&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== PLAY event flags ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
! Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_PLAY_EVENT_FLAG_COMPLEX       ||   0x04 || Complex wave variations definition&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Enums ==&lt;br /&gt;
&lt;br /&gt;
=== Event types ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
! Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_PLAY               ||   0x00 || Play a wave, from start to finish&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_PLAY_COMPLEX       ||   0x01 || Play a wave, with parameters&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_STOP               ||   0x03 || Stop playing&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_PITCH              ||   0x04 || Set the pitch&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_VOLUME             ||   0x05 || Set the volume&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LOWPASS            ||   0x07 || Low-pass filter&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LFO_PITCH          ||   0x08 || Low-frequency oscillator on the pitch&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LFO_MULTI          ||   0x09 || Low-frequency oscillator on the pitch and amplitude&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_ENVELOPE_AMPLITUDE ||   0x0A || DAHDSR envelope on the amplitude&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_ENVELOPE_PITCH     ||   0x0B || DAHDSR envelope on the pitch&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_LOOP               ||   0x0C || Loop a wave&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_MARKER             ||   0x0E || Marker&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_DISABLED           ||   0x0F || A disabled event&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_MIXBINS            ||   0x10 || Set a separate volume for each channel&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_ENVIRONMENT_REVERB ||   0x11 || Environmental reverb&lt;br /&gt;
|-&lt;br /&gt;
| XSB_EVENT_TYPE_MIXBINSPAN         ||   0x12 || Set channel volumes according to a listener orientation&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Variation selection methods ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name&lt;br /&gt;
! Value&lt;br /&gt;
! Description&lt;br /&gt;
|-&lt;br /&gt;
| XSB_VARIATION_SELECT_PARAMETER    ||   0x03 || Parameter-controlled&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Code_Formatting_Conventions&amp;diff=427</id>
		<title>Code Formatting Conventions</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Code_Formatting_Conventions&amp;diff=427"/>
		<updated>2018-10-07T14:17:29Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* C++ Standard */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;Note:&#039;&#039;&#039; These are mostly the [http://wiki.scummvm.org/index.php/Code_Formatting_Conventions ScummVM code formatting conventions], with some minor changes.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Use common sense ==&lt;br /&gt;
&lt;br /&gt;
These are conventions which we try to follow when writing code for xoreos. Sticking to a common set of formatting / indention rules makes it easier to read through our source base (which now exceed half a million lines of code by far, making this quite important). If you want to submit patches, please try to adhere to these rules.&lt;br /&gt;
&lt;br /&gt;
We don&#039;t always follow these rules slavishly, in certain cases it is OK (and in fact might be favorable) to stray from them. Applying common sense, as usual, is a good idea.&lt;br /&gt;
&lt;br /&gt;
In the following examples tabs are replaced by spaces for visual consistency with the Code Formatting Conventions. But in actual code, use tabs for indentations (our tabs are assumed to be 4 spaces wide).&lt;br /&gt;
&lt;br /&gt;
== C++ Standard ==&lt;br /&gt;
&lt;br /&gt;
Among the three main repositories, xoreos, xoreos-tools and Phaethon, we&#039;re following three different versions of the C++ standard.&lt;br /&gt;
&lt;br /&gt;
* xoreos itself follows the oldest standard for now, C++03&lt;br /&gt;
* xoreos-tools follows the C++11 standard&lt;br /&gt;
* Phaethon follows the C++14 standard, due to the reliance on the relaxed constexpr rules in [https://woboq.com/blog/verdigris-qt-without-moc.html Verdigris]&lt;br /&gt;
&lt;br /&gt;
With xoreos-tools, we&#039;re currently in a C++11 trial period. If everything goes well, we&#039;re opening xoreos for C++11 as well.&lt;br /&gt;
&lt;br /&gt;
== Hugging braces ==&lt;br /&gt;
&lt;br /&gt;
Braces in your code should look like the following example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
for (int i = 0; i &amp;lt; t; i++) {&lt;br /&gt;
    [...]&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
if (j &amp;lt; k) {&lt;br /&gt;
    [...]&lt;br /&gt;
} else if (j &amp;gt; k) {&lt;br /&gt;
    [...]&lt;br /&gt;
} else {&lt;br /&gt;
    [...]&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
class Dummy {&lt;br /&gt;
    [...]&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Did you see the {}&#039;s on that?&lt;br /&gt;
&lt;br /&gt;
== Tabs for indenting, spaces for alignment ==&lt;br /&gt;
&lt;br /&gt;
Says it all, really.&lt;br /&gt;
&lt;br /&gt;
== Whitespaces ==&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Conventional operators surrounded by a space character&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
a = (b + c) * d;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;C++ reserved words separated from opening parentheses by a white space&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
while (true) {&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Commas followed by a white space&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
someFunction(a, b, c);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
int d, e;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Semicolons followed by a space character, if there is more on a line&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
for (int a = 0; b &amp;lt; c; d++)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
doSomething(e); doSomething(f);	// This is probably bad style anyway&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Semicolons preceded by a space character, if it ends an empty loop body&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
It should also contain a comment to make it clear that the loop is intentionally empty.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
while (i &amp;lt; length - 1 &amp;amp;&amp;amp; array[++i] != item) ; // Look for index of item with an empty loop&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
The following syntax is also acceptable:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
while (i &amp;lt; length - 1 &amp;amp;&amp;amp; array[++i] != item)&lt;br /&gt;
	; //this loop is intentionally empty&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;When declaring class inheritance and in a ? construct, colons should be surrounded by white space&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
class BusWheel : public RubberInflatable {&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
(isNight) ? colorMeDark() : colorMeBright();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Indentation level is not increased after namespace clause&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
namespace Scumm {&lt;br /&gt;
&lt;br /&gt;
byte Actor::kInvalidBox = 0;&lt;br /&gt;
&lt;br /&gt;
void Actor::initActorClass(ScummEngine *scumm) {&lt;br /&gt;
    _vm = scumm;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
} // End of namespace Scumm&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;However, namespaces used solely for forward-declarations should indent&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
namespace Aurora {&lt;br /&gt;
    namespace NWScript {&lt;br /&gt;
        class Object;&lt;br /&gt;
    }&lt;br /&gt;
} &lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Array delete operator has no whitespace before []&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
delete[] foo;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Template definitions&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
No whitespace between template keyword and &amp;lt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
template&amp;lt;typename foo&amp;gt;&lt;br /&gt;
void myFunc(foo arg) {&lt;br /&gt;
    // ...&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Operator overloading&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Operator keyword is NOT separated from the name, except for type conversion operators where it is required.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
struct Foo {&lt;br /&gt;
    void operator()() {&lt;br /&gt;
        // ...&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    operator bool() {&lt;br /&gt;
        return true;&lt;br /&gt;
    }&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Pointers and casts&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
One whitespace after a cast.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
const char *ptr = (const char *) foobar;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;References&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
We use the same rule for references as we do for pointers: use a whitespace before the &amp;quot;&amp;amp;&amp;quot; but not after it.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
int i = 0;&lt;br /&gt;
int &amp;amp;ref = i;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Trailing whitespace&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
No trailing whitespace, at all. This means that lines should never end with spaces or tabs. Remove them. Empty lines should be completely empty; not even indenting tabs should be there.&lt;br /&gt;
&lt;br /&gt;
== Include order ==&lt;br /&gt;
&lt;br /&gt;
Include directives should be grouped by subsystem, roughly ordered by specificity, from general to specific.&lt;br /&gt;
&lt;br /&gt;
The group order is as follows:&lt;br /&gt;
&lt;br /&gt;
* C++ versions of standard C headers&lt;br /&gt;
* Standard C++ headers&lt;br /&gt;
* Standard C headers&lt;br /&gt;
* Library includes&lt;br /&gt;
* src/common&lt;br /&gt;
* src/aurora&lt;br /&gt;
* src/graphics&lt;br /&gt;
* src/sound&lt;br /&gt;
* src/video&lt;br /&gt;
* src/events&lt;br /&gt;
* src/engines&lt;br /&gt;
&lt;br /&gt;
Each group is separated by an empty line. The includes within each group are again ordered roughly by specificity, with includes used by other includes first. But in a .cpp file implementing an interface specified in a .h file, the .h file sits ontop of its group.&lt;br /&gt;
&lt;br /&gt;
For example, these could be the include directives in src/engines/nwn/game.cpp:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
#include &amp;lt;cassert&amp;gt;&lt;br /&gt;
&lt;br /&gt;
#include &amp;lt;list&amp;gt;&lt;br /&gt;
#include &amp;lt;map&amp;gt;&lt;br /&gt;
&lt;br /&gt;
#include &amp;quot;src/common/util.h&amp;quot;&lt;br /&gt;
#include &amp;quot;src/common/ustring.h&amp;quot;&lt;br /&gt;
#include &amp;quot;src/common/filelist.h&amp;quot;&lt;br /&gt;
&lt;br /&gt;
#include &amp;quot;src/aurora/types.h&amp;quot;&lt;br /&gt;
#include &amp;quot;src/aurora/talkman.h&amp;quot;&lt;br /&gt;
&lt;br /&gt;
#include &amp;quot;src/engines/aurora/util.h&amp;quot;&lt;br /&gt;
&lt;br /&gt;
#include &amp;quot;src/engines/nwn/game.h&amp;quot;&lt;br /&gt;
#include &amp;quot;src/engines/nwn/util.h&amp;quot;&lt;br /&gt;
#include &amp;quot;src/engines/nwn/nwn.h&amp;quot;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Switch/Case constructs ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
switch (cmd) {&lt;br /&gt;
    case kSomeCmd:&lt;br /&gt;
        someCmd();&lt;br /&gt;
        // Fall Through intended&lt;br /&gt;
    case kSomeVerySimilarCmd:&lt;br /&gt;
        someMoreCmd();&lt;br /&gt;
        break;&lt;br /&gt;
    case kSaveCmd:&lt;br /&gt;
        save();&lt;br /&gt;
        break;&lt;br /&gt;
    case kLoadCmd:&lt;br /&gt;
    case kPlayCmd:&lt;br /&gt;
        close();&lt;br /&gt;
        break;&lt;br /&gt;
    default:&lt;br /&gt;
        Dialog::handleCommand(sender, cmd, data);&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
* Note comment on whether fall through is intentional.&lt;br /&gt;
&lt;br /&gt;
== Naming ==&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Constants&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Basically, you have two choices (this has historical reasons, and we probably should try to unify this one day):&lt;br /&gt;
&lt;br /&gt;
# Camel case with prefix &#039;k&#039;: &amp;lt;pre&amp;gt; kSomeKludgyConstantName &amp;lt;/pre &amp;gt;&lt;br /&gt;
# All upper case, with words separated by underscores (no leading/trailing underscores): &amp;lt;pre&amp;gt;SOME_KLUDGY_CONSTANT_NAME&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
(As a side remark, we recommend avoiding #define for creating constants, because these can lead to weird and difficult to track down conflicts. Instead use enums or the &amp;lt;code&amp;gt;const&amp;lt;/code&amp;gt; keyword.)&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Type names&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Camel case starting with upper case.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
class MyClass { /* ... */ };&lt;br /&gt;
struct MyStruct { /* ... */ };&lt;br /&gt;
typedef int MyInt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Class member variables&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Prefixed with &#039;_&#039; and in camel case (Yo! no underscore separators), starting with lowercase.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
char *_someVariableName;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Class methods&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Camel case, starting with lowercase.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
void thisIsMyFancyMethod();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Local variables&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Use camel case (Yo! no underscore separators), starting with lowercase.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
char *someVariableName;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that for POD structures it is fine to use this rule too.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Global variables&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
In general you should avoid global variables, but if it can&#039;t be avoided, use &#039;g_&#039; as prefix, camel case, and start with lowercase&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
int g_someGlobalVariable;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Special comments ==&lt;br /&gt;
&lt;br /&gt;
=== Special Keywords ===&lt;br /&gt;
&lt;br /&gt;
The following goes slightly beyond code formatting: We use certain keywords (together with an explanatory text) to mark certain sections of our code. In particular:&lt;br /&gt;
* &#039;&#039;&#039;FIXME&#039;&#039;&#039; marks code that contains hacks or bad temporary workarounds, things that really should be revised at a later point.&lt;br /&gt;
* &#039;&#039;&#039;TODO&#039;&#039;&#039; marks incomplete code, or things that could be done better but are left for the future.&lt;br /&gt;
* &#039;&#039;&#039;WORKAROUND&#039;&#039;&#039; marks code that works around bugs in the original game, like script bugs. Sometimes these bugs worked in the original due to bugs in the original engine, sometimes the bug was visible in the original, too. It&#039;s important that you explain here what exactly you work around, and if applicable, refer to relevant tracker items!&lt;br /&gt;
&lt;br /&gt;
=== Doxygen documentation comments ===&lt;br /&gt;
&lt;br /&gt;
xoreos uses the [http://www.doxygen.org/ Doxygen] software to generate HTML documentation for the codebase.&lt;br /&gt;
&lt;br /&gt;
Doxygen supports &#039;&#039;documentation blocks&#039;&#039;. These are specially-formatted comments that doxygen prints out in the generated documentation. They are similar in purpose to Java&#039;s JavaDoc or Python&#039;s docstrings.&lt;br /&gt;
&lt;br /&gt;
There are many ways to mark such comments, but developers are encouraged to use the JavaDoc style:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
/** Move (&amp;quot;warp&amp;quot;) the mouse cursor to the specified position in virtual&lt;br /&gt;
 *  screen coordinates.&lt;br /&gt;
 *&lt;br /&gt;
 *  @param x   the new x position of the mouse.&lt;br /&gt;
 *  @param y   the new y position of the mouse.&lt;br /&gt;
 */&lt;br /&gt;
virtual void warpMouse(int x, int y) = 0;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
As shown in the example, documentation blocks also support several special commands such as &#039;&#039;&#039;param&#039;&#039;&#039;. Those are prefixed with either &#039;&#039;&#039;@&#039;&#039;&#039; or &#039;&#039;&#039;\&#039;&#039;&#039;, but developers should always use &#039;&#039;&#039;@&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
If you want to add a brief explanation of a variable or function &#039;&#039;after&#039;&#039; its declaration, this is the correct syntax:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
int16 x;	///&amp;lt; The horizontal part of the point.&lt;br /&gt;
int16 y;	///&amp;lt; The vertical part of the point.&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For more information, visit the official documentation:&lt;br /&gt;
* [http://www.stack.nl/~dimitri/doxygen/docblocks.html Documentation blocks].&lt;br /&gt;
* [http://www.stack.nl/~dimitri/doxygen/commands.html List of available commands].&lt;br /&gt;
&lt;br /&gt;
== Automatically converting code to our conventions ==&lt;br /&gt;
The following settings for [http://astyle.sourceforge.net/ Artistic Style] (also known as astyle) approximate our code formatting conventions and can be used to quickly convert a big bunch of source files to our conventions. Note that you may still have to manually clean up some stuff afterwards.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
indent=tab=4&lt;br /&gt;
brackets=attach&lt;br /&gt;
pad-oper&lt;br /&gt;
pad-header&lt;br /&gt;
align-pointer=name&lt;br /&gt;
unpad-paren&lt;br /&gt;
indent-preprocessor&lt;br /&gt;
convert-tabs&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Alternatively, [https://github.com/xoreos/xoreos/blob/master/.uncrustifyrc this config file] for [http://uncrustify.sourceforge.net/ uncrustify] should also work as a starting point for our conventions. Again, you may still clean things up manually.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Compiling_xoreos-tools&amp;diff=426</id>
		<title>Compiling xoreos-tools</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Compiling_xoreos-tools&amp;diff=426"/>
		<updated>2018-10-07T14:12:17Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* Compiler and build system */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page gives a few tips and pointers on how to compile xoreos-tools on various platforms.&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
==Compiler and build system==&lt;br /&gt;
&lt;br /&gt;
xoreos-tools is written in C++, so a C++ compiler, like [https://gcc.gnu.org/ GCC] or [http://clang.llvm.org/ clang] is required. xoreos-tools follows the C++11 standard. It has two build systems: [https://en.wikipedia.org/wiki/GNU_build_system Autotools] ([https://www.gnu.org/software/autoconf/ Autoconf], [https://www.gnu.org/software/automake/ Automake] and [https://www.gnu.org/software/libtool/ Libtool]) and [https://en.wikipedia.org/wiki/CMake CMake]. Use whichever you feel more comfortable with.&lt;br /&gt;
&lt;br /&gt;
===GNU/Linux===&lt;br /&gt;
&lt;br /&gt;
On Debian-based distributions (including Ubuntu), you should be able to install the required compiler and build system packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;apt-get install libc6-dev g++ make autoconf automake libtool gettext&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install the necessary packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo pacman -S base-devel cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On other distributions, it should work similarily.&lt;br /&gt;
&lt;br /&gt;
===Windows===&lt;br /&gt;
&lt;br /&gt;
Since Visual Studio does not work with autotools, you have to use the CMake build system if you want to compile xoreos with Visual Studio. If you&#039;re using [http://www.mingw.org/ MinGW], however, you&#039;re free to choose either build system.&lt;br /&gt;
&lt;br /&gt;
On Windows, it is recommended that instead of Visual Studio, you use [https://msys2.github.io/ MSYS2] together with [https://mingw-w64.org/ Mingw-w64] (which can produce both 32-bit and 64-bit binaries). MSYS2 provides a package manager, with which you can install xoreos&#039; library dependencies very easily.&lt;br /&gt;
&lt;br /&gt;
You can install the 32-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-i686-toolchain mingw-w64-i686-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can install the 64-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-x86_64-toolchain mingw-w64-x86_64-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Libraries==&lt;br /&gt;
&lt;br /&gt;
xoreos-tools uses the following libraries to function:&lt;br /&gt;
&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Iconv iconv]&lt;br /&gt;
* [http://www.zlib.net/ zlib] (&amp;gt;= 1.2.3.4)&lt;br /&gt;
* [http://www.xmlsoft.org/ libxml2] (&amp;gt;= 2.8.0)&lt;br /&gt;
* [http://www.boost.org/ Boost] (&amp;gt;= 1.53.0)&lt;br /&gt;
** Boost.Utility&lt;br /&gt;
** Boost.StringAlgo&lt;br /&gt;
** Boost.System&lt;br /&gt;
** Boost.Filesystem&lt;br /&gt;
** Boost.Regex&lt;br /&gt;
** Boost.Hash&lt;br /&gt;
** Boost.Function&lt;br /&gt;
** Boost.Bind&lt;br /&gt;
** Boost.Uuid&lt;br /&gt;
** Boost.Smart_Ptr&lt;br /&gt;
** Boost.ScopeExit&lt;br /&gt;
** Boost.Atomic&lt;br /&gt;
** Boost.Locale&lt;br /&gt;
&lt;br /&gt;
On Debian-based GNU/Linux distribution (including Ubuntu), you should be able to install these libraries and their development packages with&lt;br /&gt;
&lt;br /&gt;
 apt-get install zlib1g-dev libxml2-dev libboost-all-dev&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install these dependencies with&lt;br /&gt;
&lt;br /&gt;
 sudo pacman -S zlib libxml2 boost boost-libs&lt;br /&gt;
&lt;br /&gt;
Other GNU/Linux distributions should work similarily.&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 32-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-i686-zlib mingw-w64-i686-libxml2 mingw-w64-i686-boost&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 64-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-x86_64-zlib mingw-w64-x86_64-libxml2 mingw-w64-x86_64-boost&lt;br /&gt;
&lt;br /&gt;
Windows users not using MSYS2 will have to visit each website manually and download a precompiled version, or, if not available, download the source and compile the library themselves.&lt;br /&gt;
&lt;br /&gt;
==Compiling xoreos==&lt;br /&gt;
&lt;br /&gt;
Make you have your compiler, build system and libraries installed correctly. Then open a terminal and change into the directory of your sources.&lt;br /&gt;
&lt;br /&gt;
===autotools===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;./autogen.sh &amp;amp;&amp;amp; ./configure &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binaries can then be found in the src subdirectory.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional ./configure flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* --with-werror &amp;amp;nbsp;&lt;br /&gt;
|| Compile with -Werror&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --without-warnings &amp;amp;nbsp;&lt;br /&gt;
|| Compile without the extra warnings enabled&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --with-lto &amp;amp;nbsp;&lt;br /&gt;
|| Compile with link-time optimization&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===CMake ===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;cmake . &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binaries can then be found in the bin subdirectory.&lt;br /&gt;
&lt;br /&gt;
Please read [http://www.cmake.org/runningcmake/ Running CMake] on the CMake website for in-depth information on invoking CMake.&lt;br /&gt;
&lt;br /&gt;
==Unit tests==&lt;br /&gt;
&lt;br /&gt;
On both build systems,&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;make check&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
compiles and runs our unit tests.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Compiling_xoreos&amp;diff=425</id>
		<title>Compiling xoreos</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Compiling_xoreos&amp;diff=425"/>
		<updated>2018-10-07T14:11:54Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* Compiler and build system */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page gives a few tips and pointers on how to compile xoreos on various platforms.&lt;br /&gt;
__TOC__&lt;br /&gt;
&lt;br /&gt;
==Compiler and build system==&lt;br /&gt;
&lt;br /&gt;
xoreos is written in C++, so a C++ compiler, like [https://gcc.gnu.org/ GCC] or [http://clang.llvm.org/ clang] is required. xoreos follows the C++03 standard. It has two build systems: [https://en.wikipedia.org/wiki/GNU_build_system Autotools] ([https://www.gnu.org/software/autoconf/ Autoconf], [https://www.gnu.org/software/automake/ Automake] and [https://www.gnu.org/software/libtool/ Libtool]) and [https://en.wikipedia.org/wiki/CMake CMake]. Use whichever you feel more comfortable with.&lt;br /&gt;
&lt;br /&gt;
===GNU/Linux===&lt;br /&gt;
&lt;br /&gt;
On Debian-based distributions (including Ubuntu), you should be able to install the required compiler and build system packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo apt-get install libc6-dev g++ make autoconf automake libtool gettext cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install the necessary packages with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;sudo pacman -S base-devel cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On other distributions, it should work similarily.&lt;br /&gt;
&lt;br /&gt;
===Mac OS X===&lt;br /&gt;
&lt;br /&gt;
Due to the dependency on SDL2 (see below), you need at least Mac OS X 10.5 if you use a precompiled SDL2 library, and at least Mac OS X 10.7 if you&#039;re compiling SDL2 yourself.&lt;br /&gt;
&lt;br /&gt;
===Windows===&lt;br /&gt;
&lt;br /&gt;
Since Visual Studio does not work with autotools, you have to use the CMake build system if you want to compile xoreos with Visual Studio. If you&#039;re using [http://www.mingw.org/ MinGW], however, you&#039;re free to choose either build system.&lt;br /&gt;
&lt;br /&gt;
On Windows, it is recommended that instead of Visual Studio, you use [https://msys2.github.io/ MSYS2] together with [https://mingw-w64.org/ Mingw-w64] (which can produce both 32-bit and 64-bit binaries). MSYS2 provides a package manager, with which you can install xoreos&#039; library dependencies very easily.&lt;br /&gt;
&lt;br /&gt;
You can install the 32-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-i686-toolchain mingw-w64-i686-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can install the 64-bit toolchain in MSYS2 with&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;pacman -S base-devel git mingw-w64-x86_64-toolchain mingw-w64-x86_64-cmake&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Libraries==&lt;br /&gt;
&lt;br /&gt;
xoreos uses the following libraries to function:&lt;br /&gt;
&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Iconv iconv]&lt;br /&gt;
* [http://www.zlib.net/ zlib] (&amp;gt;= 1.2.3.4)&lt;br /&gt;
* [http://tukaani.org/xz/ liblzma] (&amp;gt;= 5.0.5)&lt;br /&gt;
* [http://www.xmlsoft.org/ libxml2] (&amp;gt;= 2.8.0)&lt;br /&gt;
* [http://www.boost.org/ Boost] (&amp;gt;= 1.53.0)&lt;br /&gt;
** Boost.Utility&lt;br /&gt;
** Boost.StringAlgo&lt;br /&gt;
** Boost.System&lt;br /&gt;
** Boost.Filesystem&lt;br /&gt;
** Boost.Regex&lt;br /&gt;
** Boost.Unordered&lt;br /&gt;
** Boost.Hash&lt;br /&gt;
** Boost.Date_Time&lt;br /&gt;
** Boost.Function&lt;br /&gt;
** Boost.Bind&lt;br /&gt;
** Boost.Uuid&lt;br /&gt;
** Boost.Smart_Ptr&lt;br /&gt;
** Boost.ScopeExit&lt;br /&gt;
** Boost.Atomic&lt;br /&gt;
** Boost.Locale&lt;br /&gt;
* [https://en.wikipedia.org/wiki/OpenGL OpenGL] (&amp;gt;= 2.1)&lt;br /&gt;
* [https://www.libsdl.org/ SDL2] (&amp;gt;= 2.0.0)&lt;br /&gt;
* [http://www.freetype.org/ FreeType 2] (&amp;gt;= 2.4.0 (libtool number &amp;gt;= 11.0.5))&lt;br /&gt;
* [https://en.wikipedia.org/wiki/OpenAL OpenAL] (&amp;gt;= 1.12) (&#039;&#039;&#039;See below&#039;&#039;&#039;)&lt;br /&gt;
* [http://www.underbit.com/products/mad/ MAD] (&amp;gt;= 0.15.1b)&lt;br /&gt;
* [https://www.xiph.org/downloads/ libogg] (&amp;gt;= 1.2.0)&lt;br /&gt;
* [https://www.xiph.org/downloads/ libvorbis] (&amp;gt;= 1.3.1)&lt;br /&gt;
* [http://www.audiocoding.com/faad2.html libfaad] (&amp;gt;= 2.7)&lt;br /&gt;
* [https://www.xvid.org/ libxvidcore] (&amp;gt;= 1.2.2)&lt;br /&gt;
&lt;br /&gt;
On Debian-based GNU/Linux distribution (including Ubuntu), you should be able to install these libraries and their development packages with&lt;br /&gt;
&lt;br /&gt;
 sudo apt-get install zlib1g-dev liblzma-dev libxml2-dev libboost-all-dev libsdl2-dev \&lt;br /&gt;
     libfreetype6-dev libopenal-dev libmad0-dev libogg-dev libvorbis-dev libfaad-dev \&lt;br /&gt;
     libxvidcore-dev&lt;br /&gt;
&lt;br /&gt;
On Arch Linux, you can install these dependencies with&lt;br /&gt;
&lt;br /&gt;
 sudo pacman -S zlib xz libxml2 boost boost-libs sdl2 freetype2 openal libmad libogg \&lt;br /&gt;
     libvorbis faad2 xvidcore&lt;br /&gt;
&lt;br /&gt;
Other GNU/Linux distributions should work similarily.&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 32-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-i686-zlib mingw-w64-i686-xz mingw-w64-i686-libxml2 \&lt;br /&gt;
     mingw-w64-i686-boost mingw-w64-i686-SDL2 mingw-w64-i686-freetype \&lt;br /&gt;
     mingw-w64-i686-openal mingw-w64-i686-libmad mingw-w64-i686-libogg \&lt;br /&gt;
     mingw-w64-i686-libvorbis  mingw-w64-i686-faad2 mingw-w64-i686-xvidcore&lt;br /&gt;
&lt;br /&gt;
On Windows, if you&#039;re using MSYS2, you can install these dependencies for 64-bit with&lt;br /&gt;
&lt;br /&gt;
  pacman -S mingw-w64-x86_64-zlib mingw-w64-x86_64-xz mingw-w64-x86_64-libxml2 \&lt;br /&gt;
     mingw-w64-x86_64-boost mingw-w64-x86_64-SDL2 mingw-w64-x86_64-freetype \&lt;br /&gt;
     mingw-w64-x86_64-openal mingw-w64-x86_64-libmad mingw-w64-x86_64-libogg \&lt;br /&gt;
     mingw-w64-x86_64-libvorbis  mingw-w64-x86_64-faad2 mingw-w64-x86_64-xvidcore&lt;br /&gt;
&lt;br /&gt;
Windows users not using MSYS2 will have to visit each website manually and download a precompiled version, or, if not available, download the source and compile the library themselves.&lt;br /&gt;
&lt;br /&gt;
===  Guide for Visual Studio 2017 users ===&lt;br /&gt;
&lt;br /&gt;
* Download source from https://github.com/win-iconv/win-iconv and build the library using CMake&lt;br /&gt;
* Download https://zlib.net/zlib1211.zip, extract and build the library using CMake&lt;br /&gt;
* Download https://tukaani.org/xz/xz-5.2.4.tar.gz, extract and build the library using the solution file in windows/vs2017&lt;br /&gt;
* Download ftp://xmlsoft.org/libxml2/libxml2-2.9.8.tar.gz, extract and build the library by following instructions in win32/Readme.txt&lt;br /&gt;
* Download and install precompiled Boost libraries from https://sourceforge.net/projects/boost/files/boost-binaries/1.67.0/&lt;br /&gt;
* Download and extract https://www.libsdl.org/release/SDL2-devel-2.0.8-VC.zip&lt;br /&gt;
* Download https://download.savannah.gnu.org/releases/freetype/ft291.zip and build the library using CMake&lt;br /&gt;
* Download and extract http://kcat.strangesoft.net/openal-binaries/openal-soft-1.18.2-bin.zip&lt;br /&gt;
* Download ftp://ftp.mars.org/pub/mpeg/libmad-0.15.1b.tar.gz and build the library using the project file in msvc++. To build a 64-bit library, create a new configuration and replace preprocessor definition FPM_INTEL with FPM_64BIT&lt;br /&gt;
* Download http://downloads.xiph.org/releases/ogg/libogg-1.3.3.zip, extract and build both dynamic and static libraries using solution files in win32/VS2015&lt;br /&gt;
* Download http://downloads.xiph.org/releases/vorbis/libvorbis-1.3.6.zip, extract and build both dynamic and static libraries using solution files in win32/VS2010&lt;br /&gt;
* Download https://vorboss.dl.sourceforge.net/project/faac/faad2-src/faad2-2.8.0/faad2-2.8.8.tar.gz, extract and build projects &#039;&#039;&#039;libfaad&#039;&#039;&#039; and &#039;&#039;&#039;libfaad2_dll&#039;&#039;&#039; using the solution file in project/msvc. To build 64-bit libraries, create a new configuration&lt;br /&gt;
* Download source from https://github.com/seedhartha/xvidcore and build the library using CMake (requires NASM to be installed and present in PATH)&lt;br /&gt;
* Build xoreos using CMake&lt;br /&gt;
&lt;br /&gt;
To build a project using CMake, create a folder named &#039;&#039;&#039;build&#039;&#039;&#039; in a root directory of a project and from there invoke&lt;br /&gt;
&lt;br /&gt;
  cmake .. -G &amp;quot;Visual Studio 15 2017&amp;quot;&lt;br /&gt;
&lt;br /&gt;
or, for 64-bit&lt;br /&gt;
&lt;br /&gt;
  cmake .. -G &amp;quot;Visual Studio 15 2017 Win64&amp;quot;&lt;br /&gt;
&lt;br /&gt;
Open CMakeCache.txt in your favorite text editor and fill in missing information as needed. Then run cmake again. Project&#039;s solution file should be created at this point.&lt;br /&gt;
&lt;br /&gt;
=== A note on OpenAL ===&lt;br /&gt;
&lt;br /&gt;
On Mac OS X, we&#039;re using Apple&#039;s OpenAL implementation, so OpenAL does not need to be installed separately there.&lt;br /&gt;
&lt;br /&gt;
On both GNU/Linux and Microsoft Windows, we require [http://kcat.strangesoft.net/openal.html OpenAL Soft]. There is a propriety OpenAL implementation by Creative Labs, Inc. for Microsoft Windows, which can be found at [http://openal.org/ http://openal.org/], but it&#039;s unfortunately old, outdated and abandoned. We do not recommend its use.&lt;br /&gt;
&lt;br /&gt;
Likewise, on NetBSD and other systems using pkgsrc, you should use [http://pkgsrc.se/audio/openal-soft openal-soft] instead of [http://pkgsrc.se/audio/openal openal].&lt;br /&gt;
&lt;br /&gt;
==Compiling xoreos==&lt;br /&gt;
&lt;br /&gt;
Make sure you have your compiler, build system and libraries installed correctly. Then open a terminal and change into the directory of your sources.&lt;br /&gt;
&lt;br /&gt;
===autotools===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;./autogen.sh &amp;amp;&amp;amp; ./configure &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binary can be found in the src subdirectory, called &amp;quot;xoreos&amp;quot; or, on Windows, &amp;quot;xoreos.exe&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional ./configure flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* --with-werror &amp;amp;nbsp;&lt;br /&gt;
|| Compile with -Werror&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --without-warnings &amp;amp;nbsp;&lt;br /&gt;
|| Compile without the extra warnings enabled&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --with-lto &amp;amp;nbsp;&lt;br /&gt;
|| Compile with link-time optimization&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* --disable-external-glew &amp;amp;nbsp;&lt;br /&gt;
|| Always compile against the internal GLEW libraries&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
===CMake ===&lt;br /&gt;
&lt;br /&gt;
Type&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;cmake . &amp;amp;&amp;amp; make&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The binary can be found in the bin subdirectory, called &amp;quot;xoreos&amp;quot; or, on Windows, &amp;quot;xoreos.exe&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Please read [http://www.cmake.org/runningcmake/ Running CMake] on the CMake website for in-depth information on invoking CMake.&lt;br /&gt;
&lt;br /&gt;
Optional, non-conventional cmake flags:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|&lt;br /&gt;
* -DBoost_USE_STATIC_LIBS=on &amp;amp;nbsp;&lt;br /&gt;
|| Link Boost statically instead of dynamically&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
* -DGLEW_INTERNAL=on &amp;amp;nbsp;&lt;br /&gt;
|| Always use internal GLEW library&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note&#039;&#039;&#039;: The CMake&#039;s stock FindBoost.cmake doesn&#039;t correctly detect dependencies when linking statically. In this case, xoreos might fail to link, missing symbols for ICU, when linking Boost statically.&lt;br /&gt;
&lt;br /&gt;
Moreover, if you&#039;re running GNU/Linux and have wrapper scripts installed that force the building of &amp;quot;hardened&amp;quot; binaries (often called &amp;quot;hardening-wrapper&amp;quot;, but differs between Linux distributions), compiling xoreos might fail during the linking stage, when using statically linking Boost libraries. This is due to those static Boost libraries being incompatible with the compiler option &amp;quot;-fPIE&amp;quot;, which is often added by hardening wrapper scripts. A workaround is to disable -fPIE for this compilation (which is distribution-specific).&lt;br /&gt;
&lt;br /&gt;
==Unit tests==&lt;br /&gt;
&lt;br /&gt;
On both build systems,&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;make check&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
compiles and runs our unit tests.&lt;br /&gt;
&lt;br /&gt;
==Running xoreos==&lt;br /&gt;
&lt;br /&gt;
Please have a look at the [[Running xoreos]] page.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Releases&amp;diff=419</id>
		<title>Releases</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Releases&amp;diff=419"/>
		<updated>2018-07-04T11:40:43Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__TOC__&lt;br /&gt;
&lt;br /&gt;
==git tag and version numbers==&lt;br /&gt;
&lt;br /&gt;
In general, a full xoreos release consists of two tags in each of the xoreos, xoreos-tools and phaethon repositories. On tag is the actual release, which looks like &amp;quot;v0.0.4&amp;quot;. The other is used to calculate the number of commits since the release for git builds and looks like &amp;quot;desc/0.0.4&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Both tags point to the same release announcement commit. The release tag will have release notes, source and pre-compiled binary packages for Linux, macOS and Windows attached on GitHub. The downloads page on the xoreos website will also point to the same binary packages.&lt;br /&gt;
&lt;br /&gt;
The three main repositories (xoreos, xoreos-tools and phaethon) have a linked release schedule, each advancing to the same version number on release. All other repositories are &amp;quot;floating&amp;quot; and are not versioned.&lt;br /&gt;
&lt;br /&gt;
==Code names==&lt;br /&gt;
&lt;br /&gt;
Each release has an (inofficial) code name, like &amp;quot;Aribeth&amp;quot; for the first release 0.0.2. These names won&#039;t appear in the code itself. They&#039;re only used on the website and for promotional concerns.&lt;br /&gt;
&lt;br /&gt;
The current plans for code names is to use character names found in the games xoreos targets. Each release advances both the letter of the alphabet that name starts with, and the game the character is found (in game release order). Each of those wrap around at the end.&lt;br /&gt;
&lt;br /&gt;
The games were released in this order:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! style=&amp;quot;text-align:left;&amp;quot;| Year&lt;br /&gt;
! style=&amp;quot;text-align:left;&amp;quot;| Game&lt;br /&gt;
|-&lt;br /&gt;
|2002 || Neverwinter Nights&lt;br /&gt;
|-&lt;br /&gt;
|2003 || Knights of the Old Republic&lt;br /&gt;
|-&lt;br /&gt;
|2004 || Knights of the Old Republic II&lt;br /&gt;
|-&lt;br /&gt;
|2005 || Jade Empire&lt;br /&gt;
|-&lt;br /&gt;
|2006 || Neverwinter Nights 2&lt;br /&gt;
|-&lt;br /&gt;
|2007 || The Witcher&lt;br /&gt;
|-&lt;br /&gt;
|2008 || Sonic Chronicles&lt;br /&gt;
|-&lt;br /&gt;
|2009 || Dragon Age: Origins&lt;br /&gt;
|-&lt;br /&gt;
|2011 || Dragon Age II&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The past releases were this:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! style=&amp;quot;text-align:left;&amp;quot;| Version&lt;br /&gt;
! style=&amp;quot;text-align:left;&amp;quot;| Code name&lt;br /&gt;
! style=&amp;quot;text-align:left;&amp;quot;| Game&lt;br /&gt;
|-&lt;br /&gt;
|0.0.2 || Aribeth || Neverwinter Nights&lt;br /&gt;
|-&lt;br /&gt;
|0.0.3 || Bastila || Knights of the Old Republic&lt;br /&gt;
|-&lt;br /&gt;
|0.0.4 || Chodo || Knights of the Old Republic II&lt;br /&gt;
|-&lt;br /&gt;
|0.0.5  || Dawn Star || Jade Empire&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Continuing, the next releases would be:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! style=&amp;quot;text-align:left;&amp;quot;| Version&lt;br /&gt;
! style=&amp;quot;text-align:left;&amp;quot;| Code name&lt;br /&gt;
! style=&amp;quot;text-align:left;&amp;quot;| Game&lt;br /&gt;
|-&lt;br /&gt;
|0.0.6  || Elanee? || Neverwinter Nights 2&lt;br /&gt;
|-&lt;br /&gt;
|0.0.7  || Foltest? || The Witcher&lt;br /&gt;
|-&lt;br /&gt;
|0.0.8  || General Raxos? Green Hill Zone? || Sonic Chronicles&lt;br /&gt;
|-&lt;br /&gt;
|0.0.9  || Herren? || Dragon Age: Origins&lt;br /&gt;
|-&lt;br /&gt;
|0.0.10 || Isabela? || Dragon Age II&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Release notes==&lt;br /&gt;
&lt;br /&gt;
The release notes summarize the changes found in the ChangeLog file, so that they&#039;re more easily digested. The same summary can be found in the NEWS.md file.&lt;br /&gt;
&lt;br /&gt;
Additionally, the release notes on GitHub will also contain links to Arch Linux&#039;s AUR, Linux distribution build files in the repository and similar. There will also be a list describing which pre-compiled binary packages are available and their SHA-256 checksums.&lt;br /&gt;
&lt;br /&gt;
==Downloads==&lt;br /&gt;
&lt;br /&gt;
Several pre-compiled binary packages will be available on the GitHub release notes and the website downloads page. These are created by [[User:DrMcCoy]] using cross-compilers running on Linux.&lt;br /&gt;
&lt;br /&gt;
The current set-up, to be first used for the upcoming 0.0.5 release, consists of&lt;br /&gt;
&lt;br /&gt;
* A Debian Jessie chroot with gcc 4.9 (full C++11 support), to compile xoreos and xoreos-tools for Linux, 32-bit and 64-bit&lt;br /&gt;
* A Debian Stretch chroot with gcc 6.3 (full C++14 support), to compile Phaethon for Linux, 32-bit and 64-bit&lt;br /&gt;
* OS X Cross, with clang 6.0.0 (full C++17 support), targeting macOS &amp;gt;= 10.9, 64-bit only&lt;br /&gt;
* Mingw-w64 with gcc 7.3 (full C++17 support), targeting Windows, 32-bit and 64-bit&lt;br /&gt;
&lt;br /&gt;
==Website post and press releases==&lt;br /&gt;
&lt;br /&gt;
Each release will also follow a news post on the xoreos website. That news post will be submitted to GamingOnLinux and several subreddits. Submitting the news to other gaming- or Linux-related news sites might be an option, but that hasn&#039;t been fruitful in the past.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=TODO&amp;diff=418</id>
		<title>TODO</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=TODO&amp;diff=418"/>
		<updated>2018-07-04T11:39:50Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a long rambly list of things left to do in xoreos and xoreos-tools. Anybody is welcome to tackle any of these tasks, but please also read our [[Developer_Central|general contributor overview]], including our [[Code_Formatting_Conventions|Code Formatting Conventions]], [[Commit_Guidelines|Commit Guidelines]] and [https://github.com/xoreos/xoreos/blob/master/CODE_OF_CONDUCT.md Code of Conduct]. If you plan to do any of these tasks, please also [[Contact_us|contact us]] beforehand, so we can better coordinate multiple people interested in doing the same task, and discuss how to best solve the problem. Thanks. :)&lt;br /&gt;
&lt;br /&gt;
(&#039;&#039;&#039;See also:&#039;&#039;&#039; the Kanban-like &amp;quot;Projects&amp;quot; boards on GitHub: https://github.com/orgs/xoreos/projects)&lt;br /&gt;
&lt;br /&gt;
== Documentation ==&lt;br /&gt;
&lt;br /&gt;
=== Developer information ===&lt;br /&gt;
* Extend the developer information on the wiki&lt;br /&gt;
** Explain how to get the xoreos sources on various platforms&lt;br /&gt;
** Expand GNU/Linux compiling instructions to cover more distributions&lt;br /&gt;
** Expand Mac OS X compiling instructions&lt;br /&gt;
*** Xcode&lt;br /&gt;
*** Homebrew/MacPorts/Fink&lt;br /&gt;
*** CMake, Libraries&lt;br /&gt;
** [http://wiki.arx-libertatis.org/Developer_Information Arx Libertatis] has an extensive dev page&lt;br /&gt;
* Document file formats on the wiki?&lt;br /&gt;
** Or integrate info into XentaxWiki?&lt;br /&gt;
** Both?&lt;br /&gt;
&lt;br /&gt;
=== User information ===&lt;br /&gt;
* More user information on the wiki&lt;br /&gt;
** How to download xoreos&lt;br /&gt;
** How to install the games on various platforms&lt;br /&gt;
** [http://wiki.arx-libertatis.org/Main_Page Arx Libertatis] does that pretty well&lt;br /&gt;
&lt;br /&gt;
=== Modder information ===&lt;br /&gt;
* Link to relevant modding resources&lt;br /&gt;
* Maybe even some kind of Modder&#039;s Handbook&lt;br /&gt;
** A big overview of modding Aurora games in general&lt;br /&gt;
*** Differences and commonalities between games&lt;br /&gt;
** Linking/Grouping engine functions between games&lt;br /&gt;
&lt;br /&gt;
== Website ==&lt;br /&gt;
&lt;br /&gt;
=== Design ===&lt;br /&gt;
* Better website design?&lt;br /&gt;
** It still should be static in the end&lt;br /&gt;
*** No PHP or Rails&lt;br /&gt;
*** Very light on JavaScript&lt;br /&gt;
*** No Flash!&lt;br /&gt;
** Maybe a bit more unique, graphical&lt;br /&gt;
** For legal reasons, we shouldn&#039;t directly use art or designs from the original games&lt;br /&gt;
*** Something inspired by the art of the orginal games would fit&lt;br /&gt;
&lt;br /&gt;
=== Octopress ===&lt;br /&gt;
* Move away from Octopress?&lt;br /&gt;
** Alternative should still produce static HTML somehow&lt;br /&gt;
** Octopress works rather well. It reads Markdown, which is a plus&lt;br /&gt;
* Octopress 3.0?&lt;br /&gt;
** Not finished yet, it seems&lt;br /&gt;
&lt;br /&gt;
== Standalone(ish) fixes/improvements ==&lt;br /&gt;
&lt;br /&gt;
=== Broken NWN2 XML ===&lt;br /&gt;
* Not standards-conforming XML. Need custom XML parser; stock XML parsing libraries will just throw errors.&lt;br /&gt;
** &amp;lt;nowiki&amp;gt;&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;NWN2UI&amp;quot;&amp;gt;&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
** No single root element&lt;br /&gt;
** Attribute values not enclosed in quotes most of the time&lt;br /&gt;
** Special characters in attribute values not properly escaped&lt;br /&gt;
** Unmatched quotes on several occasions&lt;br /&gt;
* Event functions&lt;br /&gt;
* Special values like PARENT_WIDTH&lt;br /&gt;
* [https://github.com/xoreos/xoreos-tools/pull/1 Altrite is working on a broken-XML fixer]&lt;br /&gt;
&lt;br /&gt;
=== CJK glyphs in the console ===&lt;br /&gt;
* The &amp;quot;system font&amp;quot; we use for our debug console, DejaVu Sans Mono Bold, does not feature any CJK (Chinese, Japanese, Korean) glyphs&lt;br /&gt;
* Not strictly necessary, but nice to have for printing, say, Witcher area names in Asian languages&lt;br /&gt;
* We could maybe integrate CJK glyphs from the [http://fonts.jp/hanazono/ Hanazono fonts] or other suitable libre fonts&lt;br /&gt;
* We need to match the height with DejaVu Sans Mono Bold&lt;br /&gt;
* CJK glyphs tend to be more complex and therefore wider. They&#039;re usually rendered twice as wide as Latin glyphs&lt;br /&gt;
* Our console code needs to take that into account&lt;br /&gt;
&lt;br /&gt;
=== Fuzzing ===&lt;br /&gt;
* Set up fuzzing targets for everything for [https://llvm.org/docs/LibFuzzer.html libFuzzer]&lt;br /&gt;
** File readers, image decoders, etc.&lt;br /&gt;
* Can be integrated with [http://lcamtuf.coredump.cx/afl/ afl] (american fuzzy lop): https://github.com/llvm-mirror/compiler-rt/blob/master/lib/fuzzer/afl/afl_driver.cpp&lt;br /&gt;
* Integrate it with our build system somehow&lt;br /&gt;
** ./configure flag for building with fuzzing instrumentation?&lt;br /&gt;
** Needs to check that the compiler can do that&lt;br /&gt;
** make fuzzers then builds the targets?&lt;br /&gt;
* File formats previously manually fuzzed with afl:&lt;br /&gt;
** CBGT, CDPTH, DDS, NBFS, NCGR, NCLR, SBM, TGA, TPC, TXB&lt;br /&gt;
** 2DA, KEY/BIF, ERF, GFF3, GFF4, GDA, TLK, NSBTX, RIM, SMALL, SSF&lt;br /&gt;
* Continuous fuzzing via [https://github.com/google/oss-fuzz OSS-Fuzz] (currently only taking &amp;quot;important&amp;quot; projects)&lt;br /&gt;
&lt;br /&gt;
=== Script decompiler ===&lt;br /&gt;
* It might be quite useful to have a NWScript decompiler in xoreos-tools&lt;br /&gt;
* We have a script disassembler, ncsdis&lt;br /&gt;
** Which already does code flow analysis&lt;br /&gt;
* Missing:&lt;br /&gt;
** Code generation&lt;br /&gt;
** Collapsing of instruction chains into single-line NWScript code&lt;br /&gt;
*** For example, &amp;quot;int var = foo * bar + quux&amp;quot; compiles to a long chain with multiple temporaries&lt;br /&gt;
** Proper handling of structs and vectors&lt;br /&gt;
&lt;br /&gt;
=== Script compiler ===&lt;br /&gt;
* An NWScript compiler might be useful as well&lt;br /&gt;
** A script assembler might be an easy first step&lt;br /&gt;
&lt;br /&gt;
=== File format writers ===&lt;br /&gt;
* GFF3Writer, GFF4Writer&lt;br /&gt;
** Both necessary to create save games compatible with the original games&lt;br /&gt;
** Also useful for a xml2gff tool&lt;br /&gt;
* xml2tlk&lt;br /&gt;
** TalkTable_GFF::write02() and ::write05()&lt;br /&gt;
** Needs GFF4Writer&lt;br /&gt;
* Archive (ERF, RIM, KEY/BIF) packers?&lt;br /&gt;
&lt;br /&gt;
=== Config file ===&lt;br /&gt;
* Should be more preserving of the layout&lt;br /&gt;
** Especially empty lines&lt;br /&gt;
** UTF-8 Byte-Order-Mark when using native Windows editors&lt;br /&gt;
** \r is currently always stripped. Maybe preserve that too&lt;br /&gt;
*** Autodetect when \r is already used, and add it to new config lines too&lt;br /&gt;
** This basically needs a complete rewrite of the config parser&lt;br /&gt;
*** Don&#039;t just look for comments, just throw everything after &amp;quot;foo=bar&amp;quot; into the &amp;quot;comment&amp;quot; variable, including whitespace&lt;br /&gt;
*** And all whitespace before &amp;quot;foo=bar&amp;quot; into a &amp;quot;prefix&amp;quot; variable&lt;br /&gt;
** Maybe even always add BOM and \r when writing a new config file on Windows?&lt;br /&gt;
&lt;br /&gt;
=== GUI ===&lt;br /&gt;
* xoreos could use a global GUI to start games from&lt;br /&gt;
** https://github.com/ocornut/imgui?&lt;br /&gt;
* Should probably be similar to ScummVM&#039;s GUI, at least in effect&lt;br /&gt;
* Should read the config file, list all targets&lt;br /&gt;
** Press a &amp;quot;Play&amp;quot; button to play the game&lt;br /&gt;
** Press an &amp;quot;Edit&amp;quot; button to edit the entry&lt;br /&gt;
*** Dialog options to edit common settings&lt;br /&gt;
*** An additional free-form editor?&lt;br /&gt;
*** Game-specific options?&lt;br /&gt;
** A button to edit global settings (&amp;quot;xoreos&amp;quot; config domain)&lt;br /&gt;
** For the future, a way to immediately load a saved game?&lt;br /&gt;
** An &amp;quot;Add&amp;quot; button to add a game&lt;br /&gt;
*** File browser&lt;br /&gt;
**** Select directories for most game&lt;br /&gt;
**** Select file for Sonic Chronicles&lt;br /&gt;
*** View current saved games of a target?&lt;br /&gt;
* Probably implemented using OpenGL, just like, say, the console&lt;br /&gt;
* Theme-able/Skinable?&lt;br /&gt;
* Some potential stumbling blocks&lt;br /&gt;
** Displaying &amp;quot;uncommon&amp;quot; text in both game descriptions and file paths&lt;br /&gt;
*** &amp;quot;Decomposed&amp;quot; letters, i.e. base letter + combining glyphs&lt;br /&gt;
*** CJK&lt;br /&gt;
*** Arabic and other scripts where letters change depending on their place in the word&lt;br /&gt;
*** Right-to-left&lt;br /&gt;
** Shortening those strings when they don&#039;t fit in their fields is also potentially difficult&lt;br /&gt;
&lt;br /&gt;
=== Localization ===&lt;br /&gt;
* Text in exceptions?&lt;br /&gt;
** At least the user-visible ones, like &amp;quot;Failed to detect game&amp;quot;&lt;br /&gt;
** Or maybe we should clean that up and split them into &amp;quot;program logic failure&amp;quot; and &amp;quot;user failure&amp;quot;, with only the latter translated&lt;br /&gt;
* Strings for the engine loader progress bar&lt;br /&gt;
* Debug console string&lt;br /&gt;
* GUI (see above) strings&lt;br /&gt;
* [http://www.gnu.org/software/gettext/ GNU gettext] would be one solution&lt;br /&gt;
&lt;br /&gt;
=== Unit tests ===&lt;br /&gt;
* More unit tests&lt;br /&gt;
&lt;br /&gt;
=== Phaethon ===&lt;br /&gt;
* More readers&lt;br /&gt;
* Writers?&lt;br /&gt;
&lt;br /&gt;
=== Model converters ===&lt;br /&gt;
* Document the model formats&lt;br /&gt;
* Convert between the binary model formats and their ASCII equivalents&lt;br /&gt;
* Convert between the binary model formats and ones that can be opened by modelling tools&lt;br /&gt;
** 3D Studio Max&lt;br /&gt;
** Blender&lt;br /&gt;
&lt;br /&gt;
=== Full-fledged modding toolset ===&lt;br /&gt;
* Similar to the NWN, NWN2 or Witcher toolset, but portable and FLOSS&lt;br /&gt;
** Might also support other games?&lt;br /&gt;
* Out of scope for xoreos&lt;br /&gt;
** Still, such a thing would be welcome under the xoreos banner&lt;br /&gt;
* [http://sourceforge.net/projects/neveredit/ Neveredit] might still be worth a look&lt;br /&gt;
&lt;br /&gt;
== Build system ==&lt;br /&gt;
&lt;br /&gt;
=== CMake ===&lt;br /&gt;
* Current doesn&#039;t set the git version to &amp;quot;+unk&amp;quot; when git isn&#039;t found&lt;br /&gt;
* make doxygen?&lt;br /&gt;
&lt;br /&gt;
=== Autotools ===&lt;br /&gt;
* Suppress the &amp;quot;fatal: not a git repository&amp;quot; when building gitstamp without a git directory&lt;br /&gt;
* Increased modularity&lt;br /&gt;
** Disabling engines&lt;br /&gt;
** Making library dependencies optional (and disabling certain features, then)&lt;br /&gt;
*** liblzma? Only needed for the iOS version of KotOR&lt;br /&gt;
*** libxml2? Only needed for the two Dragon Age games&lt;br /&gt;
** When something is disabled, skip it, if possible&lt;br /&gt;
*** Like the videos in KotOR Mac&lt;br /&gt;
** If skipping is not possible, error out&lt;br /&gt;
&lt;br /&gt;
== Nitro ==&lt;br /&gt;
&lt;br /&gt;
* The Nintendo DS (Nitro) specific file formats should probably be moved out of src/aurora/ and into src/nitro&lt;br /&gt;
* nitrofile, cdpth, nsbtx, smallfile&lt;br /&gt;
** nsbtx needs to be split into a class accessing the textures in src/nitro/ and an archive class on top in src/aurora/&lt;br /&gt;
** This means src/aurora/ accesses src/nitro/, so libnitro.la needs to come after libaurora.la in the linking order&lt;br /&gt;
* ndsrom as well?&lt;br /&gt;
* What about nftrfont and model_sonic in src/graphics/aurora/?&lt;br /&gt;
** src/graphics/nitro/?&lt;br /&gt;
** This would have src/graphics/nitro/ access src/graphics/aurora/, so graphics/libnitro.la needs to come before graphics/libaurora.la in the linking order&lt;br /&gt;
** That would be the other way round than for src/nitro/. Too confusing?&lt;br /&gt;
&lt;br /&gt;
== Graphics ==&lt;br /&gt;
&lt;br /&gt;
=== MDL supermodels and animations ===&lt;br /&gt;
* Mostly working in NWN thanks to jbowtie&#039;s work&lt;br /&gt;
* Might need some cleanup&lt;br /&gt;
* Models should smoothly change between different animations&lt;br /&gt;
* The animation system probably needs to be a bit more complex, to allow for &amp;quot;overlaying&amp;quot; different animations onto each other. For example, for speaking while holding an object and keeping the head focused on the PC character.&lt;br /&gt;
&lt;br /&gt;
=== Lighting ===&lt;br /&gt;
* We don&#039;t yet have a proper light system&lt;br /&gt;
* I started working on it: [https://drmccoy.de/xoreos/20150809T223407.png], but my approach is seriously lacking. You can see the edges of the tiles that make up on NWN area in many cases ([https://drmccoy.de/xoreos/20150809T223507.png], [https://drmccoy.de/xoreos/20150809T223548.png])&lt;br /&gt;
** See the [https://github.com/xoreos/xoreos/tree/light light branch] in the git repository&lt;br /&gt;
** Of course, the actual glLight* stuff won&#039;t be relevant anymore as soon as shaders are there&lt;br /&gt;
** Lighting in several (ASCII?) area tiles is broken&lt;br /&gt;
*** The door in Prelude.nwm&#039;s &amp;quot;m0q1a&amp;quot; area&lt;br /&gt;
*** A water tile in Chapter2.nwm&#039;s &amp;quot;map_m2q1a&amp;quot; area&lt;br /&gt;
*** A sloped snow tile in XP2_Chapter3.nwm&#039;s &amp;quot;thecityoflostsou&amp;quot;&lt;br /&gt;
&lt;br /&gt;
=== Materials ===&lt;br /&gt;
* Materials in The Witcher are closely tied to shaders&lt;br /&gt;
&lt;br /&gt;
=== OpenGL and Shaders ===&lt;br /&gt;
* mirv_ is currently working on a graphics system overhaul, complete with shader support&lt;br /&gt;
* All Aurora games use shaders in some form&lt;br /&gt;
* NWN uses ARB shaders. We probably need to rewrite them from scratch&lt;br /&gt;
* DirectX shaders might be automatically convertible with Cg?&lt;br /&gt;
* Otherwise, look at what Wine does with the shaders, and use that as a basis?&lt;br /&gt;
* All the games, even NWN, use some form of shaders. Still totally missing from xoreos, since we have no idea how to use them in general yet. Moreover, this was before GLSL, so they&#039;re in the old assembly-like language. We probably need to rewrite them from scratch&lt;br /&gt;
* We need shaders for tinting in NWN2 (objects and area geometry) and TexturePaint nodes in Witcher&lt;br /&gt;
&lt;br /&gt;
=== SDL 1.2 ===&lt;br /&gt;
* Optionally link against SDL 1.2 instead of SDL 2&lt;br /&gt;
* Should ideally use a configure flag to select between the two&lt;br /&gt;
** Maybe a CMake flag as well, if possible&lt;br /&gt;
* Assigned to clone2727, so anybody interested in this should coordinate with him&lt;br /&gt;
&lt;br /&gt;
== Videos ==&lt;br /&gt;
&lt;br /&gt;
=== XMV/WMV ===&lt;br /&gt;
* Used in Xbox versions of KotOR/KotOR2&lt;br /&gt;
* Our WMV decoder (for XMV videos used in Xbox versions) is missing P-frames and J-frames&lt;br /&gt;
** Code exists in ffmpeg, but is connected to the MPEG-4 family mess&lt;br /&gt;
&lt;br /&gt;
=== Actimagine VX ===&lt;br /&gt;
* Used in the Nintendo DS game Sonic Chronicles&lt;br /&gt;
* https://wiki.multimedia.cx/index.php?title=Actimagine_Video_Codec&lt;br /&gt;
&lt;br /&gt;
=== Sorenson 3 ===&lt;br /&gt;
* One single video in the Mac port of KotOR2, the Aspyr logo, uses the Sorenson 3 codec&lt;br /&gt;
** ffmpeg has a decoder, but it&#039;s connected to the MPEG-4 family mess (SVQ3 is similar to H.264)&lt;br /&gt;
* ScummVM needs that too&lt;br /&gt;
** While xoreos is GPLv3+, ScummVM is GPLv2+&lt;br /&gt;
** Somebody implementing Sorenson 3 for xoreos should ideally give explicit permission to relicense it GPLv2+ for ScummVM&lt;br /&gt;
*** Of course, if the decoder is based on prior work by other people, it has to be compatible with both GPLv2+ and GPLv3+&lt;br /&gt;
&lt;br /&gt;
=== Optimizations ===&lt;br /&gt;
* Optimize our simple BitStream interface&lt;br /&gt;
** See [https://fgiesen.wordpress.com/2016/01/02/end-of-buffer-checks-in-decompressors/ this blog post]&lt;br /&gt;
** Specifically, we don&#039;t do any peeking at all&lt;br /&gt;
** It still needs to handle different memory layouts, though&lt;br /&gt;
* Likewise, our Huffman class could probably be tuned a lot&lt;br /&gt;
* Pull in fft/rdft/dct/mdct optimizations from FFmpeg?&lt;br /&gt;
* I experimented with that in a private branch and it didn&#039;t do anything for Bink performance&lt;br /&gt;
&lt;br /&gt;
== Sound ==&lt;br /&gt;
&lt;br /&gt;
=== FMOD ===&lt;br /&gt;
* Dragon Age: Origins uses FMOD for sound and music&lt;br /&gt;
* I have experimental FSB (FMOD sound bank) support working in a private branch&lt;br /&gt;
* FEV (FMOD events) format is still unknown to us&lt;br /&gt;
** Apparently, groups of event lists with events&lt;br /&gt;
** Event is everything from &amp;quot;play sound&amp;quot;, over &amp;quot;set volume&amp;quot; to &amp;quot;apply echo&amp;quot;&lt;br /&gt;
** Game areas specify the group to use for the area&lt;br /&gt;
** Scripts then probably tell FMOD to play event lists out of that group&lt;br /&gt;
&lt;br /&gt;
=== Wwise ===&lt;br /&gt;
* Dragon Age 2 uses Wwise for sound and music&lt;br /&gt;
* Should be similar in concept to FMD&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
=== Gamepad binding ===&lt;br /&gt;
* The Xbox versions of KotOR and KotOR2 don&#039;t use a mouse. We have basic support for joysticks/gamepads, but no real bindings to the engine or ideas how to handle that in general&lt;br /&gt;
* We might want to handle the controller support the new KotOR2 Steam update brought&lt;br /&gt;
** override folder contains a gamepad.txt then&lt;br /&gt;
* Also hack in controller support for a non-Steam KotOR2? And for KotOR?&lt;br /&gt;
* Controller support in Jade Empire&lt;br /&gt;
* Controller support for Sonic? It is a Nintendo DS game after all&lt;br /&gt;
* Controller support for the non-console versions of the Dragon Age games?&lt;br /&gt;
&lt;br /&gt;
== Network ==&lt;br /&gt;
* We need a network subsystem&lt;br /&gt;
** [https://www.libsdl.org/projects/SDL_net/ SDL_net]?&lt;br /&gt;
** [http://www.boost.org/doc/libs/release/libs/asio/ Boost.Asio]?&lt;br /&gt;
** More options here: http://stackoverflow.com/questions/118945/best-c-c-network-library&lt;br /&gt;
* Engines need to be split into client and server classes&lt;br /&gt;
** The original engines all still do that, even when not exposing anything to users&lt;br /&gt;
** NWN and NWN2 allow user multiplayer&lt;br /&gt;
&lt;br /&gt;
== Engines ==&lt;br /&gt;
&lt;br /&gt;
=== Script system ===&lt;br /&gt;
* ImperatorPrime had started on a script system rewrite&lt;br /&gt;
** Includes functions with real signatures&lt;br /&gt;
** Maybe switch to that, if it works&lt;br /&gt;
* Rounds, object heartbeat scripts&lt;br /&gt;
* KotOR2 and NWN2 have some extensions&lt;br /&gt;
** It seems like they don&#039;t need any extensions to the low-level bytecode stuff&lt;br /&gt;
* Witcher uses Lua scripts together with NWScript&lt;br /&gt;
* Sonic has no scripts at all, it seems&lt;br /&gt;
* Currently a script in an infinite loop locks the game thread&lt;br /&gt;
** Timeout? Asynchronous script execution?&lt;br /&gt;
&lt;br /&gt;
=== NWN ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Basics are there, but needs fleshing out&lt;br /&gt;
** Character generator is mostly working&lt;br /&gt;
* [[Pathfinding]], walkmesh&lt;br /&gt;
** &amp;quot;Moving&amp;quot; should move the PC, not the camera&lt;br /&gt;
** NPC walking&lt;br /&gt;
** Triggers, areas on the floor that calls scripts on enter/leave&lt;br /&gt;
* Models&lt;br /&gt;
** ASCII models need averaging of smooth group normals&lt;br /&gt;
* NWN objects need an inventory concept&lt;br /&gt;
** Player characters&#039; might be different&lt;br /&gt;
*** Inventory tetris&lt;br /&gt;
*** Inventory item icons&lt;br /&gt;
* Multi-page asian fonts&lt;br /&gt;
* LanguageID 0 is not necessarily &amp;quot;English&amp;quot;, but &amp;quot;The language of the game install&amp;quot;&lt;br /&gt;
** This is okay for languages with Latin characters&lt;br /&gt;
** Messes up strings in community modules with Asian languages that stuff strings in to languageID 0&lt;br /&gt;
** The original fails there too, though&lt;br /&gt;
&lt;br /&gt;
=== KotOR/KotOR2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Many are already there&lt;br /&gt;
* Dialogues&lt;br /&gt;
** DLG files, similar to NWN&lt;br /&gt;
** Some extensions, like camera setup&lt;br /&gt;
** Dialogues are displayed very different than NWN&lt;br /&gt;
** KotOR2 has script extensions&lt;br /&gt;
*** Passing parameters to scripts&lt;br /&gt;
*** Call several scripts, combine with AND/OR for branching&lt;br /&gt;
* Animations&lt;br /&gt;
** Mostly working now&lt;br /&gt;
* Minigames&lt;br /&gt;
** Swoop racing&lt;br /&gt;
** Pazaak&lt;br /&gt;
** Hardcoded, mostly removed from usual game logic&lt;br /&gt;
&lt;br /&gt;
=== Jade Empire ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Main menu with options submenu is there&lt;br /&gt;
* Minigames&lt;br /&gt;
** Flyer, top-down shoot-em-up thing&lt;br /&gt;
** Hardcoded, mostly removed from usual game logic&lt;br /&gt;
* Player character&lt;br /&gt;
** Needs research&lt;br /&gt;
* Sound&lt;br /&gt;
** Uses an ASCII variant of the [http://wiki.multimedia.cx/index.php?title=XACT XACT formats]&lt;br /&gt;
*** Cues probably not as complex as FMOD/Wwise&lt;br /&gt;
*** Effects need extension of the Sound system, maybe&lt;br /&gt;
** Xbox version might use the binary format?&lt;br /&gt;
*** Sound banks could be handles as archives and indexed in the ResourceManager?&lt;br /&gt;
** [https://github.com/flibitijibibo/FACT FACT] is an implementation of XAudio, including XACT, zlib-licensed&lt;br /&gt;
&lt;br /&gt;
=== NWN2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Implemented using XML&lt;br /&gt;
** See [[#Broken NWN2 XML|Broken NWN2 XML]]&lt;br /&gt;
* Animations (Granny)&lt;br /&gt;
** [https://github.com/SkywingvL/nwn2dev-public nwn2-dev] contains some code working with Granny data&lt;br /&gt;
*** Call into the original Granny DLL to convert between binary and ASCII Granny data, though&lt;br /&gt;
** [https://github.com/berenm/xoreos-tools/tree/granny berenm started some Granny RE]&lt;br /&gt;
** Based on berenm&#039;s RE efforts, Arbos has written a tool to convert to/from MDB+GR2: https://github.com/Arbos/nwn2mdk&lt;br /&gt;
*** Probably a good starting point for integrating NWN2 animations into xoreos&lt;br /&gt;
* Facial animations (FaceFX)&lt;br /&gt;
* Trees (SpeedTree)&lt;br /&gt;
* Proper evaluation of creature model parts (equipped items)&lt;br /&gt;
* Player character&lt;br /&gt;
** Reading of PC files in creature&lt;br /&gt;
* Walkmeshes. CromFr wrote a specs document here: https://gist.github.com/CromFr/104bac52dc9191099d9d9e3dbd2c4975&lt;br /&gt;
&lt;br /&gt;
=== Sonic Chronicles ===&lt;br /&gt;
* Allow using the contents from an extracted NDS file?&lt;br /&gt;
* Menus&lt;br /&gt;
** GUI files that are GFF&lt;br /&gt;
** Actions in a state machine in GDA files?&lt;br /&gt;
* Music/Sound&lt;br /&gt;
** Music is apparently similar to MIDI, or to a tracker format?&lt;br /&gt;
** Sounds and instruments for music are in a sound_data.sadl archive&lt;br /&gt;
* Animations&lt;br /&gt;
** Bone animations, best implemented with shaders, blocked by the graphics subsystem rewrite&lt;br /&gt;
* Player character(s)&lt;br /&gt;
** Needs research&lt;br /&gt;
&lt;br /&gt;
=== The Witcher ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Apparently build using Lua&lt;br /&gt;
** System/Scripts/ has gui*.luc files&lt;br /&gt;
* Animations&lt;br /&gt;
** Needs research&lt;br /&gt;
* Player character, Geralt&lt;br /&gt;
** Needs research&lt;br /&gt;
&lt;br /&gt;
=== Dragon Age: Origins / Dragon Age 2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Scaleform_GFx Scaleform GFx]&lt;br /&gt;
** [http://social.bioware.com/wiki/datoolset/index.php/UI_Tutorial_%28draft%29 UI Tutorial] on the Dragon Age toolset wiki&lt;br /&gt;
** Flash-based!&lt;br /&gt;
** A good starting point for a reimplementation might be [https://en.wikipedia.org/wiki/Gameswf Gameswf].&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Gnash Gnash], [https://en.wikipedia.org/wiki/Lightspark Lightspark], [https://en.wikipedia.org/wiki/Swfdec Swfdec]&lt;br /&gt;
** [http://www.nowrap.de/flasm.html Flasm] can disassemble/assemble ActionScript, [http://www.nowrap.de/flare.html Flare] can decompile it&lt;br /&gt;
** [https://wwwimages2.adobe.com/content/dam/acom/en/devnet/pdf/swf-file-format-spec.pdf swf-file-format-spec.pdf] is a great reference which covers mostly every aspect of the gfx files.&lt;br /&gt;
** [https://github.com/jindrapetrik/jpexs-decompiler jpexs-decompiler] can decompile and handles scaleform specific tags.&lt;br /&gt;
* Animations&lt;br /&gt;
** Bone animations, best implemented with shaders, blocked by the graphics subsystem rewrite&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Developer_Central&amp;diff=416</id>
		<title>Developer Central</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Developer_Central&amp;diff=416"/>
		<updated>2018-06-26T16:54:07Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this page is to give a link to all kinds of resources that contain information valuable to current and future developers of xoreos.&lt;br /&gt;
&lt;br /&gt;
== The source repository ==&lt;br /&gt;
&lt;br /&gt;
The main xoreos source repositories are hosted on [https://github.com/xoreos/ GitHub]. Please see the [[Git]] page on details on how the repositories are structured and how to retrieve the code.&lt;br /&gt;
&lt;br /&gt;
== Compilation ==&lt;br /&gt;
&lt;br /&gt;
See the [[Compiling xoreos]] and [[Compiling xoreos-tools]] pages for information on how to compile our source code on various operating systems.&lt;br /&gt;
&lt;br /&gt;
== Community ==&lt;br /&gt;
&lt;br /&gt;
We strive to be a friendly and open development community. Therefore, we have adopted a [https://github.com/xoreos/xoreos/blob/master/CODE_OF_CONDUCT.md Code of Conduct] guiding us. By participating in this project you agree to abide by its terms.&lt;br /&gt;
&lt;br /&gt;
Our main place for organizing and socializing is the [[IRC channel|#xoreos channel on Freenode IRC]]. You will find most of the developers idling there, happy to answer any questions you might have. If you plan to become a frequent contributor, please consider regularly joining this channel as well.&lt;br /&gt;
&lt;br /&gt;
However, there is not public log bot in #xoreos, so there is no public, permanent record. Therefore, discussions about far reaching changes in the codebase are best held on [[Mailing lists|our mailing list]]. Contributors are encouraged to subscribe to this list.&lt;br /&gt;
&lt;br /&gt;
If you intend to work on a feature, or otherwise contribute to xoreos, please notify us before-hand, so that unnecessary, accidentally doubling of work can be avoided.&lt;br /&gt;
&lt;br /&gt;
== Reporting bugs ==&lt;br /&gt;
&lt;br /&gt;
Bugs should be reported on the GitHub issue tracker. If the bug concerns xoreos itself, use the [https://github.com/xoreos/xoreos/issues one for xoreos], if the bug concerns the xoreos-tools, use the [https://github.com/xoreos/xoreos-tools/issues one for xoreos-tools]. Likewise, all the other [https://github.com/xoreos repositories] have issue tracking enabled.&lt;br /&gt;
&lt;br /&gt;
== Code style ==&lt;br /&gt;
&lt;br /&gt;
We have [[Code Formatting Conventions]] you are expected to follow. Patches and pull requests that do not follow these conventions will be rejected or at least delayed until they are cleaned up to comply.&lt;br /&gt;
&lt;br /&gt;
== Commit guidelines ==&lt;br /&gt;
&lt;br /&gt;
Please read the [[Commit Guidelines]]. We want to keep our project history clean and readable.&lt;br /&gt;
&lt;br /&gt;
== Branches ==&lt;br /&gt;
&lt;br /&gt;
Do not work directly on the master branch. Instead, use [https://www.atlassian.com/git/tutorials/comparing-workflows/feature-branch-workflow feature branches], one for each new feature you are working on. This ensures that each feature has its own, clean history that can be reviewed more easily. Once the feature has been merged into the main development tree, you are of course free to delete your feature branch again.&lt;br /&gt;
&lt;br /&gt;
== Pull Requests ==&lt;br /&gt;
&lt;br /&gt;
If you do not have push permissions to the official xoreos repositories, and especially if you&#039;re a first-time contributor, we prefer to receive your changes as a [https://help.github.com/articles/using-pull-requests pull request on GitHub]. This requires you to have/register a GitHub account, fork our repository, commit your changes to a branch and then issue a Pull Request.&lt;br /&gt;
&lt;br /&gt;
Please only add commits belonging to this one feature to the pull requests; do not intersperse them with unrelated changes. Also try to [https://git-scm.com/book/en/v2/Git-Tools-Rewriting-History actively tidy your history]: combine related commits with interactive rebasing, separate monolithic commits, etc. Feel free to force-push to your feature branch to tidy your history.&lt;br /&gt;
&lt;br /&gt;
Before and during the review process, please keep up to date with the xoreos master branch by [https://git-scm.com/book/en/v2/Git-Branching-Rebasing rebasing] your changes onto the current master.&lt;br /&gt;
&lt;br /&gt;
== Pushing to the official repositories ==&lt;br /&gt;
&lt;br /&gt;
Once we&#039;ve made sure that you understood and can follow the style and commit guidelines and you expressed interest in further contributing to xoreos, we will be happy to have you join the xoreos development team, and grant you push permissions to the official repositories. You are then expected to continue to follow these guidelines out of your own accord, without the need for intervention by other developers. If you are unsure about how a specific case interact with the guidelines, please feel free to ask.&lt;br /&gt;
&lt;br /&gt;
To avoid people accidentally working on the same feature, or otherwise stepping on each others&#039; toes, consider announcement what you are working on in the [[IRC channel]] or the [[Mailing lists|mailing list]].&lt;br /&gt;
&lt;br /&gt;
== Continuous Integration ==&lt;br /&gt;
&lt;br /&gt;
The public xoreos repositories are build by two [https://en.wikipedia.org/wiki/Continuous_integration Continuous Integration] services on every push: [https://travis-ci.org/ Travis CI] (for GNU/Linux, using both the autotools and the CMake build systems and also using both gcc and clang) and [https://www.appveyor.com/ AppVeyor] (for Windows, using Microsoft Visual Studio). If a compilation error occurs, the build failure announced is on our [https://wiki.xoreos.org/index.php?title=IRC_channel IRC channel], so that it may be fixed quickly. Pull Requests are also run through these CI services and we like to have all failures fixed before merging.&lt;br /&gt;
&lt;br /&gt;
== Unit tests ==&lt;br /&gt;
&lt;br /&gt;
The xoreos repositories also provide unit tests for many common classes. These are build and run right after the main binaries on every push, by the CI services we use. A failure in one of these unit tests leads to the build being treated as failed. That way, it&#039;s immediately obvious when we break anything.&lt;br /&gt;
&lt;br /&gt;
All xoreos developers are advised to run these unit tests themselves while writing code that touches the common code. In both of our build systems, &amp;quot;make check&amp;quot; does exactly this.&lt;br /&gt;
&lt;br /&gt;
When writing new common classes, or adding functionality to existing ones, also writing new unit tests checking the new functionality is hugely appreciated.&lt;br /&gt;
&lt;br /&gt;
== Releases ==&lt;br /&gt;
&lt;br /&gt;
A short overview on how xoreos releases work can be found on the [[Releases]] page.&lt;br /&gt;
&lt;br /&gt;
== Reverse engineering help ==&lt;br /&gt;
&lt;br /&gt;
For people starting out with reverse engineering, here are a few useful resources:&lt;br /&gt;
&lt;br /&gt;
* The [http://wiki.scummvm.org/index.php/HOWTO-Reverse_Engineering HOWTO-Reverse Engineering] page in ScummVM&#039;s wiki&lt;br /&gt;
* [http://rewiki.awiki.org/wiki/Main_Page REWiki] contains a collection of game reverse engineering knowledge. They have a [http://rewiki.awiki.org/wiki/Reverse_engineering_hints hints page] as well&lt;br /&gt;
* [http://wiki.xentax.com/index.php?title=Game_File_Format_Central XentaxWiki] focuses on game file formats. They too have a [http://wiki.xentax.com/index.php?title=DGTEFF guide page]&lt;br /&gt;
* For audio and video formats, there&#039;s [http://wiki.multimedia.cx/ MultimediaWiki], which is associated with the ffmpeg and libav projects&lt;br /&gt;
&lt;br /&gt;
== Modding communities ==&lt;br /&gt;
&lt;br /&gt;
A lot of information about the file formats can be gleamed from the modding communities:&lt;br /&gt;
&lt;br /&gt;
* [https://neverwintervault.org/ The Neverwinter Vault] for Neverwinter Nights and Neverwinter Nights 2&lt;br /&gt;
* [http://nwn2.wikia.com/wiki/Main_Page NWN2 wiki] for Neverwinter Nights 2&lt;br /&gt;
* [https://deadlystream.com/ Deadly Stream] for Knights of the Old Republic and Knights of the Old Republic II&lt;br /&gt;
* [http://jadeempire-modding.wikia.com/wiki/Jade_Empire_Modding_Wiki Jade Empire Modding wiki] for Jade Empire&lt;br /&gt;
* The [http://www.datoolset.net/wiki/Main_Page Dragon Age Toolset wiki] for Dragon Age: Origins and Dragon Age II&lt;br /&gt;
* The [http://witcher.wikia.com/wiki/Category:File_Formats Witcher wiki] for The Witcher&lt;br /&gt;
* [http://sonicretro.org/ Sonic Retro] for Sonic Chronicles&lt;br /&gt;
* [https://www.nexusmods.com/ Nexus Mods]&lt;br /&gt;
* [https://nwnlexicon.com/index.php?title=Main_Page NWN Lexicon]&lt;br /&gt;
&lt;br /&gt;
== To do list ==&lt;br /&gt;
&lt;br /&gt;
Our [[TODO|Main TODO list]] contains a rambly, non-exhaustive collection of things left to do.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Releases&amp;diff=415</id>
		<title>Releases</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Releases&amp;diff=415"/>
		<updated>2018-06-26T16:52:52Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: Created page with &amp;quot;__TOC__  ==git tag and version numbers==  In general, a full xoreos release consists of two tags in each of the xoreos, xoreos-tools and phaethon repositories. On tag is the a...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__TOC__&lt;br /&gt;
&lt;br /&gt;
==git tag and version numbers==&lt;br /&gt;
&lt;br /&gt;
In general, a full xoreos release consists of two tags in each of the xoreos, xoreos-tools and phaethon repositories. On tag is the actual release, which looks like &amp;quot;v0.0.4&amp;quot;. The other is used to calculate the number of commits since the release for git builds and looks like &amp;quot;desc/0.0.4&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Both tags point to the same release announcement commit. The release tag will have release notes, source and pre-compiled binary packages for Linux, macOS and Windows attached on GitHub. The downloads page on the xoreos website will also point to the same binary packages.&lt;br /&gt;
&lt;br /&gt;
The three main repositories (xoreos, xoreos-tools and phaethon) have a linked release schedule, each advancing to the same version number on release. All other repositories are &amp;quot;floating&amp;quot; and are not versioned.&lt;br /&gt;
&lt;br /&gt;
==Code names==&lt;br /&gt;
&lt;br /&gt;
Each release has an (inofficial) code name, like &amp;quot;Aribeth&amp;quot; for the first release 0.0.2. These names won&#039;t appear in the code itself. They&#039;re only used on the website and for promotional concerns.&lt;br /&gt;
&lt;br /&gt;
The current plans for code names is to use character names found in the games xoreos targets. Each release advances both the letter of the alphabet that name starts with, and the game the character is found (in game release order). Each of those wrap around at the end.&lt;br /&gt;
&lt;br /&gt;
The games were released in this order:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! style=&amp;quot;text-align:left;&amp;quot;| Year&lt;br /&gt;
! style=&amp;quot;text-align:left;&amp;quot;| Game&lt;br /&gt;
|-&lt;br /&gt;
|2002 || Neverwinter Nights&lt;br /&gt;
|-&lt;br /&gt;
|2003 || Knights of the Old Republic&lt;br /&gt;
|-&lt;br /&gt;
|2004 || Knights of the Old Republic II&lt;br /&gt;
|-&lt;br /&gt;
|2005 || Jade Empire&lt;br /&gt;
|-&lt;br /&gt;
|2006 || Neverwinter Nights 2&lt;br /&gt;
|-&lt;br /&gt;
|2007 || The Witcher&lt;br /&gt;
|-&lt;br /&gt;
|2008 || Sonic Chronicles&lt;br /&gt;
|-&lt;br /&gt;
|2009 || Dragon Age: Origins&lt;br /&gt;
|-&lt;br /&gt;
|2011 || Dragon Age II&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The past releases were this:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! style=&amp;quot;text-align:left;&amp;quot;| Version&lt;br /&gt;
! style=&amp;quot;text-align:left;&amp;quot;| Code name&lt;br /&gt;
! style=&amp;quot;text-align:left;&amp;quot;| Game&lt;br /&gt;
|-&lt;br /&gt;
|0.0.2 || Aribeth || Neverwinter Nights&lt;br /&gt;
|-&lt;br /&gt;
|0.0.3 || Bastila || Knights of the Old Republic&lt;br /&gt;
|-&lt;br /&gt;
|0.0.4 || Chodo || Knights of the Old Republic II&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Continuing, the next releases would be:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! style=&amp;quot;text-align:left;&amp;quot;| Version&lt;br /&gt;
! style=&amp;quot;text-align:left;&amp;quot;| Code name&lt;br /&gt;
! style=&amp;quot;text-align:left;&amp;quot;| Game&lt;br /&gt;
|-&lt;br /&gt;
|0.0.5  || Dawn Star? || Jade Empire&lt;br /&gt;
|-&lt;br /&gt;
|0.0.6  || Elanee? || Neverwinter Nights 2&lt;br /&gt;
|-&lt;br /&gt;
|0.0.7  || Foltest? || The Witcher&lt;br /&gt;
|-&lt;br /&gt;
|0.0.8  || General Raxos? Green Hill Zone? || Sonic Chronicles&lt;br /&gt;
|-&lt;br /&gt;
|0.0.9  || Herren? || Dragon Age: Origins&lt;br /&gt;
|-&lt;br /&gt;
|0.0.10 || Isabela? || Dragon Age II&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Release notes==&lt;br /&gt;
&lt;br /&gt;
The release notes summarize the changes found in the ChangeLog file, so that they&#039;re more easily digested. The same summary can be found in the NEWS.md file.&lt;br /&gt;
&lt;br /&gt;
Additionally, the release notes on GitHub will also contain links to Arch Linux&#039;s AUR, Linux distribution build files in the repository and similar. There will also be a list describing which pre-compiled binary packages are available and their SHA-256 checksums.&lt;br /&gt;
&lt;br /&gt;
==Downloads==&lt;br /&gt;
&lt;br /&gt;
Several pre-compiled binary packages will be available on the GitHub release notes and the website downloads page. These are created by [[User:DrMcCoy]] using cross-compilers running on Linux.&lt;br /&gt;
&lt;br /&gt;
The current set-up, to be first used for the upcoming 0.0.5 release, consists of&lt;br /&gt;
&lt;br /&gt;
* A Debian Jessie chroot with gcc 4.9 (full C++11 support), to compile xoreos and xoreos-tools for Linux, 32-bit and 64-bit&lt;br /&gt;
* A Debian Stretch chroot with gcc 6.3 (full C++14 support), to compile Phaethon for Linux, 32-bit and 64-bit&lt;br /&gt;
* OS X Cross, with clang 6.0.0 (full C++17 support), targeting macOS &amp;gt;= 10.9, 64-bit only&lt;br /&gt;
* Mingw-w64 with gcc 7.3 (full C++17 support), targeting Windows, 32-bit and 64-bit&lt;br /&gt;
&lt;br /&gt;
==Website post and press releases==&lt;br /&gt;
&lt;br /&gt;
Each release will also follow a news post on the xoreos website. That news post will be submitted to GamingOnLinux and several subreddits. Submitting the news to other gaming- or Linux-related news sites might be an option, but that hasn&#039;t been fruitful in the past.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Developer_Central&amp;diff=382</id>
		<title>Developer Central</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Developer_Central&amp;diff=382"/>
		<updated>2018-06-17T20:58:35Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this page is to give a link to all kinds of resources that contain information valuable to current and future developers of xoreos.&lt;br /&gt;
&lt;br /&gt;
== The source repository ==&lt;br /&gt;
&lt;br /&gt;
The main xoreos source repositories are hosted on [https://github.com/xoreos/ GitHub]. Please see the [[Git]] page on details on how the repositories are structured and how to retrieve the code.&lt;br /&gt;
&lt;br /&gt;
== Compilation ==&lt;br /&gt;
&lt;br /&gt;
See the [[Compiling xoreos]] and [[Compiling xoreos-tools]] pages for information on how to compile our source code on various operating systems.&lt;br /&gt;
&lt;br /&gt;
== Community ==&lt;br /&gt;
&lt;br /&gt;
We strive to be a friendly and open development community. Therefore, we have adopted a [https://github.com/xoreos/xoreos/blob/master/CODE_OF_CONDUCT.md Code of Conduct] guiding us. By participating in this project you agree to abide by its terms.&lt;br /&gt;
&lt;br /&gt;
Our main place for organizing and socializing is the [[IRC channel|#xoreos channel on Freenode IRC]]. You will find most of the developers idling there, happy to answer any questions you might have. If you plan to become a frequent contributor, please consider regularly joining this channel as well.&lt;br /&gt;
&lt;br /&gt;
However, there is not public log bot in #xoreos, so there is no public, permanent record. Therefore, discussions about far reaching changes in the codebase are best held on [[Mailing lists|our mailing list]]. Contributors are encouraged to subscribe to this list.&lt;br /&gt;
&lt;br /&gt;
If you intend to work on a feature, or otherwise contribute to xoreos, please notify us before-hand, so that unnecessary, accidentally doubling of work can be avoided.&lt;br /&gt;
&lt;br /&gt;
== Reporting bugs ==&lt;br /&gt;
&lt;br /&gt;
Bugs should be reported on the GitHub issue tracker. If the bug concerns xoreos itself, use the [https://github.com/xoreos/xoreos/issues one for xoreos], if the bug concerns the xoreos-tools, use the [https://github.com/xoreos/xoreos-tools/issues one for xoreos-tools]. Likewise, all the other [https://github.com/xoreos repositories] have issue tracking enabled.&lt;br /&gt;
&lt;br /&gt;
== Code style ==&lt;br /&gt;
&lt;br /&gt;
We have [[Code Formatting Conventions]] you are expected to follow. Patches and pull requests that do not follow these conventions will be rejected or at least delayed until they are cleaned up to comply.&lt;br /&gt;
&lt;br /&gt;
== Commit guidelines ==&lt;br /&gt;
&lt;br /&gt;
Please read the [[Commit Guidelines]]. We want to keep our project history clean and readable.&lt;br /&gt;
&lt;br /&gt;
== Branches ==&lt;br /&gt;
&lt;br /&gt;
Do not work directly on the master branch. Instead, use [https://www.atlassian.com/git/tutorials/comparing-workflows/feature-branch-workflow feature branches], one for each new feature you are working on. This ensures that each feature has its own, clean history that can be reviewed more easily. Once the feature has been merged into the main development tree, you are of course free to delete your feature branch again.&lt;br /&gt;
&lt;br /&gt;
== Pull Requests ==&lt;br /&gt;
&lt;br /&gt;
If you do not have push permissions to the official xoreos repositories, and especially if you&#039;re a first-time contributor, we prefer to receive your changes as a [https://help.github.com/articles/using-pull-requests pull request on GitHub]. This requires you to have/register a GitHub account, fork our repository, commit your changes to a branch and then issue a Pull Request.&lt;br /&gt;
&lt;br /&gt;
Please only add commits belonging to this one feature to the pull requests; do not intersperse them with unrelated changes. Also try to [https://git-scm.com/book/en/v2/Git-Tools-Rewriting-History actively tidy your history]: combine related commits with interactive rebasing, separate monolithic commits, etc. Feel free to force-push to your feature branch to tidy your history.&lt;br /&gt;
&lt;br /&gt;
Before and during the review process, please keep up to date with the xoreos master branch by [https://git-scm.com/book/en/v2/Git-Branching-Rebasing rebasing] your changes onto the current master.&lt;br /&gt;
&lt;br /&gt;
== Pushing to the official repositories ==&lt;br /&gt;
&lt;br /&gt;
Once we&#039;ve made sure that you understood and can follow the style and commit guidelines and you expressed interest in further contributing to xoreos, we will be happy to have you join the xoreos development team, and grant you push permissions to the official repositories. You are then expected to continue to follow these guidelines out of your own accord, without the need for intervention by other developers. If you are unsure about how a specific case interact with the guidelines, please feel free to ask.&lt;br /&gt;
&lt;br /&gt;
To avoid people accidentally working on the same feature, or otherwise stepping on each others&#039; toes, consider announcement what you are working on in the [[IRC channel]] or the [[Mailing lists|mailing list]].&lt;br /&gt;
&lt;br /&gt;
== Continuous Integration ==&lt;br /&gt;
&lt;br /&gt;
The public xoreos repositories are build by two [https://en.wikipedia.org/wiki/Continuous_integration Continuous Integration] services on every push: [https://travis-ci.org/ Travis CI] (for GNU/Linux, using both the autotools and the CMake build systems and also using both gcc and clang) and [https://www.appveyor.com/ AppVeyor] (for Windows, using Microsoft Visual Studio). If a compilation error occurs, the build failure announced is on our [https://wiki.xoreos.org/index.php?title=IRC_channel IRC channel], so that it may be fixed quickly. Pull Requests are also run through these CI services and we like to have all failures fixed before merging.&lt;br /&gt;
&lt;br /&gt;
== Unit tests ==&lt;br /&gt;
&lt;br /&gt;
The xoreos repositories also provide unit tests for many common classes. These are build and run right after the main binaries on every push, by the CI services we use. A failure in one of these unit tests leads to the build being treated as failed. That way, it&#039;s immediately obvious when we break anything.&lt;br /&gt;
&lt;br /&gt;
All xoreos developers are advised to run these unit tests themselves while writing code that touches the common code. In both of our build systems, &amp;quot;make check&amp;quot; does exactly this.&lt;br /&gt;
&lt;br /&gt;
When writing new common classes, or adding functionality to existing ones, also writing new unit tests checking the new functionality is hugely appreciated.&lt;br /&gt;
&lt;br /&gt;
== Reverse engineering help ==&lt;br /&gt;
&lt;br /&gt;
For people starting out with reverse engineering, here are a few useful resources:&lt;br /&gt;
&lt;br /&gt;
* The [http://wiki.scummvm.org/index.php/HOWTO-Reverse_Engineering HOWTO-Reverse Engineering] page in ScummVM&#039;s wiki&lt;br /&gt;
* [http://rewiki.awiki.org/wiki/Main_Page REWiki] contains a collection of game reverse engineering knowledge. They have a [http://rewiki.awiki.org/wiki/Reverse_engineering_hints hints page] as well&lt;br /&gt;
* [http://wiki.xentax.com/index.php?title=Game_File_Format_Central XentaxWiki] focuses on game file formats. They too have a [http://wiki.xentax.com/index.php?title=DGTEFF guide page]&lt;br /&gt;
* For audio and video formats, there&#039;s [http://wiki.multimedia.cx/ MultimediaWiki], which is associated with the ffmpeg and libav projects&lt;br /&gt;
&lt;br /&gt;
== Modding communities ==&lt;br /&gt;
&lt;br /&gt;
A lot of information about the file formats can be gleamed from the modding communities:&lt;br /&gt;
&lt;br /&gt;
* [https://neverwintervault.org/ The Neverwinter Vault] for Neverwinter Nights and Neverwinter Nights 2&lt;br /&gt;
* [http://nwn2.wikia.com/wiki/Main_Page NWN2 wiki] for Neverwinter Nights 2&lt;br /&gt;
* [https://deadlystream.com/ Deadly Stream] for Knights of the Old Republic and Knights of the Old Republic II&lt;br /&gt;
* [http://jadeempire-modding.wikia.com/wiki/Jade_Empire_Modding_Wiki Jade Empire Modding wiki] for Jade Empire&lt;br /&gt;
* The [http://www.datoolset.net/wiki/Main_Page Dragon Age Toolset wiki] for Dragon Age: Origins and Dragon Age II&lt;br /&gt;
* The [http://witcher.wikia.com/wiki/Category:File_Formats Witcher wiki] for The Witcher&lt;br /&gt;
* [http://sonicretro.org/ Sonic Retro] for Sonic Chronicles&lt;br /&gt;
* [https://www.nexusmods.com/ Nexus Mods]&lt;br /&gt;
* [https://nwnlexicon.com/index.php?title=Main_Page NWN Lexicon]&lt;br /&gt;
&lt;br /&gt;
== To do list ==&lt;br /&gt;
&lt;br /&gt;
Our [[TODO|Main TODO list]] contains a rambly, non-exhaustive collection of things left to do.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=TODO&amp;diff=381</id>
		<title>TODO</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=TODO&amp;diff=381"/>
		<updated>2018-06-17T19:58:10Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* NWN2 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a long rambly list of things left to do in xoreos and xoreos-tools. Anybody is welcome to tackle any of these tasks, but please also read our [[Developer_Central|general contributor overview]], including our [[Code_Formatting_Conventions|Code Formatting Conventions]], [[Commit_Guidelines|Commit Guidelines]] and [https://github.com/xoreos/xoreos/blob/master/CODE_OF_CONDUCT.md Code of Conduct]. If you plan to do any of these tasks, please also [[Contact_us|contact us]] beforehand, so we can better coordinate multiple people interested in doing the same task, and discuss how to best solve the problem. Thanks. :)&lt;br /&gt;
&lt;br /&gt;
(&#039;&#039;&#039;See also:&#039;&#039;&#039; the Kanban-like &amp;quot;Projects&amp;quot; boards on GitHub: https://github.com/orgs/xoreos/projects, but they&#039;re not public and no way to make public at the moment. Boo.)&lt;br /&gt;
&lt;br /&gt;
== Documentation ==&lt;br /&gt;
&lt;br /&gt;
=== Developer information ===&lt;br /&gt;
* Extend the developer information on the wiki&lt;br /&gt;
** Explain how to get the xoreos sources on various platforms&lt;br /&gt;
** Expand GNU/Linux compiling instructions to cover more distributions&lt;br /&gt;
** Expand Mac OS X compiling instructions&lt;br /&gt;
*** Xcode&lt;br /&gt;
*** Homebrew/MacPorts/Fink&lt;br /&gt;
*** CMake, Libraries&lt;br /&gt;
** [http://wiki.arx-libertatis.org/Developer_Information Arx Libertatis] has an extensive dev page&lt;br /&gt;
* Document file formats on the wiki?&lt;br /&gt;
** Or integrate info into XentaxWiki?&lt;br /&gt;
** Both?&lt;br /&gt;
&lt;br /&gt;
=== User information ===&lt;br /&gt;
* More user information on the wiki&lt;br /&gt;
** How to download xoreos&lt;br /&gt;
** How to install the games on various platforms&lt;br /&gt;
** [http://wiki.arx-libertatis.org/Main_Page Arx Libertatis] does that pretty well&lt;br /&gt;
&lt;br /&gt;
=== Modder information ===&lt;br /&gt;
* Link to relevant modding resources&lt;br /&gt;
* Maybe even some kind of Modder&#039;s Handbook&lt;br /&gt;
** A big overview of modding Aurora games in general&lt;br /&gt;
*** Differences and commonalities between games&lt;br /&gt;
** Linking/Grouping engine functions between games&lt;br /&gt;
&lt;br /&gt;
== Website ==&lt;br /&gt;
&lt;br /&gt;
=== Design ===&lt;br /&gt;
* Better website design?&lt;br /&gt;
** It still should be static in the end&lt;br /&gt;
*** No PHP or Rails&lt;br /&gt;
*** Very light on JavaScript&lt;br /&gt;
*** No Flash!&lt;br /&gt;
** Maybe a bit more unique, graphical&lt;br /&gt;
** For legal reasons, we shouldn&#039;t directly use art or designs from the original games&lt;br /&gt;
*** Something inspired by the art of the orginal games would fit&lt;br /&gt;
&lt;br /&gt;
=== Octopress ===&lt;br /&gt;
* Move away from Octopress?&lt;br /&gt;
** Alternative should still produce static HTML somehow&lt;br /&gt;
** Octopress works rather well. It reads Markdown, which is a plus&lt;br /&gt;
* Octopress 3.0?&lt;br /&gt;
** Not finished yet, it seems&lt;br /&gt;
&lt;br /&gt;
== Standalone(ish) fixes/improvements ==&lt;br /&gt;
&lt;br /&gt;
=== Broken NWN2 XML ===&lt;br /&gt;
* Not standards-conforming XML. Need custom XML parser; stock XML parsing libraries will just throw errors.&lt;br /&gt;
** &amp;lt;nowiki&amp;gt;&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;NWN2UI&amp;quot;&amp;gt;&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
** No single root element&lt;br /&gt;
** Attribute values not enclosed in quotes most of the time&lt;br /&gt;
** Special characters in attribute values not properly escaped&lt;br /&gt;
** Unmatched quotes on several occasions&lt;br /&gt;
* Event functions&lt;br /&gt;
* Special values like PARENT_WIDTH&lt;br /&gt;
* [https://github.com/xoreos/xoreos-tools/pull/1 Altrite is working on a broken-XML fixer]&lt;br /&gt;
&lt;br /&gt;
=== CJK glyphs in the console ===&lt;br /&gt;
* The &amp;quot;system font&amp;quot; we use for our debug console, DejaVu Sans Mono Bold, does not feature any CJK (Chinese, Japanese, Korean) glyphs&lt;br /&gt;
* Not strictly necessary, but nice to have for printing, say, Witcher area names in Asian languages&lt;br /&gt;
* We could maybe integrate CJK glyphs from the [http://fonts.jp/hanazono/ Hanazono fonts] or other suitable libre fonts&lt;br /&gt;
* We need to match the height with DejaVu Sans Mono Bold&lt;br /&gt;
* CJK glyphs tend to be more complex and therefore wider. They&#039;re usually rendered twice as wide as Latin glyphs&lt;br /&gt;
* Our console code needs to take that into account&lt;br /&gt;
&lt;br /&gt;
=== Fuzzing ===&lt;br /&gt;
* Set up fuzzing targets for everything for [https://llvm.org/docs/LibFuzzer.html libFuzzer]&lt;br /&gt;
** File readers, image decoders, etc.&lt;br /&gt;
* Can be integrated with [http://lcamtuf.coredump.cx/afl/ afl] (american fuzzy lop): https://github.com/llvm-mirror/compiler-rt/blob/master/lib/fuzzer/afl/afl_driver.cpp&lt;br /&gt;
* Integrate it with our build system somehow&lt;br /&gt;
** ./configure flag for building with fuzzing instrumentation?&lt;br /&gt;
** Needs to check that the compiler can do that&lt;br /&gt;
** make fuzzers then builds the targets?&lt;br /&gt;
* File formats previously manually fuzzed with afl:&lt;br /&gt;
** CBGT, CDPTH, DDS, NBFS, NCGR, NCLR, SBM, TGA, TPC, TXB&lt;br /&gt;
** 2DA, KEY/BIF, ERF, GFF3, GFF4, GDA, TLK, NSBTX, RIM, SMALL, SSF&lt;br /&gt;
* Continuous fuzzing via [https://github.com/google/oss-fuzz OSS-Fuzz] (currently only taking &amp;quot;important&amp;quot; projects)&lt;br /&gt;
&lt;br /&gt;
=== Script decompiler ===&lt;br /&gt;
* It might be quite useful to have a NWScript decompiler in xoreos-tools&lt;br /&gt;
* We have a script disassembler, ncsdis&lt;br /&gt;
** Which already does code flow analysis&lt;br /&gt;
* Missing:&lt;br /&gt;
** Code generation&lt;br /&gt;
** Collapsing of instruction chains into single-line NWScript code&lt;br /&gt;
*** For example, &amp;quot;int var = foo * bar + quux&amp;quot; compiles to a long chain with multiple temporaries&lt;br /&gt;
** Proper handling of structs and vectors&lt;br /&gt;
&lt;br /&gt;
=== Script compiler ===&lt;br /&gt;
* An NWScript compiler might be useful as well&lt;br /&gt;
** A script assembler might be an easy first step&lt;br /&gt;
&lt;br /&gt;
=== File format writers ===&lt;br /&gt;
* GFF3Writer, GFF4Writer&lt;br /&gt;
** Both necessary to create save games compatible with the original games&lt;br /&gt;
** Also useful for a xml2gff tool&lt;br /&gt;
* xml2tlk&lt;br /&gt;
** TalkTable_GFF::write02() and ::write05()&lt;br /&gt;
** Needs GFF4Writer&lt;br /&gt;
* Archive (ERF, RIM, KEY/BIF) packers?&lt;br /&gt;
&lt;br /&gt;
=== Config file ===&lt;br /&gt;
* Should be more preserving of the layout&lt;br /&gt;
** Especially empty lines&lt;br /&gt;
** UTF-8 Byte-Order-Mark when using native Windows editors&lt;br /&gt;
** \r is currently always stripped. Maybe preserve that too&lt;br /&gt;
*** Autodetect when \r is already used, and add it to new config lines too&lt;br /&gt;
** This basically needs a complete rewrite of the config parser&lt;br /&gt;
*** Don&#039;t just look for comments, just throw everything after &amp;quot;foo=bar&amp;quot; into the &amp;quot;comment&amp;quot; variable, including whitespace&lt;br /&gt;
*** And all whitespace before &amp;quot;foo=bar&amp;quot; into a &amp;quot;prefix&amp;quot; variable&lt;br /&gt;
** Maybe even always add BOM and \r when writing a new config file on Windows?&lt;br /&gt;
&lt;br /&gt;
=== Windows-specific / Wine-specific ===&lt;br /&gt;
* When running my mingw32 cross-compiled xoreos EXE in Wine, the menu button texts are partially cut off&lt;br /&gt;
** Z-fighting issue?&lt;br /&gt;
** Does that also occur on a real Windows?&lt;br /&gt;
&lt;br /&gt;
=== GUI ===&lt;br /&gt;
* xoreos could use a global GUI to start games from&lt;br /&gt;
* Should probably be similar to ScummVM&#039;s GUI, at least in effect&lt;br /&gt;
* Should read the config file, list all targets&lt;br /&gt;
** Press a &amp;quot;Play&amp;quot; button to play the game&lt;br /&gt;
** Press an &amp;quot;Edit&amp;quot; button to edit the entry&lt;br /&gt;
*** Dialog options to edit common settings&lt;br /&gt;
*** An additional free-form editor?&lt;br /&gt;
*** Game-specific options?&lt;br /&gt;
** A button to edit global settings (&amp;quot;xoreos&amp;quot; config domain)&lt;br /&gt;
** For the future, a way to immediately load a saved game?&lt;br /&gt;
** An &amp;quot;Add&amp;quot; button to add a game&lt;br /&gt;
*** File browser&lt;br /&gt;
**** Select directories for most game&lt;br /&gt;
**** Select file for Sonic Chronicles&lt;br /&gt;
*** View current saved games of a target?&lt;br /&gt;
* Probably implemented using OpenGL, just like, say, the console&lt;br /&gt;
* Theme-able/Skinable?&lt;br /&gt;
* Some potential stumbling blocks&lt;br /&gt;
** Displaying &amp;quot;uncommon&amp;quot; text in both game descriptions and file paths&lt;br /&gt;
*** &amp;quot;Decomposed&amp;quot; letters, i.e. base letter + combining glyphs&lt;br /&gt;
*** CJK&lt;br /&gt;
*** Arabic and other scripts where letters change depending on their place in the word&lt;br /&gt;
*** Right-to-left&lt;br /&gt;
** Shortening those strings when they don&#039;t fit in their fields is also potentially difficult&lt;br /&gt;
&lt;br /&gt;
=== Localization ===&lt;br /&gt;
* Text in exceptions?&lt;br /&gt;
** At least the user-visible ones, like &amp;quot;Failed to detect game&amp;quot;&lt;br /&gt;
** Or maybe we should clean that up and split them into &amp;quot;program logic failure&amp;quot; and &amp;quot;user failure&amp;quot;, with only the latter translated&lt;br /&gt;
* Strings for the engine loader progress bar&lt;br /&gt;
* Debug console string&lt;br /&gt;
* GUI (see above) strings&lt;br /&gt;
* [http://www.gnu.org/software/gettext/ GNU gettext] would be one solution&lt;br /&gt;
&lt;br /&gt;
=== Unit tests ===&lt;br /&gt;
* More unit tests&lt;br /&gt;
&lt;br /&gt;
=== Resource Explorer ===&lt;br /&gt;
* A portable, user-friendly graphical resource explorer could be useful&lt;br /&gt;
* [https://github.com/xoreos/phaethon Phaethon] is a start&lt;br /&gt;
** It can look into game archives, show textures and play sounds&lt;br /&gt;
** It uses [https://www.wxwidgets.org/ wxWidgets] to do the GUI&lt;br /&gt;
** Or possibly rewriting it to use [https://www.qt.io/ Qt] is better?&lt;br /&gt;
&lt;br /&gt;
=== Model converters ===&lt;br /&gt;
* Document the model formats&lt;br /&gt;
* Convert between the binary model formats and their ASCII equivalents&lt;br /&gt;
* Convert between the binary model formats and ones that can be opened by modelling tools&lt;br /&gt;
** 3D Studio Max&lt;br /&gt;
** Blender&lt;br /&gt;
&lt;br /&gt;
=== Full-fledged modding toolset ===&lt;br /&gt;
* Similar to the NWN, NWN2 or Witcher toolset, but portable and FLOSS&lt;br /&gt;
** Might also support other games?&lt;br /&gt;
* Out of scope for xoreos&lt;br /&gt;
** Still, such a thing would be welcome under the xoreos banner&lt;br /&gt;
* [http://sourceforge.net/projects/neveredit/ Neveredit] might still be worth a look&lt;br /&gt;
&lt;br /&gt;
== Build system ==&lt;br /&gt;
&lt;br /&gt;
=== CMake ===&lt;br /&gt;
* Current doesn&#039;t set the git version to &amp;quot;+unk&amp;quot; when git isn&#039;t found&lt;br /&gt;
* make install/uninstall?&lt;br /&gt;
* make doxygen?&lt;br /&gt;
&lt;br /&gt;
=== Autotools ===&lt;br /&gt;
* Suppress the &amp;quot;fatal: not a git repository&amp;quot; when building gitstamp without a git directory&lt;br /&gt;
* Increased modularity&lt;br /&gt;
** Disabling engines&lt;br /&gt;
** Making library dependencies optional (and disabling certain features, then)&lt;br /&gt;
*** liblzma? Only needed for the iOS version of KotOR&lt;br /&gt;
*** libxml2? Only needed for the two Dragon Age games&lt;br /&gt;
** When something is disabled, skip it, if possible&lt;br /&gt;
*** Like the videos in KotOR Mac&lt;br /&gt;
** If skipping is not possible, error out&lt;br /&gt;
&lt;br /&gt;
== Nitro ==&lt;br /&gt;
&lt;br /&gt;
* The Nintendo DS (Nitro) specific file formats should probably be moved out of src/aurora/ and into src/nitro&lt;br /&gt;
* nitrofile, cdpth, nsbtx, smallfile&lt;br /&gt;
** nsbtx needs to be split into a class accessing the textures in src/nitro/ and an archive class on top in src/aurora/&lt;br /&gt;
** This means src/aurora/ accesses src/nitro/, so libnitro.la needs to come after libaurora.la in the linking order&lt;br /&gt;
* ndsrom as well?&lt;br /&gt;
* What about nftrfont and model_sonic in src/graphics/aurora/?&lt;br /&gt;
** src/graphics/nitro/?&lt;br /&gt;
** This would have src/graphics/nitro/ access src/graphics/aurora/, so graphics/libnitro.la needs to come before graphics/libaurora.la in the linking order&lt;br /&gt;
** That would be the other way round than for src/nitro/. Too confusing?&lt;br /&gt;
&lt;br /&gt;
== Graphics ==&lt;br /&gt;
&lt;br /&gt;
=== MDL supermodels and animations ===&lt;br /&gt;
* Mostly working in NWN thanks to jbowtie&#039;s work&lt;br /&gt;
* Might need some cleanup&lt;br /&gt;
* Models should smoothly change between different animations&lt;br /&gt;
* The animation system probably needs to be a bit more complex, to allow for &amp;quot;overlaying&amp;quot; different animations onto each other. For example, for speaking while holding an object and keeping the head focused on the PC character.&lt;br /&gt;
&lt;br /&gt;
=== Lighting ===&lt;br /&gt;
* We don&#039;t yet have a proper light system&lt;br /&gt;
* I started working on it: [https://drmccoy.de/xoreos/20150809T223407.png], but my approach is seriously lacking. You can see the edges of the tiles that make up on NWN area in many cases ([https://drmccoy.de/xoreos/20150809T223507.png], [https://drmccoy.de/xoreos/20150809T223548.png])&lt;br /&gt;
** See the [https://github.com/xoreos/xoreos/tree/light light branch] in the git repository&lt;br /&gt;
** Of course, the actual glLight* stuff won&#039;t be relevant anymore as soon as shaders are there&lt;br /&gt;
** Lighting in several (ASCII?) area tiles is broken&lt;br /&gt;
*** The door in Prelude.nwm&#039;s &amp;quot;m0q1a&amp;quot; area&lt;br /&gt;
*** A water tile in Chapter2.nwm&#039;s &amp;quot;map_m2q1a&amp;quot; area&lt;br /&gt;
*** A sloped snow tile in XP2_Chapter3.nwm&#039;s &amp;quot;thecityoflostsou&amp;quot;&lt;br /&gt;
&lt;br /&gt;
=== Materials ===&lt;br /&gt;
* Materials in The Witcher are closely tied to shaders&lt;br /&gt;
&lt;br /&gt;
=== OpenGL and Shaders ===&lt;br /&gt;
* mirv_ is currently working on a graphics system overhaul, complete with shader support&lt;br /&gt;
* All Aurora games use shaders in some form&lt;br /&gt;
* NWN uses ARB shaders. We probably need to rewrite them from scratch&lt;br /&gt;
* DirectX shaders might be automatically convertible with Cg?&lt;br /&gt;
* Otherwise, look at what Wine does with the shaders, and use that as a basis?&lt;br /&gt;
* All the games, even NWN, use some form of shaders. Still totally missing from xoreos, since we have no idea how to use them in general yet. Moreover, this was before GLSL, so they&#039;re in the old assembly-like language. We probably need to rewrite them from scratch&lt;br /&gt;
* We need shaders for tinting in NWN2 (objects and area geometry) and TexturePaint nodes in Witcher&lt;br /&gt;
&lt;br /&gt;
=== SDL 1.2 ===&lt;br /&gt;
* Optionally link against SDL 1.2 instead of SDL 2&lt;br /&gt;
* Should ideally use a configure flag to select between the two&lt;br /&gt;
** Maybe a CMake flag as well, if possible&lt;br /&gt;
* Assigned to clone2727, so anybody interested in this should coordinate with him&lt;br /&gt;
&lt;br /&gt;
== Videos ==&lt;br /&gt;
&lt;br /&gt;
=== XMV/WMV ===&lt;br /&gt;
* Used in Xbox versions of KotOR/KotOR2&lt;br /&gt;
* Our WMV decoder (for XMV videos used in Xbox versions) is missing P-frames and J-frame&lt;br /&gt;
** Code exists in ffmpeg, but is connected to the MPEG-4 family mess&lt;br /&gt;
&lt;br /&gt;
=== Actimagine VX ===&lt;br /&gt;
* Used in the Nintendo DS game Sonic Chronicles&lt;br /&gt;
* https://wiki.multimedia.cx/index.php?title=Actimagine_Video_Codec&lt;br /&gt;
&lt;br /&gt;
=== Sorenson 3 ===&lt;br /&gt;
* One single video in the Mac port of KotOR2, the Aspyr logo, uses the Sorenson 3 codec&lt;br /&gt;
** ffmpeg has a decoder, but it&#039;s connected to the MPEG-4 family mess (SVQ3 is similar to H.264)&lt;br /&gt;
* ScummVM needs that too&lt;br /&gt;
** While xoreos is GPLv3+, ScummVM is GPLv2+&lt;br /&gt;
** Somebody implementing Sorenson 3 for xoreos should ideally give explicit permission to relicense it GPLv2+ for ScummVM&lt;br /&gt;
*** Of course, if the decoder is based on prior work by other people, it has to be compatible with both GPLv2+ and GPLv3+&lt;br /&gt;
&lt;br /&gt;
=== Optimizations ===&lt;br /&gt;
* Optimize our simple BitStream interface&lt;br /&gt;
** See [https://fgiesen.wordpress.com/2016/01/02/end-of-buffer-checks-in-decompressors/ this blog post]&lt;br /&gt;
** Specifically, we don&#039;t do any peeking at all&lt;br /&gt;
** It still needs to handle different memory layouts, though&lt;br /&gt;
* Likewise, our Huffman class could probably be tuned a lot&lt;br /&gt;
* Pull in fft/rdft/dct/mdct optimizations from FFmpeg?&lt;br /&gt;
* I experimented with that in a private branch and it didn&#039;t do anything for Bink performance&lt;br /&gt;
&lt;br /&gt;
== Sound ==&lt;br /&gt;
&lt;br /&gt;
=== FMOD ===&lt;br /&gt;
* Dragon Age: Origins uses FMOD for sound and music&lt;br /&gt;
* I have experimental FSB (FMOD sound bank) support working in a private branch&lt;br /&gt;
* FEV (FMOD events) format is still unknown to us&lt;br /&gt;
** Apparently, groups of event lists with events&lt;br /&gt;
** Event is everything from &amp;quot;play sound&amp;quot;, over &amp;quot;set volume&amp;quot; to &amp;quot;apply echo&amp;quot;&lt;br /&gt;
** Game areas specify the group to use for the area&lt;br /&gt;
** Scripts then probably tell FMOD to play event lists out of that group&lt;br /&gt;
&lt;br /&gt;
=== Wwise ===&lt;br /&gt;
* Dragon Age 2 uses Wwise for sound and music&lt;br /&gt;
* Should be similar in concept to FMD&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
=== Gamepad binding ===&lt;br /&gt;
* The Xbox versions of KotOR and KotOR2 don&#039;t use a mouse. We have basic support for joysticks/gamepads, but no real bindings to the engine or ideas how to handle that in general&lt;br /&gt;
* We might want to handle the controller support the new KotOR2 Steam update brought&lt;br /&gt;
** override folder contains a gamepad.txt then&lt;br /&gt;
* Also hack in controller support for a non-Steam KotOR2? And for KotOR?&lt;br /&gt;
* Controller support in Jade Empire&lt;br /&gt;
* Controller support for Sonic? It is a Nintendo DS game after all&lt;br /&gt;
* Controller support for the non-console versions of the Dragon Age games?&lt;br /&gt;
&lt;br /&gt;
== Network ==&lt;br /&gt;
* We need a network subsystem&lt;br /&gt;
** [https://www.libsdl.org/projects/SDL_net/ SDL_net]?&lt;br /&gt;
** [http://www.boost.org/doc/libs/release/libs/asio/ Boost.Asio]?&lt;br /&gt;
** More options here: http://stackoverflow.com/questions/118945/best-c-c-network-library&lt;br /&gt;
* Engines need to be split into client and server classes&lt;br /&gt;
** The original engines all still do that, even when not exposing anything to users&lt;br /&gt;
** NWN and NWN2 allow user multiplayer&lt;br /&gt;
&lt;br /&gt;
== Engines ==&lt;br /&gt;
&lt;br /&gt;
=== Script system ===&lt;br /&gt;
* ImperatorPrime had started on a script system rewrite&lt;br /&gt;
** Includes functions with real signatures&lt;br /&gt;
** Maybe switch to that, if it works&lt;br /&gt;
* Rounds, object heartbeat scripts&lt;br /&gt;
* KotOR2 and NWN2 have some extensions&lt;br /&gt;
** It seems like they don&#039;t need any extensions to the low-level bytecode stuff&lt;br /&gt;
* Witcher uses Lua scripts together with NWScript&lt;br /&gt;
* Sonic has no scripts at all, it seems&lt;br /&gt;
* Currently a script in an infinite loop locks the game thread&lt;br /&gt;
** Timeout? Asynchronous script execution?&lt;br /&gt;
&lt;br /&gt;
=== NWN ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Basics are there, but needs fleshing out&lt;br /&gt;
** Character generator is mostly working&lt;br /&gt;
* [[Pathfinding]], walkmesh&lt;br /&gt;
** &amp;quot;Moving&amp;quot; should move the PC, not the camera&lt;br /&gt;
** NPC walking&lt;br /&gt;
** Triggers, areas on the floor that calls scripts on enter/leave&lt;br /&gt;
* Models&lt;br /&gt;
** ASCII models need averaging of smooth group normals&lt;br /&gt;
* NWN objects need an inventory concept&lt;br /&gt;
** Player characters&#039; might be different&lt;br /&gt;
*** Inventory tetris&lt;br /&gt;
*** Inventory item icons&lt;br /&gt;
* Multi-page asian fonts&lt;br /&gt;
* LanguageID 0 is not necessarily &amp;quot;English&amp;quot;, but &amp;quot;The language of the game install&amp;quot;&lt;br /&gt;
** This is okay for languages with Latin characters&lt;br /&gt;
** Messes up strings in community modules with Asian languages that stuff strings in to languageID 0&lt;br /&gt;
** The original fails there too, though&lt;br /&gt;
&lt;br /&gt;
=== KotOR/KotOR2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Many are already there&lt;br /&gt;
* Dialogues&lt;br /&gt;
** DLG files, similar to NWN&lt;br /&gt;
** Some extensions, like camera setup&lt;br /&gt;
** Dialogues are displayed very different than NWN&lt;br /&gt;
** KotOR2 has script extensions&lt;br /&gt;
*** Passing parameters to scripts&lt;br /&gt;
*** Call several scripts, combine with AND/OR for branching&lt;br /&gt;
* Animations&lt;br /&gt;
** Mostly working now&lt;br /&gt;
* Minigames&lt;br /&gt;
** Swoop racing&lt;br /&gt;
** Pazaak&lt;br /&gt;
** Hardcoded, mostly removed from usual game logic&lt;br /&gt;
&lt;br /&gt;
=== Jade Empire ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Main menu with options submenu is there&lt;br /&gt;
* Minigames&lt;br /&gt;
** Flyer, top-down shoot-em-up thing&lt;br /&gt;
** Hardcoded, mostly removed from usual game logic&lt;br /&gt;
* Player character&lt;br /&gt;
** Needs research&lt;br /&gt;
* Sound&lt;br /&gt;
** Uses an ASCII variant of the [http://wiki.multimedia.cx/index.php?title=XACT XACT formats]&lt;br /&gt;
*** Cues probably not as complex as FMOD/Wwise&lt;br /&gt;
*** Effects need extension of the Sound system, maybe&lt;br /&gt;
** Xbox version might use the binary format?&lt;br /&gt;
*** Sound banks could be handles as archives and indexed in the ResourceManager?&lt;br /&gt;
** [https://github.com/flibitijibibo/FACT FACT] is an implementation of XAudio, including XACT, zlib-licensed&lt;br /&gt;
&lt;br /&gt;
=== NWN2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Implemented using XML&lt;br /&gt;
** See [[#Broken NWN2 XML|Broken NWN2 XML]]&lt;br /&gt;
* Animations (Granny)&lt;br /&gt;
** [https://github.com/SkywingvL/nwn2dev-public nwn2-dev] contains some code working with Granny data&lt;br /&gt;
*** Call into the original Granny DLL to convert between binary and ASCII Granny data, though&lt;br /&gt;
** [https://github.com/berenm/xoreos-tools/tree/granny berenm started some Granny RE]&lt;br /&gt;
** Based on berenm&#039;s RE efforts, Arbos has written a tool to convert to/from MDB+GR2: https://github.com/Arbos/nwn2mdk&lt;br /&gt;
*** Probably a good starting point for integrating NWN2 animations into xoreos&lt;br /&gt;
* Facial animations (FaceFX)&lt;br /&gt;
* Trees (SpeedTree)&lt;br /&gt;
* Proper evaluation of creature model parts (equipped items)&lt;br /&gt;
* Player character&lt;br /&gt;
** Reading of PC files in creature&lt;br /&gt;
* Walkmeshes. CromFr wrote a specs document here: https://gist.github.com/CromFr/104bac52dc9191099d9d9e3dbd2c4975&lt;br /&gt;
&lt;br /&gt;
=== Sonic Chronicles ===&lt;br /&gt;
* Allow using the contents from an extracted NDS file?&lt;br /&gt;
* Menus&lt;br /&gt;
** GUI files that are GFF&lt;br /&gt;
** Actions in a state machine in GDA files?&lt;br /&gt;
* Music/Sound&lt;br /&gt;
** Music is apparently similar to MIDI, or to a tracker format?&lt;br /&gt;
** Sounds and instruments for music are in a sound_data.sadl archive&lt;br /&gt;
* Animations&lt;br /&gt;
** Bone animations, best implemented with shaders, blocked by the graphics subsystem rewrite&lt;br /&gt;
* Player character(s)&lt;br /&gt;
** Needs research&lt;br /&gt;
&lt;br /&gt;
=== The Witcher ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Apparently build using Lua&lt;br /&gt;
** System/Scripts/ has gui*.luc files&lt;br /&gt;
* Animations&lt;br /&gt;
** Needs research&lt;br /&gt;
* Player character, Geralt&lt;br /&gt;
** Needs research&lt;br /&gt;
&lt;br /&gt;
=== Dragon Age: Origins / Dragon Age 2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Scaleform_GFx Scaleform GFx]&lt;br /&gt;
** [http://social.bioware.com/wiki/datoolset/index.php/UI_Tutorial_%28draft%29 UI Tutorial] on the Dragon Age toolset wiki&lt;br /&gt;
** Flash-based!&lt;br /&gt;
** A good starting point for a reimplementation might be [https://en.wikipedia.org/wiki/Gameswf Gameswf].&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Gnash Gnash], [https://en.wikipedia.org/wiki/Lightspark Lightspark], [https://en.wikipedia.org/wiki/Swfdec Swfdec]&lt;br /&gt;
** [http://www.nowrap.de/flasm.html Flasm] can disassemble/assemble ActionScript, [http://www.nowrap.de/flare.html Flare] can decompile it&lt;br /&gt;
** [https://wwwimages2.adobe.com/content/dam/acom/en/devnet/pdf/swf-file-format-spec.pdf swf-file-format-spec.pdf] is a great reference which covers mostly every aspect of the gfx files.&lt;br /&gt;
** [https://github.com/jindrapetrik/jpexs-decompiler jpexs-decompiler] can decompile and handles scaleform specific tags.&lt;br /&gt;
* Animations&lt;br /&gt;
** Bone animations, best implemented with shaders, blocked by the graphics subsystem rewrite&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=TODO&amp;diff=369</id>
		<title>TODO</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=TODO&amp;diff=369"/>
		<updated>2018-06-15T13:55:22Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* NWN2 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a long rambly list of things left to do in xoreos and xoreos-tools. Anybody is welcome to tackle any of these tasks, but please also read our [[Developer_Central|general contributor overview]], including our [[Code_Formatting_Conventions|Code Formatting Conventions]], [[Commit_Guidelines|Commit Guidelines]] and [https://github.com/xoreos/xoreos/blob/master/CODE_OF_CONDUCT.md Code of Conduct]. If you plan to do any of these tasks, please also [[Contact_us|contact us]] beforehand, so we can better coordinate multiple people interested in doing the same task, and discuss how to best solve the problem. Thanks. :)&lt;br /&gt;
&lt;br /&gt;
(&#039;&#039;&#039;See also:&#039;&#039;&#039; the Kanban-like &amp;quot;Projects&amp;quot; boards on GitHub: https://github.com/orgs/xoreos/projects, but they&#039;re not public and no way to make public at the moment. Boo.)&lt;br /&gt;
&lt;br /&gt;
== Documentation ==&lt;br /&gt;
&lt;br /&gt;
=== Developer information ===&lt;br /&gt;
* Extend the developer information on the wiki&lt;br /&gt;
** Explain how to get the xoreos sources on various platforms&lt;br /&gt;
** Expand GNU/Linux compiling instructions to cover more distributions&lt;br /&gt;
** Expand Mac OS X compiling instructions&lt;br /&gt;
*** Xcode&lt;br /&gt;
*** Homebrew/MacPorts/Fink&lt;br /&gt;
*** CMake, Libraries&lt;br /&gt;
** [http://wiki.arx-libertatis.org/Developer_Information Arx Libertatis] has an extensive dev page&lt;br /&gt;
* Document file formats on the wiki?&lt;br /&gt;
** Or integrate info into XentaxWiki?&lt;br /&gt;
** Both?&lt;br /&gt;
&lt;br /&gt;
=== User information ===&lt;br /&gt;
* More user information on the wiki&lt;br /&gt;
** How to download xoreos&lt;br /&gt;
** How to install the games on various platforms&lt;br /&gt;
** [http://wiki.arx-libertatis.org/Main_Page Arx Libertatis] does that pretty well&lt;br /&gt;
&lt;br /&gt;
=== Modder information ===&lt;br /&gt;
* Link to relevant modding resources&lt;br /&gt;
* Maybe even some kind of Modder&#039;s Handbook&lt;br /&gt;
** A big overview of modding Aurora games in general&lt;br /&gt;
*** Differences and commonalities between games&lt;br /&gt;
** Linking/Grouping engine functions between games&lt;br /&gt;
&lt;br /&gt;
== Website ==&lt;br /&gt;
&lt;br /&gt;
=== Design ===&lt;br /&gt;
* Better website design?&lt;br /&gt;
** It still should be static in the end&lt;br /&gt;
*** No PHP or Rails&lt;br /&gt;
*** Very light on JavaScript&lt;br /&gt;
*** No Flash!&lt;br /&gt;
** Maybe a bit more unique, graphical&lt;br /&gt;
** For legal reasons, we shouldn&#039;t directly use art or designs from the original games&lt;br /&gt;
*** Something inspired by the art of the orginal games would fit&lt;br /&gt;
&lt;br /&gt;
=== Octopress ===&lt;br /&gt;
* Move away from Octopress?&lt;br /&gt;
** Alternative should still produce static HTML somehow&lt;br /&gt;
** Octopress works rather well. It reads Markdown, which is a plus&lt;br /&gt;
* Octopress 3.0?&lt;br /&gt;
** Not finished yet, it seems&lt;br /&gt;
&lt;br /&gt;
== Standalone(ish) fixes/improvements ==&lt;br /&gt;
&lt;br /&gt;
=== Broken NWN2 XML ===&lt;br /&gt;
* Not standards-conforming XML. Need custom XML parser; stock XML parsing libraries will just throw errors.&lt;br /&gt;
** &amp;lt;nowiki&amp;gt;&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;NWN2UI&amp;quot;&amp;gt;&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
** No single root element&lt;br /&gt;
** Attribute values not enclosed in quotes most of the time&lt;br /&gt;
** Special characters in attribute values not properly escaped&lt;br /&gt;
** Unmatched quotes on several occasions&lt;br /&gt;
* Event functions&lt;br /&gt;
* Special values like PARENT_WIDTH&lt;br /&gt;
* [https://github.com/xoreos/xoreos-tools/pull/1 Altrite is working on a broken-XML fixer]&lt;br /&gt;
&lt;br /&gt;
=== CJK glyphs in the console ===&lt;br /&gt;
* The &amp;quot;system font&amp;quot; we use for our debug console, DejaVu Sans Mono Bold, does not feature any CJK (Chinese, Japanese, Korean) glyphs&lt;br /&gt;
* Not strictly necessary, but nice to have for printing, say, Witcher area names in Asian languages&lt;br /&gt;
* We could maybe integrate CJK glyphs from the [http://fonts.jp/hanazono/ Hanazono fonts] or other suitable libre fonts&lt;br /&gt;
* We need to match the height with DejaVu Sans Mono Bold&lt;br /&gt;
* CJK glyphs tend to be more complex and therefore wider. They&#039;re usually rendered twice as wide as Latin glyphs&lt;br /&gt;
* Our console code needs to take that into account&lt;br /&gt;
&lt;br /&gt;
=== Fuzzing ===&lt;br /&gt;
* Set up fuzzing targets for everything for [https://llvm.org/docs/LibFuzzer.html libFuzzer]&lt;br /&gt;
** File readers, image decoders, etc.&lt;br /&gt;
* Can be integrated with [http://lcamtuf.coredump.cx/afl/ afl] (american fuzzy lop): https://github.com/llvm-mirror/compiler-rt/blob/master/lib/fuzzer/afl/afl_driver.cpp&lt;br /&gt;
* Integrate it with our build system somehow&lt;br /&gt;
** ./configure flag for building with fuzzing instrumentation?&lt;br /&gt;
** Needs to check that the compiler can do that&lt;br /&gt;
** make fuzzers then builds the targets?&lt;br /&gt;
* File formats previously manually fuzzed with afl:&lt;br /&gt;
** CBGT, CDPTH, DDS, NBFS, NCGR, NCLR, SBM, TGA, TPC, TXB&lt;br /&gt;
** 2DA, KEY/BIF, ERF, GFF3, GFF4, GDA, TLK, NSBTX, RIM, SMALL, SSF&lt;br /&gt;
* Continuous fuzzing via [https://github.com/google/oss-fuzz OSS-Fuzz] (currently only taking &amp;quot;important&amp;quot; projects)&lt;br /&gt;
&lt;br /&gt;
=== Script decompiler ===&lt;br /&gt;
* It might be quite useful to have a NWScript decompiler in xoreos-tools&lt;br /&gt;
* We have a script disassembler, ncsdis&lt;br /&gt;
** Which already does code flow analysis&lt;br /&gt;
* Missing:&lt;br /&gt;
** Code generation&lt;br /&gt;
** Collapsing of instruction chains into single-line NWScript code&lt;br /&gt;
*** For example, &amp;quot;int var = foo * bar + quux&amp;quot; compiles to a long chain with multiple temporaries&lt;br /&gt;
** Proper handling of structs and vectors&lt;br /&gt;
&lt;br /&gt;
=== Script compiler ===&lt;br /&gt;
* An NWScript compiler might be useful as well&lt;br /&gt;
** A script assembler might be an easy first step&lt;br /&gt;
&lt;br /&gt;
=== File format writers ===&lt;br /&gt;
* GFF3Writer, GFF4Writer&lt;br /&gt;
** Both necessary to create save games compatible with the original games&lt;br /&gt;
** Also useful for a xml2gff tool&lt;br /&gt;
* xml2tlk&lt;br /&gt;
** TalkTable_GFF::write02() and ::write05()&lt;br /&gt;
** Needs GFF4Writer&lt;br /&gt;
* Archive (ERF, RIM, KEY/BIF) packers?&lt;br /&gt;
&lt;br /&gt;
=== Config file ===&lt;br /&gt;
* Should be more preserving of the layout&lt;br /&gt;
** Especially empty lines&lt;br /&gt;
** UTF-8 Byte-Order-Mark when using native Windows editors&lt;br /&gt;
** \r is currently always stripped. Maybe preserve that too&lt;br /&gt;
*** Autodetect when \r is already used, and add it to new config lines too&lt;br /&gt;
** This basically needs a complete rewrite of the config parser&lt;br /&gt;
*** Don&#039;t just look for comments, just throw everything after &amp;quot;foo=bar&amp;quot; into the &amp;quot;comment&amp;quot; variable, including whitespace&lt;br /&gt;
*** And all whitespace before &amp;quot;foo=bar&amp;quot; into a &amp;quot;prefix&amp;quot; variable&lt;br /&gt;
** Maybe even always add BOM and \r when writing a new config file on Windows?&lt;br /&gt;
&lt;br /&gt;
=== Windows-specific / Wine-specific ===&lt;br /&gt;
* When running my mingw32 cross-compiled xoreos EXE in Wine, the menu button texts are partially cut off&lt;br /&gt;
** Z-fighting issue?&lt;br /&gt;
** Does that also occur on a real Windows?&lt;br /&gt;
&lt;br /&gt;
=== GUI ===&lt;br /&gt;
* xoreos could use a global GUI to start games from&lt;br /&gt;
* Should probably be similar to ScummVM&#039;s GUI, at least in effect&lt;br /&gt;
* Should read the config file, list all targets&lt;br /&gt;
** Press a &amp;quot;Play&amp;quot; button to play the game&lt;br /&gt;
** Press an &amp;quot;Edit&amp;quot; button to edit the entry&lt;br /&gt;
*** Dialog options to edit common settings&lt;br /&gt;
*** An additional free-form editor?&lt;br /&gt;
*** Game-specific options?&lt;br /&gt;
** A button to edit global settings (&amp;quot;xoreos&amp;quot; config domain)&lt;br /&gt;
** For the future, a way to immediately load a saved game?&lt;br /&gt;
** An &amp;quot;Add&amp;quot; button to add a game&lt;br /&gt;
*** File browser&lt;br /&gt;
**** Select directories for most game&lt;br /&gt;
**** Select file for Sonic Chronicles&lt;br /&gt;
*** View current saved games of a target?&lt;br /&gt;
* Probably implemented using OpenGL, just like, say, the console&lt;br /&gt;
* Theme-able/Skinable?&lt;br /&gt;
* Some potential stumbling blocks&lt;br /&gt;
** Displaying &amp;quot;uncommon&amp;quot; text in both game descriptions and file paths&lt;br /&gt;
*** &amp;quot;Decomposed&amp;quot; letters, i.e. base letter + combining glyphs&lt;br /&gt;
*** CJK&lt;br /&gt;
*** Arabic and other scripts where letters change depending on their place in the word&lt;br /&gt;
*** Right-to-left&lt;br /&gt;
** Shortening those strings when they don&#039;t fit in their fields is also potentially difficult&lt;br /&gt;
&lt;br /&gt;
=== Localization ===&lt;br /&gt;
* Text in exceptions?&lt;br /&gt;
** At least the user-visible ones, like &amp;quot;Failed to detect game&amp;quot;&lt;br /&gt;
** Or maybe we should clean that up and split them into &amp;quot;program logic failure&amp;quot; and &amp;quot;user failure&amp;quot;, with only the latter translated&lt;br /&gt;
* Strings for the engine loader progress bar&lt;br /&gt;
* Debug console string&lt;br /&gt;
* GUI (see above) strings&lt;br /&gt;
* [http://www.gnu.org/software/gettext/ GNU gettext] would be one solution&lt;br /&gt;
&lt;br /&gt;
=== Unit tests ===&lt;br /&gt;
* More unit tests&lt;br /&gt;
&lt;br /&gt;
=== Resource Explorer ===&lt;br /&gt;
* A portable, user-friendly graphical resource explorer could be useful&lt;br /&gt;
* [https://github.com/xoreos/phaethon Phaethon] is a start&lt;br /&gt;
** It can look into game archives, show textures and play sounds&lt;br /&gt;
** It uses [https://www.wxwidgets.org/ wxWidgets] to do the GUI&lt;br /&gt;
** Or possibly rewriting it to use [https://www.qt.io/ Qt] is better?&lt;br /&gt;
&lt;br /&gt;
=== Model converters ===&lt;br /&gt;
* Document the model formats&lt;br /&gt;
* Convert between the binary model formats and their ASCII equivalents&lt;br /&gt;
* Convert between the binary model formats and ones that can be opened by modelling tools&lt;br /&gt;
** 3D Studio Max&lt;br /&gt;
** Blender&lt;br /&gt;
&lt;br /&gt;
=== Full-fledged modding toolset ===&lt;br /&gt;
* Similar to the NWN, NWN2 or Witcher toolset, but portable and FLOSS&lt;br /&gt;
** Might also support other games?&lt;br /&gt;
* Out of scope for xoreos&lt;br /&gt;
** Still, such a thing would be welcome under the xoreos banner&lt;br /&gt;
* [http://sourceforge.net/projects/neveredit/ Neveredit] might still be worth a look&lt;br /&gt;
&lt;br /&gt;
== Build system ==&lt;br /&gt;
&lt;br /&gt;
=== CMake ===&lt;br /&gt;
* Current doesn&#039;t set the git version to &amp;quot;+unk&amp;quot; when git isn&#039;t found&lt;br /&gt;
* make install/uninstall?&lt;br /&gt;
* make doxygen?&lt;br /&gt;
&lt;br /&gt;
=== Autotools ===&lt;br /&gt;
* Suppress the &amp;quot;fatal: not a git repository&amp;quot; when building gitstamp without a git directory&lt;br /&gt;
* Increased modularity&lt;br /&gt;
** Disabling engines&lt;br /&gt;
** Making library dependencies optional (and disabling certain features, then)&lt;br /&gt;
*** liblzma? Only needed for the iOS version of KotOR&lt;br /&gt;
*** libxml2? Only needed for the two Dragon Age games&lt;br /&gt;
** When something is disabled, skip it, if possible&lt;br /&gt;
*** Like the videos in KotOR Mac&lt;br /&gt;
** If skipping is not possible, error out&lt;br /&gt;
&lt;br /&gt;
== Nitro ==&lt;br /&gt;
&lt;br /&gt;
* The Nintendo DS (Nitro) specific file formats should probably be moved out of src/aurora/ and into src/nitro&lt;br /&gt;
* nitrofile, cdpth, nsbtx, smallfile&lt;br /&gt;
** nsbtx needs to be split into a class accessing the textures in src/nitro/ and an archive class on top in src/aurora/&lt;br /&gt;
** This means src/aurora/ accesses src/nitro/, so libnitro.la needs to come after libaurora.la in the linking order&lt;br /&gt;
* ndsrom as well?&lt;br /&gt;
* What about nftrfont and model_sonic in src/graphics/aurora/?&lt;br /&gt;
** src/graphics/nitro/?&lt;br /&gt;
** This would have src/graphics/nitro/ access src/graphics/aurora/, so graphics/libnitro.la needs to come before graphics/libaurora.la in the linking order&lt;br /&gt;
** That would be the other way round than for src/nitro/. Too confusing?&lt;br /&gt;
&lt;br /&gt;
== Graphics ==&lt;br /&gt;
&lt;br /&gt;
=== MDL supermodels and animations ===&lt;br /&gt;
* Mostly working in NWN thanks to jbowtie&#039;s work&lt;br /&gt;
* Might need some cleanup&lt;br /&gt;
* Models should smoothly change between different animations&lt;br /&gt;
* The animation system probably needs to be a bit more complex, to allow for &amp;quot;overlaying&amp;quot; different animations onto each other. For example, for speaking while holding an object and keeping the head focused on the PC character.&lt;br /&gt;
&lt;br /&gt;
=== Lighting ===&lt;br /&gt;
* We don&#039;t yet have a proper light system&lt;br /&gt;
* I started working on it: [https://drmccoy.de/xoreos/20150809T223407.png], but my approach is seriously lacking. You can see the edges of the tiles that make up on NWN area in many cases ([https://drmccoy.de/xoreos/20150809T223507.png], [https://drmccoy.de/xoreos/20150809T223548.png])&lt;br /&gt;
** See the [https://github.com/xoreos/xoreos/tree/light light branch] in the git repository&lt;br /&gt;
** Of course, the actual glLight* stuff won&#039;t be relevant anymore as soon as shaders are there&lt;br /&gt;
** Lighting in several (ASCII?) area tiles is broken&lt;br /&gt;
*** The door in Prelude.nwm&#039;s &amp;quot;m0q1a&amp;quot; area&lt;br /&gt;
*** A water tile in Chapter2.nwm&#039;s &amp;quot;map_m2q1a&amp;quot; area&lt;br /&gt;
*** A sloped snow tile in XP2_Chapter3.nwm&#039;s &amp;quot;thecityoflostsou&amp;quot;&lt;br /&gt;
&lt;br /&gt;
=== Materials ===&lt;br /&gt;
* Materials in The Witcher are closely tied to shaders&lt;br /&gt;
&lt;br /&gt;
=== OpenGL and Shaders ===&lt;br /&gt;
* mirv_ is currently working on a graphics system overhaul, complete with shader support&lt;br /&gt;
* All Aurora games use shaders in some form&lt;br /&gt;
* NWN uses ARB shaders. We probably need to rewrite them from scratch&lt;br /&gt;
* DirectX shaders might be automatically convertible with Cg?&lt;br /&gt;
* Otherwise, look at what Wine does with the shaders, and use that as a basis?&lt;br /&gt;
* All the games, even NWN, use some form of shaders. Still totally missing from xoreos, since we have no idea how to use them in general yet. Moreover, this was before GLSL, so they&#039;re in the old assembly-like language. We probably need to rewrite them from scratch&lt;br /&gt;
* We need shaders for tinting in NWN2 (objects and area geometry) and TexturePaint nodes in Witcher&lt;br /&gt;
&lt;br /&gt;
=== SDL 1.2 ===&lt;br /&gt;
* Optionally link against SDL 1.2 instead of SDL 2&lt;br /&gt;
* Should ideally use a configure flag to select between the two&lt;br /&gt;
** Maybe a CMake flag as well, if possible&lt;br /&gt;
* Assigned to clone2727, so anybody interested in this should coordinate with him&lt;br /&gt;
&lt;br /&gt;
== Videos ==&lt;br /&gt;
&lt;br /&gt;
=== XMV/WMV ===&lt;br /&gt;
* Used in Xbox versions of KotOR/KotOR2&lt;br /&gt;
* Our WMV decoder (for XMV videos used in Xbox versions) is missing P-frames and J-frame&lt;br /&gt;
** Code exists in ffmpeg, but is connected to the MPEG-4 family mess&lt;br /&gt;
&lt;br /&gt;
=== Actimagine VX ===&lt;br /&gt;
* Used in the Nintendo DS game Sonic Chronicles&lt;br /&gt;
* https://wiki.multimedia.cx/index.php?title=Actimagine_Video_Codec&lt;br /&gt;
&lt;br /&gt;
=== Sorenson 3 ===&lt;br /&gt;
* One single video in the Mac port of KotOR2, the Aspyr logo, uses the Sorenson 3 codec&lt;br /&gt;
** ffmpeg has a decoder, but it&#039;s connected to the MPEG-4 family mess (SVQ3 is similar to H.264)&lt;br /&gt;
* ScummVM needs that too&lt;br /&gt;
** While xoreos is GPLv3+, ScummVM is GPLv2+&lt;br /&gt;
** Somebody implementing Sorenson 3 for xoreos should ideally give explicit permission to relicense it GPLv2+ for ScummVM&lt;br /&gt;
*** Of course, if the decoder is based on prior work by other people, it has to be compatible with both GPLv2+ and GPLv3+&lt;br /&gt;
&lt;br /&gt;
=== Optimizations ===&lt;br /&gt;
* Optimize our simple BitStream interface&lt;br /&gt;
** See [https://fgiesen.wordpress.com/2016/01/02/end-of-buffer-checks-in-decompressors/ this blog post]&lt;br /&gt;
** Specifically, we don&#039;t do any peeking at all&lt;br /&gt;
** It still needs to handle different memory layouts, though&lt;br /&gt;
* Likewise, our Huffman class could probably be tuned a lot&lt;br /&gt;
* Pull in fft/rdft/dct/mdct optimizations from FFmpeg?&lt;br /&gt;
* I experimented with that in a private branch and it didn&#039;t do anything for Bink performance&lt;br /&gt;
&lt;br /&gt;
== Sound ==&lt;br /&gt;
&lt;br /&gt;
=== FMOD ===&lt;br /&gt;
* Dragon Age: Origins uses FMOD for sound and music&lt;br /&gt;
* I have experimental FSB (FMOD sound bank) support working in a private branch&lt;br /&gt;
* FEV (FMOD events) format is still unknown to us&lt;br /&gt;
** Apparently, groups of event lists with events&lt;br /&gt;
** Event is everything from &amp;quot;play sound&amp;quot;, over &amp;quot;set volume&amp;quot; to &amp;quot;apply echo&amp;quot;&lt;br /&gt;
** Game areas specify the group to use for the area&lt;br /&gt;
** Scripts then probably tell FMOD to play event lists out of that group&lt;br /&gt;
&lt;br /&gt;
=== Wwise ===&lt;br /&gt;
* Dragon Age 2 uses Wwise for sound and music&lt;br /&gt;
* Should be similar in concept to FMD&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
=== Gamepad binding ===&lt;br /&gt;
* The Xbox versions of KotOR and KotOR2 don&#039;t use a mouse. We have basic support for joysticks/gamepads, but no real bindings to the engine or ideas how to handle that in general&lt;br /&gt;
* We might want to handle the controller support the new KotOR2 Steam update brought&lt;br /&gt;
** override folder contains a gamepad.txt then&lt;br /&gt;
* Also hack in controller support for a non-Steam KotOR2? And for KotOR?&lt;br /&gt;
* Controller support in Jade Empire&lt;br /&gt;
* Controller support for Sonic? It is a Nintendo DS game after all&lt;br /&gt;
* Controller support for the non-console versions of the Dragon Age games?&lt;br /&gt;
&lt;br /&gt;
== Network ==&lt;br /&gt;
* We need a network subsystem&lt;br /&gt;
** [https://www.libsdl.org/projects/SDL_net/ SDL_net]?&lt;br /&gt;
** [http://www.boost.org/doc/libs/release/libs/asio/ Boost.Asio]?&lt;br /&gt;
** More options here: http://stackoverflow.com/questions/118945/best-c-c-network-library&lt;br /&gt;
* Engines need to be split into client and server classes&lt;br /&gt;
** The original engines all still do that, even when not exposing anything to users&lt;br /&gt;
** NWN and NWN2 allow user multiplayer&lt;br /&gt;
&lt;br /&gt;
== Engines ==&lt;br /&gt;
&lt;br /&gt;
=== Script system ===&lt;br /&gt;
* ImperatorPrime had started on a script system rewrite&lt;br /&gt;
** Includes functions with real signatures&lt;br /&gt;
** Maybe switch to that, if it works&lt;br /&gt;
* Rounds, object heartbeat scripts&lt;br /&gt;
* KotOR2 and NWN2 have some extensions&lt;br /&gt;
** It seems like they don&#039;t need any extensions to the low-level bytecode stuff&lt;br /&gt;
* Witcher uses Lua scripts together with NWScript&lt;br /&gt;
* Sonic has no scripts at all, it seems&lt;br /&gt;
* Currently a script in an infinite loop locks the game thread&lt;br /&gt;
** Timeout? Asynchronous script execution?&lt;br /&gt;
&lt;br /&gt;
=== NWN ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Basics are there, but needs fleshing out&lt;br /&gt;
** Character generator is mostly working&lt;br /&gt;
* [[Pathfinding]], walkmesh&lt;br /&gt;
** &amp;quot;Moving&amp;quot; should move the PC, not the camera&lt;br /&gt;
** NPC walking&lt;br /&gt;
** Triggers, areas on the floor that calls scripts on enter/leave&lt;br /&gt;
* Models&lt;br /&gt;
** ASCII models need averaging of smooth group normals&lt;br /&gt;
* NWN objects need an inventory concept&lt;br /&gt;
** Player characters&#039; might be different&lt;br /&gt;
*** Inventory tetris&lt;br /&gt;
*** Inventory item icons&lt;br /&gt;
* Multi-page asian fonts&lt;br /&gt;
* LanguageID 0 is not necessarily &amp;quot;English&amp;quot;, but &amp;quot;The language of the game install&amp;quot;&lt;br /&gt;
** This is okay for languages with Latin characters&lt;br /&gt;
** Messes up strings in community modules with Asian languages that stuff strings in to languageID 0&lt;br /&gt;
** The original fails there too, though&lt;br /&gt;
&lt;br /&gt;
=== KotOR/KotOR2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Many are already there&lt;br /&gt;
* Dialogues&lt;br /&gt;
** DLG files, similar to NWN&lt;br /&gt;
** Some extensions, like camera setup&lt;br /&gt;
** Dialogues are displayed very different than NWN&lt;br /&gt;
** KotOR2 has script extensions&lt;br /&gt;
*** Passing parameters to scripts&lt;br /&gt;
*** Call several scripts, combine with AND/OR for branching&lt;br /&gt;
* Animations&lt;br /&gt;
** Mostly working now&lt;br /&gt;
* Minigames&lt;br /&gt;
** Swoop racing&lt;br /&gt;
** Pazaak&lt;br /&gt;
** Hardcoded, mostly removed from usual game logic&lt;br /&gt;
&lt;br /&gt;
=== Jade Empire ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Main menu with options submenu is there&lt;br /&gt;
* Minigames&lt;br /&gt;
** Flyer, top-down shoot-em-up thing&lt;br /&gt;
** Hardcoded, mostly removed from usual game logic&lt;br /&gt;
* Player character&lt;br /&gt;
** Needs research&lt;br /&gt;
* Sound&lt;br /&gt;
** Uses an ASCII variant of the [http://wiki.multimedia.cx/index.php?title=XACT XACT formats]&lt;br /&gt;
*** Cues probably not as complex as FMOD/Wwise&lt;br /&gt;
*** Effects need extension of the Sound system, maybe&lt;br /&gt;
** Xbox version might use the binary format?&lt;br /&gt;
*** Sound banks could be handles as archives and indexed in the ResourceManager?&lt;br /&gt;
** [https://github.com/flibitijibibo/FACT FACT] is an implementation of XAudio, including XACT, zlib-licensed&lt;br /&gt;
&lt;br /&gt;
=== NWN2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Implemented using XML&lt;br /&gt;
** See [[#Broken NWN2 XML|Broken NWN2 XML]]&lt;br /&gt;
* Animations (Granny)&lt;br /&gt;
** [https://github.com/SkywingvL/nwn2dev-public nwn2-dev] contains some code working with Granny data&lt;br /&gt;
*** Call into the original Granny DLL to convert between binary and ASCII Granny data, though&lt;br /&gt;
** [https://github.com/berenm/xoreos-tools/tree/granny berenm started some Granny RE]&lt;br /&gt;
* Facial animations (FaceFX)&lt;br /&gt;
* Trees (SpeedTree)&lt;br /&gt;
* Proper evaluation of creature model parts (equipped items)&lt;br /&gt;
* Player character&lt;br /&gt;
** Reading of PC files in creature&lt;br /&gt;
* Walkmeshes. CromFr wrote a specs document here: https://gist.github.com/CromFr/104bac52dc9191099d9d9e3dbd2c4975&lt;br /&gt;
&lt;br /&gt;
=== Sonic Chronicles ===&lt;br /&gt;
* Allow using the contents from an extracted NDS file?&lt;br /&gt;
* Menus&lt;br /&gt;
** GUI files that are GFF&lt;br /&gt;
** Actions in a state machine in GDA files?&lt;br /&gt;
* Music/Sound&lt;br /&gt;
** Music is apparently similar to MIDI, or to a tracker format?&lt;br /&gt;
** Sounds and instruments for music are in a sound_data.sadl archive&lt;br /&gt;
* Animations&lt;br /&gt;
** Bone animations, best implemented with shaders, blocked by the graphics subsystem rewrite&lt;br /&gt;
* Player character(s)&lt;br /&gt;
** Needs research&lt;br /&gt;
&lt;br /&gt;
=== The Witcher ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Apparently build using Lua&lt;br /&gt;
** System/Scripts/ has gui*.luc files&lt;br /&gt;
* Animations&lt;br /&gt;
** Needs research&lt;br /&gt;
* Player character, Geralt&lt;br /&gt;
** Needs research&lt;br /&gt;
&lt;br /&gt;
=== Dragon Age: Origins / Dragon Age 2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Scaleform_GFx Scaleform GFx]&lt;br /&gt;
** [http://social.bioware.com/wiki/datoolset/index.php/UI_Tutorial_%28draft%29 UI Tutorial] on the Dragon Age toolset wiki&lt;br /&gt;
** Flash-based!&lt;br /&gt;
** A good starting point for a reimplementation might be [https://en.wikipedia.org/wiki/Gameswf Gameswf].&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Gnash Gnash], [https://en.wikipedia.org/wiki/Lightspark Lightspark], [https://en.wikipedia.org/wiki/Swfdec Swfdec]&lt;br /&gt;
** [http://www.nowrap.de/flasm.html Flasm] can disassemble/assemble ActionScript, [http://www.nowrap.de/flare.html Flare] can decompile it&lt;br /&gt;
** [https://wwwimages2.adobe.com/content/dam/acom/en/devnet/pdf/swf-file-format-spec.pdf swf-file-format-spec.pdf] is a great reference which covers mostly every aspect of the gfx files.&lt;br /&gt;
** [https://github.com/jindrapetrik/jpexs-decompiler jpexs-decompiler] can decompile and handles scaleform specific tags.&lt;br /&gt;
* Animations&lt;br /&gt;
** Bone animations, best implemented with shaders, blocked by the graphics subsystem rewrite&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=TODO&amp;diff=368</id>
		<title>TODO</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=TODO&amp;diff=368"/>
		<updated>2018-06-14T09:17:19Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* Fuzzing */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a long rambly list of things left to do in xoreos and xoreos-tools. Anybody is welcome to tackle any of these tasks, but please also read our [[Developer_Central|general contributor overview]], including our [[Code_Formatting_Conventions|Code Formatting Conventions]], [[Commit_Guidelines|Commit Guidelines]] and [https://github.com/xoreos/xoreos/blob/master/CODE_OF_CONDUCT.md Code of Conduct]. If you plan to do any of these tasks, please also [[Contact_us|contact us]] beforehand, so we can better coordinate multiple people interested in doing the same task, and discuss how to best solve the problem. Thanks. :)&lt;br /&gt;
&lt;br /&gt;
(&#039;&#039;&#039;See also:&#039;&#039;&#039; the Kanban-like &amp;quot;Projects&amp;quot; boards on GitHub: https://github.com/orgs/xoreos/projects, but they&#039;re not public and no way to make public at the moment. Boo.)&lt;br /&gt;
&lt;br /&gt;
== Documentation ==&lt;br /&gt;
&lt;br /&gt;
=== Developer information ===&lt;br /&gt;
* Extend the developer information on the wiki&lt;br /&gt;
** Explain how to get the xoreos sources on various platforms&lt;br /&gt;
** Expand GNU/Linux compiling instructions to cover more distributions&lt;br /&gt;
** Expand Mac OS X compiling instructions&lt;br /&gt;
*** Xcode&lt;br /&gt;
*** Homebrew/MacPorts/Fink&lt;br /&gt;
*** CMake, Libraries&lt;br /&gt;
** [http://wiki.arx-libertatis.org/Developer_Information Arx Libertatis] has an extensive dev page&lt;br /&gt;
* Document file formats on the wiki?&lt;br /&gt;
** Or integrate info into XentaxWiki?&lt;br /&gt;
** Both?&lt;br /&gt;
&lt;br /&gt;
=== User information ===&lt;br /&gt;
* More user information on the wiki&lt;br /&gt;
** How to download xoreos&lt;br /&gt;
** How to install the games on various platforms&lt;br /&gt;
** [http://wiki.arx-libertatis.org/Main_Page Arx Libertatis] does that pretty well&lt;br /&gt;
&lt;br /&gt;
=== Modder information ===&lt;br /&gt;
* Link to relevant modding resources&lt;br /&gt;
* Maybe even some kind of Modder&#039;s Handbook&lt;br /&gt;
** A big overview of modding Aurora games in general&lt;br /&gt;
*** Differences and commonalities between games&lt;br /&gt;
** Linking/Grouping engine functions between games&lt;br /&gt;
&lt;br /&gt;
== Website ==&lt;br /&gt;
&lt;br /&gt;
=== Design ===&lt;br /&gt;
* Better website design?&lt;br /&gt;
** It still should be static in the end&lt;br /&gt;
*** No PHP or Rails&lt;br /&gt;
*** Very light on JavaScript&lt;br /&gt;
*** No Flash!&lt;br /&gt;
** Maybe a bit more unique, graphical&lt;br /&gt;
** For legal reasons, we shouldn&#039;t directly use art or designs from the original games&lt;br /&gt;
*** Something inspired by the art of the orginal games would fit&lt;br /&gt;
&lt;br /&gt;
=== Octopress ===&lt;br /&gt;
* Move away from Octopress?&lt;br /&gt;
** Alternative should still produce static HTML somehow&lt;br /&gt;
** Octopress works rather well. It reads Markdown, which is a plus&lt;br /&gt;
* Octopress 3.0?&lt;br /&gt;
** Not finished yet, it seems&lt;br /&gt;
&lt;br /&gt;
== Standalone(ish) fixes/improvements ==&lt;br /&gt;
&lt;br /&gt;
=== Broken NWN2 XML ===&lt;br /&gt;
* Not standards-conforming XML. Need custom XML parser; stock XML parsing libraries will just throw errors.&lt;br /&gt;
** &amp;lt;nowiki&amp;gt;&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;NWN2UI&amp;quot;&amp;gt;&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
** No single root element&lt;br /&gt;
** Attribute values not enclosed in quotes most of the time&lt;br /&gt;
** Special characters in attribute values not properly escaped&lt;br /&gt;
** Unmatched quotes on several occasions&lt;br /&gt;
* Event functions&lt;br /&gt;
* Special values like PARENT_WIDTH&lt;br /&gt;
* [https://github.com/xoreos/xoreos-tools/pull/1 Altrite is working on a broken-XML fixer]&lt;br /&gt;
&lt;br /&gt;
=== CJK glyphs in the console ===&lt;br /&gt;
* The &amp;quot;system font&amp;quot; we use for our debug console, DejaVu Sans Mono Bold, does not feature any CJK (Chinese, Japanese, Korean) glyphs&lt;br /&gt;
* Not strictly necessary, but nice to have for printing, say, Witcher area names in Asian languages&lt;br /&gt;
* We could maybe integrate CJK glyphs from the [http://fonts.jp/hanazono/ Hanazono fonts] or other suitable libre fonts&lt;br /&gt;
* We need to match the height with DejaVu Sans Mono Bold&lt;br /&gt;
* CJK glyphs tend to be more complex and therefore wider. They&#039;re usually rendered twice as wide as Latin glyphs&lt;br /&gt;
* Our console code needs to take that into account&lt;br /&gt;
&lt;br /&gt;
=== Fuzzing ===&lt;br /&gt;
* Set up fuzzing targets for everything for [https://llvm.org/docs/LibFuzzer.html libFuzzer]&lt;br /&gt;
** File readers, image decoders, etc.&lt;br /&gt;
* Can be integrated with [http://lcamtuf.coredump.cx/afl/ afl] (american fuzzy lop): https://github.com/llvm-mirror/compiler-rt/blob/master/lib/fuzzer/afl/afl_driver.cpp&lt;br /&gt;
* Integrate it with our build system somehow&lt;br /&gt;
** ./configure flag for building with fuzzing instrumentation?&lt;br /&gt;
** Needs to check that the compiler can do that&lt;br /&gt;
** make fuzzers then builds the targets?&lt;br /&gt;
* File formats previously manually fuzzed with afl:&lt;br /&gt;
** CBGT, CDPTH, DDS, NBFS, NCGR, NCLR, SBM, TGA, TPC, TXB&lt;br /&gt;
** 2DA, KEY/BIF, ERF, GFF3, GFF4, GDA, TLK, NSBTX, RIM, SMALL, SSF&lt;br /&gt;
* Continuous fuzzing via [https://github.com/google/oss-fuzz OSS-Fuzz] (currently only taking &amp;quot;important&amp;quot; projects)&lt;br /&gt;
&lt;br /&gt;
=== Script decompiler ===&lt;br /&gt;
* It might be quite useful to have a NWScript decompiler in xoreos-tools&lt;br /&gt;
* We have a script disassembler, ncsdis&lt;br /&gt;
** Which already does code flow analysis&lt;br /&gt;
* Missing:&lt;br /&gt;
** Code generation&lt;br /&gt;
** Collapsing of instruction chains into single-line NWScript code&lt;br /&gt;
*** For example, &amp;quot;int var = foo * bar + quux&amp;quot; compiles to a long chain with multiple temporaries&lt;br /&gt;
** Proper handling of structs and vectors&lt;br /&gt;
&lt;br /&gt;
=== Script compiler ===&lt;br /&gt;
* An NWScript compiler might be useful as well&lt;br /&gt;
** A script assembler might be an easy first step&lt;br /&gt;
&lt;br /&gt;
=== File format writers ===&lt;br /&gt;
* GFF3Writer, GFF4Writer&lt;br /&gt;
** Both necessary to create save games compatible with the original games&lt;br /&gt;
** Also useful for a xml2gff tool&lt;br /&gt;
* xml2tlk&lt;br /&gt;
** TalkTable_GFF::write02() and ::write05()&lt;br /&gt;
** Needs GFF4Writer&lt;br /&gt;
* Archive (ERF, RIM, KEY/BIF) packers?&lt;br /&gt;
&lt;br /&gt;
=== Config file ===&lt;br /&gt;
* Should be more preserving of the layout&lt;br /&gt;
** Especially empty lines&lt;br /&gt;
** UTF-8 Byte-Order-Mark when using native Windows editors&lt;br /&gt;
** \r is currently always stripped. Maybe preserve that too&lt;br /&gt;
*** Autodetect when \r is already used, and add it to new config lines too&lt;br /&gt;
** This basically needs a complete rewrite of the config parser&lt;br /&gt;
*** Don&#039;t just look for comments, just throw everything after &amp;quot;foo=bar&amp;quot; into the &amp;quot;comment&amp;quot; variable, including whitespace&lt;br /&gt;
*** And all whitespace before &amp;quot;foo=bar&amp;quot; into a &amp;quot;prefix&amp;quot; variable&lt;br /&gt;
** Maybe even always add BOM and \r when writing a new config file on Windows?&lt;br /&gt;
&lt;br /&gt;
=== Windows-specific / Wine-specific ===&lt;br /&gt;
* When running my mingw32 cross-compiled xoreos EXE in Wine, the menu button texts are partially cut off&lt;br /&gt;
** Z-fighting issue?&lt;br /&gt;
** Does that also occur on a real Windows?&lt;br /&gt;
&lt;br /&gt;
=== GUI ===&lt;br /&gt;
* xoreos could use a global GUI to start games from&lt;br /&gt;
* Should probably be similar to ScummVM&#039;s GUI, at least in effect&lt;br /&gt;
* Should read the config file, list all targets&lt;br /&gt;
** Press a &amp;quot;Play&amp;quot; button to play the game&lt;br /&gt;
** Press an &amp;quot;Edit&amp;quot; button to edit the entry&lt;br /&gt;
*** Dialog options to edit common settings&lt;br /&gt;
*** An additional free-form editor?&lt;br /&gt;
*** Game-specific options?&lt;br /&gt;
** A button to edit global settings (&amp;quot;xoreos&amp;quot; config domain)&lt;br /&gt;
** For the future, a way to immediately load a saved game?&lt;br /&gt;
** An &amp;quot;Add&amp;quot; button to add a game&lt;br /&gt;
*** File browser&lt;br /&gt;
**** Select directories for most game&lt;br /&gt;
**** Select file for Sonic Chronicles&lt;br /&gt;
*** View current saved games of a target?&lt;br /&gt;
* Probably implemented using OpenGL, just like, say, the console&lt;br /&gt;
* Theme-able/Skinable?&lt;br /&gt;
* Some potential stumbling blocks&lt;br /&gt;
** Displaying &amp;quot;uncommon&amp;quot; text in both game descriptions and file paths&lt;br /&gt;
*** &amp;quot;Decomposed&amp;quot; letters, i.e. base letter + combining glyphs&lt;br /&gt;
*** CJK&lt;br /&gt;
*** Arabic and other scripts where letters change depending on their place in the word&lt;br /&gt;
*** Right-to-left&lt;br /&gt;
** Shortening those strings when they don&#039;t fit in their fields is also potentially difficult&lt;br /&gt;
&lt;br /&gt;
=== Localization ===&lt;br /&gt;
* Text in exceptions?&lt;br /&gt;
** At least the user-visible ones, like &amp;quot;Failed to detect game&amp;quot;&lt;br /&gt;
** Or maybe we should clean that up and split them into &amp;quot;program logic failure&amp;quot; and &amp;quot;user failure&amp;quot;, with only the latter translated&lt;br /&gt;
* Strings for the engine loader progress bar&lt;br /&gt;
* Debug console string&lt;br /&gt;
* GUI (see above) strings&lt;br /&gt;
* [http://www.gnu.org/software/gettext/ GNU gettext] would be one solution&lt;br /&gt;
&lt;br /&gt;
=== Unit tests ===&lt;br /&gt;
* More unit tests&lt;br /&gt;
&lt;br /&gt;
=== Resource Explorer ===&lt;br /&gt;
* A portable, user-friendly graphical resource explorer could be useful&lt;br /&gt;
* [https://github.com/xoreos/phaethon Phaethon] is a start&lt;br /&gt;
** It can look into game archives, show textures and play sounds&lt;br /&gt;
** It uses [https://www.wxwidgets.org/ wxWidgets] to do the GUI&lt;br /&gt;
** Or possibly rewriting it to use [https://www.qt.io/ Qt] is better?&lt;br /&gt;
&lt;br /&gt;
=== Model converters ===&lt;br /&gt;
* Document the model formats&lt;br /&gt;
* Convert between the binary model formats and their ASCII equivalents&lt;br /&gt;
* Convert between the binary model formats and ones that can be opened by modelling tools&lt;br /&gt;
** 3D Studio Max&lt;br /&gt;
** Blender&lt;br /&gt;
&lt;br /&gt;
=== Full-fledged modding toolset ===&lt;br /&gt;
* Similar to the NWN, NWN2 or Witcher toolset, but portable and FLOSS&lt;br /&gt;
** Might also support other games?&lt;br /&gt;
* Out of scope for xoreos&lt;br /&gt;
** Still, such a thing would be welcome under the xoreos banner&lt;br /&gt;
* [http://sourceforge.net/projects/neveredit/ Neveredit] might still be worth a look&lt;br /&gt;
&lt;br /&gt;
== Build system ==&lt;br /&gt;
&lt;br /&gt;
=== CMake ===&lt;br /&gt;
* Current doesn&#039;t set the git version to &amp;quot;+unk&amp;quot; when git isn&#039;t found&lt;br /&gt;
* make install/uninstall?&lt;br /&gt;
* make doxygen?&lt;br /&gt;
&lt;br /&gt;
=== Autotools ===&lt;br /&gt;
* Suppress the &amp;quot;fatal: not a git repository&amp;quot; when building gitstamp without a git directory&lt;br /&gt;
* Increased modularity&lt;br /&gt;
** Disabling engines&lt;br /&gt;
** Making library dependencies optional (and disabling certain features, then)&lt;br /&gt;
*** liblzma? Only needed for the iOS version of KotOR&lt;br /&gt;
*** libxml2? Only needed for the two Dragon Age games&lt;br /&gt;
** When something is disabled, skip it, if possible&lt;br /&gt;
*** Like the videos in KotOR Mac&lt;br /&gt;
** If skipping is not possible, error out&lt;br /&gt;
&lt;br /&gt;
== Nitro ==&lt;br /&gt;
&lt;br /&gt;
* The Nintendo DS (Nitro) specific file formats should probably be moved out of src/aurora/ and into src/nitro&lt;br /&gt;
* nitrofile, cdpth, nsbtx, smallfile&lt;br /&gt;
** nsbtx needs to be split into a class accessing the textures in src/nitro/ and an archive class on top in src/aurora/&lt;br /&gt;
** This means src/aurora/ accesses src/nitro/, so libnitro.la needs to come after libaurora.la in the linking order&lt;br /&gt;
* ndsrom as well?&lt;br /&gt;
* What about nftrfont and model_sonic in src/graphics/aurora/?&lt;br /&gt;
** src/graphics/nitro/?&lt;br /&gt;
** This would have src/graphics/nitro/ access src/graphics/aurora/, so graphics/libnitro.la needs to come before graphics/libaurora.la in the linking order&lt;br /&gt;
** That would be the other way round than for src/nitro/. Too confusing?&lt;br /&gt;
&lt;br /&gt;
== Graphics ==&lt;br /&gt;
&lt;br /&gt;
=== MDL supermodels and animations ===&lt;br /&gt;
* Mostly working in NWN thanks to jbowtie&#039;s work&lt;br /&gt;
* Might need some cleanup&lt;br /&gt;
* Models should smoothly change between different animations&lt;br /&gt;
* The animation system probably needs to be a bit more complex, to allow for &amp;quot;overlaying&amp;quot; different animations onto each other. For example, for speaking while holding an object and keeping the head focused on the PC character.&lt;br /&gt;
&lt;br /&gt;
=== Lighting ===&lt;br /&gt;
* We don&#039;t yet have a proper light system&lt;br /&gt;
* I started working on it: [https://drmccoy.de/xoreos/20150809T223407.png], but my approach is seriously lacking. You can see the edges of the tiles that make up on NWN area in many cases ([https://drmccoy.de/xoreos/20150809T223507.png], [https://drmccoy.de/xoreos/20150809T223548.png])&lt;br /&gt;
** See the [https://github.com/xoreos/xoreos/tree/light light branch] in the git repository&lt;br /&gt;
** Of course, the actual glLight* stuff won&#039;t be relevant anymore as soon as shaders are there&lt;br /&gt;
** Lighting in several (ASCII?) area tiles is broken&lt;br /&gt;
*** The door in Prelude.nwm&#039;s &amp;quot;m0q1a&amp;quot; area&lt;br /&gt;
*** A water tile in Chapter2.nwm&#039;s &amp;quot;map_m2q1a&amp;quot; area&lt;br /&gt;
*** A sloped snow tile in XP2_Chapter3.nwm&#039;s &amp;quot;thecityoflostsou&amp;quot;&lt;br /&gt;
&lt;br /&gt;
=== Materials ===&lt;br /&gt;
* Materials in The Witcher are closely tied to shaders&lt;br /&gt;
&lt;br /&gt;
=== OpenGL and Shaders ===&lt;br /&gt;
* mirv_ is currently working on a graphics system overhaul, complete with shader support&lt;br /&gt;
* All Aurora games use shaders in some form&lt;br /&gt;
* NWN uses ARB shaders. We probably need to rewrite them from scratch&lt;br /&gt;
* DirectX shaders might be automatically convertible with Cg?&lt;br /&gt;
* Otherwise, look at what Wine does with the shaders, and use that as a basis?&lt;br /&gt;
* All the games, even NWN, use some form of shaders. Still totally missing from xoreos, since we have no idea how to use them in general yet. Moreover, this was before GLSL, so they&#039;re in the old assembly-like language. We probably need to rewrite them from scratch&lt;br /&gt;
* We need shaders for tinting in NWN2 (objects and area geometry) and TexturePaint nodes in Witcher&lt;br /&gt;
&lt;br /&gt;
=== SDL 1.2 ===&lt;br /&gt;
* Optionally link against SDL 1.2 instead of SDL 2&lt;br /&gt;
* Should ideally use a configure flag to select between the two&lt;br /&gt;
** Maybe a CMake flag as well, if possible&lt;br /&gt;
* Assigned to clone2727, so anybody interested in this should coordinate with him&lt;br /&gt;
&lt;br /&gt;
== Videos ==&lt;br /&gt;
&lt;br /&gt;
=== XMV/WMV ===&lt;br /&gt;
* Used in Xbox versions of KotOR/KotOR2&lt;br /&gt;
* Our WMV decoder (for XMV videos used in Xbox versions) is missing P-frames and J-frame&lt;br /&gt;
** Code exists in ffmpeg, but is connected to the MPEG-4 family mess&lt;br /&gt;
&lt;br /&gt;
=== Actimagine VX ===&lt;br /&gt;
* Used in the Nintendo DS game Sonic Chronicles&lt;br /&gt;
* https://wiki.multimedia.cx/index.php?title=Actimagine_Video_Codec&lt;br /&gt;
&lt;br /&gt;
=== Sorenson 3 ===&lt;br /&gt;
* One single video in the Mac port of KotOR2, the Aspyr logo, uses the Sorenson 3 codec&lt;br /&gt;
** ffmpeg has a decoder, but it&#039;s connected to the MPEG-4 family mess (SVQ3 is similar to H.264)&lt;br /&gt;
* ScummVM needs that too&lt;br /&gt;
** While xoreos is GPLv3+, ScummVM is GPLv2+&lt;br /&gt;
** Somebody implementing Sorenson 3 for xoreos should ideally give explicit permission to relicense it GPLv2+ for ScummVM&lt;br /&gt;
*** Of course, if the decoder is based on prior work by other people, it has to be compatible with both GPLv2+ and GPLv3+&lt;br /&gt;
&lt;br /&gt;
=== Optimizations ===&lt;br /&gt;
* Optimize our simple BitStream interface&lt;br /&gt;
** See [https://fgiesen.wordpress.com/2016/01/02/end-of-buffer-checks-in-decompressors/ this blog post]&lt;br /&gt;
** Specifically, we don&#039;t do any peeking at all&lt;br /&gt;
** It still needs to handle different memory layouts, though&lt;br /&gt;
* Likewise, our Huffman class could probably be tuned a lot&lt;br /&gt;
* Pull in fft/rdft/dct/mdct optimizations from FFmpeg?&lt;br /&gt;
* I experimented with that in a private branch and it didn&#039;t do anything for Bink performance&lt;br /&gt;
&lt;br /&gt;
== Sound ==&lt;br /&gt;
&lt;br /&gt;
=== FMOD ===&lt;br /&gt;
* Dragon Age: Origins uses FMOD for sound and music&lt;br /&gt;
* I have experimental FSB (FMOD sound bank) support working in a private branch&lt;br /&gt;
* FEV (FMOD events) format is still unknown to us&lt;br /&gt;
** Apparently, groups of event lists with events&lt;br /&gt;
** Event is everything from &amp;quot;play sound&amp;quot;, over &amp;quot;set volume&amp;quot; to &amp;quot;apply echo&amp;quot;&lt;br /&gt;
** Game areas specify the group to use for the area&lt;br /&gt;
** Scripts then probably tell FMOD to play event lists out of that group&lt;br /&gt;
&lt;br /&gt;
=== Wwise ===&lt;br /&gt;
* Dragon Age 2 uses Wwise for sound and music&lt;br /&gt;
* Should be similar in concept to FMD&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
=== Gamepad binding ===&lt;br /&gt;
* The Xbox versions of KotOR and KotOR2 don&#039;t use a mouse. We have basic support for joysticks/gamepads, but no real bindings to the engine or ideas how to handle that in general&lt;br /&gt;
* We might want to handle the controller support the new KotOR2 Steam update brought&lt;br /&gt;
** override folder contains a gamepad.txt then&lt;br /&gt;
* Also hack in controller support for a non-Steam KotOR2? And for KotOR?&lt;br /&gt;
* Controller support in Jade Empire&lt;br /&gt;
* Controller support for Sonic? It is a Nintendo DS game after all&lt;br /&gt;
* Controller support for the non-console versions of the Dragon Age games?&lt;br /&gt;
&lt;br /&gt;
== Network ==&lt;br /&gt;
* We need a network subsystem&lt;br /&gt;
** [https://www.libsdl.org/projects/SDL_net/ SDL_net]?&lt;br /&gt;
** [http://www.boost.org/doc/libs/release/libs/asio/ Boost.Asio]?&lt;br /&gt;
** More options here: http://stackoverflow.com/questions/118945/best-c-c-network-library&lt;br /&gt;
* Engines need to be split into client and server classes&lt;br /&gt;
** The original engines all still do that, even when not exposing anything to users&lt;br /&gt;
** NWN and NWN2 allow user multiplayer&lt;br /&gt;
&lt;br /&gt;
== Engines ==&lt;br /&gt;
&lt;br /&gt;
=== Script system ===&lt;br /&gt;
* ImperatorPrime had started on a script system rewrite&lt;br /&gt;
** Includes functions with real signatures&lt;br /&gt;
** Maybe switch to that, if it works&lt;br /&gt;
* Rounds, object heartbeat scripts&lt;br /&gt;
* KotOR2 and NWN2 have some extensions&lt;br /&gt;
** It seems like they don&#039;t need any extensions to the low-level bytecode stuff&lt;br /&gt;
* Witcher uses Lua scripts together with NWScript&lt;br /&gt;
* Sonic has no scripts at all, it seems&lt;br /&gt;
* Currently a script in an infinite loop locks the game thread&lt;br /&gt;
** Timeout? Asynchronous script execution?&lt;br /&gt;
&lt;br /&gt;
=== NWN ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Basics are there, but needs fleshing out&lt;br /&gt;
** Character generator is mostly working&lt;br /&gt;
* [[Pathfinding]], walkmesh&lt;br /&gt;
** &amp;quot;Moving&amp;quot; should move the PC, not the camera&lt;br /&gt;
** NPC walking&lt;br /&gt;
** Triggers, areas on the floor that calls scripts on enter/leave&lt;br /&gt;
* Models&lt;br /&gt;
** ASCII models need averaging of smooth group normals&lt;br /&gt;
* NWN objects need an inventory concept&lt;br /&gt;
** Player characters&#039; might be different&lt;br /&gt;
*** Inventory tetris&lt;br /&gt;
*** Inventory item icons&lt;br /&gt;
* Multi-page asian fonts&lt;br /&gt;
* LanguageID 0 is not necessarily &amp;quot;English&amp;quot;, but &amp;quot;The language of the game install&amp;quot;&lt;br /&gt;
** This is okay for languages with Latin characters&lt;br /&gt;
** Messes up strings in community modules with Asian languages that stuff strings in to languageID 0&lt;br /&gt;
** The original fails there too, though&lt;br /&gt;
&lt;br /&gt;
=== KotOR/KotOR2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Many are already there&lt;br /&gt;
* Dialogues&lt;br /&gt;
** DLG files, similar to NWN&lt;br /&gt;
** Some extensions, like camera setup&lt;br /&gt;
** Dialogues are displayed very different than NWN&lt;br /&gt;
** KotOR2 has script extensions&lt;br /&gt;
*** Passing parameters to scripts&lt;br /&gt;
*** Call several scripts, combine with AND/OR for branching&lt;br /&gt;
* Animations&lt;br /&gt;
** Mostly working now&lt;br /&gt;
* Minigames&lt;br /&gt;
** Swoop racing&lt;br /&gt;
** Pazaak&lt;br /&gt;
** Hardcoded, mostly removed from usual game logic&lt;br /&gt;
&lt;br /&gt;
=== Jade Empire ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Main menu with options submenu is there&lt;br /&gt;
* Minigames&lt;br /&gt;
** Flyer, top-down shoot-em-up thing&lt;br /&gt;
** Hardcoded, mostly removed from usual game logic&lt;br /&gt;
* Player character&lt;br /&gt;
** Needs research&lt;br /&gt;
* Sound&lt;br /&gt;
** Uses an ASCII variant of the [http://wiki.multimedia.cx/index.php?title=XACT XACT formats]&lt;br /&gt;
*** Cues probably not as complex as FMOD/Wwise&lt;br /&gt;
*** Effects need extension of the Sound system, maybe&lt;br /&gt;
** Xbox version might use the binary format?&lt;br /&gt;
*** Sound banks could be handles as archives and indexed in the ResourceManager?&lt;br /&gt;
** [https://github.com/flibitijibibo/FACT FACT] is an implementation of XAudio, including XACT, zlib-licensed&lt;br /&gt;
&lt;br /&gt;
=== NWN2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Implemented using XML&lt;br /&gt;
** See [[#Broken NWN2 XML|Broken NWN2 XML]]&lt;br /&gt;
* Animations (Granny)&lt;br /&gt;
** [https://github.com/SkywingvL/nwn2dev-public nwn2-dev] contains some code working with Granny data&lt;br /&gt;
*** Call into the original Granny DLL to convert between binary and ASCII Granny data, though&lt;br /&gt;
** [https://github.com/berenm/xoreos-tools/tree/granny berenm started some Granny RE]&lt;br /&gt;
* Facial animations (FaceFX)&lt;br /&gt;
* Trees (SpeedTree)&lt;br /&gt;
* Proper evaluation of creature model parts (equipped items)&lt;br /&gt;
* Player character&lt;br /&gt;
** Reading of PC files in creature&lt;br /&gt;
&lt;br /&gt;
=== Sonic Chronicles ===&lt;br /&gt;
* Allow using the contents from an extracted NDS file?&lt;br /&gt;
* Menus&lt;br /&gt;
** GUI files that are GFF&lt;br /&gt;
** Actions in a state machine in GDA files?&lt;br /&gt;
* Music/Sound&lt;br /&gt;
** Music is apparently similar to MIDI, or to a tracker format?&lt;br /&gt;
** Sounds and instruments for music are in a sound_data.sadl archive&lt;br /&gt;
* Animations&lt;br /&gt;
** Bone animations, best implemented with shaders, blocked by the graphics subsystem rewrite&lt;br /&gt;
* Player character(s)&lt;br /&gt;
** Needs research&lt;br /&gt;
&lt;br /&gt;
=== The Witcher ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Apparently build using Lua&lt;br /&gt;
** System/Scripts/ has gui*.luc files&lt;br /&gt;
* Animations&lt;br /&gt;
** Needs research&lt;br /&gt;
* Player character, Geralt&lt;br /&gt;
** Needs research&lt;br /&gt;
&lt;br /&gt;
=== Dragon Age: Origins / Dragon Age 2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Scaleform_GFx Scaleform GFx]&lt;br /&gt;
** [http://social.bioware.com/wiki/datoolset/index.php/UI_Tutorial_%28draft%29 UI Tutorial] on the Dragon Age toolset wiki&lt;br /&gt;
** Flash-based!&lt;br /&gt;
** A good starting point for a reimplementation might be [https://en.wikipedia.org/wiki/Gameswf Gameswf].&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Gnash Gnash], [https://en.wikipedia.org/wiki/Lightspark Lightspark], [https://en.wikipedia.org/wiki/Swfdec Swfdec]&lt;br /&gt;
** [http://www.nowrap.de/flasm.html Flasm] can disassemble/assemble ActionScript, [http://www.nowrap.de/flare.html Flare] can decompile it&lt;br /&gt;
** [https://wwwimages2.adobe.com/content/dam/acom/en/devnet/pdf/swf-file-format-spec.pdf swf-file-format-spec.pdf] is a great reference which covers mostly every aspect of the gfx files.&lt;br /&gt;
** [https://github.com/jindrapetrik/jpexs-decompiler jpexs-decompiler] can decompile and handles scaleform specific tags.&lt;br /&gt;
* Animations&lt;br /&gt;
** Bone animations, best implemented with shaders, blocked by the graphics subsystem rewrite&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=Developer_Central&amp;diff=356</id>
		<title>Developer Central</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=Developer_Central&amp;diff=356"/>
		<updated>2018-05-20T23:49:50Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* Reverse engineering help */ Update REWiki URLs&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this page is to give a link to all kinds of resources that contain information valuable to current and future developers of xoreos.&lt;br /&gt;
&lt;br /&gt;
== The source repository ==&lt;br /&gt;
&lt;br /&gt;
The main xoreos source repositories are hosted on [https://github.com/xoreos/ GitHub]. Please see the [[Git]] page on details on how the repositories are structured and how to retrieve the code.&lt;br /&gt;
&lt;br /&gt;
== Compilation ==&lt;br /&gt;
&lt;br /&gt;
See the [[Compiling xoreos]] and [[Compiling xoreos-tools]] pages for information on how to compile our source code on various operating systems.&lt;br /&gt;
&lt;br /&gt;
== Community ==&lt;br /&gt;
&lt;br /&gt;
We strive to be a friendly and open development community. Therefore, we have adopted a [https://github.com/xoreos/xoreos/blob/master/CODE_OF_CONDUCT.md Code of Conduct] guiding us. By participating in this project you agree to abide by its terms.&lt;br /&gt;
&lt;br /&gt;
Our main place for organizing and socializing is the [[IRC channel|#xoreos channel on Freenode IRC]]. You will find most of the developers idling there, happy to answer any questions you might have. If you plan to become a frequent contributor, please consider regularly joining this channel as well.&lt;br /&gt;
&lt;br /&gt;
However, there is not public log bot in #xoreos, so there is no public, permanent record. Therefore, discussions about far reaching changes in the codebase are best held on [[Mailing lists|our mailing list]]. Contributors are encouraged to subscribe to this list.&lt;br /&gt;
&lt;br /&gt;
If you intend to work on a feature, or otherwise contribute to xoreos, please notify us before-hand, so that unnecessary, accidentally doubling of work can be avoided.&lt;br /&gt;
&lt;br /&gt;
== Reporting bugs ==&lt;br /&gt;
&lt;br /&gt;
Bugs should be reported on the GitHub issue tracker. If the bug concerns xoreos itself, use the [https://github.com/xoreos/xoreos/issues one for xoreos], if the bug concerns the xoreos-tools, use the [https://github.com/xoreos/xoreos-tools/issues one for xoreos-tools]. Likewise, all the other [https://github.com/xoreos repositories] have issue tracking enabled.&lt;br /&gt;
&lt;br /&gt;
== Code style ==&lt;br /&gt;
&lt;br /&gt;
We have [[Code Formatting Conventions]] you are expected to follow. Patches and pull requests that do not follow these conventions will be rejected or at least delayed until they are cleaned up to comply.&lt;br /&gt;
&lt;br /&gt;
== Commit guidelines ==&lt;br /&gt;
&lt;br /&gt;
Please read the [[Commit Guidelines]]. We want to keep our project history clean and readable.&lt;br /&gt;
&lt;br /&gt;
== Branches ==&lt;br /&gt;
&lt;br /&gt;
Do not work directly on the master branch. Instead, use [https://www.atlassian.com/git/tutorials/comparing-workflows/feature-branch-workflow feature branches], one for each new feature you are working on. This ensures that each feature has its own, clean history that can be reviewed more easily. Once the feature has been merged into the main development tree, you are of course free to delete your feature branch again.&lt;br /&gt;
&lt;br /&gt;
== Pull Requests ==&lt;br /&gt;
&lt;br /&gt;
If you do not have push permissions to the official xoreos repositories, and especially if you&#039;re a first-time contributor, we prefer to receive your changes as a [https://help.github.com/articles/using-pull-requests pull request on GitHub]. This requires you to have/register a GitHub account, fork our repository, commit your changes to a branch and then issue a Pull Request.&lt;br /&gt;
&lt;br /&gt;
Please only add commits belonging to this one feature to the pull requests; do not intersperse them with unrelated changes. Also try to [https://git-scm.com/book/en/v2/Git-Tools-Rewriting-History actively tidy your history]: combine related commits with interactive rebasing, separate monolithic commits, etc. Feel free to force-push to your feature branch to tidy your history.&lt;br /&gt;
&lt;br /&gt;
Before and during the review process, please keep up to date with the xoreos master branch by [https://git-scm.com/book/en/v2/Git-Branching-Rebasing rebasing] your changes onto the current master.&lt;br /&gt;
&lt;br /&gt;
== Pushing to the official repositories ==&lt;br /&gt;
&lt;br /&gt;
Once we&#039;ve made sure that you understood and can follow the style and commit guidelines and you expressed interest in further contributing to xoreos, we will be happy to have you join the xoreos development team, and grant you push permissions to the official repositories. You are then expected to continue to follow these guidelines out of your own accord, without the need for intervention by other developers. If you are unsure about how a specific case interact with the guidelines, please feel free to ask.&lt;br /&gt;
&lt;br /&gt;
To avoid people accidentally working on the same feature, or otherwise stepping on each others&#039; toes, consider announcement what you are working on in the [[IRC channel]] or the [[Mailing lists|mailing list]].&lt;br /&gt;
&lt;br /&gt;
== Continuous Integration ==&lt;br /&gt;
&lt;br /&gt;
The public xoreos repositories are build by two [https://en.wikipedia.org/wiki/Continuous_integration Continuous Integration] services on every push: [https://travis-ci.org/ Travis CI] (for GNU/Linux, using both the autotools and the CMake build systems and also using both gcc and clang) and [https://www.appveyor.com/ AppVeyor] (for Windows, using Microsoft Visual Studio). If a compilation error occurs, the build failure announced is on our [https://wiki.xoreos.org/index.php?title=IRC_channel IRC channel], so that it may be fixed quickly. Pull Requests are also run through these CI services and we like to have all failures fixed before merging.&lt;br /&gt;
&lt;br /&gt;
== Unit tests ==&lt;br /&gt;
&lt;br /&gt;
The xoreos repositories also provide unit tests for many common classes. These are build and run right after the main binaries on every push, by the CI services we use. A failure in one of these unit tests leads to the build being treated as failed. That way, it&#039;s immediately obvious when we break anything.&lt;br /&gt;
&lt;br /&gt;
All xoreos developers are advised to run these unit tests themselves while writing code that touches the common code. In both of our build systems, &amp;quot;make check&amp;quot; does exactly this.&lt;br /&gt;
&lt;br /&gt;
When writing new common classes, or adding functionality to existing ones, also writing new unit tests checking the new functionality is hugely appreciated.&lt;br /&gt;
&lt;br /&gt;
== Reverse engineering help ==&lt;br /&gt;
&lt;br /&gt;
For people starting out with reverse engineering, here are a few useful resources:&lt;br /&gt;
&lt;br /&gt;
* The [http://wiki.scummvm.org/index.php/HOWTO-Reverse_Engineering HOWTO-Reverse Engineering] page in ScummVM&#039;s wiki&lt;br /&gt;
* [http://rewiki.awiki.org/wiki/Main_Page REWiki] contains a collection of game reverse engineering knowledge. They have a [http://rewiki.awiki.org/wiki/Reverse_engineering_hints hints page] as well&lt;br /&gt;
* [http://wiki.xentax.com/index.php?title=Game_File_Format_Central XentaxWiki] focuses on game file formats. They too have a [http://wiki.xentax.com/index.php?title=DGTEFF guide page]&lt;br /&gt;
* For audio and video formats, there&#039;s [http://wiki.multimedia.cx/ MultimediaWiki], which is associated with the ffmpeg and libav projects&lt;br /&gt;
&lt;br /&gt;
== To do list ==&lt;br /&gt;
&lt;br /&gt;
Our [[TODO|Main TODO list]] contains a rambly, non-exhaustive collection of things left to do.&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=TODO&amp;diff=355</id>
		<title>TODO</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=TODO&amp;diff=355"/>
		<updated>2018-05-15T22:01:55Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* Jade Empire */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a long rambly list of things left to do in xoreos and xoreos-tools. Anybody is welcome to tackle any of these tasks, but please also read our [[Developer_Central|general contributor overview]], including our [[Code_Formatting_Conventions|Code Formatting Conventions]], [[Commit_Guidelines|Commit Guidelines]] and [https://github.com/xoreos/xoreos/blob/master/CODE_OF_CONDUCT.md Code of Conduct]. If you plan to do any of these tasks, please also [[Contact_us|contact us]] beforehand, so we can better coordinate multiple people interested in doing the same task, and discuss how to best solve the problem. Thanks. :)&lt;br /&gt;
&lt;br /&gt;
(&#039;&#039;&#039;See also:&#039;&#039;&#039; the Kanban-like &amp;quot;Projects&amp;quot; boards on GitHub: https://github.com/orgs/xoreos/projects, but they&#039;re not public and no way to make public at the moment. Boo.)&lt;br /&gt;
&lt;br /&gt;
== Documentation ==&lt;br /&gt;
&lt;br /&gt;
=== Developer information ===&lt;br /&gt;
* Extend the developer information on the wiki&lt;br /&gt;
** Explain how to get the xoreos sources on various platforms&lt;br /&gt;
** Expand GNU/Linux compiling instructions to cover more distributions&lt;br /&gt;
** Expand Mac OS X compiling instructions&lt;br /&gt;
*** Xcode&lt;br /&gt;
*** Homebrew/MacPorts/Fink&lt;br /&gt;
*** CMake, Libraries&lt;br /&gt;
** [http://wiki.arx-libertatis.org/Developer_Information Arx Libertatis] has an extensive dev page&lt;br /&gt;
* Document file formats on the wiki?&lt;br /&gt;
** Or integrate info into XentaxWiki?&lt;br /&gt;
** Both?&lt;br /&gt;
&lt;br /&gt;
=== User information ===&lt;br /&gt;
* More user information on the wiki&lt;br /&gt;
** How to download xoreos&lt;br /&gt;
** How to install the games on various platforms&lt;br /&gt;
** [http://wiki.arx-libertatis.org/Main_Page Arx Libertatis] does that pretty well&lt;br /&gt;
&lt;br /&gt;
=== Modder information ===&lt;br /&gt;
* Link to relevant modding resources&lt;br /&gt;
* Maybe even some kind of Modder&#039;s Handbook&lt;br /&gt;
** A big overview of modding Aurora games in general&lt;br /&gt;
*** Differences and commonalities between games&lt;br /&gt;
** Linking/Grouping engine functions between games&lt;br /&gt;
&lt;br /&gt;
== Website ==&lt;br /&gt;
&lt;br /&gt;
=== Design ===&lt;br /&gt;
* Better website design?&lt;br /&gt;
** It still should be static in the end&lt;br /&gt;
*** No PHP or Rails&lt;br /&gt;
*** Very light on JavaScript&lt;br /&gt;
*** No Flash!&lt;br /&gt;
** Maybe a bit more unique, graphical&lt;br /&gt;
** For legal reasons, we shouldn&#039;t directly use art or designs from the original games&lt;br /&gt;
*** Something inspired by the art of the orginal games would fit&lt;br /&gt;
&lt;br /&gt;
=== Octopress ===&lt;br /&gt;
* Move away from Octopress?&lt;br /&gt;
** Alternative should still produce static HTML somehow&lt;br /&gt;
** Octopress works rather well. It reads Markdown, which is a plus&lt;br /&gt;
* Octopress 3.0?&lt;br /&gt;
** Not finished yet, it seems&lt;br /&gt;
&lt;br /&gt;
== Standalone(ish) fixes/improvements ==&lt;br /&gt;
&lt;br /&gt;
=== Broken NWN2 XML ===&lt;br /&gt;
* Not standards-conforming XML. Need custom XML parser; stock XML parsing libraries will just throw errors.&lt;br /&gt;
** &amp;lt;nowiki&amp;gt;&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;NWN2UI&amp;quot;&amp;gt;&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
** No single root element&lt;br /&gt;
** Attribute values not enclosed in quotes most of the time&lt;br /&gt;
** Special characters in attribute values not properly escaped&lt;br /&gt;
** Unmatched quotes on several occasions&lt;br /&gt;
* Event functions&lt;br /&gt;
* Special values like PARENT_WIDTH&lt;br /&gt;
* [https://github.com/xoreos/xoreos-tools/pull/1 Altrite is working on a broken-XML fixer]&lt;br /&gt;
&lt;br /&gt;
=== CJK glyphs in the console ===&lt;br /&gt;
* The &amp;quot;system font&amp;quot; we use for our debug console, DejaVu Sans Mono Bold, does not feature any CJK (Chinese, Japanese, Korean) glyphs&lt;br /&gt;
* Not strictly necessary, but nice to have for printing, say, Witcher area names in Asian languages&lt;br /&gt;
* We could maybe integrate CJK glyphs from the [http://fonts.jp/hanazono/ Hanazono fonts] or other suitable libre fonts&lt;br /&gt;
* We need to match the height with DejaVu Sans Mono Bold&lt;br /&gt;
* CJK glyphs tend to be more complex and therefore wider. They&#039;re usually rendered twice as wide as Latin glyphs&lt;br /&gt;
* Our console code needs to take that into account&lt;br /&gt;
&lt;br /&gt;
=== Fuzzing ===&lt;br /&gt;
* Run our file readers, image decoders, etc. through a fuzzer, like [http://lcamtuf.coredump.cx/afl/ afl] (american fuzzy lop)&lt;br /&gt;
* Fix any cases where it crashes&lt;br /&gt;
* The xoreos-tools might be a good starting point for singular, standalone testing&lt;br /&gt;
** For image decoders, a slightly modified xoreostex2tga tool might work&lt;br /&gt;
* File formats already fuzzed:&lt;br /&gt;
** CBGT, CDPTH, DDS, NBFS, NCGR, NCLR, SBM, TGA, TPC, TXB&lt;br /&gt;
** 2DA, KEY/BIF, ERF, GFF3, GFF4, GDA, TLK, NSBTX, RIM, SMALL, SSF&lt;br /&gt;
&lt;br /&gt;
=== Script decompiler ===&lt;br /&gt;
* It might be quite useful to have a NWScript decompiler in xoreos-tools&lt;br /&gt;
* We have a script disassembler, ncsdis&lt;br /&gt;
** Which already does code flow analysis&lt;br /&gt;
* Missing:&lt;br /&gt;
** Code generation&lt;br /&gt;
** Collapsing of instruction chains into single-line NWScript code&lt;br /&gt;
*** For example, &amp;quot;int var = foo * bar + quux&amp;quot; compiles to a long chain with multiple temporaries&lt;br /&gt;
** Proper handling of structs and vectors&lt;br /&gt;
&lt;br /&gt;
=== Script compiler ===&lt;br /&gt;
* An NWScript compiler might be useful as well&lt;br /&gt;
** A script assembler might be an easy first step&lt;br /&gt;
&lt;br /&gt;
=== File format writers ===&lt;br /&gt;
* GFF3Writer, GFF4Writer&lt;br /&gt;
** Both necessary to create save games compatible with the original games&lt;br /&gt;
** Also useful for a xml2gff tool&lt;br /&gt;
* xml2tlk&lt;br /&gt;
** TalkTable_GFF::write02() and ::write05()&lt;br /&gt;
** Needs GFF4Writer&lt;br /&gt;
* Archive (ERF, RIM, KEY/BIF) packers?&lt;br /&gt;
&lt;br /&gt;
=== Config file ===&lt;br /&gt;
* Should be more preserving of the layout&lt;br /&gt;
** Especially empty lines&lt;br /&gt;
** UTF-8 Byte-Order-Mark when using native Windows editors&lt;br /&gt;
** \r is currently always stripped. Maybe preserve that too&lt;br /&gt;
*** Autodetect when \r is already used, and add it to new config lines too&lt;br /&gt;
** This basically needs a complete rewrite of the config parser&lt;br /&gt;
*** Don&#039;t just look for comments, just throw everything after &amp;quot;foo=bar&amp;quot; into the &amp;quot;comment&amp;quot; variable, including whitespace&lt;br /&gt;
*** And all whitespace before &amp;quot;foo=bar&amp;quot; into a &amp;quot;prefix&amp;quot; variable&lt;br /&gt;
** Maybe even always add BOM and \r when writing a new config file on Windows?&lt;br /&gt;
&lt;br /&gt;
=== Windows-specific / Wine-specific ===&lt;br /&gt;
* When running my mingw32 cross-compiled xoreos EXE in Wine, the menu button texts are partially cut off&lt;br /&gt;
** Z-fighting issue?&lt;br /&gt;
** Does that also occur on a real Windows?&lt;br /&gt;
&lt;br /&gt;
=== GUI ===&lt;br /&gt;
* xoreos could use a global GUI to start games from&lt;br /&gt;
* Should probably be similar to ScummVM&#039;s GUI, at least in effect&lt;br /&gt;
* Should read the config file, list all targets&lt;br /&gt;
** Press a &amp;quot;Play&amp;quot; button to play the game&lt;br /&gt;
** Press an &amp;quot;Edit&amp;quot; button to edit the entry&lt;br /&gt;
*** Dialog options to edit common settings&lt;br /&gt;
*** An additional free-form editor?&lt;br /&gt;
*** Game-specific options?&lt;br /&gt;
** A button to edit global settings (&amp;quot;xoreos&amp;quot; config domain)&lt;br /&gt;
** For the future, a way to immediately load a saved game?&lt;br /&gt;
** An &amp;quot;Add&amp;quot; button to add a game&lt;br /&gt;
*** File browser&lt;br /&gt;
**** Select directories for most game&lt;br /&gt;
**** Select file for Sonic Chronicles&lt;br /&gt;
*** View current saved games of a target?&lt;br /&gt;
* Probably implemented using OpenGL, just like, say, the console&lt;br /&gt;
* Theme-able/Skinable?&lt;br /&gt;
* Some potential stumbling blocks&lt;br /&gt;
** Displaying &amp;quot;uncommon&amp;quot; text in both game descriptions and file paths&lt;br /&gt;
*** &amp;quot;Decomposed&amp;quot; letters, i.e. base letter + combining glyphs&lt;br /&gt;
*** CJK&lt;br /&gt;
*** Arabic and other scripts where letters change depending on their place in the word&lt;br /&gt;
*** Right-to-left&lt;br /&gt;
** Shortening those strings when they don&#039;t fit in their fields is also potentially difficult&lt;br /&gt;
&lt;br /&gt;
=== Localization ===&lt;br /&gt;
* Text in exceptions?&lt;br /&gt;
** At least the user-visible ones, like &amp;quot;Failed to detect game&amp;quot;&lt;br /&gt;
** Or maybe we should clean that up and split them into &amp;quot;program logic failure&amp;quot; and &amp;quot;user failure&amp;quot;, with only the latter translated&lt;br /&gt;
* Strings for the engine loader progress bar&lt;br /&gt;
* Debug console string&lt;br /&gt;
* GUI (see above) strings&lt;br /&gt;
* [http://www.gnu.org/software/gettext/ GNU gettext] would be one solution&lt;br /&gt;
&lt;br /&gt;
=== Unit tests ===&lt;br /&gt;
* More unit tests&lt;br /&gt;
&lt;br /&gt;
=== Resource Explorer ===&lt;br /&gt;
* A portable, user-friendly graphical resource explorer could be useful&lt;br /&gt;
* [https://github.com/xoreos/phaethon Phaethon] is a start&lt;br /&gt;
** It can look into game archives, show textures and play sounds&lt;br /&gt;
** It uses [https://www.wxwidgets.org/ wxWidgets] to do the GUI&lt;br /&gt;
** Or possibly rewriting it to use [https://www.qt.io/ Qt] is better?&lt;br /&gt;
&lt;br /&gt;
=== Model converters ===&lt;br /&gt;
* Document the model formats&lt;br /&gt;
* Convert between the binary model formats and their ASCII equivalents&lt;br /&gt;
* Convert between the binary model formats and ones that can be opened by modelling tools&lt;br /&gt;
** 3D Studio Max&lt;br /&gt;
** Blender&lt;br /&gt;
&lt;br /&gt;
=== Full-fledged modding toolset ===&lt;br /&gt;
* Similar to the NWN, NWN2 or Witcher toolset, but portable and FLOSS&lt;br /&gt;
** Might also support other games?&lt;br /&gt;
* Out of scope for xoreos&lt;br /&gt;
** Still, such a thing would be welcome under the xoreos banner&lt;br /&gt;
* [http://sourceforge.net/projects/neveredit/ Neveredit] might still be worth a look&lt;br /&gt;
&lt;br /&gt;
== Build system ==&lt;br /&gt;
&lt;br /&gt;
=== CMake ===&lt;br /&gt;
* Current doesn&#039;t set the git version to &amp;quot;+unk&amp;quot; when git isn&#039;t found&lt;br /&gt;
* make install/uninstall?&lt;br /&gt;
* make doxygen?&lt;br /&gt;
&lt;br /&gt;
=== Autotools ===&lt;br /&gt;
* Suppress the &amp;quot;fatal: not a git repository&amp;quot; when building gitstamp without a git directory&lt;br /&gt;
* Increased modularity&lt;br /&gt;
** Disabling engines&lt;br /&gt;
** Making library dependencies optional (and disabling certain features, then)&lt;br /&gt;
*** liblzma? Only needed for the iOS version of KotOR&lt;br /&gt;
*** libxml2? Only needed for the two Dragon Age games&lt;br /&gt;
** When something is disabled, skip it, if possible&lt;br /&gt;
*** Like the videos in KotOR Mac&lt;br /&gt;
** If skipping is not possible, error out&lt;br /&gt;
&lt;br /&gt;
== Nitro ==&lt;br /&gt;
&lt;br /&gt;
* The Nintendo DS (Nitro) specific file formats should probably be moved out of src/aurora/ and into src/nitro&lt;br /&gt;
* nitrofile, cdpth, nsbtx, smallfile&lt;br /&gt;
** nsbtx needs to be split into a class accessing the textures in src/nitro/ and an archive class on top in src/aurora/&lt;br /&gt;
** This means src/aurora/ accesses src/nitro/, so libnitro.la needs to come after libaurora.la in the linking order&lt;br /&gt;
* ndsrom as well?&lt;br /&gt;
* What about nftrfont and model_sonic in src/graphics/aurora/?&lt;br /&gt;
** src/graphics/nitro/?&lt;br /&gt;
** This would have src/graphics/nitro/ access src/graphics/aurora/, so graphics/libnitro.la needs to come before graphics/libaurora.la in the linking order&lt;br /&gt;
** That would be the other way round than for src/nitro/. Too confusing?&lt;br /&gt;
&lt;br /&gt;
== Graphics ==&lt;br /&gt;
&lt;br /&gt;
=== MDL supermodels and animations ===&lt;br /&gt;
* Mostly working in NWN thanks to jbowtie&#039;s work&lt;br /&gt;
* Might need some cleanup&lt;br /&gt;
* Models should smoothly change between different animations&lt;br /&gt;
* The animation system probably needs to be a bit more complex, to allow for &amp;quot;overlaying&amp;quot; different animations onto each other. For example, for speaking while holding an object and keeping the head focused on the PC character.&lt;br /&gt;
&lt;br /&gt;
=== Lighting ===&lt;br /&gt;
* We don&#039;t yet have a proper light system&lt;br /&gt;
* I started working on it: [https://drmccoy.de/xoreos/20150809T223407.png], but my approach is seriously lacking. You can see the edges of the tiles that make up on NWN area in many cases ([https://drmccoy.de/xoreos/20150809T223507.png], [https://drmccoy.de/xoreos/20150809T223548.png])&lt;br /&gt;
** See the [https://github.com/xoreos/xoreos/tree/light light branch] in the git repository&lt;br /&gt;
** Of course, the actual glLight* stuff won&#039;t be relevant anymore as soon as shaders are there&lt;br /&gt;
** Lighting in several (ASCII?) area tiles is broken&lt;br /&gt;
*** The door in Prelude.nwm&#039;s &amp;quot;m0q1a&amp;quot; area&lt;br /&gt;
*** A water tile in Chapter2.nwm&#039;s &amp;quot;map_m2q1a&amp;quot; area&lt;br /&gt;
*** A sloped snow tile in XP2_Chapter3.nwm&#039;s &amp;quot;thecityoflostsou&amp;quot;&lt;br /&gt;
&lt;br /&gt;
=== Materials ===&lt;br /&gt;
* Materials in The Witcher are closely tied to shaders&lt;br /&gt;
&lt;br /&gt;
=== OpenGL and Shaders ===&lt;br /&gt;
* mirv_ is currently working on a graphics system overhaul, complete with shader support&lt;br /&gt;
* All Aurora games use shaders in some form&lt;br /&gt;
* NWN uses ARB shaders. We probably need to rewrite them from scratch&lt;br /&gt;
* DirectX shaders might be automatically convertible with Cg?&lt;br /&gt;
* Otherwise, look at what Wine does with the shaders, and use that as a basis?&lt;br /&gt;
* All the games, even NWN, use some form of shaders. Still totally missing from xoreos, since we have no idea how to use them in general yet. Moreover, this was before GLSL, so they&#039;re in the old assembly-like language. We probably need to rewrite them from scratch&lt;br /&gt;
* We need shaders for tinting in NWN2 (objects and area geometry) and TexturePaint nodes in Witcher&lt;br /&gt;
&lt;br /&gt;
=== SDL 1.2 ===&lt;br /&gt;
* Optionally link against SDL 1.2 instead of SDL 2&lt;br /&gt;
* Should ideally use a configure flag to select between the two&lt;br /&gt;
** Maybe a CMake flag as well, if possible&lt;br /&gt;
* Assigned to clone2727, so anybody interested in this should coordinate with him&lt;br /&gt;
&lt;br /&gt;
== Videos ==&lt;br /&gt;
&lt;br /&gt;
=== XMV/WMV ===&lt;br /&gt;
* Used in Xbox versions of KotOR/KotOR2&lt;br /&gt;
* Our WMV decoder (for XMV videos used in Xbox versions) is missing P-frames and J-frame&lt;br /&gt;
** Code exists in ffmpeg, but is connected to the MPEG-4 family mess&lt;br /&gt;
&lt;br /&gt;
=== Actimagine VX ===&lt;br /&gt;
* Used in the Nintendo DS game Sonic Chronicles&lt;br /&gt;
* https://wiki.multimedia.cx/index.php?title=Actimagine_Video_Codec&lt;br /&gt;
&lt;br /&gt;
=== Sorenson 3 ===&lt;br /&gt;
* One single video in the Mac port of KotOR2, the Aspyr logo, uses the Sorenson 3 codec&lt;br /&gt;
** ffmpeg has a decoder, but it&#039;s connected to the MPEG-4 family mess (SVQ3 is similar to H.264)&lt;br /&gt;
* ScummVM needs that too&lt;br /&gt;
** While xoreos is GPLv3+, ScummVM is GPLv2+&lt;br /&gt;
** Somebody implementing Sorenson 3 for xoreos should ideally give explicit permission to relicense it GPLv2+ for ScummVM&lt;br /&gt;
*** Of course, if the decoder is based on prior work by other people, it has to be compatible with both GPLv2+ and GPLv3+&lt;br /&gt;
&lt;br /&gt;
=== Optimizations ===&lt;br /&gt;
* Optimize our simple BitStream interface&lt;br /&gt;
** See [https://fgiesen.wordpress.com/2016/01/02/end-of-buffer-checks-in-decompressors/ this blog post]&lt;br /&gt;
** Specifically, we don&#039;t do any peeking at all&lt;br /&gt;
** It still needs to handle different memory layouts, though&lt;br /&gt;
* Likewise, our Huffman class could probably be tuned a lot&lt;br /&gt;
* Pull in fft/rdft/dct/mdct optimizations from FFmpeg?&lt;br /&gt;
* I experimented with that in a private branch and it didn&#039;t do anything for Bink performance&lt;br /&gt;
&lt;br /&gt;
== Sound ==&lt;br /&gt;
&lt;br /&gt;
=== FMOD ===&lt;br /&gt;
* Dragon Age: Origins uses FMOD for sound and music&lt;br /&gt;
* I have experimental FSB (FMOD sound bank) support working in a private branch&lt;br /&gt;
* FEV (FMOD events) format is still unknown to us&lt;br /&gt;
** Apparently, groups of event lists with events&lt;br /&gt;
** Event is everything from &amp;quot;play sound&amp;quot;, over &amp;quot;set volume&amp;quot; to &amp;quot;apply echo&amp;quot;&lt;br /&gt;
** Game areas specify the group to use for the area&lt;br /&gt;
** Scripts then probably tell FMOD to play event lists out of that group&lt;br /&gt;
&lt;br /&gt;
=== Wwise ===&lt;br /&gt;
* Dragon Age 2 uses Wwise for sound and music&lt;br /&gt;
* Should be similar in concept to FMD&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
=== Gamepad binding ===&lt;br /&gt;
* The Xbox versions of KotOR and KotOR2 don&#039;t use a mouse. We have basic support for joysticks/gamepads, but no real bindings to the engine or ideas how to handle that in general&lt;br /&gt;
* We might want to handle the controller support the new KotOR2 Steam update brought&lt;br /&gt;
** override folder contains a gamepad.txt then&lt;br /&gt;
* Also hack in controller support for a non-Steam KotOR2? And for KotOR?&lt;br /&gt;
* Controller support in Jade Empire&lt;br /&gt;
* Controller support for Sonic? It is a Nintendo DS game after all&lt;br /&gt;
* Controller support for the non-console versions of the Dragon Age games?&lt;br /&gt;
&lt;br /&gt;
== Network ==&lt;br /&gt;
* We need a network subsystem&lt;br /&gt;
** [https://www.libsdl.org/projects/SDL_net/ SDL_net]?&lt;br /&gt;
** [http://www.boost.org/doc/libs/release/libs/asio/ Boost.Asio]?&lt;br /&gt;
** More options here: http://stackoverflow.com/questions/118945/best-c-c-network-library&lt;br /&gt;
* Engines need to be split into client and server classes&lt;br /&gt;
** The original engines all still do that, even when not exposing anything to users&lt;br /&gt;
** NWN and NWN2 allow user multiplayer&lt;br /&gt;
&lt;br /&gt;
== Engines ==&lt;br /&gt;
&lt;br /&gt;
=== Script system ===&lt;br /&gt;
* ImperatorPrime had started on a script system rewrite&lt;br /&gt;
** Includes functions with real signatures&lt;br /&gt;
** Maybe switch to that, if it works&lt;br /&gt;
* Rounds, object heartbeat scripts&lt;br /&gt;
* KotOR2 and NWN2 have some extensions&lt;br /&gt;
** It seems like they don&#039;t need any extensions to the low-level bytecode stuff&lt;br /&gt;
* Witcher uses Lua scripts together with NWScript&lt;br /&gt;
* Sonic has no scripts at all, it seems&lt;br /&gt;
* Currently a script in an infinite loop locks the game thread&lt;br /&gt;
** Timeout? Asynchronous script execution?&lt;br /&gt;
&lt;br /&gt;
=== NWN ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Basics are there, but needs fleshing out&lt;br /&gt;
** Character generator is mostly working&lt;br /&gt;
* [[Pathfinding]], walkmesh&lt;br /&gt;
** &amp;quot;Moving&amp;quot; should move the PC, not the camera&lt;br /&gt;
** NPC walking&lt;br /&gt;
** Triggers, areas on the floor that calls scripts on enter/leave&lt;br /&gt;
* Models&lt;br /&gt;
** ASCII models need averaging of smooth group normals&lt;br /&gt;
* NWN objects need an inventory concept&lt;br /&gt;
** Player characters&#039; might be different&lt;br /&gt;
*** Inventory tetris&lt;br /&gt;
*** Inventory item icons&lt;br /&gt;
* Multi-page asian fonts&lt;br /&gt;
* LanguageID 0 is not necessarily &amp;quot;English&amp;quot;, but &amp;quot;The language of the game install&amp;quot;&lt;br /&gt;
** This is okay for languages with Latin characters&lt;br /&gt;
** Messes up strings in community modules with Asian languages that stuff strings in to languageID 0&lt;br /&gt;
** The original fails there too, though&lt;br /&gt;
&lt;br /&gt;
=== KotOR/KotOR2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Many are already there&lt;br /&gt;
* Dialogues&lt;br /&gt;
** DLG files, similar to NWN&lt;br /&gt;
** Some extensions, like camera setup&lt;br /&gt;
** Dialogues are displayed very different than NWN&lt;br /&gt;
** KotOR2 has script extensions&lt;br /&gt;
*** Passing parameters to scripts&lt;br /&gt;
*** Call several scripts, combine with AND/OR for branching&lt;br /&gt;
* Animations&lt;br /&gt;
** Mostly working now&lt;br /&gt;
* Minigames&lt;br /&gt;
** Swoop racing&lt;br /&gt;
** Pazaak&lt;br /&gt;
** Hardcoded, mostly removed from usual game logic&lt;br /&gt;
&lt;br /&gt;
=== Jade Empire ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Main menu with options submenu is there&lt;br /&gt;
* Minigames&lt;br /&gt;
** Flyer, top-down shoot-em-up thing&lt;br /&gt;
** Hardcoded, mostly removed from usual game logic&lt;br /&gt;
* Player character&lt;br /&gt;
** Needs research&lt;br /&gt;
* Sound&lt;br /&gt;
** Uses an ASCII variant of the [http://wiki.multimedia.cx/index.php?title=XACT XACT formats]&lt;br /&gt;
*** Cues probably not as complex as FMOD/Wwise&lt;br /&gt;
*** Effects need extension of the Sound system, maybe&lt;br /&gt;
** Xbox version might use the binary format?&lt;br /&gt;
*** Sound banks could be handles as archives and indexed in the ResourceManager?&lt;br /&gt;
** [https://github.com/flibitijibibo/FACT FACT] is an implementation of XAudio, including XACT, zlib-licensed&lt;br /&gt;
&lt;br /&gt;
=== NWN2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Implemented using XML&lt;br /&gt;
** See [[#Broken NWN2 XML|Broken NWN2 XML]]&lt;br /&gt;
* Animations (Granny)&lt;br /&gt;
** [https://github.com/SkywingvL/nwn2dev-public nwn2-dev] contains some code working with Granny data&lt;br /&gt;
*** Call into the original Granny DLL to convert between binary and ASCII Granny data, though&lt;br /&gt;
** [https://github.com/berenm/xoreos-tools/tree/granny berenm started some Granny RE]&lt;br /&gt;
* Facial animations (FaceFX)&lt;br /&gt;
* Trees (SpeedTree)&lt;br /&gt;
* Proper evaluation of creature model parts (equipped items)&lt;br /&gt;
* Player character&lt;br /&gt;
** Reading of PC files in creature&lt;br /&gt;
&lt;br /&gt;
=== Sonic Chronicles ===&lt;br /&gt;
* Allow using the contents from an extracted NDS file?&lt;br /&gt;
* Menus&lt;br /&gt;
** GUI files that are GFF&lt;br /&gt;
** Actions in a state machine in GDA files?&lt;br /&gt;
* Music/Sound&lt;br /&gt;
** Music is apparently similar to MIDI, or to a tracker format?&lt;br /&gt;
** Sounds and instruments for music are in a sound_data.sadl archive&lt;br /&gt;
* Animations&lt;br /&gt;
** Bone animations, best implemented with shaders, blocked by the graphics subsystem rewrite&lt;br /&gt;
* Player character(s)&lt;br /&gt;
** Needs research&lt;br /&gt;
&lt;br /&gt;
=== The Witcher ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Apparently build using Lua&lt;br /&gt;
** System/Scripts/ has gui*.luc files&lt;br /&gt;
* Animations&lt;br /&gt;
** Needs research&lt;br /&gt;
* Player character, Geralt&lt;br /&gt;
** Needs research&lt;br /&gt;
&lt;br /&gt;
=== Dragon Age: Origins / Dragon Age 2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Scaleform_GFx Scaleform GFx]&lt;br /&gt;
** [http://social.bioware.com/wiki/datoolset/index.php/UI_Tutorial_%28draft%29 UI Tutorial] on the Dragon Age toolset wiki&lt;br /&gt;
** Flash-based!&lt;br /&gt;
** A good starting point for a reimplementation might be [https://en.wikipedia.org/wiki/Gameswf Gameswf].&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Gnash Gnash], [https://en.wikipedia.org/wiki/Lightspark Lightspark], [https://en.wikipedia.org/wiki/Swfdec Swfdec]&lt;br /&gt;
** [http://www.nowrap.de/flasm.html Flasm] can disassemble/assemble ActionScript, [http://www.nowrap.de/flare.html Flare] can decompile it&lt;br /&gt;
** [https://wwwimages2.adobe.com/content/dam/acom/en/devnet/pdf/swf-file-format-spec.pdf swf-file-format-spec.pdf] is a great reference which covers mostly every aspect of the gfx files.&lt;br /&gt;
** [https://github.com/jindrapetrik/jpexs-decompiler jpexs-decompiler] can decompile and handles scaleform specific tags.&lt;br /&gt;
* Animations&lt;br /&gt;
** Bone animations, best implemented with shaders, blocked by the graphics subsystem rewrite&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=TODO&amp;diff=354</id>
		<title>TODO</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=TODO&amp;diff=354"/>
		<updated>2018-05-15T21:59:32Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* NWN */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a long rambly list of things left to do in xoreos and xoreos-tools. Anybody is welcome to tackle any of these tasks, but please also read our [[Developer_Central|general contributor overview]], including our [[Code_Formatting_Conventions|Code Formatting Conventions]], [[Commit_Guidelines|Commit Guidelines]] and [https://github.com/xoreos/xoreos/blob/master/CODE_OF_CONDUCT.md Code of Conduct]. If you plan to do any of these tasks, please also [[Contact_us|contact us]] beforehand, so we can better coordinate multiple people interested in doing the same task, and discuss how to best solve the problem. Thanks. :)&lt;br /&gt;
&lt;br /&gt;
(&#039;&#039;&#039;See also:&#039;&#039;&#039; the Kanban-like &amp;quot;Projects&amp;quot; boards on GitHub: https://github.com/orgs/xoreos/projects, but they&#039;re not public and no way to make public at the moment. Boo.)&lt;br /&gt;
&lt;br /&gt;
== Documentation ==&lt;br /&gt;
&lt;br /&gt;
=== Developer information ===&lt;br /&gt;
* Extend the developer information on the wiki&lt;br /&gt;
** Explain how to get the xoreos sources on various platforms&lt;br /&gt;
** Expand GNU/Linux compiling instructions to cover more distributions&lt;br /&gt;
** Expand Mac OS X compiling instructions&lt;br /&gt;
*** Xcode&lt;br /&gt;
*** Homebrew/MacPorts/Fink&lt;br /&gt;
*** CMake, Libraries&lt;br /&gt;
** [http://wiki.arx-libertatis.org/Developer_Information Arx Libertatis] has an extensive dev page&lt;br /&gt;
* Document file formats on the wiki?&lt;br /&gt;
** Or integrate info into XentaxWiki?&lt;br /&gt;
** Both?&lt;br /&gt;
&lt;br /&gt;
=== User information ===&lt;br /&gt;
* More user information on the wiki&lt;br /&gt;
** How to download xoreos&lt;br /&gt;
** How to install the games on various platforms&lt;br /&gt;
** [http://wiki.arx-libertatis.org/Main_Page Arx Libertatis] does that pretty well&lt;br /&gt;
&lt;br /&gt;
=== Modder information ===&lt;br /&gt;
* Link to relevant modding resources&lt;br /&gt;
* Maybe even some kind of Modder&#039;s Handbook&lt;br /&gt;
** A big overview of modding Aurora games in general&lt;br /&gt;
*** Differences and commonalities between games&lt;br /&gt;
** Linking/Grouping engine functions between games&lt;br /&gt;
&lt;br /&gt;
== Website ==&lt;br /&gt;
&lt;br /&gt;
=== Design ===&lt;br /&gt;
* Better website design?&lt;br /&gt;
** It still should be static in the end&lt;br /&gt;
*** No PHP or Rails&lt;br /&gt;
*** Very light on JavaScript&lt;br /&gt;
*** No Flash!&lt;br /&gt;
** Maybe a bit more unique, graphical&lt;br /&gt;
** For legal reasons, we shouldn&#039;t directly use art or designs from the original games&lt;br /&gt;
*** Something inspired by the art of the orginal games would fit&lt;br /&gt;
&lt;br /&gt;
=== Octopress ===&lt;br /&gt;
* Move away from Octopress?&lt;br /&gt;
** Alternative should still produce static HTML somehow&lt;br /&gt;
** Octopress works rather well. It reads Markdown, which is a plus&lt;br /&gt;
* Octopress 3.0?&lt;br /&gt;
** Not finished yet, it seems&lt;br /&gt;
&lt;br /&gt;
== Standalone(ish) fixes/improvements ==&lt;br /&gt;
&lt;br /&gt;
=== Broken NWN2 XML ===&lt;br /&gt;
* Not standards-conforming XML. Need custom XML parser; stock XML parsing libraries will just throw errors.&lt;br /&gt;
** &amp;lt;nowiki&amp;gt;&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;NWN2UI&amp;quot;&amp;gt;&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
** No single root element&lt;br /&gt;
** Attribute values not enclosed in quotes most of the time&lt;br /&gt;
** Special characters in attribute values not properly escaped&lt;br /&gt;
** Unmatched quotes on several occasions&lt;br /&gt;
* Event functions&lt;br /&gt;
* Special values like PARENT_WIDTH&lt;br /&gt;
* [https://github.com/xoreos/xoreos-tools/pull/1 Altrite is working on a broken-XML fixer]&lt;br /&gt;
&lt;br /&gt;
=== CJK glyphs in the console ===&lt;br /&gt;
* The &amp;quot;system font&amp;quot; we use for our debug console, DejaVu Sans Mono Bold, does not feature any CJK (Chinese, Japanese, Korean) glyphs&lt;br /&gt;
* Not strictly necessary, but nice to have for printing, say, Witcher area names in Asian languages&lt;br /&gt;
* We could maybe integrate CJK glyphs from the [http://fonts.jp/hanazono/ Hanazono fonts] or other suitable libre fonts&lt;br /&gt;
* We need to match the height with DejaVu Sans Mono Bold&lt;br /&gt;
* CJK glyphs tend to be more complex and therefore wider. They&#039;re usually rendered twice as wide as Latin glyphs&lt;br /&gt;
* Our console code needs to take that into account&lt;br /&gt;
&lt;br /&gt;
=== Fuzzing ===&lt;br /&gt;
* Run our file readers, image decoders, etc. through a fuzzer, like [http://lcamtuf.coredump.cx/afl/ afl] (american fuzzy lop)&lt;br /&gt;
* Fix any cases where it crashes&lt;br /&gt;
* The xoreos-tools might be a good starting point for singular, standalone testing&lt;br /&gt;
** For image decoders, a slightly modified xoreostex2tga tool might work&lt;br /&gt;
* File formats already fuzzed:&lt;br /&gt;
** CBGT, CDPTH, DDS, NBFS, NCGR, NCLR, SBM, TGA, TPC, TXB&lt;br /&gt;
** 2DA, KEY/BIF, ERF, GFF3, GFF4, GDA, TLK, NSBTX, RIM, SMALL, SSF&lt;br /&gt;
&lt;br /&gt;
=== Script decompiler ===&lt;br /&gt;
* It might be quite useful to have a NWScript decompiler in xoreos-tools&lt;br /&gt;
* We have a script disassembler, ncsdis&lt;br /&gt;
** Which already does code flow analysis&lt;br /&gt;
* Missing:&lt;br /&gt;
** Code generation&lt;br /&gt;
** Collapsing of instruction chains into single-line NWScript code&lt;br /&gt;
*** For example, &amp;quot;int var = foo * bar + quux&amp;quot; compiles to a long chain with multiple temporaries&lt;br /&gt;
** Proper handling of structs and vectors&lt;br /&gt;
&lt;br /&gt;
=== Script compiler ===&lt;br /&gt;
* An NWScript compiler might be useful as well&lt;br /&gt;
** A script assembler might be an easy first step&lt;br /&gt;
&lt;br /&gt;
=== File format writers ===&lt;br /&gt;
* GFF3Writer, GFF4Writer&lt;br /&gt;
** Both necessary to create save games compatible with the original games&lt;br /&gt;
** Also useful for a xml2gff tool&lt;br /&gt;
* xml2tlk&lt;br /&gt;
** TalkTable_GFF::write02() and ::write05()&lt;br /&gt;
** Needs GFF4Writer&lt;br /&gt;
* Archive (ERF, RIM, KEY/BIF) packers?&lt;br /&gt;
&lt;br /&gt;
=== Config file ===&lt;br /&gt;
* Should be more preserving of the layout&lt;br /&gt;
** Especially empty lines&lt;br /&gt;
** UTF-8 Byte-Order-Mark when using native Windows editors&lt;br /&gt;
** \r is currently always stripped. Maybe preserve that too&lt;br /&gt;
*** Autodetect when \r is already used, and add it to new config lines too&lt;br /&gt;
** This basically needs a complete rewrite of the config parser&lt;br /&gt;
*** Don&#039;t just look for comments, just throw everything after &amp;quot;foo=bar&amp;quot; into the &amp;quot;comment&amp;quot; variable, including whitespace&lt;br /&gt;
*** And all whitespace before &amp;quot;foo=bar&amp;quot; into a &amp;quot;prefix&amp;quot; variable&lt;br /&gt;
** Maybe even always add BOM and \r when writing a new config file on Windows?&lt;br /&gt;
&lt;br /&gt;
=== Windows-specific / Wine-specific ===&lt;br /&gt;
* When running my mingw32 cross-compiled xoreos EXE in Wine, the menu button texts are partially cut off&lt;br /&gt;
** Z-fighting issue?&lt;br /&gt;
** Does that also occur on a real Windows?&lt;br /&gt;
&lt;br /&gt;
=== GUI ===&lt;br /&gt;
* xoreos could use a global GUI to start games from&lt;br /&gt;
* Should probably be similar to ScummVM&#039;s GUI, at least in effect&lt;br /&gt;
* Should read the config file, list all targets&lt;br /&gt;
** Press a &amp;quot;Play&amp;quot; button to play the game&lt;br /&gt;
** Press an &amp;quot;Edit&amp;quot; button to edit the entry&lt;br /&gt;
*** Dialog options to edit common settings&lt;br /&gt;
*** An additional free-form editor?&lt;br /&gt;
*** Game-specific options?&lt;br /&gt;
** A button to edit global settings (&amp;quot;xoreos&amp;quot; config domain)&lt;br /&gt;
** For the future, a way to immediately load a saved game?&lt;br /&gt;
** An &amp;quot;Add&amp;quot; button to add a game&lt;br /&gt;
*** File browser&lt;br /&gt;
**** Select directories for most game&lt;br /&gt;
**** Select file for Sonic Chronicles&lt;br /&gt;
*** View current saved games of a target?&lt;br /&gt;
* Probably implemented using OpenGL, just like, say, the console&lt;br /&gt;
* Theme-able/Skinable?&lt;br /&gt;
* Some potential stumbling blocks&lt;br /&gt;
** Displaying &amp;quot;uncommon&amp;quot; text in both game descriptions and file paths&lt;br /&gt;
*** &amp;quot;Decomposed&amp;quot; letters, i.e. base letter + combining glyphs&lt;br /&gt;
*** CJK&lt;br /&gt;
*** Arabic and other scripts where letters change depending on their place in the word&lt;br /&gt;
*** Right-to-left&lt;br /&gt;
** Shortening those strings when they don&#039;t fit in their fields is also potentially difficult&lt;br /&gt;
&lt;br /&gt;
=== Localization ===&lt;br /&gt;
* Text in exceptions?&lt;br /&gt;
** At least the user-visible ones, like &amp;quot;Failed to detect game&amp;quot;&lt;br /&gt;
** Or maybe we should clean that up and split them into &amp;quot;program logic failure&amp;quot; and &amp;quot;user failure&amp;quot;, with only the latter translated&lt;br /&gt;
* Strings for the engine loader progress bar&lt;br /&gt;
* Debug console string&lt;br /&gt;
* GUI (see above) strings&lt;br /&gt;
* [http://www.gnu.org/software/gettext/ GNU gettext] would be one solution&lt;br /&gt;
&lt;br /&gt;
=== Unit tests ===&lt;br /&gt;
* More unit tests&lt;br /&gt;
&lt;br /&gt;
=== Resource Explorer ===&lt;br /&gt;
* A portable, user-friendly graphical resource explorer could be useful&lt;br /&gt;
* [https://github.com/xoreos/phaethon Phaethon] is a start&lt;br /&gt;
** It can look into game archives, show textures and play sounds&lt;br /&gt;
** It uses [https://www.wxwidgets.org/ wxWidgets] to do the GUI&lt;br /&gt;
** Or possibly rewriting it to use [https://www.qt.io/ Qt] is better?&lt;br /&gt;
&lt;br /&gt;
=== Model converters ===&lt;br /&gt;
* Document the model formats&lt;br /&gt;
* Convert between the binary model formats and their ASCII equivalents&lt;br /&gt;
* Convert between the binary model formats and ones that can be opened by modelling tools&lt;br /&gt;
** 3D Studio Max&lt;br /&gt;
** Blender&lt;br /&gt;
&lt;br /&gt;
=== Full-fledged modding toolset ===&lt;br /&gt;
* Similar to the NWN, NWN2 or Witcher toolset, but portable and FLOSS&lt;br /&gt;
** Might also support other games?&lt;br /&gt;
* Out of scope for xoreos&lt;br /&gt;
** Still, such a thing would be welcome under the xoreos banner&lt;br /&gt;
* [http://sourceforge.net/projects/neveredit/ Neveredit] might still be worth a look&lt;br /&gt;
&lt;br /&gt;
== Build system ==&lt;br /&gt;
&lt;br /&gt;
=== CMake ===&lt;br /&gt;
* Current doesn&#039;t set the git version to &amp;quot;+unk&amp;quot; when git isn&#039;t found&lt;br /&gt;
* make install/uninstall?&lt;br /&gt;
* make doxygen?&lt;br /&gt;
&lt;br /&gt;
=== Autotools ===&lt;br /&gt;
* Suppress the &amp;quot;fatal: not a git repository&amp;quot; when building gitstamp without a git directory&lt;br /&gt;
* Increased modularity&lt;br /&gt;
** Disabling engines&lt;br /&gt;
** Making library dependencies optional (and disabling certain features, then)&lt;br /&gt;
*** liblzma? Only needed for the iOS version of KotOR&lt;br /&gt;
*** libxml2? Only needed for the two Dragon Age games&lt;br /&gt;
** When something is disabled, skip it, if possible&lt;br /&gt;
*** Like the videos in KotOR Mac&lt;br /&gt;
** If skipping is not possible, error out&lt;br /&gt;
&lt;br /&gt;
== Nitro ==&lt;br /&gt;
&lt;br /&gt;
* The Nintendo DS (Nitro) specific file formats should probably be moved out of src/aurora/ and into src/nitro&lt;br /&gt;
* nitrofile, cdpth, nsbtx, smallfile&lt;br /&gt;
** nsbtx needs to be split into a class accessing the textures in src/nitro/ and an archive class on top in src/aurora/&lt;br /&gt;
** This means src/aurora/ accesses src/nitro/, so libnitro.la needs to come after libaurora.la in the linking order&lt;br /&gt;
* ndsrom as well?&lt;br /&gt;
* What about nftrfont and model_sonic in src/graphics/aurora/?&lt;br /&gt;
** src/graphics/nitro/?&lt;br /&gt;
** This would have src/graphics/nitro/ access src/graphics/aurora/, so graphics/libnitro.la needs to come before graphics/libaurora.la in the linking order&lt;br /&gt;
** That would be the other way round than for src/nitro/. Too confusing?&lt;br /&gt;
&lt;br /&gt;
== Graphics ==&lt;br /&gt;
&lt;br /&gt;
=== MDL supermodels and animations ===&lt;br /&gt;
* Mostly working in NWN thanks to jbowtie&#039;s work&lt;br /&gt;
* Might need some cleanup&lt;br /&gt;
* Models should smoothly change between different animations&lt;br /&gt;
* The animation system probably needs to be a bit more complex, to allow for &amp;quot;overlaying&amp;quot; different animations onto each other. For example, for speaking while holding an object and keeping the head focused on the PC character.&lt;br /&gt;
&lt;br /&gt;
=== Lighting ===&lt;br /&gt;
* We don&#039;t yet have a proper light system&lt;br /&gt;
* I started working on it: [https://drmccoy.de/xoreos/20150809T223407.png], but my approach is seriously lacking. You can see the edges of the tiles that make up on NWN area in many cases ([https://drmccoy.de/xoreos/20150809T223507.png], [https://drmccoy.de/xoreos/20150809T223548.png])&lt;br /&gt;
** See the [https://github.com/xoreos/xoreos/tree/light light branch] in the git repository&lt;br /&gt;
** Of course, the actual glLight* stuff won&#039;t be relevant anymore as soon as shaders are there&lt;br /&gt;
** Lighting in several (ASCII?) area tiles is broken&lt;br /&gt;
*** The door in Prelude.nwm&#039;s &amp;quot;m0q1a&amp;quot; area&lt;br /&gt;
*** A water tile in Chapter2.nwm&#039;s &amp;quot;map_m2q1a&amp;quot; area&lt;br /&gt;
*** A sloped snow tile in XP2_Chapter3.nwm&#039;s &amp;quot;thecityoflostsou&amp;quot;&lt;br /&gt;
&lt;br /&gt;
=== Materials ===&lt;br /&gt;
* Materials in The Witcher are closely tied to shaders&lt;br /&gt;
&lt;br /&gt;
=== OpenGL and Shaders ===&lt;br /&gt;
* mirv_ is currently working on a graphics system overhaul, complete with shader support&lt;br /&gt;
* All Aurora games use shaders in some form&lt;br /&gt;
* NWN uses ARB shaders. We probably need to rewrite them from scratch&lt;br /&gt;
* DirectX shaders might be automatically convertible with Cg?&lt;br /&gt;
* Otherwise, look at what Wine does with the shaders, and use that as a basis?&lt;br /&gt;
* All the games, even NWN, use some form of shaders. Still totally missing from xoreos, since we have no idea how to use them in general yet. Moreover, this was before GLSL, so they&#039;re in the old assembly-like language. We probably need to rewrite them from scratch&lt;br /&gt;
* We need shaders for tinting in NWN2 (objects and area geometry) and TexturePaint nodes in Witcher&lt;br /&gt;
&lt;br /&gt;
=== SDL 1.2 ===&lt;br /&gt;
* Optionally link against SDL 1.2 instead of SDL 2&lt;br /&gt;
* Should ideally use a configure flag to select between the two&lt;br /&gt;
** Maybe a CMake flag as well, if possible&lt;br /&gt;
* Assigned to clone2727, so anybody interested in this should coordinate with him&lt;br /&gt;
&lt;br /&gt;
== Videos ==&lt;br /&gt;
&lt;br /&gt;
=== XMV/WMV ===&lt;br /&gt;
* Used in Xbox versions of KotOR/KotOR2&lt;br /&gt;
* Our WMV decoder (for XMV videos used in Xbox versions) is missing P-frames and J-frame&lt;br /&gt;
** Code exists in ffmpeg, but is connected to the MPEG-4 family mess&lt;br /&gt;
&lt;br /&gt;
=== Actimagine VX ===&lt;br /&gt;
* Used in the Nintendo DS game Sonic Chronicles&lt;br /&gt;
* https://wiki.multimedia.cx/index.php?title=Actimagine_Video_Codec&lt;br /&gt;
&lt;br /&gt;
=== Sorenson 3 ===&lt;br /&gt;
* One single video in the Mac port of KotOR2, the Aspyr logo, uses the Sorenson 3 codec&lt;br /&gt;
** ffmpeg has a decoder, but it&#039;s connected to the MPEG-4 family mess (SVQ3 is similar to H.264)&lt;br /&gt;
* ScummVM needs that too&lt;br /&gt;
** While xoreos is GPLv3+, ScummVM is GPLv2+&lt;br /&gt;
** Somebody implementing Sorenson 3 for xoreos should ideally give explicit permission to relicense it GPLv2+ for ScummVM&lt;br /&gt;
*** Of course, if the decoder is based on prior work by other people, it has to be compatible with both GPLv2+ and GPLv3+&lt;br /&gt;
&lt;br /&gt;
=== Optimizations ===&lt;br /&gt;
* Optimize our simple BitStream interface&lt;br /&gt;
** See [https://fgiesen.wordpress.com/2016/01/02/end-of-buffer-checks-in-decompressors/ this blog post]&lt;br /&gt;
** Specifically, we don&#039;t do any peeking at all&lt;br /&gt;
** It still needs to handle different memory layouts, though&lt;br /&gt;
* Likewise, our Huffman class could probably be tuned a lot&lt;br /&gt;
* Pull in fft/rdft/dct/mdct optimizations from FFmpeg?&lt;br /&gt;
* I experimented with that in a private branch and it didn&#039;t do anything for Bink performance&lt;br /&gt;
&lt;br /&gt;
== Sound ==&lt;br /&gt;
&lt;br /&gt;
=== FMOD ===&lt;br /&gt;
* Dragon Age: Origins uses FMOD for sound and music&lt;br /&gt;
* I have experimental FSB (FMOD sound bank) support working in a private branch&lt;br /&gt;
* FEV (FMOD events) format is still unknown to us&lt;br /&gt;
** Apparently, groups of event lists with events&lt;br /&gt;
** Event is everything from &amp;quot;play sound&amp;quot;, over &amp;quot;set volume&amp;quot; to &amp;quot;apply echo&amp;quot;&lt;br /&gt;
** Game areas specify the group to use for the area&lt;br /&gt;
** Scripts then probably tell FMOD to play event lists out of that group&lt;br /&gt;
&lt;br /&gt;
=== Wwise ===&lt;br /&gt;
* Dragon Age 2 uses Wwise for sound and music&lt;br /&gt;
* Should be similar in concept to FMD&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
=== Gamepad binding ===&lt;br /&gt;
* The Xbox versions of KotOR and KotOR2 don&#039;t use a mouse. We have basic support for joysticks/gamepads, but no real bindings to the engine or ideas how to handle that in general&lt;br /&gt;
* We might want to handle the controller support the new KotOR2 Steam update brought&lt;br /&gt;
** override folder contains a gamepad.txt then&lt;br /&gt;
* Also hack in controller support for a non-Steam KotOR2? And for KotOR?&lt;br /&gt;
* Controller support in Jade Empire&lt;br /&gt;
* Controller support for Sonic? It is a Nintendo DS game after all&lt;br /&gt;
* Controller support for the non-console versions of the Dragon Age games?&lt;br /&gt;
&lt;br /&gt;
== Network ==&lt;br /&gt;
* We need a network subsystem&lt;br /&gt;
** [https://www.libsdl.org/projects/SDL_net/ SDL_net]?&lt;br /&gt;
** [http://www.boost.org/doc/libs/release/libs/asio/ Boost.Asio]?&lt;br /&gt;
** More options here: http://stackoverflow.com/questions/118945/best-c-c-network-library&lt;br /&gt;
* Engines need to be split into client and server classes&lt;br /&gt;
** The original engines all still do that, even when not exposing anything to users&lt;br /&gt;
** NWN and NWN2 allow user multiplayer&lt;br /&gt;
&lt;br /&gt;
== Engines ==&lt;br /&gt;
&lt;br /&gt;
=== Script system ===&lt;br /&gt;
* ImperatorPrime had started on a script system rewrite&lt;br /&gt;
** Includes functions with real signatures&lt;br /&gt;
** Maybe switch to that, if it works&lt;br /&gt;
* Rounds, object heartbeat scripts&lt;br /&gt;
* KotOR2 and NWN2 have some extensions&lt;br /&gt;
** It seems like they don&#039;t need any extensions to the low-level bytecode stuff&lt;br /&gt;
* Witcher uses Lua scripts together with NWScript&lt;br /&gt;
* Sonic has no scripts at all, it seems&lt;br /&gt;
* Currently a script in an infinite loop locks the game thread&lt;br /&gt;
** Timeout? Asynchronous script execution?&lt;br /&gt;
&lt;br /&gt;
=== NWN ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Basics are there, but needs fleshing out&lt;br /&gt;
** Character generator is mostly working&lt;br /&gt;
* [[Pathfinding]], walkmesh&lt;br /&gt;
** &amp;quot;Moving&amp;quot; should move the PC, not the camera&lt;br /&gt;
** NPC walking&lt;br /&gt;
** Triggers, areas on the floor that calls scripts on enter/leave&lt;br /&gt;
* Models&lt;br /&gt;
** ASCII models need averaging of smooth group normals&lt;br /&gt;
* NWN objects need an inventory concept&lt;br /&gt;
** Player characters&#039; might be different&lt;br /&gt;
*** Inventory tetris&lt;br /&gt;
*** Inventory item icons&lt;br /&gt;
* Multi-page asian fonts&lt;br /&gt;
* LanguageID 0 is not necessarily &amp;quot;English&amp;quot;, but &amp;quot;The language of the game install&amp;quot;&lt;br /&gt;
** This is okay for languages with Latin characters&lt;br /&gt;
** Messes up strings in community modules with Asian languages that stuff strings in to languageID 0&lt;br /&gt;
** The original fails there too, though&lt;br /&gt;
&lt;br /&gt;
=== KotOR/KotOR2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Many are already there&lt;br /&gt;
* Dialogues&lt;br /&gt;
** DLG files, similar to NWN&lt;br /&gt;
** Some extensions, like camera setup&lt;br /&gt;
** Dialogues are displayed very different than NWN&lt;br /&gt;
** KotOR2 has script extensions&lt;br /&gt;
*** Passing parameters to scripts&lt;br /&gt;
*** Call several scripts, combine with AND/OR for branching&lt;br /&gt;
* Animations&lt;br /&gt;
** Mostly working now&lt;br /&gt;
* Minigames&lt;br /&gt;
** Swoop racing&lt;br /&gt;
** Pazaak&lt;br /&gt;
** Hardcoded, mostly removed from usual game logic&lt;br /&gt;
&lt;br /&gt;
=== Jade Empire ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Apparently very similar to KotOR&#039;s menus&lt;br /&gt;
* Minigames&lt;br /&gt;
** Flyer, top-down shoot-em-up thing&lt;br /&gt;
** Hardcoded, mostly removed from usual game logic&lt;br /&gt;
* Player character&lt;br /&gt;
** Needs research&lt;br /&gt;
* Sound&lt;br /&gt;
** Uses an ASCII variant of the [http://wiki.multimedia.cx/index.php?title=XACT XACT formats]&lt;br /&gt;
*** Cues probably not as complex as FMOD/Wwise&lt;br /&gt;
*** Effects need extension of the Sound system, maybe&lt;br /&gt;
** Xbox version might use the binary format?&lt;br /&gt;
*** Sound banks could be handles as archives and indexed in the ResourceManager?&lt;br /&gt;
** [https://github.com/FNA-XNA/FNA/tree/master/src/Audio FNA] has an implementation of XACT. Probably quite useful to look at that&lt;br /&gt;
&lt;br /&gt;
=== NWN2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Implemented using XML&lt;br /&gt;
** See [[#Broken NWN2 XML|Broken NWN2 XML]]&lt;br /&gt;
* Animations (Granny)&lt;br /&gt;
** [https://github.com/SkywingvL/nwn2dev-public nwn2-dev] contains some code working with Granny data&lt;br /&gt;
*** Call into the original Granny DLL to convert between binary and ASCII Granny data, though&lt;br /&gt;
** [https://github.com/berenm/xoreos-tools/tree/granny berenm started some Granny RE]&lt;br /&gt;
* Facial animations (FaceFX)&lt;br /&gt;
* Trees (SpeedTree)&lt;br /&gt;
* Proper evaluation of creature model parts (equipped items)&lt;br /&gt;
* Player character&lt;br /&gt;
** Reading of PC files in creature&lt;br /&gt;
&lt;br /&gt;
=== Sonic Chronicles ===&lt;br /&gt;
* Allow using the contents from an extracted NDS file?&lt;br /&gt;
* Menus&lt;br /&gt;
** GUI files that are GFF&lt;br /&gt;
** Actions in a state machine in GDA files?&lt;br /&gt;
* Music/Sound&lt;br /&gt;
** Music is apparently similar to MIDI, or to a tracker format?&lt;br /&gt;
** Sounds and instruments for music are in a sound_data.sadl archive&lt;br /&gt;
* Animations&lt;br /&gt;
** Bone animations, best implemented with shaders, blocked by the graphics subsystem rewrite&lt;br /&gt;
* Player character(s)&lt;br /&gt;
** Needs research&lt;br /&gt;
&lt;br /&gt;
=== The Witcher ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Apparently build using Lua&lt;br /&gt;
** System/Scripts/ has gui*.luc files&lt;br /&gt;
* Animations&lt;br /&gt;
** Needs research&lt;br /&gt;
* Player character, Geralt&lt;br /&gt;
** Needs research&lt;br /&gt;
&lt;br /&gt;
=== Dragon Age: Origins / Dragon Age 2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Scaleform_GFx Scaleform GFx]&lt;br /&gt;
** [http://social.bioware.com/wiki/datoolset/index.php/UI_Tutorial_%28draft%29 UI Tutorial] on the Dragon Age toolset wiki&lt;br /&gt;
** Flash-based!&lt;br /&gt;
** A good starting point for a reimplementation might be [https://en.wikipedia.org/wiki/Gameswf Gameswf].&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Gnash Gnash], [https://en.wikipedia.org/wiki/Lightspark Lightspark], [https://en.wikipedia.org/wiki/Swfdec Swfdec]&lt;br /&gt;
** [http://www.nowrap.de/flasm.html Flasm] can disassemble/assemble ActionScript, [http://www.nowrap.de/flare.html Flare] can decompile it&lt;br /&gt;
** [https://wwwimages2.adobe.com/content/dam/acom/en/devnet/pdf/swf-file-format-spec.pdf swf-file-format-spec.pdf] is a great reference which covers mostly every aspect of the gfx files.&lt;br /&gt;
** [https://github.com/jindrapetrik/jpexs-decompiler jpexs-decompiler] can decompile and handles scaleform specific tags.&lt;br /&gt;
* Animations&lt;br /&gt;
** Bone animations, best implemented with shaders, blocked by the graphics subsystem rewrite&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=TODO&amp;diff=353</id>
		<title>TODO</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=TODO&amp;diff=353"/>
		<updated>2018-05-15T21:59:10Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* KotOR/KotOR2 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a long rambly list of things left to do in xoreos and xoreos-tools. Anybody is welcome to tackle any of these tasks, but please also read our [[Developer_Central|general contributor overview]], including our [[Code_Formatting_Conventions|Code Formatting Conventions]], [[Commit_Guidelines|Commit Guidelines]] and [https://github.com/xoreos/xoreos/blob/master/CODE_OF_CONDUCT.md Code of Conduct]. If you plan to do any of these tasks, please also [[Contact_us|contact us]] beforehand, so we can better coordinate multiple people interested in doing the same task, and discuss how to best solve the problem. Thanks. :)&lt;br /&gt;
&lt;br /&gt;
(&#039;&#039;&#039;See also:&#039;&#039;&#039; the Kanban-like &amp;quot;Projects&amp;quot; boards on GitHub: https://github.com/orgs/xoreos/projects, but they&#039;re not public and no way to make public at the moment. Boo.)&lt;br /&gt;
&lt;br /&gt;
== Documentation ==&lt;br /&gt;
&lt;br /&gt;
=== Developer information ===&lt;br /&gt;
* Extend the developer information on the wiki&lt;br /&gt;
** Explain how to get the xoreos sources on various platforms&lt;br /&gt;
** Expand GNU/Linux compiling instructions to cover more distributions&lt;br /&gt;
** Expand Mac OS X compiling instructions&lt;br /&gt;
*** Xcode&lt;br /&gt;
*** Homebrew/MacPorts/Fink&lt;br /&gt;
*** CMake, Libraries&lt;br /&gt;
** [http://wiki.arx-libertatis.org/Developer_Information Arx Libertatis] has an extensive dev page&lt;br /&gt;
* Document file formats on the wiki?&lt;br /&gt;
** Or integrate info into XentaxWiki?&lt;br /&gt;
** Both?&lt;br /&gt;
&lt;br /&gt;
=== User information ===&lt;br /&gt;
* More user information on the wiki&lt;br /&gt;
** How to download xoreos&lt;br /&gt;
** How to install the games on various platforms&lt;br /&gt;
** [http://wiki.arx-libertatis.org/Main_Page Arx Libertatis] does that pretty well&lt;br /&gt;
&lt;br /&gt;
=== Modder information ===&lt;br /&gt;
* Link to relevant modding resources&lt;br /&gt;
* Maybe even some kind of Modder&#039;s Handbook&lt;br /&gt;
** A big overview of modding Aurora games in general&lt;br /&gt;
*** Differences and commonalities between games&lt;br /&gt;
** Linking/Grouping engine functions between games&lt;br /&gt;
&lt;br /&gt;
== Website ==&lt;br /&gt;
&lt;br /&gt;
=== Design ===&lt;br /&gt;
* Better website design?&lt;br /&gt;
** It still should be static in the end&lt;br /&gt;
*** No PHP or Rails&lt;br /&gt;
*** Very light on JavaScript&lt;br /&gt;
*** No Flash!&lt;br /&gt;
** Maybe a bit more unique, graphical&lt;br /&gt;
** For legal reasons, we shouldn&#039;t directly use art or designs from the original games&lt;br /&gt;
*** Something inspired by the art of the orginal games would fit&lt;br /&gt;
&lt;br /&gt;
=== Octopress ===&lt;br /&gt;
* Move away from Octopress?&lt;br /&gt;
** Alternative should still produce static HTML somehow&lt;br /&gt;
** Octopress works rather well. It reads Markdown, which is a plus&lt;br /&gt;
* Octopress 3.0?&lt;br /&gt;
** Not finished yet, it seems&lt;br /&gt;
&lt;br /&gt;
== Standalone(ish) fixes/improvements ==&lt;br /&gt;
&lt;br /&gt;
=== Broken NWN2 XML ===&lt;br /&gt;
* Not standards-conforming XML. Need custom XML parser; stock XML parsing libraries will just throw errors.&lt;br /&gt;
** &amp;lt;nowiki&amp;gt;&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;NWN2UI&amp;quot;&amp;gt;&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
** No single root element&lt;br /&gt;
** Attribute values not enclosed in quotes most of the time&lt;br /&gt;
** Special characters in attribute values not properly escaped&lt;br /&gt;
** Unmatched quotes on several occasions&lt;br /&gt;
* Event functions&lt;br /&gt;
* Special values like PARENT_WIDTH&lt;br /&gt;
* [https://github.com/xoreos/xoreos-tools/pull/1 Altrite is working on a broken-XML fixer]&lt;br /&gt;
&lt;br /&gt;
=== CJK glyphs in the console ===&lt;br /&gt;
* The &amp;quot;system font&amp;quot; we use for our debug console, DejaVu Sans Mono Bold, does not feature any CJK (Chinese, Japanese, Korean) glyphs&lt;br /&gt;
* Not strictly necessary, but nice to have for printing, say, Witcher area names in Asian languages&lt;br /&gt;
* We could maybe integrate CJK glyphs from the [http://fonts.jp/hanazono/ Hanazono fonts] or other suitable libre fonts&lt;br /&gt;
* We need to match the height with DejaVu Sans Mono Bold&lt;br /&gt;
* CJK glyphs tend to be more complex and therefore wider. They&#039;re usually rendered twice as wide as Latin glyphs&lt;br /&gt;
* Our console code needs to take that into account&lt;br /&gt;
&lt;br /&gt;
=== Fuzzing ===&lt;br /&gt;
* Run our file readers, image decoders, etc. through a fuzzer, like [http://lcamtuf.coredump.cx/afl/ afl] (american fuzzy lop)&lt;br /&gt;
* Fix any cases where it crashes&lt;br /&gt;
* The xoreos-tools might be a good starting point for singular, standalone testing&lt;br /&gt;
** For image decoders, a slightly modified xoreostex2tga tool might work&lt;br /&gt;
* File formats already fuzzed:&lt;br /&gt;
** CBGT, CDPTH, DDS, NBFS, NCGR, NCLR, SBM, TGA, TPC, TXB&lt;br /&gt;
** 2DA, KEY/BIF, ERF, GFF3, GFF4, GDA, TLK, NSBTX, RIM, SMALL, SSF&lt;br /&gt;
&lt;br /&gt;
=== Script decompiler ===&lt;br /&gt;
* It might be quite useful to have a NWScript decompiler in xoreos-tools&lt;br /&gt;
* We have a script disassembler, ncsdis&lt;br /&gt;
** Which already does code flow analysis&lt;br /&gt;
* Missing:&lt;br /&gt;
** Code generation&lt;br /&gt;
** Collapsing of instruction chains into single-line NWScript code&lt;br /&gt;
*** For example, &amp;quot;int var = foo * bar + quux&amp;quot; compiles to a long chain with multiple temporaries&lt;br /&gt;
** Proper handling of structs and vectors&lt;br /&gt;
&lt;br /&gt;
=== Script compiler ===&lt;br /&gt;
* An NWScript compiler might be useful as well&lt;br /&gt;
** A script assembler might be an easy first step&lt;br /&gt;
&lt;br /&gt;
=== File format writers ===&lt;br /&gt;
* GFF3Writer, GFF4Writer&lt;br /&gt;
** Both necessary to create save games compatible with the original games&lt;br /&gt;
** Also useful for a xml2gff tool&lt;br /&gt;
* xml2tlk&lt;br /&gt;
** TalkTable_GFF::write02() and ::write05()&lt;br /&gt;
** Needs GFF4Writer&lt;br /&gt;
* Archive (ERF, RIM, KEY/BIF) packers?&lt;br /&gt;
&lt;br /&gt;
=== Config file ===&lt;br /&gt;
* Should be more preserving of the layout&lt;br /&gt;
** Especially empty lines&lt;br /&gt;
** UTF-8 Byte-Order-Mark when using native Windows editors&lt;br /&gt;
** \r is currently always stripped. Maybe preserve that too&lt;br /&gt;
*** Autodetect when \r is already used, and add it to new config lines too&lt;br /&gt;
** This basically needs a complete rewrite of the config parser&lt;br /&gt;
*** Don&#039;t just look for comments, just throw everything after &amp;quot;foo=bar&amp;quot; into the &amp;quot;comment&amp;quot; variable, including whitespace&lt;br /&gt;
*** And all whitespace before &amp;quot;foo=bar&amp;quot; into a &amp;quot;prefix&amp;quot; variable&lt;br /&gt;
** Maybe even always add BOM and \r when writing a new config file on Windows?&lt;br /&gt;
&lt;br /&gt;
=== Windows-specific / Wine-specific ===&lt;br /&gt;
* When running my mingw32 cross-compiled xoreos EXE in Wine, the menu button texts are partially cut off&lt;br /&gt;
** Z-fighting issue?&lt;br /&gt;
** Does that also occur on a real Windows?&lt;br /&gt;
&lt;br /&gt;
=== GUI ===&lt;br /&gt;
* xoreos could use a global GUI to start games from&lt;br /&gt;
* Should probably be similar to ScummVM&#039;s GUI, at least in effect&lt;br /&gt;
* Should read the config file, list all targets&lt;br /&gt;
** Press a &amp;quot;Play&amp;quot; button to play the game&lt;br /&gt;
** Press an &amp;quot;Edit&amp;quot; button to edit the entry&lt;br /&gt;
*** Dialog options to edit common settings&lt;br /&gt;
*** An additional free-form editor?&lt;br /&gt;
*** Game-specific options?&lt;br /&gt;
** A button to edit global settings (&amp;quot;xoreos&amp;quot; config domain)&lt;br /&gt;
** For the future, a way to immediately load a saved game?&lt;br /&gt;
** An &amp;quot;Add&amp;quot; button to add a game&lt;br /&gt;
*** File browser&lt;br /&gt;
**** Select directories for most game&lt;br /&gt;
**** Select file for Sonic Chronicles&lt;br /&gt;
*** View current saved games of a target?&lt;br /&gt;
* Probably implemented using OpenGL, just like, say, the console&lt;br /&gt;
* Theme-able/Skinable?&lt;br /&gt;
* Some potential stumbling blocks&lt;br /&gt;
** Displaying &amp;quot;uncommon&amp;quot; text in both game descriptions and file paths&lt;br /&gt;
*** &amp;quot;Decomposed&amp;quot; letters, i.e. base letter + combining glyphs&lt;br /&gt;
*** CJK&lt;br /&gt;
*** Arabic and other scripts where letters change depending on their place in the word&lt;br /&gt;
*** Right-to-left&lt;br /&gt;
** Shortening those strings when they don&#039;t fit in their fields is also potentially difficult&lt;br /&gt;
&lt;br /&gt;
=== Localization ===&lt;br /&gt;
* Text in exceptions?&lt;br /&gt;
** At least the user-visible ones, like &amp;quot;Failed to detect game&amp;quot;&lt;br /&gt;
** Or maybe we should clean that up and split them into &amp;quot;program logic failure&amp;quot; and &amp;quot;user failure&amp;quot;, with only the latter translated&lt;br /&gt;
* Strings for the engine loader progress bar&lt;br /&gt;
* Debug console string&lt;br /&gt;
* GUI (see above) strings&lt;br /&gt;
* [http://www.gnu.org/software/gettext/ GNU gettext] would be one solution&lt;br /&gt;
&lt;br /&gt;
=== Unit tests ===&lt;br /&gt;
* More unit tests&lt;br /&gt;
&lt;br /&gt;
=== Resource Explorer ===&lt;br /&gt;
* A portable, user-friendly graphical resource explorer could be useful&lt;br /&gt;
* [https://github.com/xoreos/phaethon Phaethon] is a start&lt;br /&gt;
** It can look into game archives, show textures and play sounds&lt;br /&gt;
** It uses [https://www.wxwidgets.org/ wxWidgets] to do the GUI&lt;br /&gt;
** Or possibly rewriting it to use [https://www.qt.io/ Qt] is better?&lt;br /&gt;
&lt;br /&gt;
=== Model converters ===&lt;br /&gt;
* Document the model formats&lt;br /&gt;
* Convert between the binary model formats and their ASCII equivalents&lt;br /&gt;
* Convert between the binary model formats and ones that can be opened by modelling tools&lt;br /&gt;
** 3D Studio Max&lt;br /&gt;
** Blender&lt;br /&gt;
&lt;br /&gt;
=== Full-fledged modding toolset ===&lt;br /&gt;
* Similar to the NWN, NWN2 or Witcher toolset, but portable and FLOSS&lt;br /&gt;
** Might also support other games?&lt;br /&gt;
* Out of scope for xoreos&lt;br /&gt;
** Still, such a thing would be welcome under the xoreos banner&lt;br /&gt;
* [http://sourceforge.net/projects/neveredit/ Neveredit] might still be worth a look&lt;br /&gt;
&lt;br /&gt;
== Build system ==&lt;br /&gt;
&lt;br /&gt;
=== CMake ===&lt;br /&gt;
* Current doesn&#039;t set the git version to &amp;quot;+unk&amp;quot; when git isn&#039;t found&lt;br /&gt;
* make install/uninstall?&lt;br /&gt;
* make doxygen?&lt;br /&gt;
&lt;br /&gt;
=== Autotools ===&lt;br /&gt;
* Suppress the &amp;quot;fatal: not a git repository&amp;quot; when building gitstamp without a git directory&lt;br /&gt;
* Increased modularity&lt;br /&gt;
** Disabling engines&lt;br /&gt;
** Making library dependencies optional (and disabling certain features, then)&lt;br /&gt;
*** liblzma? Only needed for the iOS version of KotOR&lt;br /&gt;
*** libxml2? Only needed for the two Dragon Age games&lt;br /&gt;
** When something is disabled, skip it, if possible&lt;br /&gt;
*** Like the videos in KotOR Mac&lt;br /&gt;
** If skipping is not possible, error out&lt;br /&gt;
&lt;br /&gt;
== Nitro ==&lt;br /&gt;
&lt;br /&gt;
* The Nintendo DS (Nitro) specific file formats should probably be moved out of src/aurora/ and into src/nitro&lt;br /&gt;
* nitrofile, cdpth, nsbtx, smallfile&lt;br /&gt;
** nsbtx needs to be split into a class accessing the textures in src/nitro/ and an archive class on top in src/aurora/&lt;br /&gt;
** This means src/aurora/ accesses src/nitro/, so libnitro.la needs to come after libaurora.la in the linking order&lt;br /&gt;
* ndsrom as well?&lt;br /&gt;
* What about nftrfont and model_sonic in src/graphics/aurora/?&lt;br /&gt;
** src/graphics/nitro/?&lt;br /&gt;
** This would have src/graphics/nitro/ access src/graphics/aurora/, so graphics/libnitro.la needs to come before graphics/libaurora.la in the linking order&lt;br /&gt;
** That would be the other way round than for src/nitro/. Too confusing?&lt;br /&gt;
&lt;br /&gt;
== Graphics ==&lt;br /&gt;
&lt;br /&gt;
=== MDL supermodels and animations ===&lt;br /&gt;
* Mostly working in NWN thanks to jbowtie&#039;s work&lt;br /&gt;
* Might need some cleanup&lt;br /&gt;
* Models should smoothly change between different animations&lt;br /&gt;
* The animation system probably needs to be a bit more complex, to allow for &amp;quot;overlaying&amp;quot; different animations onto each other. For example, for speaking while holding an object and keeping the head focused on the PC character.&lt;br /&gt;
&lt;br /&gt;
=== Lighting ===&lt;br /&gt;
* We don&#039;t yet have a proper light system&lt;br /&gt;
* I started working on it: [https://drmccoy.de/xoreos/20150809T223407.png], but my approach is seriously lacking. You can see the edges of the tiles that make up on NWN area in many cases ([https://drmccoy.de/xoreos/20150809T223507.png], [https://drmccoy.de/xoreos/20150809T223548.png])&lt;br /&gt;
** See the [https://github.com/xoreos/xoreos/tree/light light branch] in the git repository&lt;br /&gt;
** Of course, the actual glLight* stuff won&#039;t be relevant anymore as soon as shaders are there&lt;br /&gt;
** Lighting in several (ASCII?) area tiles is broken&lt;br /&gt;
*** The door in Prelude.nwm&#039;s &amp;quot;m0q1a&amp;quot; area&lt;br /&gt;
*** A water tile in Chapter2.nwm&#039;s &amp;quot;map_m2q1a&amp;quot; area&lt;br /&gt;
*** A sloped snow tile in XP2_Chapter3.nwm&#039;s &amp;quot;thecityoflostsou&amp;quot;&lt;br /&gt;
&lt;br /&gt;
=== Materials ===&lt;br /&gt;
* Materials in The Witcher are closely tied to shaders&lt;br /&gt;
&lt;br /&gt;
=== OpenGL and Shaders ===&lt;br /&gt;
* mirv_ is currently working on a graphics system overhaul, complete with shader support&lt;br /&gt;
* All Aurora games use shaders in some form&lt;br /&gt;
* NWN uses ARB shaders. We probably need to rewrite them from scratch&lt;br /&gt;
* DirectX shaders might be automatically convertible with Cg?&lt;br /&gt;
* Otherwise, look at what Wine does with the shaders, and use that as a basis?&lt;br /&gt;
* All the games, even NWN, use some form of shaders. Still totally missing from xoreos, since we have no idea how to use them in general yet. Moreover, this was before GLSL, so they&#039;re in the old assembly-like language. We probably need to rewrite them from scratch&lt;br /&gt;
* We need shaders for tinting in NWN2 (objects and area geometry) and TexturePaint nodes in Witcher&lt;br /&gt;
&lt;br /&gt;
=== SDL 1.2 ===&lt;br /&gt;
* Optionally link against SDL 1.2 instead of SDL 2&lt;br /&gt;
* Should ideally use a configure flag to select between the two&lt;br /&gt;
** Maybe a CMake flag as well, if possible&lt;br /&gt;
* Assigned to clone2727, so anybody interested in this should coordinate with him&lt;br /&gt;
&lt;br /&gt;
== Videos ==&lt;br /&gt;
&lt;br /&gt;
=== XMV/WMV ===&lt;br /&gt;
* Used in Xbox versions of KotOR/KotOR2&lt;br /&gt;
* Our WMV decoder (for XMV videos used in Xbox versions) is missing P-frames and J-frame&lt;br /&gt;
** Code exists in ffmpeg, but is connected to the MPEG-4 family mess&lt;br /&gt;
&lt;br /&gt;
=== Actimagine VX ===&lt;br /&gt;
* Used in the Nintendo DS game Sonic Chronicles&lt;br /&gt;
* https://wiki.multimedia.cx/index.php?title=Actimagine_Video_Codec&lt;br /&gt;
&lt;br /&gt;
=== Sorenson 3 ===&lt;br /&gt;
* One single video in the Mac port of KotOR2, the Aspyr logo, uses the Sorenson 3 codec&lt;br /&gt;
** ffmpeg has a decoder, but it&#039;s connected to the MPEG-4 family mess (SVQ3 is similar to H.264)&lt;br /&gt;
* ScummVM needs that too&lt;br /&gt;
** While xoreos is GPLv3+, ScummVM is GPLv2+&lt;br /&gt;
** Somebody implementing Sorenson 3 for xoreos should ideally give explicit permission to relicense it GPLv2+ for ScummVM&lt;br /&gt;
*** Of course, if the decoder is based on prior work by other people, it has to be compatible with both GPLv2+ and GPLv3+&lt;br /&gt;
&lt;br /&gt;
=== Optimizations ===&lt;br /&gt;
* Optimize our simple BitStream interface&lt;br /&gt;
** See [https://fgiesen.wordpress.com/2016/01/02/end-of-buffer-checks-in-decompressors/ this blog post]&lt;br /&gt;
** Specifically, we don&#039;t do any peeking at all&lt;br /&gt;
** It still needs to handle different memory layouts, though&lt;br /&gt;
* Likewise, our Huffman class could probably be tuned a lot&lt;br /&gt;
* Pull in fft/rdft/dct/mdct optimizations from FFmpeg?&lt;br /&gt;
* I experimented with that in a private branch and it didn&#039;t do anything for Bink performance&lt;br /&gt;
&lt;br /&gt;
== Sound ==&lt;br /&gt;
&lt;br /&gt;
=== FMOD ===&lt;br /&gt;
* Dragon Age: Origins uses FMOD for sound and music&lt;br /&gt;
* I have experimental FSB (FMOD sound bank) support working in a private branch&lt;br /&gt;
* FEV (FMOD events) format is still unknown to us&lt;br /&gt;
** Apparently, groups of event lists with events&lt;br /&gt;
** Event is everything from &amp;quot;play sound&amp;quot;, over &amp;quot;set volume&amp;quot; to &amp;quot;apply echo&amp;quot;&lt;br /&gt;
** Game areas specify the group to use for the area&lt;br /&gt;
** Scripts then probably tell FMOD to play event lists out of that group&lt;br /&gt;
&lt;br /&gt;
=== Wwise ===&lt;br /&gt;
* Dragon Age 2 uses Wwise for sound and music&lt;br /&gt;
* Should be similar in concept to FMD&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
=== Gamepad binding ===&lt;br /&gt;
* The Xbox versions of KotOR and KotOR2 don&#039;t use a mouse. We have basic support for joysticks/gamepads, but no real bindings to the engine or ideas how to handle that in general&lt;br /&gt;
* We might want to handle the controller support the new KotOR2 Steam update brought&lt;br /&gt;
** override folder contains a gamepad.txt then&lt;br /&gt;
* Also hack in controller support for a non-Steam KotOR2? And for KotOR?&lt;br /&gt;
* Controller support in Jade Empire&lt;br /&gt;
* Controller support for Sonic? It is a Nintendo DS game after all&lt;br /&gt;
* Controller support for the non-console versions of the Dragon Age games?&lt;br /&gt;
&lt;br /&gt;
== Network ==&lt;br /&gt;
* We need a network subsystem&lt;br /&gt;
** [https://www.libsdl.org/projects/SDL_net/ SDL_net]?&lt;br /&gt;
** [http://www.boost.org/doc/libs/release/libs/asio/ Boost.Asio]?&lt;br /&gt;
** More options here: http://stackoverflow.com/questions/118945/best-c-c-network-library&lt;br /&gt;
* Engines need to be split into client and server classes&lt;br /&gt;
** The original engines all still do that, even when not exposing anything to users&lt;br /&gt;
** NWN and NWN2 allow user multiplayer&lt;br /&gt;
&lt;br /&gt;
== Engines ==&lt;br /&gt;
&lt;br /&gt;
=== Script system ===&lt;br /&gt;
* ImperatorPrime had started on a script system rewrite&lt;br /&gt;
** Includes functions with real signatures&lt;br /&gt;
** Maybe switch to that, if it works&lt;br /&gt;
* Rounds, object heartbeat scripts&lt;br /&gt;
* KotOR2 and NWN2 have some extensions&lt;br /&gt;
** It seems like they don&#039;t need any extensions to the low-level bytecode stuff&lt;br /&gt;
* Witcher uses Lua scripts together with NWScript&lt;br /&gt;
* Sonic has no scripts at all, it seems&lt;br /&gt;
* Currently a script in an infinite loop locks the game thread&lt;br /&gt;
** Timeout? Asynchronous script execution?&lt;br /&gt;
&lt;br /&gt;
=== NWN ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Basics are there, but needs fleshing out&lt;br /&gt;
** Supermanu is working on the character generator&lt;br /&gt;
* [[Pathfinding]], walkmesh&lt;br /&gt;
** &amp;quot;Moving&amp;quot; should move the PC, not the camera&lt;br /&gt;
** NPC walking&lt;br /&gt;
** Triggers, areas on the floor that calls scripts on enter/leave&lt;br /&gt;
* Models&lt;br /&gt;
** ASCII models need averaging of smooth group normals&lt;br /&gt;
* NWN objects need an inventory concept&lt;br /&gt;
** Player characters&#039; might be different&lt;br /&gt;
*** Inventory tetris&lt;br /&gt;
*** Inventory item icons&lt;br /&gt;
* Multi-page asian fonts&lt;br /&gt;
* LanguageID 0 is not necessarily &amp;quot;English&amp;quot;, but &amp;quot;The language of the game install&amp;quot;&lt;br /&gt;
** This is okay for languages with Latin characters&lt;br /&gt;
** Messes up strings in community modules with Asian languages that stuff strings in to languageID 0&lt;br /&gt;
** The original fails there too, though&lt;br /&gt;
&lt;br /&gt;
=== KotOR/KotOR2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Many are already there&lt;br /&gt;
* Dialogues&lt;br /&gt;
** DLG files, similar to NWN&lt;br /&gt;
** Some extensions, like camera setup&lt;br /&gt;
** Dialogues are displayed very different than NWN&lt;br /&gt;
** KotOR2 has script extensions&lt;br /&gt;
*** Passing parameters to scripts&lt;br /&gt;
*** Call several scripts, combine with AND/OR for branching&lt;br /&gt;
* Animations&lt;br /&gt;
** Mostly working now&lt;br /&gt;
* Minigames&lt;br /&gt;
** Swoop racing&lt;br /&gt;
** Pazaak&lt;br /&gt;
** Hardcoded, mostly removed from usual game logic&lt;br /&gt;
&lt;br /&gt;
=== Jade Empire ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Apparently very similar to KotOR&#039;s menus&lt;br /&gt;
* Minigames&lt;br /&gt;
** Flyer, top-down shoot-em-up thing&lt;br /&gt;
** Hardcoded, mostly removed from usual game logic&lt;br /&gt;
* Player character&lt;br /&gt;
** Needs research&lt;br /&gt;
* Sound&lt;br /&gt;
** Uses an ASCII variant of the [http://wiki.multimedia.cx/index.php?title=XACT XACT formats]&lt;br /&gt;
*** Cues probably not as complex as FMOD/Wwise&lt;br /&gt;
*** Effects need extension of the Sound system, maybe&lt;br /&gt;
** Xbox version might use the binary format?&lt;br /&gt;
*** Sound banks could be handles as archives and indexed in the ResourceManager?&lt;br /&gt;
** [https://github.com/FNA-XNA/FNA/tree/master/src/Audio FNA] has an implementation of XACT. Probably quite useful to look at that&lt;br /&gt;
&lt;br /&gt;
=== NWN2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Implemented using XML&lt;br /&gt;
** See [[#Broken NWN2 XML|Broken NWN2 XML]]&lt;br /&gt;
* Animations (Granny)&lt;br /&gt;
** [https://github.com/SkywingvL/nwn2dev-public nwn2-dev] contains some code working with Granny data&lt;br /&gt;
*** Call into the original Granny DLL to convert between binary and ASCII Granny data, though&lt;br /&gt;
** [https://github.com/berenm/xoreos-tools/tree/granny berenm started some Granny RE]&lt;br /&gt;
* Facial animations (FaceFX)&lt;br /&gt;
* Trees (SpeedTree)&lt;br /&gt;
* Proper evaluation of creature model parts (equipped items)&lt;br /&gt;
* Player character&lt;br /&gt;
** Reading of PC files in creature&lt;br /&gt;
&lt;br /&gt;
=== Sonic Chronicles ===&lt;br /&gt;
* Allow using the contents from an extracted NDS file?&lt;br /&gt;
* Menus&lt;br /&gt;
** GUI files that are GFF&lt;br /&gt;
** Actions in a state machine in GDA files?&lt;br /&gt;
* Music/Sound&lt;br /&gt;
** Music is apparently similar to MIDI, or to a tracker format?&lt;br /&gt;
** Sounds and instruments for music are in a sound_data.sadl archive&lt;br /&gt;
* Animations&lt;br /&gt;
** Bone animations, best implemented with shaders, blocked by the graphics subsystem rewrite&lt;br /&gt;
* Player character(s)&lt;br /&gt;
** Needs research&lt;br /&gt;
&lt;br /&gt;
=== The Witcher ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Apparently build using Lua&lt;br /&gt;
** System/Scripts/ has gui*.luc files&lt;br /&gt;
* Animations&lt;br /&gt;
** Needs research&lt;br /&gt;
* Player character, Geralt&lt;br /&gt;
** Needs research&lt;br /&gt;
&lt;br /&gt;
=== Dragon Age: Origins / Dragon Age 2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Scaleform_GFx Scaleform GFx]&lt;br /&gt;
** [http://social.bioware.com/wiki/datoolset/index.php/UI_Tutorial_%28draft%29 UI Tutorial] on the Dragon Age toolset wiki&lt;br /&gt;
** Flash-based!&lt;br /&gt;
** A good starting point for a reimplementation might be [https://en.wikipedia.org/wiki/Gameswf Gameswf].&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Gnash Gnash], [https://en.wikipedia.org/wiki/Lightspark Lightspark], [https://en.wikipedia.org/wiki/Swfdec Swfdec]&lt;br /&gt;
** [http://www.nowrap.de/flasm.html Flasm] can disassemble/assemble ActionScript, [http://www.nowrap.de/flare.html Flare] can decompile it&lt;br /&gt;
** [https://wwwimages2.adobe.com/content/dam/acom/en/devnet/pdf/swf-file-format-spec.pdf swf-file-format-spec.pdf] is a great reference which covers mostly every aspect of the gfx files.&lt;br /&gt;
** [https://github.com/jindrapetrik/jpexs-decompiler jpexs-decompiler] can decompile and handles scaleform specific tags.&lt;br /&gt;
* Animations&lt;br /&gt;
** Bone animations, best implemented with shaders, blocked by the graphics subsystem rewrite&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=TODO&amp;diff=352</id>
		<title>TODO</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=TODO&amp;diff=352"/>
		<updated>2018-05-15T21:56:53Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* Optimizations */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a long rambly list of things left to do in xoreos and xoreos-tools. Anybody is welcome to tackle any of these tasks, but please also read our [[Developer_Central|general contributor overview]], including our [[Code_Formatting_Conventions|Code Formatting Conventions]], [[Commit_Guidelines|Commit Guidelines]] and [https://github.com/xoreos/xoreos/blob/master/CODE_OF_CONDUCT.md Code of Conduct]. If you plan to do any of these tasks, please also [[Contact_us|contact us]] beforehand, so we can better coordinate multiple people interested in doing the same task, and discuss how to best solve the problem. Thanks. :)&lt;br /&gt;
&lt;br /&gt;
(&#039;&#039;&#039;See also:&#039;&#039;&#039; the Kanban-like &amp;quot;Projects&amp;quot; boards on GitHub: https://github.com/orgs/xoreos/projects, but they&#039;re not public and no way to make public at the moment. Boo.)&lt;br /&gt;
&lt;br /&gt;
== Documentation ==&lt;br /&gt;
&lt;br /&gt;
=== Developer information ===&lt;br /&gt;
* Extend the developer information on the wiki&lt;br /&gt;
** Explain how to get the xoreos sources on various platforms&lt;br /&gt;
** Expand GNU/Linux compiling instructions to cover more distributions&lt;br /&gt;
** Expand Mac OS X compiling instructions&lt;br /&gt;
*** Xcode&lt;br /&gt;
*** Homebrew/MacPorts/Fink&lt;br /&gt;
*** CMake, Libraries&lt;br /&gt;
** [http://wiki.arx-libertatis.org/Developer_Information Arx Libertatis] has an extensive dev page&lt;br /&gt;
* Document file formats on the wiki?&lt;br /&gt;
** Or integrate info into XentaxWiki?&lt;br /&gt;
** Both?&lt;br /&gt;
&lt;br /&gt;
=== User information ===&lt;br /&gt;
* More user information on the wiki&lt;br /&gt;
** How to download xoreos&lt;br /&gt;
** How to install the games on various platforms&lt;br /&gt;
** [http://wiki.arx-libertatis.org/Main_Page Arx Libertatis] does that pretty well&lt;br /&gt;
&lt;br /&gt;
=== Modder information ===&lt;br /&gt;
* Link to relevant modding resources&lt;br /&gt;
* Maybe even some kind of Modder&#039;s Handbook&lt;br /&gt;
** A big overview of modding Aurora games in general&lt;br /&gt;
*** Differences and commonalities between games&lt;br /&gt;
** Linking/Grouping engine functions between games&lt;br /&gt;
&lt;br /&gt;
== Website ==&lt;br /&gt;
&lt;br /&gt;
=== Design ===&lt;br /&gt;
* Better website design?&lt;br /&gt;
** It still should be static in the end&lt;br /&gt;
*** No PHP or Rails&lt;br /&gt;
*** Very light on JavaScript&lt;br /&gt;
*** No Flash!&lt;br /&gt;
** Maybe a bit more unique, graphical&lt;br /&gt;
** For legal reasons, we shouldn&#039;t directly use art or designs from the original games&lt;br /&gt;
*** Something inspired by the art of the orginal games would fit&lt;br /&gt;
&lt;br /&gt;
=== Octopress ===&lt;br /&gt;
* Move away from Octopress?&lt;br /&gt;
** Alternative should still produce static HTML somehow&lt;br /&gt;
** Octopress works rather well. It reads Markdown, which is a plus&lt;br /&gt;
* Octopress 3.0?&lt;br /&gt;
** Not finished yet, it seems&lt;br /&gt;
&lt;br /&gt;
== Standalone(ish) fixes/improvements ==&lt;br /&gt;
&lt;br /&gt;
=== Broken NWN2 XML ===&lt;br /&gt;
* Not standards-conforming XML. Need custom XML parser; stock XML parsing libraries will just throw errors.&lt;br /&gt;
** &amp;lt;nowiki&amp;gt;&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;NWN2UI&amp;quot;&amp;gt;&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
** No single root element&lt;br /&gt;
** Attribute values not enclosed in quotes most of the time&lt;br /&gt;
** Special characters in attribute values not properly escaped&lt;br /&gt;
** Unmatched quotes on several occasions&lt;br /&gt;
* Event functions&lt;br /&gt;
* Special values like PARENT_WIDTH&lt;br /&gt;
* [https://github.com/xoreos/xoreos-tools/pull/1 Altrite is working on a broken-XML fixer]&lt;br /&gt;
&lt;br /&gt;
=== CJK glyphs in the console ===&lt;br /&gt;
* The &amp;quot;system font&amp;quot; we use for our debug console, DejaVu Sans Mono Bold, does not feature any CJK (Chinese, Japanese, Korean) glyphs&lt;br /&gt;
* Not strictly necessary, but nice to have for printing, say, Witcher area names in Asian languages&lt;br /&gt;
* We could maybe integrate CJK glyphs from the [http://fonts.jp/hanazono/ Hanazono fonts] or other suitable libre fonts&lt;br /&gt;
* We need to match the height with DejaVu Sans Mono Bold&lt;br /&gt;
* CJK glyphs tend to be more complex and therefore wider. They&#039;re usually rendered twice as wide as Latin glyphs&lt;br /&gt;
* Our console code needs to take that into account&lt;br /&gt;
&lt;br /&gt;
=== Fuzzing ===&lt;br /&gt;
* Run our file readers, image decoders, etc. through a fuzzer, like [http://lcamtuf.coredump.cx/afl/ afl] (american fuzzy lop)&lt;br /&gt;
* Fix any cases where it crashes&lt;br /&gt;
* The xoreos-tools might be a good starting point for singular, standalone testing&lt;br /&gt;
** For image decoders, a slightly modified xoreostex2tga tool might work&lt;br /&gt;
* File formats already fuzzed:&lt;br /&gt;
** CBGT, CDPTH, DDS, NBFS, NCGR, NCLR, SBM, TGA, TPC, TXB&lt;br /&gt;
** 2DA, KEY/BIF, ERF, GFF3, GFF4, GDA, TLK, NSBTX, RIM, SMALL, SSF&lt;br /&gt;
&lt;br /&gt;
=== Script decompiler ===&lt;br /&gt;
* It might be quite useful to have a NWScript decompiler in xoreos-tools&lt;br /&gt;
* We have a script disassembler, ncsdis&lt;br /&gt;
** Which already does code flow analysis&lt;br /&gt;
* Missing:&lt;br /&gt;
** Code generation&lt;br /&gt;
** Collapsing of instruction chains into single-line NWScript code&lt;br /&gt;
*** For example, &amp;quot;int var = foo * bar + quux&amp;quot; compiles to a long chain with multiple temporaries&lt;br /&gt;
** Proper handling of structs and vectors&lt;br /&gt;
&lt;br /&gt;
=== Script compiler ===&lt;br /&gt;
* An NWScript compiler might be useful as well&lt;br /&gt;
** A script assembler might be an easy first step&lt;br /&gt;
&lt;br /&gt;
=== File format writers ===&lt;br /&gt;
* GFF3Writer, GFF4Writer&lt;br /&gt;
** Both necessary to create save games compatible with the original games&lt;br /&gt;
** Also useful for a xml2gff tool&lt;br /&gt;
* xml2tlk&lt;br /&gt;
** TalkTable_GFF::write02() and ::write05()&lt;br /&gt;
** Needs GFF4Writer&lt;br /&gt;
* Archive (ERF, RIM, KEY/BIF) packers?&lt;br /&gt;
&lt;br /&gt;
=== Config file ===&lt;br /&gt;
* Should be more preserving of the layout&lt;br /&gt;
** Especially empty lines&lt;br /&gt;
** UTF-8 Byte-Order-Mark when using native Windows editors&lt;br /&gt;
** \r is currently always stripped. Maybe preserve that too&lt;br /&gt;
*** Autodetect when \r is already used, and add it to new config lines too&lt;br /&gt;
** This basically needs a complete rewrite of the config parser&lt;br /&gt;
*** Don&#039;t just look for comments, just throw everything after &amp;quot;foo=bar&amp;quot; into the &amp;quot;comment&amp;quot; variable, including whitespace&lt;br /&gt;
*** And all whitespace before &amp;quot;foo=bar&amp;quot; into a &amp;quot;prefix&amp;quot; variable&lt;br /&gt;
** Maybe even always add BOM and \r when writing a new config file on Windows?&lt;br /&gt;
&lt;br /&gt;
=== Windows-specific / Wine-specific ===&lt;br /&gt;
* When running my mingw32 cross-compiled xoreos EXE in Wine, the menu button texts are partially cut off&lt;br /&gt;
** Z-fighting issue?&lt;br /&gt;
** Does that also occur on a real Windows?&lt;br /&gt;
&lt;br /&gt;
=== GUI ===&lt;br /&gt;
* xoreos could use a global GUI to start games from&lt;br /&gt;
* Should probably be similar to ScummVM&#039;s GUI, at least in effect&lt;br /&gt;
* Should read the config file, list all targets&lt;br /&gt;
** Press a &amp;quot;Play&amp;quot; button to play the game&lt;br /&gt;
** Press an &amp;quot;Edit&amp;quot; button to edit the entry&lt;br /&gt;
*** Dialog options to edit common settings&lt;br /&gt;
*** An additional free-form editor?&lt;br /&gt;
*** Game-specific options?&lt;br /&gt;
** A button to edit global settings (&amp;quot;xoreos&amp;quot; config domain)&lt;br /&gt;
** For the future, a way to immediately load a saved game?&lt;br /&gt;
** An &amp;quot;Add&amp;quot; button to add a game&lt;br /&gt;
*** File browser&lt;br /&gt;
**** Select directories for most game&lt;br /&gt;
**** Select file for Sonic Chronicles&lt;br /&gt;
*** View current saved games of a target?&lt;br /&gt;
* Probably implemented using OpenGL, just like, say, the console&lt;br /&gt;
* Theme-able/Skinable?&lt;br /&gt;
* Some potential stumbling blocks&lt;br /&gt;
** Displaying &amp;quot;uncommon&amp;quot; text in both game descriptions and file paths&lt;br /&gt;
*** &amp;quot;Decomposed&amp;quot; letters, i.e. base letter + combining glyphs&lt;br /&gt;
*** CJK&lt;br /&gt;
*** Arabic and other scripts where letters change depending on their place in the word&lt;br /&gt;
*** Right-to-left&lt;br /&gt;
** Shortening those strings when they don&#039;t fit in their fields is also potentially difficult&lt;br /&gt;
&lt;br /&gt;
=== Localization ===&lt;br /&gt;
* Text in exceptions?&lt;br /&gt;
** At least the user-visible ones, like &amp;quot;Failed to detect game&amp;quot;&lt;br /&gt;
** Or maybe we should clean that up and split them into &amp;quot;program logic failure&amp;quot; and &amp;quot;user failure&amp;quot;, with only the latter translated&lt;br /&gt;
* Strings for the engine loader progress bar&lt;br /&gt;
* Debug console string&lt;br /&gt;
* GUI (see above) strings&lt;br /&gt;
* [http://www.gnu.org/software/gettext/ GNU gettext] would be one solution&lt;br /&gt;
&lt;br /&gt;
=== Unit tests ===&lt;br /&gt;
* More unit tests&lt;br /&gt;
&lt;br /&gt;
=== Resource Explorer ===&lt;br /&gt;
* A portable, user-friendly graphical resource explorer could be useful&lt;br /&gt;
* [https://github.com/xoreos/phaethon Phaethon] is a start&lt;br /&gt;
** It can look into game archives, show textures and play sounds&lt;br /&gt;
** It uses [https://www.wxwidgets.org/ wxWidgets] to do the GUI&lt;br /&gt;
** Or possibly rewriting it to use [https://www.qt.io/ Qt] is better?&lt;br /&gt;
&lt;br /&gt;
=== Model converters ===&lt;br /&gt;
* Document the model formats&lt;br /&gt;
* Convert between the binary model formats and their ASCII equivalents&lt;br /&gt;
* Convert between the binary model formats and ones that can be opened by modelling tools&lt;br /&gt;
** 3D Studio Max&lt;br /&gt;
** Blender&lt;br /&gt;
&lt;br /&gt;
=== Full-fledged modding toolset ===&lt;br /&gt;
* Similar to the NWN, NWN2 or Witcher toolset, but portable and FLOSS&lt;br /&gt;
** Might also support other games?&lt;br /&gt;
* Out of scope for xoreos&lt;br /&gt;
** Still, such a thing would be welcome under the xoreos banner&lt;br /&gt;
* [http://sourceforge.net/projects/neveredit/ Neveredit] might still be worth a look&lt;br /&gt;
&lt;br /&gt;
== Build system ==&lt;br /&gt;
&lt;br /&gt;
=== CMake ===&lt;br /&gt;
* Current doesn&#039;t set the git version to &amp;quot;+unk&amp;quot; when git isn&#039;t found&lt;br /&gt;
* make install/uninstall?&lt;br /&gt;
* make doxygen?&lt;br /&gt;
&lt;br /&gt;
=== Autotools ===&lt;br /&gt;
* Suppress the &amp;quot;fatal: not a git repository&amp;quot; when building gitstamp without a git directory&lt;br /&gt;
* Increased modularity&lt;br /&gt;
** Disabling engines&lt;br /&gt;
** Making library dependencies optional (and disabling certain features, then)&lt;br /&gt;
*** liblzma? Only needed for the iOS version of KotOR&lt;br /&gt;
*** libxml2? Only needed for the two Dragon Age games&lt;br /&gt;
** When something is disabled, skip it, if possible&lt;br /&gt;
*** Like the videos in KotOR Mac&lt;br /&gt;
** If skipping is not possible, error out&lt;br /&gt;
&lt;br /&gt;
== Nitro ==&lt;br /&gt;
&lt;br /&gt;
* The Nintendo DS (Nitro) specific file formats should probably be moved out of src/aurora/ and into src/nitro&lt;br /&gt;
* nitrofile, cdpth, nsbtx, smallfile&lt;br /&gt;
** nsbtx needs to be split into a class accessing the textures in src/nitro/ and an archive class on top in src/aurora/&lt;br /&gt;
** This means src/aurora/ accesses src/nitro/, so libnitro.la needs to come after libaurora.la in the linking order&lt;br /&gt;
* ndsrom as well?&lt;br /&gt;
* What about nftrfont and model_sonic in src/graphics/aurora/?&lt;br /&gt;
** src/graphics/nitro/?&lt;br /&gt;
** This would have src/graphics/nitro/ access src/graphics/aurora/, so graphics/libnitro.la needs to come before graphics/libaurora.la in the linking order&lt;br /&gt;
** That would be the other way round than for src/nitro/. Too confusing?&lt;br /&gt;
&lt;br /&gt;
== Graphics ==&lt;br /&gt;
&lt;br /&gt;
=== MDL supermodels and animations ===&lt;br /&gt;
* Mostly working in NWN thanks to jbowtie&#039;s work&lt;br /&gt;
* Might need some cleanup&lt;br /&gt;
* Models should smoothly change between different animations&lt;br /&gt;
* The animation system probably needs to be a bit more complex, to allow for &amp;quot;overlaying&amp;quot; different animations onto each other. For example, for speaking while holding an object and keeping the head focused on the PC character.&lt;br /&gt;
&lt;br /&gt;
=== Lighting ===&lt;br /&gt;
* We don&#039;t yet have a proper light system&lt;br /&gt;
* I started working on it: [https://drmccoy.de/xoreos/20150809T223407.png], but my approach is seriously lacking. You can see the edges of the tiles that make up on NWN area in many cases ([https://drmccoy.de/xoreos/20150809T223507.png], [https://drmccoy.de/xoreos/20150809T223548.png])&lt;br /&gt;
** See the [https://github.com/xoreos/xoreos/tree/light light branch] in the git repository&lt;br /&gt;
** Of course, the actual glLight* stuff won&#039;t be relevant anymore as soon as shaders are there&lt;br /&gt;
** Lighting in several (ASCII?) area tiles is broken&lt;br /&gt;
*** The door in Prelude.nwm&#039;s &amp;quot;m0q1a&amp;quot; area&lt;br /&gt;
*** A water tile in Chapter2.nwm&#039;s &amp;quot;map_m2q1a&amp;quot; area&lt;br /&gt;
*** A sloped snow tile in XP2_Chapter3.nwm&#039;s &amp;quot;thecityoflostsou&amp;quot;&lt;br /&gt;
&lt;br /&gt;
=== Materials ===&lt;br /&gt;
* Materials in The Witcher are closely tied to shaders&lt;br /&gt;
&lt;br /&gt;
=== OpenGL and Shaders ===&lt;br /&gt;
* mirv_ is currently working on a graphics system overhaul, complete with shader support&lt;br /&gt;
* All Aurora games use shaders in some form&lt;br /&gt;
* NWN uses ARB shaders. We probably need to rewrite them from scratch&lt;br /&gt;
* DirectX shaders might be automatically convertible with Cg?&lt;br /&gt;
* Otherwise, look at what Wine does with the shaders, and use that as a basis?&lt;br /&gt;
* All the games, even NWN, use some form of shaders. Still totally missing from xoreos, since we have no idea how to use them in general yet. Moreover, this was before GLSL, so they&#039;re in the old assembly-like language. We probably need to rewrite them from scratch&lt;br /&gt;
* We need shaders for tinting in NWN2 (objects and area geometry) and TexturePaint nodes in Witcher&lt;br /&gt;
&lt;br /&gt;
=== SDL 1.2 ===&lt;br /&gt;
* Optionally link against SDL 1.2 instead of SDL 2&lt;br /&gt;
* Should ideally use a configure flag to select between the two&lt;br /&gt;
** Maybe a CMake flag as well, if possible&lt;br /&gt;
* Assigned to clone2727, so anybody interested in this should coordinate with him&lt;br /&gt;
&lt;br /&gt;
== Videos ==&lt;br /&gt;
&lt;br /&gt;
=== XMV/WMV ===&lt;br /&gt;
* Used in Xbox versions of KotOR/KotOR2&lt;br /&gt;
* Our WMV decoder (for XMV videos used in Xbox versions) is missing P-frames and J-frame&lt;br /&gt;
** Code exists in ffmpeg, but is connected to the MPEG-4 family mess&lt;br /&gt;
&lt;br /&gt;
=== Actimagine VX ===&lt;br /&gt;
* Used in the Nintendo DS game Sonic Chronicles&lt;br /&gt;
* https://wiki.multimedia.cx/index.php?title=Actimagine_Video_Codec&lt;br /&gt;
&lt;br /&gt;
=== Sorenson 3 ===&lt;br /&gt;
* One single video in the Mac port of KotOR2, the Aspyr logo, uses the Sorenson 3 codec&lt;br /&gt;
** ffmpeg has a decoder, but it&#039;s connected to the MPEG-4 family mess (SVQ3 is similar to H.264)&lt;br /&gt;
* ScummVM needs that too&lt;br /&gt;
** While xoreos is GPLv3+, ScummVM is GPLv2+&lt;br /&gt;
** Somebody implementing Sorenson 3 for xoreos should ideally give explicit permission to relicense it GPLv2+ for ScummVM&lt;br /&gt;
*** Of course, if the decoder is based on prior work by other people, it has to be compatible with both GPLv2+ and GPLv3+&lt;br /&gt;
&lt;br /&gt;
=== Optimizations ===&lt;br /&gt;
* Optimize our simple BitStream interface&lt;br /&gt;
** See [https://fgiesen.wordpress.com/2016/01/02/end-of-buffer-checks-in-decompressors/ this blog post]&lt;br /&gt;
** Specifically, we don&#039;t do any peeking at all&lt;br /&gt;
** It still needs to handle different memory layouts, though&lt;br /&gt;
* Likewise, our Huffman class could probably be tuned a lot&lt;br /&gt;
* Pull in fft/rdft/dct/mdct optimizations from FFmpeg?&lt;br /&gt;
* I experimented with that in a private branch and it didn&#039;t do anything for Bink performance&lt;br /&gt;
&lt;br /&gt;
== Sound ==&lt;br /&gt;
&lt;br /&gt;
=== FMOD ===&lt;br /&gt;
* Dragon Age: Origins uses FMOD for sound and music&lt;br /&gt;
* I have experimental FSB (FMOD sound bank) support working in a private branch&lt;br /&gt;
* FEV (FMOD events) format is still unknown to us&lt;br /&gt;
** Apparently, groups of event lists with events&lt;br /&gt;
** Event is everything from &amp;quot;play sound&amp;quot;, over &amp;quot;set volume&amp;quot; to &amp;quot;apply echo&amp;quot;&lt;br /&gt;
** Game areas specify the group to use for the area&lt;br /&gt;
** Scripts then probably tell FMOD to play event lists out of that group&lt;br /&gt;
&lt;br /&gt;
=== Wwise ===&lt;br /&gt;
* Dragon Age 2 uses Wwise for sound and music&lt;br /&gt;
* Should be similar in concept to FMD&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
=== Gamepad binding ===&lt;br /&gt;
* The Xbox versions of KotOR and KotOR2 don&#039;t use a mouse. We have basic support for joysticks/gamepads, but no real bindings to the engine or ideas how to handle that in general&lt;br /&gt;
* We might want to handle the controller support the new KotOR2 Steam update brought&lt;br /&gt;
** override folder contains a gamepad.txt then&lt;br /&gt;
* Also hack in controller support for a non-Steam KotOR2? And for KotOR?&lt;br /&gt;
* Controller support in Jade Empire&lt;br /&gt;
* Controller support for Sonic? It is a Nintendo DS game after all&lt;br /&gt;
* Controller support for the non-console versions of the Dragon Age games?&lt;br /&gt;
&lt;br /&gt;
== Network ==&lt;br /&gt;
* We need a network subsystem&lt;br /&gt;
** [https://www.libsdl.org/projects/SDL_net/ SDL_net]?&lt;br /&gt;
** [http://www.boost.org/doc/libs/release/libs/asio/ Boost.Asio]?&lt;br /&gt;
** More options here: http://stackoverflow.com/questions/118945/best-c-c-network-library&lt;br /&gt;
* Engines need to be split into client and server classes&lt;br /&gt;
** The original engines all still do that, even when not exposing anything to users&lt;br /&gt;
** NWN and NWN2 allow user multiplayer&lt;br /&gt;
&lt;br /&gt;
== Engines ==&lt;br /&gt;
&lt;br /&gt;
=== Script system ===&lt;br /&gt;
* ImperatorPrime had started on a script system rewrite&lt;br /&gt;
** Includes functions with real signatures&lt;br /&gt;
** Maybe switch to that, if it works&lt;br /&gt;
* Rounds, object heartbeat scripts&lt;br /&gt;
* KotOR2 and NWN2 have some extensions&lt;br /&gt;
** It seems like they don&#039;t need any extensions to the low-level bytecode stuff&lt;br /&gt;
* Witcher uses Lua scripts together with NWScript&lt;br /&gt;
* Sonic has no scripts at all, it seems&lt;br /&gt;
* Currently a script in an infinite loop locks the game thread&lt;br /&gt;
** Timeout? Asynchronous script execution?&lt;br /&gt;
&lt;br /&gt;
=== NWN ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Basics are there, but needs fleshing out&lt;br /&gt;
** Supermanu is working on the character generator&lt;br /&gt;
* [[Pathfinding]], walkmesh&lt;br /&gt;
** &amp;quot;Moving&amp;quot; should move the PC, not the camera&lt;br /&gt;
** NPC walking&lt;br /&gt;
** Triggers, areas on the floor that calls scripts on enter/leave&lt;br /&gt;
* Models&lt;br /&gt;
** ASCII models need averaging of smooth group normals&lt;br /&gt;
* NWN objects need an inventory concept&lt;br /&gt;
** Player characters&#039; might be different&lt;br /&gt;
*** Inventory tetris&lt;br /&gt;
*** Inventory item icons&lt;br /&gt;
* Multi-page asian fonts&lt;br /&gt;
* LanguageID 0 is not necessarily &amp;quot;English&amp;quot;, but &amp;quot;The language of the game install&amp;quot;&lt;br /&gt;
** This is okay for languages with Latin characters&lt;br /&gt;
** Messes up strings in community modules with Asian languages that stuff strings in to languageID 0&lt;br /&gt;
** The original fails there too, though&lt;br /&gt;
&lt;br /&gt;
=== KotOR/KotOR2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Basic structure is already there, just missing most of the specific widgets stuff&lt;br /&gt;
** Semi-hardcoded, with GFF files (hierachical data, similar to XML in spirit) describing the setup. The xoreos-tools repository has a tool for converting GFF files into XML for easy reading.&lt;br /&gt;
* Dialogues&lt;br /&gt;
** DLG files, similar to NWN&lt;br /&gt;
** Some extensions, like camera setup&lt;br /&gt;
** Dialogues are displayed very different than NWN&lt;br /&gt;
** KotOR2 has script extensions&lt;br /&gt;
*** Passing parameters to scripts&lt;br /&gt;
*** Call several scripts, combine with AND/OR for branching&lt;br /&gt;
* Animations&lt;br /&gt;
** Should be similar to NWN&lt;br /&gt;
** No player character shown&lt;br /&gt;
*** Needs character creator menus&lt;br /&gt;
*** Loading of character files in class Creature&lt;br /&gt;
* Minigames&lt;br /&gt;
** Swoop racing&lt;br /&gt;
** Pazaak&lt;br /&gt;
** Hardcoded, mostly removed from usual game logic&lt;br /&gt;
&lt;br /&gt;
=== Jade Empire ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Apparently very similar to KotOR&#039;s menus&lt;br /&gt;
* Minigames&lt;br /&gt;
** Flyer, top-down shoot-em-up thing&lt;br /&gt;
** Hardcoded, mostly removed from usual game logic&lt;br /&gt;
* Player character&lt;br /&gt;
** Needs research&lt;br /&gt;
* Sound&lt;br /&gt;
** Uses an ASCII variant of the [http://wiki.multimedia.cx/index.php?title=XACT XACT formats]&lt;br /&gt;
*** Cues probably not as complex as FMOD/Wwise&lt;br /&gt;
*** Effects need extension of the Sound system, maybe&lt;br /&gt;
** Xbox version might use the binary format?&lt;br /&gt;
*** Sound banks could be handles as archives and indexed in the ResourceManager?&lt;br /&gt;
** [https://github.com/FNA-XNA/FNA/tree/master/src/Audio FNA] has an implementation of XACT. Probably quite useful to look at that&lt;br /&gt;
&lt;br /&gt;
=== NWN2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Implemented using XML&lt;br /&gt;
** See [[#Broken NWN2 XML|Broken NWN2 XML]]&lt;br /&gt;
* Animations (Granny)&lt;br /&gt;
** [https://github.com/SkywingvL/nwn2dev-public nwn2-dev] contains some code working with Granny data&lt;br /&gt;
*** Call into the original Granny DLL to convert between binary and ASCII Granny data, though&lt;br /&gt;
** [https://github.com/berenm/xoreos-tools/tree/granny berenm started some Granny RE]&lt;br /&gt;
* Facial animations (FaceFX)&lt;br /&gt;
* Trees (SpeedTree)&lt;br /&gt;
* Proper evaluation of creature model parts (equipped items)&lt;br /&gt;
* Player character&lt;br /&gt;
** Reading of PC files in creature&lt;br /&gt;
&lt;br /&gt;
=== Sonic Chronicles ===&lt;br /&gt;
* Allow using the contents from an extracted NDS file?&lt;br /&gt;
* Menus&lt;br /&gt;
** GUI files that are GFF&lt;br /&gt;
** Actions in a state machine in GDA files?&lt;br /&gt;
* Music/Sound&lt;br /&gt;
** Music is apparently similar to MIDI, or to a tracker format?&lt;br /&gt;
** Sounds and instruments for music are in a sound_data.sadl archive&lt;br /&gt;
* Animations&lt;br /&gt;
** Bone animations, best implemented with shaders, blocked by the graphics subsystem rewrite&lt;br /&gt;
* Player character(s)&lt;br /&gt;
** Needs research&lt;br /&gt;
&lt;br /&gt;
=== The Witcher ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Apparently build using Lua&lt;br /&gt;
** System/Scripts/ has gui*.luc files&lt;br /&gt;
* Animations&lt;br /&gt;
** Needs research&lt;br /&gt;
* Player character, Geralt&lt;br /&gt;
** Needs research&lt;br /&gt;
&lt;br /&gt;
=== Dragon Age: Origins / Dragon Age 2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Scaleform_GFx Scaleform GFx]&lt;br /&gt;
** [http://social.bioware.com/wiki/datoolset/index.php/UI_Tutorial_%28draft%29 UI Tutorial] on the Dragon Age toolset wiki&lt;br /&gt;
** Flash-based!&lt;br /&gt;
** A good starting point for a reimplementation might be [https://en.wikipedia.org/wiki/Gameswf Gameswf].&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Gnash Gnash], [https://en.wikipedia.org/wiki/Lightspark Lightspark], [https://en.wikipedia.org/wiki/Swfdec Swfdec]&lt;br /&gt;
** [http://www.nowrap.de/flasm.html Flasm] can disassemble/assemble ActionScript, [http://www.nowrap.de/flare.html Flare] can decompile it&lt;br /&gt;
** [https://wwwimages2.adobe.com/content/dam/acom/en/devnet/pdf/swf-file-format-spec.pdf swf-file-format-spec.pdf] is a great reference which covers mostly every aspect of the gfx files.&lt;br /&gt;
** [https://github.com/jindrapetrik/jpexs-decompiler jpexs-decompiler] can decompile and handles scaleform specific tags.&lt;br /&gt;
* Animations&lt;br /&gt;
** Bone animations, best implemented with shaders, blocked by the graphics subsystem rewrite&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=TODO&amp;diff=351</id>
		<title>TODO</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=TODO&amp;diff=351"/>
		<updated>2018-05-15T21:51:40Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* MDL supermodels and animations */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a long rambly list of things left to do in xoreos and xoreos-tools. Anybody is welcome to tackle any of these tasks, but please also read our [[Developer_Central|general contributor overview]], including our [[Code_Formatting_Conventions|Code Formatting Conventions]], [[Commit_Guidelines|Commit Guidelines]] and [https://github.com/xoreos/xoreos/blob/master/CODE_OF_CONDUCT.md Code of Conduct]. If you plan to do any of these tasks, please also [[Contact_us|contact us]] beforehand, so we can better coordinate multiple people interested in doing the same task, and discuss how to best solve the problem. Thanks. :)&lt;br /&gt;
&lt;br /&gt;
(&#039;&#039;&#039;See also:&#039;&#039;&#039; the Kanban-like &amp;quot;Projects&amp;quot; boards on GitHub: https://github.com/orgs/xoreos/projects, but they&#039;re not public and no way to make public at the moment. Boo.)&lt;br /&gt;
&lt;br /&gt;
== Documentation ==&lt;br /&gt;
&lt;br /&gt;
=== Developer information ===&lt;br /&gt;
* Extend the developer information on the wiki&lt;br /&gt;
** Explain how to get the xoreos sources on various platforms&lt;br /&gt;
** Expand GNU/Linux compiling instructions to cover more distributions&lt;br /&gt;
** Expand Mac OS X compiling instructions&lt;br /&gt;
*** Xcode&lt;br /&gt;
*** Homebrew/MacPorts/Fink&lt;br /&gt;
*** CMake, Libraries&lt;br /&gt;
** [http://wiki.arx-libertatis.org/Developer_Information Arx Libertatis] has an extensive dev page&lt;br /&gt;
* Document file formats on the wiki?&lt;br /&gt;
** Or integrate info into XentaxWiki?&lt;br /&gt;
** Both?&lt;br /&gt;
&lt;br /&gt;
=== User information ===&lt;br /&gt;
* More user information on the wiki&lt;br /&gt;
** How to download xoreos&lt;br /&gt;
** How to install the games on various platforms&lt;br /&gt;
** [http://wiki.arx-libertatis.org/Main_Page Arx Libertatis] does that pretty well&lt;br /&gt;
&lt;br /&gt;
=== Modder information ===&lt;br /&gt;
* Link to relevant modding resources&lt;br /&gt;
* Maybe even some kind of Modder&#039;s Handbook&lt;br /&gt;
** A big overview of modding Aurora games in general&lt;br /&gt;
*** Differences and commonalities between games&lt;br /&gt;
** Linking/Grouping engine functions between games&lt;br /&gt;
&lt;br /&gt;
== Website ==&lt;br /&gt;
&lt;br /&gt;
=== Design ===&lt;br /&gt;
* Better website design?&lt;br /&gt;
** It still should be static in the end&lt;br /&gt;
*** No PHP or Rails&lt;br /&gt;
*** Very light on JavaScript&lt;br /&gt;
*** No Flash!&lt;br /&gt;
** Maybe a bit more unique, graphical&lt;br /&gt;
** For legal reasons, we shouldn&#039;t directly use art or designs from the original games&lt;br /&gt;
*** Something inspired by the art of the orginal games would fit&lt;br /&gt;
&lt;br /&gt;
=== Octopress ===&lt;br /&gt;
* Move away from Octopress?&lt;br /&gt;
** Alternative should still produce static HTML somehow&lt;br /&gt;
** Octopress works rather well. It reads Markdown, which is a plus&lt;br /&gt;
* Octopress 3.0?&lt;br /&gt;
** Not finished yet, it seems&lt;br /&gt;
&lt;br /&gt;
== Standalone(ish) fixes/improvements ==&lt;br /&gt;
&lt;br /&gt;
=== Broken NWN2 XML ===&lt;br /&gt;
* Not standards-conforming XML. Need custom XML parser; stock XML parsing libraries will just throw errors.&lt;br /&gt;
** &amp;lt;nowiki&amp;gt;&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;NWN2UI&amp;quot;&amp;gt;&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
** No single root element&lt;br /&gt;
** Attribute values not enclosed in quotes most of the time&lt;br /&gt;
** Special characters in attribute values not properly escaped&lt;br /&gt;
** Unmatched quotes on several occasions&lt;br /&gt;
* Event functions&lt;br /&gt;
* Special values like PARENT_WIDTH&lt;br /&gt;
* [https://github.com/xoreos/xoreos-tools/pull/1 Altrite is working on a broken-XML fixer]&lt;br /&gt;
&lt;br /&gt;
=== CJK glyphs in the console ===&lt;br /&gt;
* The &amp;quot;system font&amp;quot; we use for our debug console, DejaVu Sans Mono Bold, does not feature any CJK (Chinese, Japanese, Korean) glyphs&lt;br /&gt;
* Not strictly necessary, but nice to have for printing, say, Witcher area names in Asian languages&lt;br /&gt;
* We could maybe integrate CJK glyphs from the [http://fonts.jp/hanazono/ Hanazono fonts] or other suitable libre fonts&lt;br /&gt;
* We need to match the height with DejaVu Sans Mono Bold&lt;br /&gt;
* CJK glyphs tend to be more complex and therefore wider. They&#039;re usually rendered twice as wide as Latin glyphs&lt;br /&gt;
* Our console code needs to take that into account&lt;br /&gt;
&lt;br /&gt;
=== Fuzzing ===&lt;br /&gt;
* Run our file readers, image decoders, etc. through a fuzzer, like [http://lcamtuf.coredump.cx/afl/ afl] (american fuzzy lop)&lt;br /&gt;
* Fix any cases where it crashes&lt;br /&gt;
* The xoreos-tools might be a good starting point for singular, standalone testing&lt;br /&gt;
** For image decoders, a slightly modified xoreostex2tga tool might work&lt;br /&gt;
* File formats already fuzzed:&lt;br /&gt;
** CBGT, CDPTH, DDS, NBFS, NCGR, NCLR, SBM, TGA, TPC, TXB&lt;br /&gt;
** 2DA, KEY/BIF, ERF, GFF3, GFF4, GDA, TLK, NSBTX, RIM, SMALL, SSF&lt;br /&gt;
&lt;br /&gt;
=== Script decompiler ===&lt;br /&gt;
* It might be quite useful to have a NWScript decompiler in xoreos-tools&lt;br /&gt;
* We have a script disassembler, ncsdis&lt;br /&gt;
** Which already does code flow analysis&lt;br /&gt;
* Missing:&lt;br /&gt;
** Code generation&lt;br /&gt;
** Collapsing of instruction chains into single-line NWScript code&lt;br /&gt;
*** For example, &amp;quot;int var = foo * bar + quux&amp;quot; compiles to a long chain with multiple temporaries&lt;br /&gt;
** Proper handling of structs and vectors&lt;br /&gt;
&lt;br /&gt;
=== Script compiler ===&lt;br /&gt;
* An NWScript compiler might be useful as well&lt;br /&gt;
** A script assembler might be an easy first step&lt;br /&gt;
&lt;br /&gt;
=== File format writers ===&lt;br /&gt;
* GFF3Writer, GFF4Writer&lt;br /&gt;
** Both necessary to create save games compatible with the original games&lt;br /&gt;
** Also useful for a xml2gff tool&lt;br /&gt;
* xml2tlk&lt;br /&gt;
** TalkTable_GFF::write02() and ::write05()&lt;br /&gt;
** Needs GFF4Writer&lt;br /&gt;
* Archive (ERF, RIM, KEY/BIF) packers?&lt;br /&gt;
&lt;br /&gt;
=== Config file ===&lt;br /&gt;
* Should be more preserving of the layout&lt;br /&gt;
** Especially empty lines&lt;br /&gt;
** UTF-8 Byte-Order-Mark when using native Windows editors&lt;br /&gt;
** \r is currently always stripped. Maybe preserve that too&lt;br /&gt;
*** Autodetect when \r is already used, and add it to new config lines too&lt;br /&gt;
** This basically needs a complete rewrite of the config parser&lt;br /&gt;
*** Don&#039;t just look for comments, just throw everything after &amp;quot;foo=bar&amp;quot; into the &amp;quot;comment&amp;quot; variable, including whitespace&lt;br /&gt;
*** And all whitespace before &amp;quot;foo=bar&amp;quot; into a &amp;quot;prefix&amp;quot; variable&lt;br /&gt;
** Maybe even always add BOM and \r when writing a new config file on Windows?&lt;br /&gt;
&lt;br /&gt;
=== Windows-specific / Wine-specific ===&lt;br /&gt;
* When running my mingw32 cross-compiled xoreos EXE in Wine, the menu button texts are partially cut off&lt;br /&gt;
** Z-fighting issue?&lt;br /&gt;
** Does that also occur on a real Windows?&lt;br /&gt;
&lt;br /&gt;
=== GUI ===&lt;br /&gt;
* xoreos could use a global GUI to start games from&lt;br /&gt;
* Should probably be similar to ScummVM&#039;s GUI, at least in effect&lt;br /&gt;
* Should read the config file, list all targets&lt;br /&gt;
** Press a &amp;quot;Play&amp;quot; button to play the game&lt;br /&gt;
** Press an &amp;quot;Edit&amp;quot; button to edit the entry&lt;br /&gt;
*** Dialog options to edit common settings&lt;br /&gt;
*** An additional free-form editor?&lt;br /&gt;
*** Game-specific options?&lt;br /&gt;
** A button to edit global settings (&amp;quot;xoreos&amp;quot; config domain)&lt;br /&gt;
** For the future, a way to immediately load a saved game?&lt;br /&gt;
** An &amp;quot;Add&amp;quot; button to add a game&lt;br /&gt;
*** File browser&lt;br /&gt;
**** Select directories for most game&lt;br /&gt;
**** Select file for Sonic Chronicles&lt;br /&gt;
*** View current saved games of a target?&lt;br /&gt;
* Probably implemented using OpenGL, just like, say, the console&lt;br /&gt;
* Theme-able/Skinable?&lt;br /&gt;
* Some potential stumbling blocks&lt;br /&gt;
** Displaying &amp;quot;uncommon&amp;quot; text in both game descriptions and file paths&lt;br /&gt;
*** &amp;quot;Decomposed&amp;quot; letters, i.e. base letter + combining glyphs&lt;br /&gt;
*** CJK&lt;br /&gt;
*** Arabic and other scripts where letters change depending on their place in the word&lt;br /&gt;
*** Right-to-left&lt;br /&gt;
** Shortening those strings when they don&#039;t fit in their fields is also potentially difficult&lt;br /&gt;
&lt;br /&gt;
=== Localization ===&lt;br /&gt;
* Text in exceptions?&lt;br /&gt;
** At least the user-visible ones, like &amp;quot;Failed to detect game&amp;quot;&lt;br /&gt;
** Or maybe we should clean that up and split them into &amp;quot;program logic failure&amp;quot; and &amp;quot;user failure&amp;quot;, with only the latter translated&lt;br /&gt;
* Strings for the engine loader progress bar&lt;br /&gt;
* Debug console string&lt;br /&gt;
* GUI (see above) strings&lt;br /&gt;
* [http://www.gnu.org/software/gettext/ GNU gettext] would be one solution&lt;br /&gt;
&lt;br /&gt;
=== Unit tests ===&lt;br /&gt;
* More unit tests&lt;br /&gt;
&lt;br /&gt;
=== Resource Explorer ===&lt;br /&gt;
* A portable, user-friendly graphical resource explorer could be useful&lt;br /&gt;
* [https://github.com/xoreos/phaethon Phaethon] is a start&lt;br /&gt;
** It can look into game archives, show textures and play sounds&lt;br /&gt;
** It uses [https://www.wxwidgets.org/ wxWidgets] to do the GUI&lt;br /&gt;
** Or possibly rewriting it to use [https://www.qt.io/ Qt] is better?&lt;br /&gt;
&lt;br /&gt;
=== Model converters ===&lt;br /&gt;
* Document the model formats&lt;br /&gt;
* Convert between the binary model formats and their ASCII equivalents&lt;br /&gt;
* Convert between the binary model formats and ones that can be opened by modelling tools&lt;br /&gt;
** 3D Studio Max&lt;br /&gt;
** Blender&lt;br /&gt;
&lt;br /&gt;
=== Full-fledged modding toolset ===&lt;br /&gt;
* Similar to the NWN, NWN2 or Witcher toolset, but portable and FLOSS&lt;br /&gt;
** Might also support other games?&lt;br /&gt;
* Out of scope for xoreos&lt;br /&gt;
** Still, such a thing would be welcome under the xoreos banner&lt;br /&gt;
* [http://sourceforge.net/projects/neveredit/ Neveredit] might still be worth a look&lt;br /&gt;
&lt;br /&gt;
== Build system ==&lt;br /&gt;
&lt;br /&gt;
=== CMake ===&lt;br /&gt;
* Current doesn&#039;t set the git version to &amp;quot;+unk&amp;quot; when git isn&#039;t found&lt;br /&gt;
* make install/uninstall?&lt;br /&gt;
* make doxygen?&lt;br /&gt;
&lt;br /&gt;
=== Autotools ===&lt;br /&gt;
* Suppress the &amp;quot;fatal: not a git repository&amp;quot; when building gitstamp without a git directory&lt;br /&gt;
* Increased modularity&lt;br /&gt;
** Disabling engines&lt;br /&gt;
** Making library dependencies optional (and disabling certain features, then)&lt;br /&gt;
*** liblzma? Only needed for the iOS version of KotOR&lt;br /&gt;
*** libxml2? Only needed for the two Dragon Age games&lt;br /&gt;
** When something is disabled, skip it, if possible&lt;br /&gt;
*** Like the videos in KotOR Mac&lt;br /&gt;
** If skipping is not possible, error out&lt;br /&gt;
&lt;br /&gt;
== Nitro ==&lt;br /&gt;
&lt;br /&gt;
* The Nintendo DS (Nitro) specific file formats should probably be moved out of src/aurora/ and into src/nitro&lt;br /&gt;
* nitrofile, cdpth, nsbtx, smallfile&lt;br /&gt;
** nsbtx needs to be split into a class accessing the textures in src/nitro/ and an archive class on top in src/aurora/&lt;br /&gt;
** This means src/aurora/ accesses src/nitro/, so libnitro.la needs to come after libaurora.la in the linking order&lt;br /&gt;
* ndsrom as well?&lt;br /&gt;
* What about nftrfont and model_sonic in src/graphics/aurora/?&lt;br /&gt;
** src/graphics/nitro/?&lt;br /&gt;
** This would have src/graphics/nitro/ access src/graphics/aurora/, so graphics/libnitro.la needs to come before graphics/libaurora.la in the linking order&lt;br /&gt;
** That would be the other way round than for src/nitro/. Too confusing?&lt;br /&gt;
&lt;br /&gt;
== Graphics ==&lt;br /&gt;
&lt;br /&gt;
=== MDL supermodels and animations ===&lt;br /&gt;
* Mostly working in NWN thanks to jbowtie&#039;s work&lt;br /&gt;
* Might need some cleanup&lt;br /&gt;
* Models should smoothly change between different animations&lt;br /&gt;
* The animation system probably needs to be a bit more complex, to allow for &amp;quot;overlaying&amp;quot; different animations onto each other. For example, for speaking while holding an object and keeping the head focused on the PC character.&lt;br /&gt;
&lt;br /&gt;
=== Lighting ===&lt;br /&gt;
* We don&#039;t yet have a proper light system&lt;br /&gt;
* I started working on it: [https://drmccoy.de/xoreos/20150809T223407.png], but my approach is seriously lacking. You can see the edges of the tiles that make up on NWN area in many cases ([https://drmccoy.de/xoreos/20150809T223507.png], [https://drmccoy.de/xoreos/20150809T223548.png])&lt;br /&gt;
** See the [https://github.com/xoreos/xoreos/tree/light light branch] in the git repository&lt;br /&gt;
** Of course, the actual glLight* stuff won&#039;t be relevant anymore as soon as shaders are there&lt;br /&gt;
** Lighting in several (ASCII?) area tiles is broken&lt;br /&gt;
*** The door in Prelude.nwm&#039;s &amp;quot;m0q1a&amp;quot; area&lt;br /&gt;
*** A water tile in Chapter2.nwm&#039;s &amp;quot;map_m2q1a&amp;quot; area&lt;br /&gt;
*** A sloped snow tile in XP2_Chapter3.nwm&#039;s &amp;quot;thecityoflostsou&amp;quot;&lt;br /&gt;
&lt;br /&gt;
=== Materials ===&lt;br /&gt;
* Materials in The Witcher are closely tied to shaders&lt;br /&gt;
&lt;br /&gt;
=== OpenGL and Shaders ===&lt;br /&gt;
* mirv_ is currently working on a graphics system overhaul, complete with shader support&lt;br /&gt;
* All Aurora games use shaders in some form&lt;br /&gt;
* NWN uses ARB shaders. We probably need to rewrite them from scratch&lt;br /&gt;
* DirectX shaders might be automatically convertible with Cg?&lt;br /&gt;
* Otherwise, look at what Wine does with the shaders, and use that as a basis?&lt;br /&gt;
* All the games, even NWN, use some form of shaders. Still totally missing from xoreos, since we have no idea how to use them in general yet. Moreover, this was before GLSL, so they&#039;re in the old assembly-like language. We probably need to rewrite them from scratch&lt;br /&gt;
* We need shaders for tinting in NWN2 (objects and area geometry) and TexturePaint nodes in Witcher&lt;br /&gt;
&lt;br /&gt;
=== SDL 1.2 ===&lt;br /&gt;
* Optionally link against SDL 1.2 instead of SDL 2&lt;br /&gt;
* Should ideally use a configure flag to select between the two&lt;br /&gt;
** Maybe a CMake flag as well, if possible&lt;br /&gt;
* Assigned to clone2727, so anybody interested in this should coordinate with him&lt;br /&gt;
&lt;br /&gt;
== Videos ==&lt;br /&gt;
&lt;br /&gt;
=== XMV/WMV ===&lt;br /&gt;
* Used in Xbox versions of KotOR/KotOR2&lt;br /&gt;
* Our WMV decoder (for XMV videos used in Xbox versions) is missing P-frames and J-frame&lt;br /&gt;
** Code exists in ffmpeg, but is connected to the MPEG-4 family mess&lt;br /&gt;
&lt;br /&gt;
=== Actimagine VX ===&lt;br /&gt;
* Used in the Nintendo DS game Sonic Chronicles&lt;br /&gt;
* https://wiki.multimedia.cx/index.php?title=Actimagine_Video_Codec&lt;br /&gt;
&lt;br /&gt;
=== Sorenson 3 ===&lt;br /&gt;
* One single video in the Mac port of KotOR2, the Aspyr logo, uses the Sorenson 3 codec&lt;br /&gt;
** ffmpeg has a decoder, but it&#039;s connected to the MPEG-4 family mess (SVQ3 is similar to H.264)&lt;br /&gt;
* ScummVM needs that too&lt;br /&gt;
** While xoreos is GPLv3+, ScummVM is GPLv2+&lt;br /&gt;
** Somebody implementing Sorenson 3 for xoreos should ideally give explicit permission to relicense it GPLv2+ for ScummVM&lt;br /&gt;
*** Of course, if the decoder is based on prior work by other people, it has to be compatible with both GPLv2+ and GPLv3+&lt;br /&gt;
&lt;br /&gt;
=== Optimizations ===&lt;br /&gt;
* Optimize our simple BitStream interface&lt;br /&gt;
** See [https://fgiesen.wordpress.com/2016/01/02/end-of-buffer-checks-in-decompressors/ this blog post]&lt;br /&gt;
** Specifically, we don&#039;t do any peeking at all&lt;br /&gt;
** It still needs to handle different memory layouts, though&lt;br /&gt;
* Likewise, our Huffman class could probably be tuned a lot&lt;br /&gt;
* Pull in fft/rdft/dct/mdct optimizations from FFmpeg?&lt;br /&gt;
&lt;br /&gt;
== Sound ==&lt;br /&gt;
&lt;br /&gt;
=== FMOD ===&lt;br /&gt;
* Dragon Age: Origins uses FMOD for sound and music&lt;br /&gt;
* I have experimental FSB (FMOD sound bank) support working in a private branch&lt;br /&gt;
* FEV (FMOD events) format is still unknown to us&lt;br /&gt;
** Apparently, groups of event lists with events&lt;br /&gt;
** Event is everything from &amp;quot;play sound&amp;quot;, over &amp;quot;set volume&amp;quot; to &amp;quot;apply echo&amp;quot;&lt;br /&gt;
** Game areas specify the group to use for the area&lt;br /&gt;
** Scripts then probably tell FMOD to play event lists out of that group&lt;br /&gt;
&lt;br /&gt;
=== Wwise ===&lt;br /&gt;
* Dragon Age 2 uses Wwise for sound and music&lt;br /&gt;
* Should be similar in concept to FMD&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
=== Gamepad binding ===&lt;br /&gt;
* The Xbox versions of KotOR and KotOR2 don&#039;t use a mouse. We have basic support for joysticks/gamepads, but no real bindings to the engine or ideas how to handle that in general&lt;br /&gt;
* We might want to handle the controller support the new KotOR2 Steam update brought&lt;br /&gt;
** override folder contains a gamepad.txt then&lt;br /&gt;
* Also hack in controller support for a non-Steam KotOR2? And for KotOR?&lt;br /&gt;
* Controller support in Jade Empire&lt;br /&gt;
* Controller support for Sonic? It is a Nintendo DS game after all&lt;br /&gt;
* Controller support for the non-console versions of the Dragon Age games?&lt;br /&gt;
&lt;br /&gt;
== Network ==&lt;br /&gt;
* We need a network subsystem&lt;br /&gt;
** [https://www.libsdl.org/projects/SDL_net/ SDL_net]?&lt;br /&gt;
** [http://www.boost.org/doc/libs/release/libs/asio/ Boost.Asio]?&lt;br /&gt;
** More options here: http://stackoverflow.com/questions/118945/best-c-c-network-library&lt;br /&gt;
* Engines need to be split into client and server classes&lt;br /&gt;
** The original engines all still do that, even when not exposing anything to users&lt;br /&gt;
** NWN and NWN2 allow user multiplayer&lt;br /&gt;
&lt;br /&gt;
== Engines ==&lt;br /&gt;
&lt;br /&gt;
=== Script system ===&lt;br /&gt;
* ImperatorPrime had started on a script system rewrite&lt;br /&gt;
** Includes functions with real signatures&lt;br /&gt;
** Maybe switch to that, if it works&lt;br /&gt;
* Rounds, object heartbeat scripts&lt;br /&gt;
* KotOR2 and NWN2 have some extensions&lt;br /&gt;
** It seems like they don&#039;t need any extensions to the low-level bytecode stuff&lt;br /&gt;
* Witcher uses Lua scripts together with NWScript&lt;br /&gt;
* Sonic has no scripts at all, it seems&lt;br /&gt;
* Currently a script in an infinite loop locks the game thread&lt;br /&gt;
** Timeout? Asynchronous script execution?&lt;br /&gt;
&lt;br /&gt;
=== NWN ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Basics are there, but needs fleshing out&lt;br /&gt;
** Supermanu is working on the character generator&lt;br /&gt;
* [[Pathfinding]], walkmesh&lt;br /&gt;
** &amp;quot;Moving&amp;quot; should move the PC, not the camera&lt;br /&gt;
** NPC walking&lt;br /&gt;
** Triggers, areas on the floor that calls scripts on enter/leave&lt;br /&gt;
* Models&lt;br /&gt;
** ASCII models need averaging of smooth group normals&lt;br /&gt;
* NWN objects need an inventory concept&lt;br /&gt;
** Player characters&#039; might be different&lt;br /&gt;
*** Inventory tetris&lt;br /&gt;
*** Inventory item icons&lt;br /&gt;
* Multi-page asian fonts&lt;br /&gt;
* LanguageID 0 is not necessarily &amp;quot;English&amp;quot;, but &amp;quot;The language of the game install&amp;quot;&lt;br /&gt;
** This is okay for languages with Latin characters&lt;br /&gt;
** Messes up strings in community modules with Asian languages that stuff strings in to languageID 0&lt;br /&gt;
** The original fails there too, though&lt;br /&gt;
&lt;br /&gt;
=== KotOR/KotOR2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Basic structure is already there, just missing most of the specific widgets stuff&lt;br /&gt;
** Semi-hardcoded, with GFF files (hierachical data, similar to XML in spirit) describing the setup. The xoreos-tools repository has a tool for converting GFF files into XML for easy reading.&lt;br /&gt;
* Dialogues&lt;br /&gt;
** DLG files, similar to NWN&lt;br /&gt;
** Some extensions, like camera setup&lt;br /&gt;
** Dialogues are displayed very different than NWN&lt;br /&gt;
** KotOR2 has script extensions&lt;br /&gt;
*** Passing parameters to scripts&lt;br /&gt;
*** Call several scripts, combine with AND/OR for branching&lt;br /&gt;
* Animations&lt;br /&gt;
** Should be similar to NWN&lt;br /&gt;
** No player character shown&lt;br /&gt;
*** Needs character creator menus&lt;br /&gt;
*** Loading of character files in class Creature&lt;br /&gt;
* Minigames&lt;br /&gt;
** Swoop racing&lt;br /&gt;
** Pazaak&lt;br /&gt;
** Hardcoded, mostly removed from usual game logic&lt;br /&gt;
&lt;br /&gt;
=== Jade Empire ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Apparently very similar to KotOR&#039;s menus&lt;br /&gt;
* Minigames&lt;br /&gt;
** Flyer, top-down shoot-em-up thing&lt;br /&gt;
** Hardcoded, mostly removed from usual game logic&lt;br /&gt;
* Player character&lt;br /&gt;
** Needs research&lt;br /&gt;
* Sound&lt;br /&gt;
** Uses an ASCII variant of the [http://wiki.multimedia.cx/index.php?title=XACT XACT formats]&lt;br /&gt;
*** Cues probably not as complex as FMOD/Wwise&lt;br /&gt;
*** Effects need extension of the Sound system, maybe&lt;br /&gt;
** Xbox version might use the binary format?&lt;br /&gt;
*** Sound banks could be handles as archives and indexed in the ResourceManager?&lt;br /&gt;
** [https://github.com/FNA-XNA/FNA/tree/master/src/Audio FNA] has an implementation of XACT. Probably quite useful to look at that&lt;br /&gt;
&lt;br /&gt;
=== NWN2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Implemented using XML&lt;br /&gt;
** See [[#Broken NWN2 XML|Broken NWN2 XML]]&lt;br /&gt;
* Animations (Granny)&lt;br /&gt;
** [https://github.com/SkywingvL/nwn2dev-public nwn2-dev] contains some code working with Granny data&lt;br /&gt;
*** Call into the original Granny DLL to convert between binary and ASCII Granny data, though&lt;br /&gt;
** [https://github.com/berenm/xoreos-tools/tree/granny berenm started some Granny RE]&lt;br /&gt;
* Facial animations (FaceFX)&lt;br /&gt;
* Trees (SpeedTree)&lt;br /&gt;
* Proper evaluation of creature model parts (equipped items)&lt;br /&gt;
* Player character&lt;br /&gt;
** Reading of PC files in creature&lt;br /&gt;
&lt;br /&gt;
=== Sonic Chronicles ===&lt;br /&gt;
* Allow using the contents from an extracted NDS file?&lt;br /&gt;
* Menus&lt;br /&gt;
** GUI files that are GFF&lt;br /&gt;
** Actions in a state machine in GDA files?&lt;br /&gt;
* Music/Sound&lt;br /&gt;
** Music is apparently similar to MIDI, or to a tracker format?&lt;br /&gt;
** Sounds and instruments for music are in a sound_data.sadl archive&lt;br /&gt;
* Animations&lt;br /&gt;
** Bone animations, best implemented with shaders, blocked by the graphics subsystem rewrite&lt;br /&gt;
* Player character(s)&lt;br /&gt;
** Needs research&lt;br /&gt;
&lt;br /&gt;
=== The Witcher ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Apparently build using Lua&lt;br /&gt;
** System/Scripts/ has gui*.luc files&lt;br /&gt;
* Animations&lt;br /&gt;
** Needs research&lt;br /&gt;
* Player character, Geralt&lt;br /&gt;
** Needs research&lt;br /&gt;
&lt;br /&gt;
=== Dragon Age: Origins / Dragon Age 2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Scaleform_GFx Scaleform GFx]&lt;br /&gt;
** [http://social.bioware.com/wiki/datoolset/index.php/UI_Tutorial_%28draft%29 UI Tutorial] on the Dragon Age toolset wiki&lt;br /&gt;
** Flash-based!&lt;br /&gt;
** A good starting point for a reimplementation might be [https://en.wikipedia.org/wiki/Gameswf Gameswf].&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Gnash Gnash], [https://en.wikipedia.org/wiki/Lightspark Lightspark], [https://en.wikipedia.org/wiki/Swfdec Swfdec]&lt;br /&gt;
** [http://www.nowrap.de/flasm.html Flasm] can disassemble/assemble ActionScript, [http://www.nowrap.de/flare.html Flare] can decompile it&lt;br /&gt;
** [https://wwwimages2.adobe.com/content/dam/acom/en/devnet/pdf/swf-file-format-spec.pdf swf-file-format-spec.pdf] is a great reference which covers mostly every aspect of the gfx files.&lt;br /&gt;
** [https://github.com/jindrapetrik/jpexs-decompiler jpexs-decompiler] can decompile and handles scaleform specific tags.&lt;br /&gt;
* Animations&lt;br /&gt;
** Bone animations, best implemented with shaders, blocked by the graphics subsystem rewrite&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=TODO&amp;diff=350</id>
		<title>TODO</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=TODO&amp;diff=350"/>
		<updated>2018-05-15T21:47:21Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* Autotools */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a long rambly list of things left to do in xoreos and xoreos-tools. Anybody is welcome to tackle any of these tasks, but please also read our [[Developer_Central|general contributor overview]], including our [[Code_Formatting_Conventions|Code Formatting Conventions]], [[Commit_Guidelines|Commit Guidelines]] and [https://github.com/xoreos/xoreos/blob/master/CODE_OF_CONDUCT.md Code of Conduct]. If you plan to do any of these tasks, please also [[Contact_us|contact us]] beforehand, so we can better coordinate multiple people interested in doing the same task, and discuss how to best solve the problem. Thanks. :)&lt;br /&gt;
&lt;br /&gt;
(&#039;&#039;&#039;See also:&#039;&#039;&#039; the Kanban-like &amp;quot;Projects&amp;quot; boards on GitHub: https://github.com/orgs/xoreos/projects, but they&#039;re not public and no way to make public at the moment. Boo.)&lt;br /&gt;
&lt;br /&gt;
== Documentation ==&lt;br /&gt;
&lt;br /&gt;
=== Developer information ===&lt;br /&gt;
* Extend the developer information on the wiki&lt;br /&gt;
** Explain how to get the xoreos sources on various platforms&lt;br /&gt;
** Expand GNU/Linux compiling instructions to cover more distributions&lt;br /&gt;
** Expand Mac OS X compiling instructions&lt;br /&gt;
*** Xcode&lt;br /&gt;
*** Homebrew/MacPorts/Fink&lt;br /&gt;
*** CMake, Libraries&lt;br /&gt;
** [http://wiki.arx-libertatis.org/Developer_Information Arx Libertatis] has an extensive dev page&lt;br /&gt;
* Document file formats on the wiki?&lt;br /&gt;
** Or integrate info into XentaxWiki?&lt;br /&gt;
** Both?&lt;br /&gt;
&lt;br /&gt;
=== User information ===&lt;br /&gt;
* More user information on the wiki&lt;br /&gt;
** How to download xoreos&lt;br /&gt;
** How to install the games on various platforms&lt;br /&gt;
** [http://wiki.arx-libertatis.org/Main_Page Arx Libertatis] does that pretty well&lt;br /&gt;
&lt;br /&gt;
=== Modder information ===&lt;br /&gt;
* Link to relevant modding resources&lt;br /&gt;
* Maybe even some kind of Modder&#039;s Handbook&lt;br /&gt;
** A big overview of modding Aurora games in general&lt;br /&gt;
*** Differences and commonalities between games&lt;br /&gt;
** Linking/Grouping engine functions between games&lt;br /&gt;
&lt;br /&gt;
== Website ==&lt;br /&gt;
&lt;br /&gt;
=== Design ===&lt;br /&gt;
* Better website design?&lt;br /&gt;
** It still should be static in the end&lt;br /&gt;
*** No PHP or Rails&lt;br /&gt;
*** Very light on JavaScript&lt;br /&gt;
*** No Flash!&lt;br /&gt;
** Maybe a bit more unique, graphical&lt;br /&gt;
** For legal reasons, we shouldn&#039;t directly use art or designs from the original games&lt;br /&gt;
*** Something inspired by the art of the orginal games would fit&lt;br /&gt;
&lt;br /&gt;
=== Octopress ===&lt;br /&gt;
* Move away from Octopress?&lt;br /&gt;
** Alternative should still produce static HTML somehow&lt;br /&gt;
** Octopress works rather well. It reads Markdown, which is a plus&lt;br /&gt;
* Octopress 3.0?&lt;br /&gt;
** Not finished yet, it seems&lt;br /&gt;
&lt;br /&gt;
== Standalone(ish) fixes/improvements ==&lt;br /&gt;
&lt;br /&gt;
=== Broken NWN2 XML ===&lt;br /&gt;
* Not standards-conforming XML. Need custom XML parser; stock XML parsing libraries will just throw errors.&lt;br /&gt;
** &amp;lt;nowiki&amp;gt;&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;NWN2UI&amp;quot;&amp;gt;&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
** No single root element&lt;br /&gt;
** Attribute values not enclosed in quotes most of the time&lt;br /&gt;
** Special characters in attribute values not properly escaped&lt;br /&gt;
** Unmatched quotes on several occasions&lt;br /&gt;
* Event functions&lt;br /&gt;
* Special values like PARENT_WIDTH&lt;br /&gt;
* [https://github.com/xoreos/xoreos-tools/pull/1 Altrite is working on a broken-XML fixer]&lt;br /&gt;
&lt;br /&gt;
=== CJK glyphs in the console ===&lt;br /&gt;
* The &amp;quot;system font&amp;quot; we use for our debug console, DejaVu Sans Mono Bold, does not feature any CJK (Chinese, Japanese, Korean) glyphs&lt;br /&gt;
* Not strictly necessary, but nice to have for printing, say, Witcher area names in Asian languages&lt;br /&gt;
* We could maybe integrate CJK glyphs from the [http://fonts.jp/hanazono/ Hanazono fonts] or other suitable libre fonts&lt;br /&gt;
* We need to match the height with DejaVu Sans Mono Bold&lt;br /&gt;
* CJK glyphs tend to be more complex and therefore wider. They&#039;re usually rendered twice as wide as Latin glyphs&lt;br /&gt;
* Our console code needs to take that into account&lt;br /&gt;
&lt;br /&gt;
=== Fuzzing ===&lt;br /&gt;
* Run our file readers, image decoders, etc. through a fuzzer, like [http://lcamtuf.coredump.cx/afl/ afl] (american fuzzy lop)&lt;br /&gt;
* Fix any cases where it crashes&lt;br /&gt;
* The xoreos-tools might be a good starting point for singular, standalone testing&lt;br /&gt;
** For image decoders, a slightly modified xoreostex2tga tool might work&lt;br /&gt;
* File formats already fuzzed:&lt;br /&gt;
** CBGT, CDPTH, DDS, NBFS, NCGR, NCLR, SBM, TGA, TPC, TXB&lt;br /&gt;
** 2DA, KEY/BIF, ERF, GFF3, GFF4, GDA, TLK, NSBTX, RIM, SMALL, SSF&lt;br /&gt;
&lt;br /&gt;
=== Script decompiler ===&lt;br /&gt;
* It might be quite useful to have a NWScript decompiler in xoreos-tools&lt;br /&gt;
* We have a script disassembler, ncsdis&lt;br /&gt;
** Which already does code flow analysis&lt;br /&gt;
* Missing:&lt;br /&gt;
** Code generation&lt;br /&gt;
** Collapsing of instruction chains into single-line NWScript code&lt;br /&gt;
*** For example, &amp;quot;int var = foo * bar + quux&amp;quot; compiles to a long chain with multiple temporaries&lt;br /&gt;
** Proper handling of structs and vectors&lt;br /&gt;
&lt;br /&gt;
=== Script compiler ===&lt;br /&gt;
* An NWScript compiler might be useful as well&lt;br /&gt;
** A script assembler might be an easy first step&lt;br /&gt;
&lt;br /&gt;
=== File format writers ===&lt;br /&gt;
* GFF3Writer, GFF4Writer&lt;br /&gt;
** Both necessary to create save games compatible with the original games&lt;br /&gt;
** Also useful for a xml2gff tool&lt;br /&gt;
* xml2tlk&lt;br /&gt;
** TalkTable_GFF::write02() and ::write05()&lt;br /&gt;
** Needs GFF4Writer&lt;br /&gt;
* Archive (ERF, RIM, KEY/BIF) packers?&lt;br /&gt;
&lt;br /&gt;
=== Config file ===&lt;br /&gt;
* Should be more preserving of the layout&lt;br /&gt;
** Especially empty lines&lt;br /&gt;
** UTF-8 Byte-Order-Mark when using native Windows editors&lt;br /&gt;
** \r is currently always stripped. Maybe preserve that too&lt;br /&gt;
*** Autodetect when \r is already used, and add it to new config lines too&lt;br /&gt;
** This basically needs a complete rewrite of the config parser&lt;br /&gt;
*** Don&#039;t just look for comments, just throw everything after &amp;quot;foo=bar&amp;quot; into the &amp;quot;comment&amp;quot; variable, including whitespace&lt;br /&gt;
*** And all whitespace before &amp;quot;foo=bar&amp;quot; into a &amp;quot;prefix&amp;quot; variable&lt;br /&gt;
** Maybe even always add BOM and \r when writing a new config file on Windows?&lt;br /&gt;
&lt;br /&gt;
=== Windows-specific / Wine-specific ===&lt;br /&gt;
* When running my mingw32 cross-compiled xoreos EXE in Wine, the menu button texts are partially cut off&lt;br /&gt;
** Z-fighting issue?&lt;br /&gt;
** Does that also occur on a real Windows?&lt;br /&gt;
&lt;br /&gt;
=== GUI ===&lt;br /&gt;
* xoreos could use a global GUI to start games from&lt;br /&gt;
* Should probably be similar to ScummVM&#039;s GUI, at least in effect&lt;br /&gt;
* Should read the config file, list all targets&lt;br /&gt;
** Press a &amp;quot;Play&amp;quot; button to play the game&lt;br /&gt;
** Press an &amp;quot;Edit&amp;quot; button to edit the entry&lt;br /&gt;
*** Dialog options to edit common settings&lt;br /&gt;
*** An additional free-form editor?&lt;br /&gt;
*** Game-specific options?&lt;br /&gt;
** A button to edit global settings (&amp;quot;xoreos&amp;quot; config domain)&lt;br /&gt;
** For the future, a way to immediately load a saved game?&lt;br /&gt;
** An &amp;quot;Add&amp;quot; button to add a game&lt;br /&gt;
*** File browser&lt;br /&gt;
**** Select directories for most game&lt;br /&gt;
**** Select file for Sonic Chronicles&lt;br /&gt;
*** View current saved games of a target?&lt;br /&gt;
* Probably implemented using OpenGL, just like, say, the console&lt;br /&gt;
* Theme-able/Skinable?&lt;br /&gt;
* Some potential stumbling blocks&lt;br /&gt;
** Displaying &amp;quot;uncommon&amp;quot; text in both game descriptions and file paths&lt;br /&gt;
*** &amp;quot;Decomposed&amp;quot; letters, i.e. base letter + combining glyphs&lt;br /&gt;
*** CJK&lt;br /&gt;
*** Arabic and other scripts where letters change depending on their place in the word&lt;br /&gt;
*** Right-to-left&lt;br /&gt;
** Shortening those strings when they don&#039;t fit in their fields is also potentially difficult&lt;br /&gt;
&lt;br /&gt;
=== Localization ===&lt;br /&gt;
* Text in exceptions?&lt;br /&gt;
** At least the user-visible ones, like &amp;quot;Failed to detect game&amp;quot;&lt;br /&gt;
** Or maybe we should clean that up and split them into &amp;quot;program logic failure&amp;quot; and &amp;quot;user failure&amp;quot;, with only the latter translated&lt;br /&gt;
* Strings for the engine loader progress bar&lt;br /&gt;
* Debug console string&lt;br /&gt;
* GUI (see above) strings&lt;br /&gt;
* [http://www.gnu.org/software/gettext/ GNU gettext] would be one solution&lt;br /&gt;
&lt;br /&gt;
=== Unit tests ===&lt;br /&gt;
* More unit tests&lt;br /&gt;
&lt;br /&gt;
=== Resource Explorer ===&lt;br /&gt;
* A portable, user-friendly graphical resource explorer could be useful&lt;br /&gt;
* [https://github.com/xoreos/phaethon Phaethon] is a start&lt;br /&gt;
** It can look into game archives, show textures and play sounds&lt;br /&gt;
** It uses [https://www.wxwidgets.org/ wxWidgets] to do the GUI&lt;br /&gt;
** Or possibly rewriting it to use [https://www.qt.io/ Qt] is better?&lt;br /&gt;
&lt;br /&gt;
=== Model converters ===&lt;br /&gt;
* Document the model formats&lt;br /&gt;
* Convert between the binary model formats and their ASCII equivalents&lt;br /&gt;
* Convert between the binary model formats and ones that can be opened by modelling tools&lt;br /&gt;
** 3D Studio Max&lt;br /&gt;
** Blender&lt;br /&gt;
&lt;br /&gt;
=== Full-fledged modding toolset ===&lt;br /&gt;
* Similar to the NWN, NWN2 or Witcher toolset, but portable and FLOSS&lt;br /&gt;
** Might also support other games?&lt;br /&gt;
* Out of scope for xoreos&lt;br /&gt;
** Still, such a thing would be welcome under the xoreos banner&lt;br /&gt;
* [http://sourceforge.net/projects/neveredit/ Neveredit] might still be worth a look&lt;br /&gt;
&lt;br /&gt;
== Build system ==&lt;br /&gt;
&lt;br /&gt;
=== CMake ===&lt;br /&gt;
* Current doesn&#039;t set the git version to &amp;quot;+unk&amp;quot; when git isn&#039;t found&lt;br /&gt;
* make install/uninstall?&lt;br /&gt;
* make doxygen?&lt;br /&gt;
&lt;br /&gt;
=== Autotools ===&lt;br /&gt;
* Suppress the &amp;quot;fatal: not a git repository&amp;quot; when building gitstamp without a git directory&lt;br /&gt;
* Increased modularity&lt;br /&gt;
** Disabling engines&lt;br /&gt;
** Making library dependencies optional (and disabling certain features, then)&lt;br /&gt;
*** liblzma? Only needed for the iOS version of KotOR&lt;br /&gt;
*** libxml2? Only needed for the two Dragon Age games&lt;br /&gt;
** When something is disabled, skip it, if possible&lt;br /&gt;
*** Like the videos in KotOR Mac&lt;br /&gt;
** If skipping is not possible, error out&lt;br /&gt;
&lt;br /&gt;
== Nitro ==&lt;br /&gt;
&lt;br /&gt;
* The Nintendo DS (Nitro) specific file formats should probably be moved out of src/aurora/ and into src/nitro&lt;br /&gt;
* nitrofile, cdpth, nsbtx, smallfile&lt;br /&gt;
** nsbtx needs to be split into a class accessing the textures in src/nitro/ and an archive class on top in src/aurora/&lt;br /&gt;
** This means src/aurora/ accesses src/nitro/, so libnitro.la needs to come after libaurora.la in the linking order&lt;br /&gt;
* ndsrom as well?&lt;br /&gt;
* What about nftrfont and model_sonic in src/graphics/aurora/?&lt;br /&gt;
** src/graphics/nitro/?&lt;br /&gt;
** This would have src/graphics/nitro/ access src/graphics/aurora/, so graphics/libnitro.la needs to come before graphics/libaurora.la in the linking order&lt;br /&gt;
** That would be the other way round than for src/nitro/. Too confusing?&lt;br /&gt;
&lt;br /&gt;
== Graphics ==&lt;br /&gt;
&lt;br /&gt;
=== MDL supermodels and animations ===&lt;br /&gt;
* Mostly working in NWN thanks to jbowtie&#039;s work&lt;br /&gt;
* Might need some cleanup&lt;br /&gt;
* Animation scale is off in a lot of cases. Mostly visible in the talking and yawning animations in non-human characters&lt;br /&gt;
* Models should smoothly change between different animations&lt;br /&gt;
* The animation system probably needs to be a bit more complex, to allow for &amp;quot;overlaying&amp;quot; different animations onto each other. For example, for speaking while holding an object and keeping the head focused on the PC character.&lt;br /&gt;
&lt;br /&gt;
=== Lighting ===&lt;br /&gt;
* We don&#039;t yet have a proper light system&lt;br /&gt;
* I started working on it: [https://drmccoy.de/xoreos/20150809T223407.png], but my approach is seriously lacking. You can see the edges of the tiles that make up on NWN area in many cases ([https://drmccoy.de/xoreos/20150809T223507.png], [https://drmccoy.de/xoreos/20150809T223548.png])&lt;br /&gt;
** See the [https://github.com/xoreos/xoreos/tree/light light branch] in the git repository&lt;br /&gt;
** Of course, the actual glLight* stuff won&#039;t be relevant anymore as soon as shaders are there&lt;br /&gt;
** Lighting in several (ASCII?) area tiles is broken&lt;br /&gt;
*** The door in Prelude.nwm&#039;s &amp;quot;m0q1a&amp;quot; area&lt;br /&gt;
*** A water tile in Chapter2.nwm&#039;s &amp;quot;map_m2q1a&amp;quot; area&lt;br /&gt;
*** A sloped snow tile in XP2_Chapter3.nwm&#039;s &amp;quot;thecityoflostsou&amp;quot;&lt;br /&gt;
&lt;br /&gt;
=== Materials ===&lt;br /&gt;
* Materials in The Witcher are closely tied to shaders&lt;br /&gt;
&lt;br /&gt;
=== OpenGL and Shaders ===&lt;br /&gt;
* mirv_ is currently working on a graphics system overhaul, complete with shader support&lt;br /&gt;
* All Aurora games use shaders in some form&lt;br /&gt;
* NWN uses ARB shaders. We probably need to rewrite them from scratch&lt;br /&gt;
* DirectX shaders might be automatically convertible with Cg?&lt;br /&gt;
* Otherwise, look at what Wine does with the shaders, and use that as a basis?&lt;br /&gt;
* All the games, even NWN, use some form of shaders. Still totally missing from xoreos, since we have no idea how to use them in general yet. Moreover, this was before GLSL, so they&#039;re in the old assembly-like language. We probably need to rewrite them from scratch&lt;br /&gt;
* We need shaders for tinting in NWN2 (objects and area geometry) and TexturePaint nodes in Witcher&lt;br /&gt;
&lt;br /&gt;
=== SDL 1.2 ===&lt;br /&gt;
* Optionally link against SDL 1.2 instead of SDL 2&lt;br /&gt;
* Should ideally use a configure flag to select between the two&lt;br /&gt;
** Maybe a CMake flag as well, if possible&lt;br /&gt;
* Assigned to clone2727, so anybody interested in this should coordinate with him&lt;br /&gt;
&lt;br /&gt;
== Videos ==&lt;br /&gt;
&lt;br /&gt;
=== XMV/WMV ===&lt;br /&gt;
* Used in Xbox versions of KotOR/KotOR2&lt;br /&gt;
* Our WMV decoder (for XMV videos used in Xbox versions) is missing P-frames and J-frame&lt;br /&gt;
** Code exists in ffmpeg, but is connected to the MPEG-4 family mess&lt;br /&gt;
&lt;br /&gt;
=== Actimagine VX ===&lt;br /&gt;
* Used in the Nintendo DS game Sonic Chronicles&lt;br /&gt;
* https://wiki.multimedia.cx/index.php?title=Actimagine_Video_Codec&lt;br /&gt;
&lt;br /&gt;
=== Sorenson 3 ===&lt;br /&gt;
* One single video in the Mac port of KotOR2, the Aspyr logo, uses the Sorenson 3 codec&lt;br /&gt;
** ffmpeg has a decoder, but it&#039;s connected to the MPEG-4 family mess (SVQ3 is similar to H.264)&lt;br /&gt;
* ScummVM needs that too&lt;br /&gt;
** While xoreos is GPLv3+, ScummVM is GPLv2+&lt;br /&gt;
** Somebody implementing Sorenson 3 for xoreos should ideally give explicit permission to relicense it GPLv2+ for ScummVM&lt;br /&gt;
*** Of course, if the decoder is based on prior work by other people, it has to be compatible with both GPLv2+ and GPLv3+&lt;br /&gt;
&lt;br /&gt;
=== Optimizations ===&lt;br /&gt;
* Optimize our simple BitStream interface&lt;br /&gt;
** See [https://fgiesen.wordpress.com/2016/01/02/end-of-buffer-checks-in-decompressors/ this blog post]&lt;br /&gt;
** Specifically, we don&#039;t do any peeking at all&lt;br /&gt;
** It still needs to handle different memory layouts, though&lt;br /&gt;
* Likewise, our Huffman class could probably be tuned a lot&lt;br /&gt;
* Pull in fft/rdft/dct/mdct optimizations from FFmpeg?&lt;br /&gt;
&lt;br /&gt;
== Sound ==&lt;br /&gt;
&lt;br /&gt;
=== FMOD ===&lt;br /&gt;
* Dragon Age: Origins uses FMOD for sound and music&lt;br /&gt;
* I have experimental FSB (FMOD sound bank) support working in a private branch&lt;br /&gt;
* FEV (FMOD events) format is still unknown to us&lt;br /&gt;
** Apparently, groups of event lists with events&lt;br /&gt;
** Event is everything from &amp;quot;play sound&amp;quot;, over &amp;quot;set volume&amp;quot; to &amp;quot;apply echo&amp;quot;&lt;br /&gt;
** Game areas specify the group to use for the area&lt;br /&gt;
** Scripts then probably tell FMOD to play event lists out of that group&lt;br /&gt;
&lt;br /&gt;
=== Wwise ===&lt;br /&gt;
* Dragon Age 2 uses Wwise for sound and music&lt;br /&gt;
* Should be similar in concept to FMD&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
=== Gamepad binding ===&lt;br /&gt;
* The Xbox versions of KotOR and KotOR2 don&#039;t use a mouse. We have basic support for joysticks/gamepads, but no real bindings to the engine or ideas how to handle that in general&lt;br /&gt;
* We might want to handle the controller support the new KotOR2 Steam update brought&lt;br /&gt;
** override folder contains a gamepad.txt then&lt;br /&gt;
* Also hack in controller support for a non-Steam KotOR2? And for KotOR?&lt;br /&gt;
* Controller support in Jade Empire&lt;br /&gt;
* Controller support for Sonic? It is a Nintendo DS game after all&lt;br /&gt;
* Controller support for the non-console versions of the Dragon Age games?&lt;br /&gt;
&lt;br /&gt;
== Network ==&lt;br /&gt;
* We need a network subsystem&lt;br /&gt;
** [https://www.libsdl.org/projects/SDL_net/ SDL_net]?&lt;br /&gt;
** [http://www.boost.org/doc/libs/release/libs/asio/ Boost.Asio]?&lt;br /&gt;
** More options here: http://stackoverflow.com/questions/118945/best-c-c-network-library&lt;br /&gt;
* Engines need to be split into client and server classes&lt;br /&gt;
** The original engines all still do that, even when not exposing anything to users&lt;br /&gt;
** NWN and NWN2 allow user multiplayer&lt;br /&gt;
&lt;br /&gt;
== Engines ==&lt;br /&gt;
&lt;br /&gt;
=== Script system ===&lt;br /&gt;
* ImperatorPrime had started on a script system rewrite&lt;br /&gt;
** Includes functions with real signatures&lt;br /&gt;
** Maybe switch to that, if it works&lt;br /&gt;
* Rounds, object heartbeat scripts&lt;br /&gt;
* KotOR2 and NWN2 have some extensions&lt;br /&gt;
** It seems like they don&#039;t need any extensions to the low-level bytecode stuff&lt;br /&gt;
* Witcher uses Lua scripts together with NWScript&lt;br /&gt;
* Sonic has no scripts at all, it seems&lt;br /&gt;
* Currently a script in an infinite loop locks the game thread&lt;br /&gt;
** Timeout? Asynchronous script execution?&lt;br /&gt;
&lt;br /&gt;
=== NWN ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Basics are there, but needs fleshing out&lt;br /&gt;
** Supermanu is working on the character generator&lt;br /&gt;
* [[Pathfinding]], walkmesh&lt;br /&gt;
** &amp;quot;Moving&amp;quot; should move the PC, not the camera&lt;br /&gt;
** NPC walking&lt;br /&gt;
** Triggers, areas on the floor that calls scripts on enter/leave&lt;br /&gt;
* Models&lt;br /&gt;
** ASCII models need averaging of smooth group normals&lt;br /&gt;
* NWN objects need an inventory concept&lt;br /&gt;
** Player characters&#039; might be different&lt;br /&gt;
*** Inventory tetris&lt;br /&gt;
*** Inventory item icons&lt;br /&gt;
* Multi-page asian fonts&lt;br /&gt;
* LanguageID 0 is not necessarily &amp;quot;English&amp;quot;, but &amp;quot;The language of the game install&amp;quot;&lt;br /&gt;
** This is okay for languages with Latin characters&lt;br /&gt;
** Messes up strings in community modules with Asian languages that stuff strings in to languageID 0&lt;br /&gt;
** The original fails there too, though&lt;br /&gt;
&lt;br /&gt;
=== KotOR/KotOR2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Basic structure is already there, just missing most of the specific widgets stuff&lt;br /&gt;
** Semi-hardcoded, with GFF files (hierachical data, similar to XML in spirit) describing the setup. The xoreos-tools repository has a tool for converting GFF files into XML for easy reading.&lt;br /&gt;
* Dialogues&lt;br /&gt;
** DLG files, similar to NWN&lt;br /&gt;
** Some extensions, like camera setup&lt;br /&gt;
** Dialogues are displayed very different than NWN&lt;br /&gt;
** KotOR2 has script extensions&lt;br /&gt;
*** Passing parameters to scripts&lt;br /&gt;
*** Call several scripts, combine with AND/OR for branching&lt;br /&gt;
* Animations&lt;br /&gt;
** Should be similar to NWN&lt;br /&gt;
** No player character shown&lt;br /&gt;
*** Needs character creator menus&lt;br /&gt;
*** Loading of character files in class Creature&lt;br /&gt;
* Minigames&lt;br /&gt;
** Swoop racing&lt;br /&gt;
** Pazaak&lt;br /&gt;
** Hardcoded, mostly removed from usual game logic&lt;br /&gt;
&lt;br /&gt;
=== Jade Empire ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Apparently very similar to KotOR&#039;s menus&lt;br /&gt;
* Minigames&lt;br /&gt;
** Flyer, top-down shoot-em-up thing&lt;br /&gt;
** Hardcoded, mostly removed from usual game logic&lt;br /&gt;
* Player character&lt;br /&gt;
** Needs research&lt;br /&gt;
* Sound&lt;br /&gt;
** Uses an ASCII variant of the [http://wiki.multimedia.cx/index.php?title=XACT XACT formats]&lt;br /&gt;
*** Cues probably not as complex as FMOD/Wwise&lt;br /&gt;
*** Effects need extension of the Sound system, maybe&lt;br /&gt;
** Xbox version might use the binary format?&lt;br /&gt;
*** Sound banks could be handles as archives and indexed in the ResourceManager?&lt;br /&gt;
** [https://github.com/FNA-XNA/FNA/tree/master/src/Audio FNA] has an implementation of XACT. Probably quite useful to look at that&lt;br /&gt;
&lt;br /&gt;
=== NWN2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Implemented using XML&lt;br /&gt;
** See [[#Broken NWN2 XML|Broken NWN2 XML]]&lt;br /&gt;
* Animations (Granny)&lt;br /&gt;
** [https://github.com/SkywingvL/nwn2dev-public nwn2-dev] contains some code working with Granny data&lt;br /&gt;
*** Call into the original Granny DLL to convert between binary and ASCII Granny data, though&lt;br /&gt;
** [https://github.com/berenm/xoreos-tools/tree/granny berenm started some Granny RE]&lt;br /&gt;
* Facial animations (FaceFX)&lt;br /&gt;
* Trees (SpeedTree)&lt;br /&gt;
* Proper evaluation of creature model parts (equipped items)&lt;br /&gt;
* Player character&lt;br /&gt;
** Reading of PC files in creature&lt;br /&gt;
&lt;br /&gt;
=== Sonic Chronicles ===&lt;br /&gt;
* Allow using the contents from an extracted NDS file?&lt;br /&gt;
* Menus&lt;br /&gt;
** GUI files that are GFF&lt;br /&gt;
** Actions in a state machine in GDA files?&lt;br /&gt;
* Music/Sound&lt;br /&gt;
** Music is apparently similar to MIDI, or to a tracker format?&lt;br /&gt;
** Sounds and instruments for music are in a sound_data.sadl archive&lt;br /&gt;
* Animations&lt;br /&gt;
** Bone animations, best implemented with shaders, blocked by the graphics subsystem rewrite&lt;br /&gt;
* Player character(s)&lt;br /&gt;
** Needs research&lt;br /&gt;
&lt;br /&gt;
=== The Witcher ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Apparently build using Lua&lt;br /&gt;
** System/Scripts/ has gui*.luc files&lt;br /&gt;
* Animations&lt;br /&gt;
** Needs research&lt;br /&gt;
* Player character, Geralt&lt;br /&gt;
** Needs research&lt;br /&gt;
&lt;br /&gt;
=== Dragon Age: Origins / Dragon Age 2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Scaleform_GFx Scaleform GFx]&lt;br /&gt;
** [http://social.bioware.com/wiki/datoolset/index.php/UI_Tutorial_%28draft%29 UI Tutorial] on the Dragon Age toolset wiki&lt;br /&gt;
** Flash-based!&lt;br /&gt;
** A good starting point for a reimplementation might be [https://en.wikipedia.org/wiki/Gameswf Gameswf].&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Gnash Gnash], [https://en.wikipedia.org/wiki/Lightspark Lightspark], [https://en.wikipedia.org/wiki/Swfdec Swfdec]&lt;br /&gt;
** [http://www.nowrap.de/flasm.html Flasm] can disassemble/assemble ActionScript, [http://www.nowrap.de/flare.html Flare] can decompile it&lt;br /&gt;
** [https://wwwimages2.adobe.com/content/dam/acom/en/devnet/pdf/swf-file-format-spec.pdf swf-file-format-spec.pdf] is a great reference which covers mostly every aspect of the gfx files.&lt;br /&gt;
** [https://github.com/jindrapetrik/jpexs-decompiler jpexs-decompiler] can decompile and handles scaleform specific tags.&lt;br /&gt;
* Animations&lt;br /&gt;
** Bone animations, best implemented with shaders, blocked by the graphics subsystem rewrite&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
	<entry>
		<id>https://wiki.xoreos.org/index.php?title=TODO&amp;diff=349</id>
		<title>TODO</title>
		<link rel="alternate" type="text/html" href="https://wiki.xoreos.org/index.php?title=TODO&amp;diff=349"/>
		<updated>2018-05-15T21:45:47Z</updated>

		<summary type="html">&lt;p&gt;DrMcCoy: /* CMake */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a long rambly list of things left to do in xoreos and xoreos-tools. Anybody is welcome to tackle any of these tasks, but please also read our [[Developer_Central|general contributor overview]], including our [[Code_Formatting_Conventions|Code Formatting Conventions]], [[Commit_Guidelines|Commit Guidelines]] and [https://github.com/xoreos/xoreos/blob/master/CODE_OF_CONDUCT.md Code of Conduct]. If you plan to do any of these tasks, please also [[Contact_us|contact us]] beforehand, so we can better coordinate multiple people interested in doing the same task, and discuss how to best solve the problem. Thanks. :)&lt;br /&gt;
&lt;br /&gt;
(&#039;&#039;&#039;See also:&#039;&#039;&#039; the Kanban-like &amp;quot;Projects&amp;quot; boards on GitHub: https://github.com/orgs/xoreos/projects, but they&#039;re not public and no way to make public at the moment. Boo.)&lt;br /&gt;
&lt;br /&gt;
== Documentation ==&lt;br /&gt;
&lt;br /&gt;
=== Developer information ===&lt;br /&gt;
* Extend the developer information on the wiki&lt;br /&gt;
** Explain how to get the xoreos sources on various platforms&lt;br /&gt;
** Expand GNU/Linux compiling instructions to cover more distributions&lt;br /&gt;
** Expand Mac OS X compiling instructions&lt;br /&gt;
*** Xcode&lt;br /&gt;
*** Homebrew/MacPorts/Fink&lt;br /&gt;
*** CMake, Libraries&lt;br /&gt;
** [http://wiki.arx-libertatis.org/Developer_Information Arx Libertatis] has an extensive dev page&lt;br /&gt;
* Document file formats on the wiki?&lt;br /&gt;
** Or integrate info into XentaxWiki?&lt;br /&gt;
** Both?&lt;br /&gt;
&lt;br /&gt;
=== User information ===&lt;br /&gt;
* More user information on the wiki&lt;br /&gt;
** How to download xoreos&lt;br /&gt;
** How to install the games on various platforms&lt;br /&gt;
** [http://wiki.arx-libertatis.org/Main_Page Arx Libertatis] does that pretty well&lt;br /&gt;
&lt;br /&gt;
=== Modder information ===&lt;br /&gt;
* Link to relevant modding resources&lt;br /&gt;
* Maybe even some kind of Modder&#039;s Handbook&lt;br /&gt;
** A big overview of modding Aurora games in general&lt;br /&gt;
*** Differences and commonalities between games&lt;br /&gt;
** Linking/Grouping engine functions between games&lt;br /&gt;
&lt;br /&gt;
== Website ==&lt;br /&gt;
&lt;br /&gt;
=== Design ===&lt;br /&gt;
* Better website design?&lt;br /&gt;
** It still should be static in the end&lt;br /&gt;
*** No PHP or Rails&lt;br /&gt;
*** Very light on JavaScript&lt;br /&gt;
*** No Flash!&lt;br /&gt;
** Maybe a bit more unique, graphical&lt;br /&gt;
** For legal reasons, we shouldn&#039;t directly use art or designs from the original games&lt;br /&gt;
*** Something inspired by the art of the orginal games would fit&lt;br /&gt;
&lt;br /&gt;
=== Octopress ===&lt;br /&gt;
* Move away from Octopress?&lt;br /&gt;
** Alternative should still produce static HTML somehow&lt;br /&gt;
** Octopress works rather well. It reads Markdown, which is a plus&lt;br /&gt;
* Octopress 3.0?&lt;br /&gt;
** Not finished yet, it seems&lt;br /&gt;
&lt;br /&gt;
== Standalone(ish) fixes/improvements ==&lt;br /&gt;
&lt;br /&gt;
=== Broken NWN2 XML ===&lt;br /&gt;
* Not standards-conforming XML. Need custom XML parser; stock XML parsing libraries will just throw errors.&lt;br /&gt;
** &amp;lt;nowiki&amp;gt;&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;NWN2UI&amp;quot;&amp;gt;&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
** No single root element&lt;br /&gt;
** Attribute values not enclosed in quotes most of the time&lt;br /&gt;
** Special characters in attribute values not properly escaped&lt;br /&gt;
** Unmatched quotes on several occasions&lt;br /&gt;
* Event functions&lt;br /&gt;
* Special values like PARENT_WIDTH&lt;br /&gt;
* [https://github.com/xoreos/xoreos-tools/pull/1 Altrite is working on a broken-XML fixer]&lt;br /&gt;
&lt;br /&gt;
=== CJK glyphs in the console ===&lt;br /&gt;
* The &amp;quot;system font&amp;quot; we use for our debug console, DejaVu Sans Mono Bold, does not feature any CJK (Chinese, Japanese, Korean) glyphs&lt;br /&gt;
* Not strictly necessary, but nice to have for printing, say, Witcher area names in Asian languages&lt;br /&gt;
* We could maybe integrate CJK glyphs from the [http://fonts.jp/hanazono/ Hanazono fonts] or other suitable libre fonts&lt;br /&gt;
* We need to match the height with DejaVu Sans Mono Bold&lt;br /&gt;
* CJK glyphs tend to be more complex and therefore wider. They&#039;re usually rendered twice as wide as Latin glyphs&lt;br /&gt;
* Our console code needs to take that into account&lt;br /&gt;
&lt;br /&gt;
=== Fuzzing ===&lt;br /&gt;
* Run our file readers, image decoders, etc. through a fuzzer, like [http://lcamtuf.coredump.cx/afl/ afl] (american fuzzy lop)&lt;br /&gt;
* Fix any cases where it crashes&lt;br /&gt;
* The xoreos-tools might be a good starting point for singular, standalone testing&lt;br /&gt;
** For image decoders, a slightly modified xoreostex2tga tool might work&lt;br /&gt;
* File formats already fuzzed:&lt;br /&gt;
** CBGT, CDPTH, DDS, NBFS, NCGR, NCLR, SBM, TGA, TPC, TXB&lt;br /&gt;
** 2DA, KEY/BIF, ERF, GFF3, GFF4, GDA, TLK, NSBTX, RIM, SMALL, SSF&lt;br /&gt;
&lt;br /&gt;
=== Script decompiler ===&lt;br /&gt;
* It might be quite useful to have a NWScript decompiler in xoreos-tools&lt;br /&gt;
* We have a script disassembler, ncsdis&lt;br /&gt;
** Which already does code flow analysis&lt;br /&gt;
* Missing:&lt;br /&gt;
** Code generation&lt;br /&gt;
** Collapsing of instruction chains into single-line NWScript code&lt;br /&gt;
*** For example, &amp;quot;int var = foo * bar + quux&amp;quot; compiles to a long chain with multiple temporaries&lt;br /&gt;
** Proper handling of structs and vectors&lt;br /&gt;
&lt;br /&gt;
=== Script compiler ===&lt;br /&gt;
* An NWScript compiler might be useful as well&lt;br /&gt;
** A script assembler might be an easy first step&lt;br /&gt;
&lt;br /&gt;
=== File format writers ===&lt;br /&gt;
* GFF3Writer, GFF4Writer&lt;br /&gt;
** Both necessary to create save games compatible with the original games&lt;br /&gt;
** Also useful for a xml2gff tool&lt;br /&gt;
* xml2tlk&lt;br /&gt;
** TalkTable_GFF::write02() and ::write05()&lt;br /&gt;
** Needs GFF4Writer&lt;br /&gt;
* Archive (ERF, RIM, KEY/BIF) packers?&lt;br /&gt;
&lt;br /&gt;
=== Config file ===&lt;br /&gt;
* Should be more preserving of the layout&lt;br /&gt;
** Especially empty lines&lt;br /&gt;
** UTF-8 Byte-Order-Mark when using native Windows editors&lt;br /&gt;
** \r is currently always stripped. Maybe preserve that too&lt;br /&gt;
*** Autodetect when \r is already used, and add it to new config lines too&lt;br /&gt;
** This basically needs a complete rewrite of the config parser&lt;br /&gt;
*** Don&#039;t just look for comments, just throw everything after &amp;quot;foo=bar&amp;quot; into the &amp;quot;comment&amp;quot; variable, including whitespace&lt;br /&gt;
*** And all whitespace before &amp;quot;foo=bar&amp;quot; into a &amp;quot;prefix&amp;quot; variable&lt;br /&gt;
** Maybe even always add BOM and \r when writing a new config file on Windows?&lt;br /&gt;
&lt;br /&gt;
=== Windows-specific / Wine-specific ===&lt;br /&gt;
* When running my mingw32 cross-compiled xoreos EXE in Wine, the menu button texts are partially cut off&lt;br /&gt;
** Z-fighting issue?&lt;br /&gt;
** Does that also occur on a real Windows?&lt;br /&gt;
&lt;br /&gt;
=== GUI ===&lt;br /&gt;
* xoreos could use a global GUI to start games from&lt;br /&gt;
* Should probably be similar to ScummVM&#039;s GUI, at least in effect&lt;br /&gt;
* Should read the config file, list all targets&lt;br /&gt;
** Press a &amp;quot;Play&amp;quot; button to play the game&lt;br /&gt;
** Press an &amp;quot;Edit&amp;quot; button to edit the entry&lt;br /&gt;
*** Dialog options to edit common settings&lt;br /&gt;
*** An additional free-form editor?&lt;br /&gt;
*** Game-specific options?&lt;br /&gt;
** A button to edit global settings (&amp;quot;xoreos&amp;quot; config domain)&lt;br /&gt;
** For the future, a way to immediately load a saved game?&lt;br /&gt;
** An &amp;quot;Add&amp;quot; button to add a game&lt;br /&gt;
*** File browser&lt;br /&gt;
**** Select directories for most game&lt;br /&gt;
**** Select file for Sonic Chronicles&lt;br /&gt;
*** View current saved games of a target?&lt;br /&gt;
* Probably implemented using OpenGL, just like, say, the console&lt;br /&gt;
* Theme-able/Skinable?&lt;br /&gt;
* Some potential stumbling blocks&lt;br /&gt;
** Displaying &amp;quot;uncommon&amp;quot; text in both game descriptions and file paths&lt;br /&gt;
*** &amp;quot;Decomposed&amp;quot; letters, i.e. base letter + combining glyphs&lt;br /&gt;
*** CJK&lt;br /&gt;
*** Arabic and other scripts where letters change depending on their place in the word&lt;br /&gt;
*** Right-to-left&lt;br /&gt;
** Shortening those strings when they don&#039;t fit in their fields is also potentially difficult&lt;br /&gt;
&lt;br /&gt;
=== Localization ===&lt;br /&gt;
* Text in exceptions?&lt;br /&gt;
** At least the user-visible ones, like &amp;quot;Failed to detect game&amp;quot;&lt;br /&gt;
** Or maybe we should clean that up and split them into &amp;quot;program logic failure&amp;quot; and &amp;quot;user failure&amp;quot;, with only the latter translated&lt;br /&gt;
* Strings for the engine loader progress bar&lt;br /&gt;
* Debug console string&lt;br /&gt;
* GUI (see above) strings&lt;br /&gt;
* [http://www.gnu.org/software/gettext/ GNU gettext] would be one solution&lt;br /&gt;
&lt;br /&gt;
=== Unit tests ===&lt;br /&gt;
* More unit tests&lt;br /&gt;
&lt;br /&gt;
=== Resource Explorer ===&lt;br /&gt;
* A portable, user-friendly graphical resource explorer could be useful&lt;br /&gt;
* [https://github.com/xoreos/phaethon Phaethon] is a start&lt;br /&gt;
** It can look into game archives, show textures and play sounds&lt;br /&gt;
** It uses [https://www.wxwidgets.org/ wxWidgets] to do the GUI&lt;br /&gt;
** Or possibly rewriting it to use [https://www.qt.io/ Qt] is better?&lt;br /&gt;
&lt;br /&gt;
=== Model converters ===&lt;br /&gt;
* Document the model formats&lt;br /&gt;
* Convert between the binary model formats and their ASCII equivalents&lt;br /&gt;
* Convert between the binary model formats and ones that can be opened by modelling tools&lt;br /&gt;
** 3D Studio Max&lt;br /&gt;
** Blender&lt;br /&gt;
&lt;br /&gt;
=== Full-fledged modding toolset ===&lt;br /&gt;
* Similar to the NWN, NWN2 or Witcher toolset, but portable and FLOSS&lt;br /&gt;
** Might also support other games?&lt;br /&gt;
* Out of scope for xoreos&lt;br /&gt;
** Still, such a thing would be welcome under the xoreos banner&lt;br /&gt;
* [http://sourceforge.net/projects/neveredit/ Neveredit] might still be worth a look&lt;br /&gt;
&lt;br /&gt;
== Build system ==&lt;br /&gt;
&lt;br /&gt;
=== CMake ===&lt;br /&gt;
* Current doesn&#039;t set the git version to &amp;quot;+unk&amp;quot; when git isn&#039;t found&lt;br /&gt;
* make install/uninstall?&lt;br /&gt;
* make doxygen?&lt;br /&gt;
&lt;br /&gt;
=== Autotools ===&lt;br /&gt;
* Suppress the &amp;quot;fatal: not a git repository&amp;quot; when building gitstamp without a git directory&lt;br /&gt;
* Increased modularity&lt;br /&gt;
** Disabling engines&lt;br /&gt;
*** Dropping library dependencies when the still enabled engine don&#039;t need them&lt;br /&gt;
** Making library dependencies optional (and disabling certain features, then)&lt;br /&gt;
*** liblzma is only needed for the iOS version of KotOR&lt;br /&gt;
*** libxml2 is only needed for the two Dragon Age games&lt;br /&gt;
*** libxvidcore is only needed for the Mac version of KotOR&lt;br /&gt;
*** libvorbis/libogg are probably only needed for The Witcher&lt;br /&gt;
** When something is disabled, skip it, if possible&lt;br /&gt;
*** Like the videos in KotOR Mac&lt;br /&gt;
** If skipping is not possible, error out&lt;br /&gt;
** We should then show a summary of what is enabled/disabled at the end of the configure script&lt;br /&gt;
&lt;br /&gt;
== Nitro ==&lt;br /&gt;
&lt;br /&gt;
* The Nintendo DS (Nitro) specific file formats should probably be moved out of src/aurora/ and into src/nitro&lt;br /&gt;
* nitrofile, cdpth, nsbtx, smallfile&lt;br /&gt;
** nsbtx needs to be split into a class accessing the textures in src/nitro/ and an archive class on top in src/aurora/&lt;br /&gt;
** This means src/aurora/ accesses src/nitro/, so libnitro.la needs to come after libaurora.la in the linking order&lt;br /&gt;
* ndsrom as well?&lt;br /&gt;
* What about nftrfont and model_sonic in src/graphics/aurora/?&lt;br /&gt;
** src/graphics/nitro/?&lt;br /&gt;
** This would have src/graphics/nitro/ access src/graphics/aurora/, so graphics/libnitro.la needs to come before graphics/libaurora.la in the linking order&lt;br /&gt;
** That would be the other way round than for src/nitro/. Too confusing?&lt;br /&gt;
&lt;br /&gt;
== Graphics ==&lt;br /&gt;
&lt;br /&gt;
=== MDL supermodels and animations ===&lt;br /&gt;
* Mostly working in NWN thanks to jbowtie&#039;s work&lt;br /&gt;
* Might need some cleanup&lt;br /&gt;
* Animation scale is off in a lot of cases. Mostly visible in the talking and yawning animations in non-human characters&lt;br /&gt;
* Models should smoothly change between different animations&lt;br /&gt;
* The animation system probably needs to be a bit more complex, to allow for &amp;quot;overlaying&amp;quot; different animations onto each other. For example, for speaking while holding an object and keeping the head focused on the PC character.&lt;br /&gt;
&lt;br /&gt;
=== Lighting ===&lt;br /&gt;
* We don&#039;t yet have a proper light system&lt;br /&gt;
* I started working on it: [https://drmccoy.de/xoreos/20150809T223407.png], but my approach is seriously lacking. You can see the edges of the tiles that make up on NWN area in many cases ([https://drmccoy.de/xoreos/20150809T223507.png], [https://drmccoy.de/xoreos/20150809T223548.png])&lt;br /&gt;
** See the [https://github.com/xoreos/xoreos/tree/light light branch] in the git repository&lt;br /&gt;
** Of course, the actual glLight* stuff won&#039;t be relevant anymore as soon as shaders are there&lt;br /&gt;
** Lighting in several (ASCII?) area tiles is broken&lt;br /&gt;
*** The door in Prelude.nwm&#039;s &amp;quot;m0q1a&amp;quot; area&lt;br /&gt;
*** A water tile in Chapter2.nwm&#039;s &amp;quot;map_m2q1a&amp;quot; area&lt;br /&gt;
*** A sloped snow tile in XP2_Chapter3.nwm&#039;s &amp;quot;thecityoflostsou&amp;quot;&lt;br /&gt;
&lt;br /&gt;
=== Materials ===&lt;br /&gt;
* Materials in The Witcher are closely tied to shaders&lt;br /&gt;
&lt;br /&gt;
=== OpenGL and Shaders ===&lt;br /&gt;
* mirv_ is currently working on a graphics system overhaul, complete with shader support&lt;br /&gt;
* All Aurora games use shaders in some form&lt;br /&gt;
* NWN uses ARB shaders. We probably need to rewrite them from scratch&lt;br /&gt;
* DirectX shaders might be automatically convertible with Cg?&lt;br /&gt;
* Otherwise, look at what Wine does with the shaders, and use that as a basis?&lt;br /&gt;
* All the games, even NWN, use some form of shaders. Still totally missing from xoreos, since we have no idea how to use them in general yet. Moreover, this was before GLSL, so they&#039;re in the old assembly-like language. We probably need to rewrite them from scratch&lt;br /&gt;
* We need shaders for tinting in NWN2 (objects and area geometry) and TexturePaint nodes in Witcher&lt;br /&gt;
&lt;br /&gt;
=== SDL 1.2 ===&lt;br /&gt;
* Optionally link against SDL 1.2 instead of SDL 2&lt;br /&gt;
* Should ideally use a configure flag to select between the two&lt;br /&gt;
** Maybe a CMake flag as well, if possible&lt;br /&gt;
* Assigned to clone2727, so anybody interested in this should coordinate with him&lt;br /&gt;
&lt;br /&gt;
== Videos ==&lt;br /&gt;
&lt;br /&gt;
=== XMV/WMV ===&lt;br /&gt;
* Used in Xbox versions of KotOR/KotOR2&lt;br /&gt;
* Our WMV decoder (for XMV videos used in Xbox versions) is missing P-frames and J-frame&lt;br /&gt;
** Code exists in ffmpeg, but is connected to the MPEG-4 family mess&lt;br /&gt;
&lt;br /&gt;
=== Actimagine VX ===&lt;br /&gt;
* Used in the Nintendo DS game Sonic Chronicles&lt;br /&gt;
* https://wiki.multimedia.cx/index.php?title=Actimagine_Video_Codec&lt;br /&gt;
&lt;br /&gt;
=== Sorenson 3 ===&lt;br /&gt;
* One single video in the Mac port of KotOR2, the Aspyr logo, uses the Sorenson 3 codec&lt;br /&gt;
** ffmpeg has a decoder, but it&#039;s connected to the MPEG-4 family mess (SVQ3 is similar to H.264)&lt;br /&gt;
* ScummVM needs that too&lt;br /&gt;
** While xoreos is GPLv3+, ScummVM is GPLv2+&lt;br /&gt;
** Somebody implementing Sorenson 3 for xoreos should ideally give explicit permission to relicense it GPLv2+ for ScummVM&lt;br /&gt;
*** Of course, if the decoder is based on prior work by other people, it has to be compatible with both GPLv2+ and GPLv3+&lt;br /&gt;
&lt;br /&gt;
=== Optimizations ===&lt;br /&gt;
* Optimize our simple BitStream interface&lt;br /&gt;
** See [https://fgiesen.wordpress.com/2016/01/02/end-of-buffer-checks-in-decompressors/ this blog post]&lt;br /&gt;
** Specifically, we don&#039;t do any peeking at all&lt;br /&gt;
** It still needs to handle different memory layouts, though&lt;br /&gt;
* Likewise, our Huffman class could probably be tuned a lot&lt;br /&gt;
* Pull in fft/rdft/dct/mdct optimizations from FFmpeg?&lt;br /&gt;
&lt;br /&gt;
== Sound ==&lt;br /&gt;
&lt;br /&gt;
=== FMOD ===&lt;br /&gt;
* Dragon Age: Origins uses FMOD for sound and music&lt;br /&gt;
* I have experimental FSB (FMOD sound bank) support working in a private branch&lt;br /&gt;
* FEV (FMOD events) format is still unknown to us&lt;br /&gt;
** Apparently, groups of event lists with events&lt;br /&gt;
** Event is everything from &amp;quot;play sound&amp;quot;, over &amp;quot;set volume&amp;quot; to &amp;quot;apply echo&amp;quot;&lt;br /&gt;
** Game areas specify the group to use for the area&lt;br /&gt;
** Scripts then probably tell FMOD to play event lists out of that group&lt;br /&gt;
&lt;br /&gt;
=== Wwise ===&lt;br /&gt;
* Dragon Age 2 uses Wwise for sound and music&lt;br /&gt;
* Should be similar in concept to FMD&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
=== Gamepad binding ===&lt;br /&gt;
* The Xbox versions of KotOR and KotOR2 don&#039;t use a mouse. We have basic support for joysticks/gamepads, but no real bindings to the engine or ideas how to handle that in general&lt;br /&gt;
* We might want to handle the controller support the new KotOR2 Steam update brought&lt;br /&gt;
** override folder contains a gamepad.txt then&lt;br /&gt;
* Also hack in controller support for a non-Steam KotOR2? And for KotOR?&lt;br /&gt;
* Controller support in Jade Empire&lt;br /&gt;
* Controller support for Sonic? It is a Nintendo DS game after all&lt;br /&gt;
* Controller support for the non-console versions of the Dragon Age games?&lt;br /&gt;
&lt;br /&gt;
== Network ==&lt;br /&gt;
* We need a network subsystem&lt;br /&gt;
** [https://www.libsdl.org/projects/SDL_net/ SDL_net]?&lt;br /&gt;
** [http://www.boost.org/doc/libs/release/libs/asio/ Boost.Asio]?&lt;br /&gt;
** More options here: http://stackoverflow.com/questions/118945/best-c-c-network-library&lt;br /&gt;
* Engines need to be split into client and server classes&lt;br /&gt;
** The original engines all still do that, even when not exposing anything to users&lt;br /&gt;
** NWN and NWN2 allow user multiplayer&lt;br /&gt;
&lt;br /&gt;
== Engines ==&lt;br /&gt;
&lt;br /&gt;
=== Script system ===&lt;br /&gt;
* ImperatorPrime had started on a script system rewrite&lt;br /&gt;
** Includes functions with real signatures&lt;br /&gt;
** Maybe switch to that, if it works&lt;br /&gt;
* Rounds, object heartbeat scripts&lt;br /&gt;
* KotOR2 and NWN2 have some extensions&lt;br /&gt;
** It seems like they don&#039;t need any extensions to the low-level bytecode stuff&lt;br /&gt;
* Witcher uses Lua scripts together with NWScript&lt;br /&gt;
* Sonic has no scripts at all, it seems&lt;br /&gt;
* Currently a script in an infinite loop locks the game thread&lt;br /&gt;
** Timeout? Asynchronous script execution?&lt;br /&gt;
&lt;br /&gt;
=== NWN ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Basics are there, but needs fleshing out&lt;br /&gt;
** Supermanu is working on the character generator&lt;br /&gt;
* [[Pathfinding]], walkmesh&lt;br /&gt;
** &amp;quot;Moving&amp;quot; should move the PC, not the camera&lt;br /&gt;
** NPC walking&lt;br /&gt;
** Triggers, areas on the floor that calls scripts on enter/leave&lt;br /&gt;
* Models&lt;br /&gt;
** ASCII models need averaging of smooth group normals&lt;br /&gt;
* NWN objects need an inventory concept&lt;br /&gt;
** Player characters&#039; might be different&lt;br /&gt;
*** Inventory tetris&lt;br /&gt;
*** Inventory item icons&lt;br /&gt;
* Multi-page asian fonts&lt;br /&gt;
* LanguageID 0 is not necessarily &amp;quot;English&amp;quot;, but &amp;quot;The language of the game install&amp;quot;&lt;br /&gt;
** This is okay for languages with Latin characters&lt;br /&gt;
** Messes up strings in community modules with Asian languages that stuff strings in to languageID 0&lt;br /&gt;
** The original fails there too, though&lt;br /&gt;
&lt;br /&gt;
=== KotOR/KotOR2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Basic structure is already there, just missing most of the specific widgets stuff&lt;br /&gt;
** Semi-hardcoded, with GFF files (hierachical data, similar to XML in spirit) describing the setup. The xoreos-tools repository has a tool for converting GFF files into XML for easy reading.&lt;br /&gt;
* Dialogues&lt;br /&gt;
** DLG files, similar to NWN&lt;br /&gt;
** Some extensions, like camera setup&lt;br /&gt;
** Dialogues are displayed very different than NWN&lt;br /&gt;
** KotOR2 has script extensions&lt;br /&gt;
*** Passing parameters to scripts&lt;br /&gt;
*** Call several scripts, combine with AND/OR for branching&lt;br /&gt;
* Animations&lt;br /&gt;
** Should be similar to NWN&lt;br /&gt;
** No player character shown&lt;br /&gt;
*** Needs character creator menus&lt;br /&gt;
*** Loading of character files in class Creature&lt;br /&gt;
* Minigames&lt;br /&gt;
** Swoop racing&lt;br /&gt;
** Pazaak&lt;br /&gt;
** Hardcoded, mostly removed from usual game logic&lt;br /&gt;
&lt;br /&gt;
=== Jade Empire ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Apparently very similar to KotOR&#039;s menus&lt;br /&gt;
* Minigames&lt;br /&gt;
** Flyer, top-down shoot-em-up thing&lt;br /&gt;
** Hardcoded, mostly removed from usual game logic&lt;br /&gt;
* Player character&lt;br /&gt;
** Needs research&lt;br /&gt;
* Sound&lt;br /&gt;
** Uses an ASCII variant of the [http://wiki.multimedia.cx/index.php?title=XACT XACT formats]&lt;br /&gt;
*** Cues probably not as complex as FMOD/Wwise&lt;br /&gt;
*** Effects need extension of the Sound system, maybe&lt;br /&gt;
** Xbox version might use the binary format?&lt;br /&gt;
*** Sound banks could be handles as archives and indexed in the ResourceManager?&lt;br /&gt;
** [https://github.com/FNA-XNA/FNA/tree/master/src/Audio FNA] has an implementation of XACT. Probably quite useful to look at that&lt;br /&gt;
&lt;br /&gt;
=== NWN2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Implemented using XML&lt;br /&gt;
** See [[#Broken NWN2 XML|Broken NWN2 XML]]&lt;br /&gt;
* Animations (Granny)&lt;br /&gt;
** [https://github.com/SkywingvL/nwn2dev-public nwn2-dev] contains some code working with Granny data&lt;br /&gt;
*** Call into the original Granny DLL to convert between binary and ASCII Granny data, though&lt;br /&gt;
** [https://github.com/berenm/xoreos-tools/tree/granny berenm started some Granny RE]&lt;br /&gt;
* Facial animations (FaceFX)&lt;br /&gt;
* Trees (SpeedTree)&lt;br /&gt;
* Proper evaluation of creature model parts (equipped items)&lt;br /&gt;
* Player character&lt;br /&gt;
** Reading of PC files in creature&lt;br /&gt;
&lt;br /&gt;
=== Sonic Chronicles ===&lt;br /&gt;
* Allow using the contents from an extracted NDS file?&lt;br /&gt;
* Menus&lt;br /&gt;
** GUI files that are GFF&lt;br /&gt;
** Actions in a state machine in GDA files?&lt;br /&gt;
* Music/Sound&lt;br /&gt;
** Music is apparently similar to MIDI, or to a tracker format?&lt;br /&gt;
** Sounds and instruments for music are in a sound_data.sadl archive&lt;br /&gt;
* Animations&lt;br /&gt;
** Bone animations, best implemented with shaders, blocked by the graphics subsystem rewrite&lt;br /&gt;
* Player character(s)&lt;br /&gt;
** Needs research&lt;br /&gt;
&lt;br /&gt;
=== The Witcher ===&lt;br /&gt;
* Menus&lt;br /&gt;
** Apparently build using Lua&lt;br /&gt;
** System/Scripts/ has gui*.luc files&lt;br /&gt;
* Animations&lt;br /&gt;
** Needs research&lt;br /&gt;
* Player character, Geralt&lt;br /&gt;
** Needs research&lt;br /&gt;
&lt;br /&gt;
=== Dragon Age: Origins / Dragon Age 2 ===&lt;br /&gt;
* Menus&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Scaleform_GFx Scaleform GFx]&lt;br /&gt;
** [http://social.bioware.com/wiki/datoolset/index.php/UI_Tutorial_%28draft%29 UI Tutorial] on the Dragon Age toolset wiki&lt;br /&gt;
** Flash-based!&lt;br /&gt;
** A good starting point for a reimplementation might be [https://en.wikipedia.org/wiki/Gameswf Gameswf].&lt;br /&gt;
** [https://en.wikipedia.org/wiki/Gnash Gnash], [https://en.wikipedia.org/wiki/Lightspark Lightspark], [https://en.wikipedia.org/wiki/Swfdec Swfdec]&lt;br /&gt;
** [http://www.nowrap.de/flasm.html Flasm] can disassemble/assemble ActionScript, [http://www.nowrap.de/flare.html Flare] can decompile it&lt;br /&gt;
** [https://wwwimages2.adobe.com/content/dam/acom/en/devnet/pdf/swf-file-format-spec.pdf swf-file-format-spec.pdf] is a great reference which covers mostly every aspect of the gfx files.&lt;br /&gt;
** [https://github.com/jindrapetrik/jpexs-decompiler jpexs-decompiler] can decompile and handles scaleform specific tags.&lt;br /&gt;
* Animations&lt;br /&gt;
** Bone animations, best implemented with shaders, blocked by the graphics subsystem rewrite&lt;/div&gt;</summary>
		<author><name>DrMcCoy</name></author>
	</entry>
</feed>