It is currently Fri Nov 24, 2017 7:19 pm

All times are UTC - 7 hours





Post new topic Reply to topic  [ 10 posts ] 
Author Message
PostPosted: Mon Oct 27, 2014 12:01 am 
Offline
User avatar

Joined: Sun Oct 12, 2014 11:06 am
Posts: 123
Location: Finland
I'm going to start working on a sound engine so I need some help with it. Is it possible (and efficient) to make a sound engine that's songs are lists of patterns? The sound engine would read what pattern to play from the list. Once the pattern ends, it would return to the list and check the next pattern to play. Also, is it possible to make the sound engine read from FamiTracker's .nsf files?

_________________
UP SIDE DOWN A B A B B A B A Hidari migi
L R L R STOP & DASH & UP & TALK Ijou nashi


Top
 Profile  
 
PostPosted: Mon Oct 27, 2014 7:10 am 
Offline

Joined: Sun Sep 19, 2004 11:12 pm
Posts: 19257
Location: NE Indiana, USA (NTSC)
Yes, sound engines commonly represent music as lists of patterns in the way you describe. And yes, FamiTracker includes a "text export" command to convert FTM to a text format that your own translator can use.


Top
 Profile  
 
PostPosted: Mon Oct 27, 2014 11:18 pm 
Offline
User avatar

Joined: Sun Oct 12, 2014 11:06 am
Posts: 123
Location: Finland
I just tried the text export, but the output doesn't really look like something that NESASM3 would understand if I added it to the program.

_________________
UP SIDE DOWN A B A B B A B A Hidari migi
L R L R STOP & DASH & UP & TALK Ijou nashi


Top
 Profile  
 
PostPosted: Tue Oct 28, 2014 7:31 am 
Offline
User avatar

Joined: Sat Feb 12, 2005 9:43 pm
Posts: 10119
Location: Rio de Janeiro - Brazil
You probably have to parse the output somehow to make it useful.


Top
 Profile  
 
PostPosted: Tue Oct 28, 2014 10:13 am 
Offline

Joined: Sun Sep 19, 2004 11:12 pm
Posts: 19257
Location: NE Indiana, USA (NTSC)
FamiTracker's text output is intended for you to write a PC program to translate the output into sequence data suitable for your own music engine. You might write this in C++, C, Java, JavaScript, Python, or whatever. Do you know any PC programming languages?


Top
 Profile  
 
PostPosted: Tue Oct 28, 2014 10:22 am 
Offline
User avatar

Joined: Sun Oct 12, 2014 11:06 am
Posts: 123
Location: Finland
tepples wrote:
Do you know any PC programming languages?


Does Touhou Danmakufu and Game Maker count? Otherwise, no. I have some old version of FamiTracker that has .NSF export. Can't I use that?

_________________
UP SIDE DOWN A B A B B A B A Hidari migi
L R L R STOP & DASH & UP & TALK Ijou nashi


Top
 Profile  
 
PostPosted: Tue Oct 28, 2014 10:30 am 
Offline

Joined: Sun Sep 19, 2004 11:12 pm
Posts: 19257
Location: NE Indiana, USA (NTSC)
In theory you can use .incbin to include the body of FamiTracker's NSF export at the load address and play music through that.

In practice it's a lot harder for at least two reasons. One is that the NSF interface defines no way to play sound effects on top of the music. The other is that an NSF is allowed to use the machine's whole memory except for the top of the stack, which means you don't know in advance which memory your game is allowed to use.


Top
 Profile  
 
PostPosted: Tue Oct 28, 2014 10:40 am 
Offline
User avatar

Joined: Sat Feb 12, 2005 9:43 pm
Posts: 10119
Location: Rio de Janeiro - Brazil
Tsutarja wrote:
I have some old version of FamiTracker that has .NSF export. Can't I use that?

If you include the whole NSF you'll be including more than the song data, since NSF files include the player code as well.

I imagine you could analyze the NSF and extract only the data from it, but if you use the exact same data format as FamiTracker you'll be essentially reimplementing the FamiTracker player, which is silly.

If you're implementing your own sound engine, you'll need to come up with your own data formats, and in order to handle custom file formats you absolutely need some programming experience.


Top
 Profile  
 
PostPosted: Tue Oct 28, 2014 2:18 pm 
Offline
User avatar

Joined: Wed Apr 02, 2008 2:09 pm
Posts: 1037
Or look into something like Famitone or Famitone2.

_________________
https://kasumi.itch.io/indivisible


Top
 Profile  
 
PostPosted: Thu Oct 30, 2014 11:05 pm 
Offline
User avatar

Joined: Sun Oct 12, 2014 11:06 am
Posts: 123
Location: Finland
Kasumi wrote:
Or look into something like Famitone or Famitone2.


I guess this would be the easiest way to get sound working. I'll try it when I have more time.

_________________
UP SIDE DOWN A B A B B A B A Hidari migi
L R L R STOP & DASH & UP & TALK Ijou nashi


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 10 posts ] 

All times are UTC - 7 hours


Who is online

Users browsing this forum: No registered users and 5 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group