Jump to content



2

In Game Sound Engine


9 replies to this topic

#1 Richi_S OFFLINE  

Richi_S

    Star Raider

  • 50 posts
  • Location:Germany - Munich

Posted Mon Jul 27, 2009 2:11 PM

As I announced in the previous topic Yet another sound system,
I finally release my In Game Sound Engine:

Attached File  IGSE.bin   4K   132 downloads

Attached File  IGSE.txt   18.37K   175 downloads

Just rename it to IGSE.asm and have some fun.

Please post Your opinion, bugs You found, and and Your suggestions!

#2 Richi_S OFFLINE  

Richi_S

    Star Raider

  • 50 posts
  • Location:Germany - Munich

Posted Mon Jul 27, 2009 2:29 PM

If you want to make your own music I recommend:
Attached File  SoundX__1994___Hozer_Video_Games__Ed_Federmeyer___WIP___a1_.bin   4K   212 downloads
So that you can hear how the instruments you choose might sound.

The batari Basic Music and Sound Page
To convert real notes in Atari 2600 values.

And finally
Anvil Studio
A great freeware MIDI editor.
It features a Mixer that lets you strip down existing midi files to two track Atari 2600 music,
and a Piano Roll Editor, which enables even persons with limited musical talent (like myself) to generate nice music.
It also displays the notes of a given Midi File very similar to the Pattern & Beat system I use.

#3 Richi_S OFFLINE  

Richi_S

    Star Raider

  • 50 posts
  • Location:Germany - Munich

Posted Mon Jul 27, 2009 2:58 PM

Quickstart: How To use The In Game Sound System

Some basic definitions:
  • TV Frame: The TV Frame is the smallest unit (60Hz, NTSC). On every TV Frame the AUDFx and AUDVx registers are updated from the Special instrument tables, the Special Instrument pointer(Music_special_pointer_X) is increased.
  • Note: Depending on the music timers prescaler (Music_timer, MUSIC_TIMER_PRESCALER) a defined number of TV Frames form one Note. If a new note is loaded the AUDFx_base register is loaded and the special instrument pointer (Music_special_pointer_X) is reloaded, the beat offset pointer is reseted (Music_beat_pointer_X_offset).
  • Beat: Eight Notes form a Beat (Music_beatX_AUDF). To every Beat a Instrument (Tia Instrument and Special Instrument Modifier, Music_PatternX_Instrument) is assigned.
  • Pattern: A Pattern is two Tables (Music_PatternX , Music_PatternX_Instrument ) that links to the Beats and assigns Instruments to the Beats.
  • Song: A Song consists of two channels. It defines the starting Point and the end point and the Loop in Point of the Patterns (MUSIC_SONG_START, MUSIC_SONG_END, MUSIC_SONG_LOOP_TO).
  • Channel: The Atari 2600 has got two channels. Every channels has got its own Pattern, Beats and Notes.


The Pattern
The pattern is played from Lesf to the right.
There is defined
  • A starting point (MUSIC_SONG_START)
  • A End point (MUSIC_SONG_END)
  • A point where the Song shall repeat after the pattern has reached the end point (MUSIC_SONG_LOOP_TO)
IGSE01.jpg


The Notes
  • The Pattern table points to a Address in the Music_beatX_AUDF table
  • The values in the table are the Notes (AUDFx). #99 is Silence (Pause)
  • The Beat Table is played from left to the right.
  • If all eight notes of one beat are played, the next beat from the pattern table is loaded.
IGSE02.jpg


The Instrument
  • Every Patterns Beat has got its Instrument (Instrument Number in Music_PatternX_Instrument).
  • The Instrument Number is divided in two Nibbles
  • The Instrument Numbers Low Nibble is the TIA Instrument (AUDCx Register)
  • The Instrument Numbers High Nibble is the Number of the Special Instrument.
  • By using the Music_special_instrument_pointer the starting address of the Music_special_AUDV_table and Music_special_AUDF_table is identified.
  • Every TV Frame the pointer to these tales is increased, the Tables are read from left to right.
  • The AUDV register is updated every TV Frame with the value from the Music_special_AUDV_table.
  • The AUDF register is updated every TV Frame with the value from the Music_special_AUDF_table plus the value of the note to be played.
