Adobe Premiere in AIR…

… not really 😉 but it`s impressive how far one can get in a few hours.
In this new version it`s now possible to edit multiple flv files and multiple mp3 files and combine them to one flv.
The binary stuff works pretty well but my main problem is the internal preview. It`s really difficult (impossible???) to play flvs and audio files and synchronize them.
Any suggestions?
So the solution for now is that everytime one clip is cut or the audio changes i create a new flv file in memory with all the changes applied and load that back into the preview.
Sure this takes some seconds and gets harder the bigger the files are but still it`s not that bad and you`ll get 100% accuracy.

Check out my screencast of the current progress here


Tweet about this on TwitterShare on FacebookShare on LinkedInShare on Google+Pin on Pinterest

13 thoughts on “Adobe Premiere in AIR…

  1. “It`s really difficult (impossible???) to play flvs and audio files and synchronize them.”

    You should speak to Andre Michelle – if anyone knows what sound can do in Flash it’ll be him.

  2. Hi,

    is there a way where we can test the lastest verion of richflv?

    looks amazing, good job.


  3. Hey Tommes,
    it`s still too early – it might take some more weeks, depending how much freetime i get 😉

  4. I think your approach is the right one, the user should see an accurate preview even if it takes a couple of seconds or more. One question, are you decoding the mp3 in order to make the cuts? or are you rearranging mp3 frames based on the timestamps?

  5. I don`t do any encoding for flvs or audio. If i import mp3 i convert the mp3 frames to flv frames and when cut just rearange them. As for the frame size do you mean the framerate? This is one thing that i`m thinking about right now. Currently it only works if all the flvs have the same framerate but it should be possible to even stutch together flvs with different framerates as variable framerates are allowed in flvs. Otherwise it would also be possible to change the framerate by rearanging the frames but this might affect the synching between audio and video frames.
    Still a lot of work to do but at the moment this project is freezed because i have too much serious stuff to do 😉
    I`ll keep you updated

  6. Hi, very cool app. As a feature, can you add a hotspot tool? So basic pen tool to create shapes over time. This creates an array of co ordinates that are dispatched to the player and drawn in real time along with an event property to listen for.

    What do you think?


  7. hello ! so nice!

    may I know about the opening of this source ?

    U will open your souce? or not ?

    I want to Use this source, any possible for me?

    I’m so interesting in your app.

    please give me a answer.

    and I feel honored by I know U.

  8. About Genaro, I think this means the size of the movie, indeed. Aspect ratio, nor frame rate. What will happen with two movies, one with 640×480 and other with 300×200, for example. The app will mantain ratio or stretch the movies?

    But my question it’s other. To include things as images or legends or movieclips… It should be very nice if may be included in a layer. (or editing state, something like that)

    And, congratulations.

  9. For the different framerates in flv’s and syncing audio you can use this:
    var needSamples:int = 0.001 * ((1000/frameRate)*(frameNumber)) * audioSampleRate * audioChannels;

    If you know how many samples you need for that frame you can rearrange the mp3 frames and set the “seek header attribute” to the correct value.

    I’m now busy coding a video-editor in Flex and I have the cutting, adding mp3’s running.
    The next thing is adding extra soundtracks with volume control.

  10. Hey Bernard,
    the problem is not to do it on the byte level but for the “quick” preview without rendering.
    So I need to sync programmatically the audio to the flv before combining them…
    Any chance to have a look at your work?

  11. I’m now busy organizing all code to neat classes. When testing I added code to the wrong places 😉 When I finished organizing you can have a look. Maybe we can combine/share some of the code to make things better.

    When you create data on byte level, how do you do it?
    I read the SWF specs and I’m creating a SWF in memory all with code like this:
    __swfBytes.writeShort(createHeader(SWFTags.SETBACKGROUNDCOLOR,3)); //Backgroundcolor header
    __swfBytes.writeByte(0xFF); //RED
    __swfBytes.writeByte(0xFF); //GREEN
    __swfBytes.writeByte(0xFF); //BLUE


    What I have seen on the internet is that most people just grabbed a swf/flv and cut out the header they needed, not creating it realtime.

    About the FLV’s: I cut them into frames, and keep track of the keyframes. Now you can cut the FLV starting on a keyframe ending on any frame you like.

  12. Damn, no edit button.. forgot some.

    About the audio syncing, I just create a new preview everytime somebody changes the timeline.
    It only takes a few seconds to render, so I think it no problem.
    You can probably create a faster preview by using an in memory SWF and create sprites for all assets and keep track of them. When you change the audio for example you can just change that sprite.

Leave a Reply

Your email address will not be published. Required fields are marked *