About me


  • housni has started 2 topics. 4 people are following them.
  • housni has made 4 replies.

Recent activity

Subscribe to this feed
  • talk

    Scott replied on August 27, 2008 01:04 to the discussion "I couldn't figure out how to implement even via demos." in Schillmania!:

    Scott
    The .swf path is determined by the soundManager.url property, it's discussed and examples are given in the project documentation (and demos.) You should read the docs! If you have read them, maybe you should read them again! :D

    Seriously though, there is a lot to read, but the SM2 "url" property is mentioned in the general/"getting started" sections in particular, and also used in each one of the demos as they load from different directories themselves.

    If you're having problems loading the .swf etc., I also recommend checking the debug output - it writes out the path of the SWF it uses at startup.
  • talk

    housni replied on August 26, 2008 11:54 to the discussion "I couldn't figure out how to implement even via demos." in Schillmania!:

    housni
    i was working on something else but i took a look at this again last night.

    my problem was i didn't know where to place the swf's hehe i know very little JS (shame on me, i know :() but i went through the JS and saw the path to the swf's and i changed that....but it still didn't work (i tested it within a folder of a PHP/ROR package i'm working on) so i copied it over to another location on my hard disk and took away file by file an the moment i took away my .htaccess, it worked! silly me, i didn't realize i had mod_rewrite doing some rewriting to stop hotlinking! anyway, it works now. great player i must say :)

    one tiny suggestion, if i may; why don't you mention the path to the swf's in your documentation? or have you already and i'm just blind (this is possible since i never realized .htaccess could have been the cause hehe)?
  • talk

    A comment on the discussion "I couldn't figure out how to implement even via demos." in Schillmania!:

    Scott
    "Once again, the soundmanager.swf is not required right? in my case, all i need is the soundmanager2.js and the inlineplayer.js, right?" .. Err.. ;) soundmanager2.swf or soundmanager2_flash9.swf ARE required for things to work. It's a flash+javascript sound library, flash is actually what loads and plays the sounds with an "invisible" movie, etc. Your error is due to either security, or that the .swf is not loading. – Scott, on August 08, 2008 16:38
  • talk

    housni replied on August 08, 2008 10:33 to the discussion "I couldn't figure out how to implement even via demos." in Schillmania!:

    housni
    i thought about that too but i do have the latest flash installed. i tried it on the latest Opera and Firefox on Linux as well as the latest IE and Firefox on two separate Windows machines, so that's 3 different machines. of course the PHP script was hosted on my Linux machine.
    Once again, the soundmanager.swf is not required right? in my case, all i need is the soundmanager2.js and the inlineplayer.js, right?

    here's the output from a windows machine:
    -----
    soundManager.initComplete(): calling soundManager.onerror()
    -- SoundManager 2 failed to load (security/load error) --
    soundManager.disable(): Disabling all functions - future calls will return false.
    soundManager: Failed to initialise.
    soundManager: No Flash response within reasonable time after document load.
    Possible causes: Flash version under 8, no support, or Flash security denying JS-Flash communication.
    soundManager: Getting impatient, still waiting for Flash.. ;)
    soundManager.beginDelayedInit(): Document loaded
    soundManager._initMovie(): Waiting for ExternalInterface call from Flash..
    soundManager._initMovie(): Got OBJECT element (created via JS)
    soundManager._createMovie(): Trying to load ../../soundmanager2.swf
    -- SoundManager 2 V2.75a.20080707 (AS2/Flash 8) --
    -----

    my html head:
    -----
    <script type="text/javascript" src="js/soundmanager2.js"></script>
    <link rel="stylesheet" type="text/css" href="css/page-player.css" />
    <script type="text/javascript" src="js/inlineplayer.js"></script>
    -----
    and i've verified that those files exist on disk.

    example of my mp3 listing:
    -----
    <a href="music/Akrobatik/The EP/05 U Got It.mp3">05 U Got It.mp3</a><br />
    <a href="music/blackalicious-purest_love-4hm.mp3">blackalicious-purest_love-4hm.mp3</a><br />
    <a href="music/Common/One Day It'll All Make Sense/10 All Night Long (feat. Erykah Badu.mp3">10 All Night Long (feat. Erykah Badu.mp3</a><br />
    -----

    if you still think it's to do with a security setting, do you have any idea what the possible list of settings could be that are affecting this?

    Thanks.
  • talk

    A comment on the discussion "I couldn't figure out how to implement even via demos." in Schillmania!:

    Scott
    Looks like the .swf isn't loading. You do have Flash 8 at least installed, right? It would appear either Flash isn't installed/supported, or the movie isn't loading. If the live demos on my site work but your local stuff doesn't, I suspect something with your local configuration. – Scott, on August 08, 2008 05:48
  • talk

    housni replied on August 07, 2008 19:39 to the discussion "I couldn't figure out how to implement even via demos." in Schillmania!:

    housni
    Hey Scott,
    Well I already tried the 'play mp3 links' method.

    this is the debug output:
    -----
    soundManager.initComplete(): calling soundManager.onerror()
    -- SoundManager 2 failed to load (security/load error) --
    soundManager.disable(): Disabling all functions - future calls will return false.
    soundManager: Failed to initialise.
    soundManager: No Flash response within reasonable time after document load.
    Possible causes: Flash version under 8, no support, or Flash security denying JS-Flash communication.
    soundManager: Getting impatient, still waiting for Flash.. ;)
    soundManager.beginDelayedInit(): Document loaded
    soundManager._initMovie(): Waiting for ExternalInterface call from Flash..
    soundManager._initMovie(): Got OBJECT element (created via JS)
    soundManager._createMovie(): Trying to load ../../soundmanager2.swf
    -- SoundManager 2 V2.75a.20080707 (AS2/Flash 8) --
    -----

    seems like it can't read soundmanager2.swf. i tried placing that file everywhere i thought it might be needed but no go.

    btw, i'm running this via my local server (Ubuntu). i'm just using PHP to read the local disk and output the mp3 files as links via HTML.

    right now, the page displays the mp3's fine (as links) but when i click on them, it launches my audio player (mplayer) instead of executing flash to play the mp3.
  • talk

    Scott replied on August 07, 2008 19:22 to the discussion "I couldn't figure out how to implement even via demos." in Schillmania!:

    Scott
    Hi housni,

    SM2 by itself doesn't make MP3s playable inline if you're simply including the javascript as with the "basic template" example; the basic demo gets the library up and running, but it is up to the developer to then write their own functionality from that point.

    There are however some demos which are included with SM2 which do this, as it's a commonly-requested feature.

    If you want to have a page that simply makes links to MP3s "play inline", I recommend looking at the play mp3 links demo, copying the files and then modifying the directory structure etc. for your own development environment.

    If you want to get fancier, there is also a Muxtape-style player which does the same inline playing, but with a fancier UI and more features.

    When first viewing the SM2 project in your browser after you've downloaded the project/demos/documentation (on the local file system, eg. c:\something or file://whatever..), Flash might not be permitting SM2 to start up due to security restrictions on the local file system. In that case, you should see some debug output instructing you to modify Flash's security settings for that particular page to be allowed to run. You will need to fix this issue before the demos will work on your hard drive.

    Alternately, SM2 works wonderfully and without security restrictions when served over HTTP (even from http://localhost/), so if you're running your own web server, you should not have to fiddle with Flash security - the demos should work without any fiddling, just like on the SM2 project page on my own site.
  • talk

    housni started a conversation in Schillmania! on August 07, 2008 15:31:

    housni
    I couldn't figure out how to implement even via demos.
    Hey Scott,
    i have very little experience in JS and i haven't worked with Flash for years.
    right now, i'm using PHP to read a list of mp3's from various location on disk and i display those mp3's in anchor tags.
    i had a look at your demos but i couldn't figure out how i could play the mp3's in place.

    all i've done is loaded the soundmanager2.js via HTML script tags.
    it looks as though soundmanager2.swf, soundmanager2_flash9.swf and the script/ folder should be present at a certain location as well (since the demo's also don't work without them)?

    am i missing something in my code?

    thanks.

    ps: lol i love the easter egg, btw.
  • talk

    Scott replied on June 17, 2008 02:04 to the discussion "remote/local/streaming audio simultaneously? and which id3 version?" in Schillmania!:

    Scott
    OK, in order!

    1) Remote MP3 support: Yep, you can load MP3s from remote URLs, different domains etc. on the web without issue, provided your page/app is served over HTTP (ie., on a web site) itself. If loading off the local filesystem, you will need to grant the Flash movie network file access in order for it to work. This can be done in the flash player global security settings control panel, the SM2 project page has more details on that. Once whitelisted, you can load both local filesystem-based and remote (over HTTP) MP3s from a page loading locally (offline).

    2) Streaming should be possible, though memory use / connection handling may be troublesome over longer periods of time. I haven't done any testing with this recently, but SM2 uses Flash and thus will exhibit the same kind of behaviour as a purely Flash-based app would in regards to loading/playing MP3 streams.

    3) Flash is reported to support both ID3V1 and ID3V2, and the behaviour is slightly different for each. Since the data for V1 is appended to the end of an MP3, it will not be received until the MP3 has fully-loaded. In the case of V2, it's right at the beginning - so this may affect your use/logic. Also I have seen some wackiness with ID3 data created/edited by iTunes, sometimes Flash doesn't seem to be able to read/parse it, at least Flash 8 from what I've seen (?) .. Just for the record. The SM2 project page has some details on this as well.
  • question

    A comment on the question "Plans to use Flash 9 or 10?" in Schillmania!:

    Scott
    Flash 9 allows access to "SoundSpectrum" (waveform?) data, 2x256 values from -1 to 1, and also sound "peak" data (left/right channel values from 0-1.) With the sound spectrum data you could draw a waveform (or a basic spectrum graph), and the peak data could be used like a "VU meter."


    I'm looking at making these features available, despite being somewhat esoteric; for the few people who've asked for this stuff, it may be useful. ;) The former has potential to be quite heavy on CPU in particular, so both features will be disabled by default as to avoid unnecessary overhead. – Scott, on June 17, 2008 01:56
  • talk

    housni started a conversation in Schillmania! on June 16, 2008 21:57:

    housni
    remote/local/streaming audio simultaneously? and which id3 version?
    Hi,
    I have 3 questions:

    -- 1 --
    How's remote mp3 support? I plan to use this to play mp3's that exist on the local filesystem as well as music that exist at other locations, accross a network and was wondering what I would have to go through to enable both these options, simultaneously.
    Does it involve Flash permissions, only?

    -- 2 --
    How about streaming audio from a service such as last.fm? Can that be done?

    -- 3 --
    What id3 versions do you support?

    Great work so far, btw :)
  • question

    housni replied on June 16, 2008 21:44 to the question "Plans to use Flash 9 or 10?" in Schillmania!:

    housni
    EQ features would be cool. I think that would be a good next step because I was looking at the interface and thinking "where's the EQ?"

    When do you plan to implement it, if at all?