#9020 closed patch
GSOC: Transform scummvm into a modplayer
Reported by: | SF/nolange | Owned by: | |
---|---|---|---|
Priority: | normal | Component: | Audio |
Version: | Keywords: | ||
Cc: | Game: |
Description
Since Im going to implement a couple audioformats its important I can test them easily. This patch is disabling the normal scummvm-launcher and instead simply loads a protracker module and plays it. Included are new projectfiles for MSVC9 and adjustments to Makefile.common to include a new directory "TFMX". I will keep any auxiliary stuff in this folder (docs describing the format, commented disassemblies,etc)
Ticket imported from: #2795660. Ticket imported from: patches/1125.
Attachments (5)
Change History (19)
by , 16 years ago
Attachment: | patch.diff added |
---|
comment:1 by , 16 years ago
Parts of the patch are not correctly formatted, you should read up on our code formatting guidelines: http://wiki.scummvm.org/index.php/Code_Formatting_Conventions .
About the new directory:
The name should be all lowercase. Also I'm myself actually unsure of the new directory, later on the standalone TFMX player should be placed in sound/. For the time of working it might be easier of course to use an alternative file with the main, as you did it. I guess your mentor(s) will have the final word here.
comment:2 by , 16 years ago
this TFMX directory wont be merged back in the main branch, it will contain stuff that I need for developing the TFMX-module. the code that ends up in scummvm will be in sound/mods - its just not there yet.
Yes I havent been correcting the code I disabled with the #if 0 directive (the rest should be fine). I wont be around on Saturday and I wanted to commit something.
comment:3 by , 16 years ago
New patch uploaded (patch2). Now parses a TFMX Module and creates a instance of a Tfmx Class based on it. Files have to be named music.dat and sample.dat (standard names for TFMX) and placed into current working dir.
comment:5 by , 16 years ago
Ah ok I didn't know about your plans with the "tfmx" directory before. :-)
comment:6 by , 16 years ago
Code formatting woes. Particularly Tfmx::load() method.
Please, fix it.
Also please, do not use caps in the directory names.
comment:7 by , 16 years ago
knakos: thanks.
Ok, Folder is lowercase now and I went over the source... twice. I hope for both our sakes that Im getting used to this convention fast =) Please tell me if Im doing anything consistenly wrong.
comment:8 by , 15 years ago
Changes in Paula.cpp/Paula.h + soundfx.cpp: Added (easy) queueing of samples by implementing methods that act similar like writes to the Amiga-Chipset would. Added counting of DMA-Interrupts, that is how often a sample finished playing. Added a base for the interrupt-interval, in most cases this will be the Cia-clockrate. Derived classes can then set the interval without scaling to the samplerate
Changes in common/scummsys.h: Only disable warnings with pragmas for MS Compilers that cant do so otherwise. Newer MSVC Versions can and should disable warnings in the Project-Settings.
Files in tfmx: Some files for debugging. Wont ever be commited back into trunk so those will contain some messy and hackish code
Added: tfmx.h/tfmx.cpp Player for TFMX-Modules.
Rest: main.cpp etc. Modified buildsystem to include new directory, modified main.cpp so it calls tfmxmain (tfmxplayer.cpp) instead of starting the GUI.
Unfortunatly it complains about unfound symbols under Unix, need some help fixing this as I dont have an idea whats wrong
comment:9 by , 15 years ago
Just some quick comments:
About the linking issues: You need to specify libtfmx.a before libsound.a. I.e. in Makefile.common, tfmx should be before sound in MODULES.
Also, you forgot a "#define TFMXDEBUG_H" in tfmx/tfmxdebug.h.
Another minor thing: You might want to use spaces for alignment, like when you aligned "="s in the enum in paula.h. I've got my tabwidth set to 2, alignment-tabs break then. Generally, tabs for indenting and spaces for alignment is the way to go, IMO.
comment:10 by , 15 years ago
And another thing: The boundaryCheck-assertion gets triggered for me. Digging into it a bit (valgrind ftw :)) showed that you forgot to initialize the _channelCtx array.
comment:12 by , 15 years ago
Status: | new → closed |
---|
comment:14 by , 6 years ago
Component: | → Audio |
---|
patch against rev 40797