Im not sure if this will run in dbpro, so you might as well try it.
Let me explain this, this snippet records your voice while playing an animation. What's the use of this? Well, let's say you are making a RTS game and you have a few cutscenes, that are made in a 3D program. Now you want to add a few voices, and its possible (easy) with this snippet.
Just put the avi/mpg in the same directory as the executable/code and load the animation. It will preview it and when you press space it will start recording. Then it will save your voice/wav as a file with a name you specified.
Try it
(im using this for a little project)
rem Sync animation on
cls RGB(0,0,128)
sync on
sync rate 0
hide mouse
text 5,5,"Sync animation on"
set cursor 5,60
nm$="bestaat.nie"
while file exist(nm$)=0
input "AVI/MPG source: ", nm$
if file exist(nm$)=1
load animation nm$,1
else
print "File not found"
endif
endwhile
x = animation width(1)/2
if x > 200 then x = 200
y = animation height(1)/2
if y > 150 then y = 150
set current bitmap 0
cls
text 5,5, "Ready - Previewing animation"
text 5,20,"Press spacekey to start recording"
play animation 1,320-x,240-y,320+x,240+y
while spacekey()=0
sync
endwhile
cls
stop animation 1
play animation 1,320-x,240-y,320+x,240+y
record sound 1,1000
sync
time = timer()
while animation playing(1)=1 and spacekey()=0 and val(s$)=<1000.0
cls
text 5,5, "Recording"
text 5,20,"Press spacekey to stop manually"
text 5,455,"Alien game Productions"
s$ = str$((timer()-time)/1000.0)
text 450,20,"Seconds: "+ s$
sync
endwhile
stop recording sound
stop animation 1
sync
if file exist("buffer.tmp")=1 then delete file "buffer.tmp"
save sound "buffer.tmp",1
if sound exist(1)=1 then delete sound 1
load sound "buffer.tmp",1
play sound 1
play animation 1,320-x,240-y,320+x,240+y
cls
text 5,5, "Recording done"
text 5,20,"Press spacekey to stop previewing"
text 5,455,"Alien game Productions"
text 450,20,"Seconds: "+ s$
while sound playing(1)=1 and spacekey()=0 : sync : endwhile
stop sound 1
stop animation 1
cls
input "Sound file name? (type NOSAVE for no saving): ", name$
if name$="NOSAVE" then end
save sound name$,1
end
Quote: "
UPDATED
Amd 2800+ 1024mb pc3200 A7N8X - Deluxe Ati Radeon 9800PRO 256mb"