[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Swftools-common] how to play .wav file from swf button

From: Jens Stolze
Subject: Re: [Swftools-common] how to play .wav file from swf button
Date: Sat, 04 Apr 2009 21:45:06 +0200

Am Samstag, den 04.04.2009, 21:19 +0200 schrieb Norman Khine:
> Hello,
> I have build a captcha type of widget using SoX to generate a .wav
> file. I am looking to make the interface a bit more full proof as
> currently it just embeds the wav file as for example:
> <embed bgcolor="white" height="16" type="audio/wav" src="tfp45.wav"
> autostart="false">

> I would like to replace the .wav player with a SWF button, so that if
> a user clicks on it it will play the file.


this is working for me.

cu,     Jens Stolze


# ---- beispiel-button-sound.sc
.flash bbox=700x400 name="beispiel-button-sound.swf" compress

# -------- Knoepfe definieren ------------- xxx 1 x xxx
        .circle knopfnormal r=22 color=yellow fill=green
        .circle knopfdrueber r=20 color=yellow fill=orange
        .circle knopfgedrueckt r=18 fill=red
        .circle aktiverbereich r=22 fill=black
# --------  Klaenge definieren 
        .swf klang1 "ruhe-bitte.swf"

# -----------Knopfaktion definieren 
        .button knopf1
                .show knopfnormal as=idle
                .show knopfdrueber as=hover
                .show aktiverbereich as=area
                .show knopfgedrueckt as=pressed
                # ------ Funktion definieren ----
# ---------- Ausgaben definieren ------- 
        .put knopf1 x=300 y=100

# ----- Actionscript routines --- 
# 1 x action-Zeile und Platzhalter-Zeile xxx

                function RunSound1(){
        .end # --- Actionscript functions 

#-- xxx 10 x  plus Anpassung der Namen xxx
# ----------- Flashscript beenden ------ xxx 1 x die end-Zeile ***

reply via email to

[Prev in Thread] Current Thread [Next in Thread]