lucasw / amiga_assembly

Amiga assembly projects for use with Vasm
3 stars 0 forks source link

sound effects #12

Open lucasw opened 6 years ago

lucasw commented 6 years ago

Import from audacity

8KHz mono - export as other uncompressed headerless raw signed 8-bit pcm

lucasw commented 6 years ago

Play arrays with python

Preview the sounds exported from audacity.

pip install scikits.audiolab
import numpy as np
import scikits.audiolab

data = np.random.uniform(-127,128,44100).astype(np.int8)
# play the array:
# have to convert to -1.0 to 1.0
scikits.audiolab.play(data/128.0, fs=44100)
lucasw commented 6 years ago

It seems easier to export from Audacity as a wav, then create a binary file in python.

lucasw commented 6 years ago

Need a player ship hit sound effect, and an enemy hit sound effect.