A Flash Developer Resource Site

Results 1 to 4 of 4

Thread: JPG to SWF converter via Cold Fusion

  1. #1
    Junior Member
    Join Date
    Jul 2000
    Posts
    1

    Post

    Hi All,

    I'd like to build a Cold Fusion Application (or ASP for that matter) that would convert JPG's to SWF files. Has anyone built something similar? My thinking was to use <CFFILE> to open and read the jpg binary data to a var and wrap it the additional header and object information before using <CFContent> to output it as a swf format.

    I originally thought of using a basic swf and replacing the jpg data portion.

    I'm not interested in using a generator like product for the task, my requirement is to simply convert jpgs to single frame swf movies.

    Anyone have any thoughts on how this could be done would be appreciated!

    Dan



  2. #2
    Senior Member
    Join Date
    Jul 2000
    Posts
    503

    WHAT????

    I don't see any reason for doing that...it is quite pointless to convert a JPEG to a one frame flash movie.

    I would write an IISAPI server extension DLL with the SDK and access with your ASP it to build the SWF.

    --Jesse

  3. #3
    "Pointless"

    In *your* opinion, of course. So, what do you propose sites like moveon (http://www.moveon.co.uk) and Moonfruit (http://www.moonfruit.com) do in order to display user-uploaded images? "Show them in a new HTML window"? Idiot.

    As any fule kno, flash can't load in jpg files while running. It can, however, load in swfs. Hence the need for a converter.

    As a reply to the original poster, you will need to parse the jpg to get the pixel sizes as well - the "wrapper" you put around the jpg needs to know how to show it (movie size, scale matrix, shape record etc). The conversion isn't that hard, but more complicated than you think.

    Also be aware that photoshop jpgs are non-standard (mime type image/pjpeg or something), and won't convert in the same way - you should either convert them to standard jfif format first or do all sorts of weird stuff with the file.

    The basic answer is "it's not easy" - it'll take you a good few days' worth of coding and there aren't any freely available programs to do it. One day I'll clean up my perl converter and release it tho :-)

  4. #4
    yeah I reckon a convertor would be very handy when loading movies and an ASP or PHP module for this would be cool.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center