— Scott McNealy, Sun Microsystems Chairman, President and ceo



Download 40,57 Mb.
Pdf ko'rish
bet298/555
Sana26.05.2022
Hajmi40,57 Mb.
#609235
1   ...   294   295   296   297   298   299   300   301   ...   555
Bog'liq
Head First Java (Kathy Sierra, Bert Bates) (z-lib.org)

316
 
chapter 11
building the 
MIDI Music Player
Let’s make a Music Machine
Over the next three chapters, we’ll build a few different sound 
applications, including a BeatBox Drum Machine. In fact, 
before the book is done, we’ll have a multi-player version so 
you can send your drum loops to another player, kind of like 
a chat room. You’re going to write the whole thing, although 
you can choose to use Ready-bake code for the GUI parts. 
OK, so not every IT department is looking for a new BeatBox 
server, but we’re doing this to learn more about Java. Building 
a BeatBox is just a way to have fun while we’re learning Java.
The finished BeatBox looks something like this:
your message, that gets 
sent to the other
players, 
along with your current 
beat pattern, when you 
hit “SendIt”
Andy: groove #2
Chris: groove2 revised
Nigel: dance beat
dance beat
incoming messages from 
other players. Click one 
to load the pattern that 
goes with it, and then click 
‘Start’ to play it.
Put checkmarks in the boxes for each of the 16 ‘beats’. For example, on beat 
1 (of 16) the Bass drum and the Maracas will play, on beat 2 nothing, and 
on beat 3 the Maracas and Closed Hi-Hat... you get the idea. When you hit 
‘Start’, it plays your pattern in a loop until you hit ‘Stop’. At any time, you 
can “capture” one of your own patterns by sending it to the BeatBox server 
(which means any other players can listen to it). You can also load any of the 
incoming patterns by clicking on the message that goes with it.
You make a beatbox loop (a 16-beat drum pattern) 
by putting checkmarks in the boxes. 


you are here
4

Download 40,57 Mb.

Do'stlaringiz bilan baham:
1   ...   294   295   296   297   298   299   300   301   ...   555




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©hozir.org 2024
ma'muriyatiga murojaat qiling

kiriting | ro'yxatdan o'tish
    Bosh sahifa
юртда тантана
Боғда битган
Бугун юртда
Эшитганлар жилманглар
Эшитмадим деманглар
битган бодомлар
Yangiariq tumani
qitish marakazi
Raqamli texnologiyalar
ilishida muhokamadan
tasdiqqa tavsiya
tavsiya etilgan
iqtisodiyot kafedrasi
steiermarkischen landesregierung
asarlaringizni yuboring
o'zingizning asarlaringizni
Iltimos faqat
faqat o'zingizning
steierm rkischen
landesregierung fachabteilung
rkischen landesregierung
hamshira loyihasi
loyihasi mavsum
faolyatining oqibatlari
asosiy adabiyotlar
fakulteti ahborot
ahborot havfsizligi
havfsizligi kafedrasi
fanidan bo’yicha
fakulteti iqtisodiyot
boshqaruv fakulteti
chiqarishda boshqaruv
ishlab chiqarishda
iqtisodiyot fakultet
multiservis tarmoqlari
fanidan asosiy
Uzbek fanidan
mavzulari potok
asosidagi multiservis
'aliyyil a'ziym
billahil 'aliyyil
illaa billahil
quvvata illaa
falah' deganida
Kompyuter savodxonligi
bo’yicha mustaqil
'alal falah'
Hayya 'alal
'alas soloh
Hayya 'alas
mavsum boyicha


yuklab olish