IGSE03.jpg

Edited by Richi_S, Mon Jul 27, 2009 2:59 PM.


#4 yuppicide OFFLINE  

yuppicide

    I am the Black Knight. Give me your money!

  • 6,933 posts
  • Location:New Jersey

Posted Mon Jul 27, 2009 9:12 PM

Sounds very interesting. I did have a read over some of the information and don't totally understand it all, but I heard your Contra (wasn't it Contra) and it was great.

I have always been interested in trying to convert over some of my friends band into the Atari 2600 and maybe this will help looking at Anvil. I know the songs won't sound the same, but if I can play them for my friend I'd be happy if they figured out it was their own song.

#5 grafixbmp OFFLINE  

grafixbmp

    Dragonstomper

  • 659 posts
  • Location:South Central US

Posted Sun Sep 6, 2009 12:01 AM

What amout of cycles and area of a full frame does it take up?

#6 Richi_S OFFLINE  

Richi_S

    Star Raider

  • 50 posts
  • Location:Germany - Munich

Posted Wed Sep 9, 2009 11:41 AM

Well, I'd say 3 to 5. I did not count them, or did any tests on that.
While programming the code I started it as a part of a game.
I did not use a timer like in the released code. I was just using STA WSYNC.
In the Engine code, every now and than, five STA WSYNC commands had been placed and it worked fine.

#7 Random Terrain OFFLINE  

Random Terrain

    Visual batari Basic User

  • 20,914 posts
  • Controlled Randomness
    Replay Value
    Nonlinear
  • Location:North Carolina (USA)

Posted Sat Sep 26, 2009 5:18 AM

View PostRichi_S, on Mon Jul 27, 2009 2:29 PM, said:

If you want to make your own music I recommend:
Attachment SoundX__...IP___a1_.bin
So that you can hear how the instruments you choose might sound.
Is that better than Tone Toy 2008:

http://www.randomter...e-toy-2008.html

#8 Richi_S OFFLINE  

Richi_S

    Star Raider

  • 50 posts
  • Location:Germany - Munich

Posted Mon Oct 12, 2009 3:40 PM

Wow, Tone Toy is a great tool... Thanks for telling me.
With the sound loop function I can get a good feeling how the "Special Instruments" will sound like, when programming them.
Without that tool it is a lot more trial and error.

#9 Tr3vor OFFLINE  

Tr3vor

    Stargunner

  • 1,738 posts
  • AAARG!
  • Location:Dream Land

Posted Thu Nov 19, 2009 5:27 PM

View PostRandom Terrain, on Sat Sep 26, 2009 5:18 AM, said:

View PostRichi_S, on Mon Jul 27, 2009 2:29 PM, said:

If you want to make your own music I recommend:
Attachment SoundX__...IP___a1_.bin
So that you can hear how the instruments you choose might sound.
Is that better than Tone Toy 2008:

http://www.randomter...e-toy-2008.html


why is the page not found?

i saw your video on youtube about it and want to try that out so I can see all the weird sounds the 2600 makes.

Edited by Tr3vor, Thu Nov 19, 2009 5:28 PM.


#10 Random Terrain OFFLINE  

Random Terrain

    Visual batari Basic User

  • 20,914 posts
  • Controlled Randomness
    Replay Value
    Nonlinear
  • Location:North Carolina (USA)

Posted Thu Nov 19, 2009 5:56 PM

View PostTr3vor, on Thu Nov 19, 2009 5:27 PM, said:

Why is the page not found?
Maybe there was a temporary problem. Seems to be working fine now:

http ://www.randomterrain.com/atari-2600-memories-program-tone-toy-2008.html


And for those who don't know, I have a new Data Creation Toy for batari Basic users:

http ://www.randomterrain.com/atari-2600-memories-batari-basic-music-toy.html

Play real Atari 2600 sounds online and create music data for bB programs.

Edited by Random Terrain, Thu Nov 19, 2009 6:02 PM.





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users