QTIndexSwapper 2

Posted on June 16, 2010 | 63 comments

Adobe Creative Cloud

It has been quite some time since I have updated anything on the QTIndexSwapper AIR application. I figured the release of AIR 2.0 and Flex 4 would be a good reason to give it a face lift. I added the ability to point to a specific folder to process a bunch of files at once. Future updates would be to let the user set a watch folder and output folder then it could just swap ATOM’s on any h264 file that shows up in the watch folder.

What is QTIndexSwapper?

With the release of the Flash Player 9 Update that supports H.264, we can now play a subset of H.264 movie files. The problem is most of the H.264 files have the index at the end of the file which for progressive download means you have to download the whole file before you can start watching any of the video.

In the notes from Tinic Uro, Adobe engineer working on the changes, there is mention of a C application that helps with rearrange the inards of a movie to put the index at the beginning. Thus help with the progressive download issue. To this end I have create an AIR application which does the index swapping for you.

Its called “QT Index Swapper” and if that isn’t enough I have also made the source available inside the AIR application. The AIR application does not have the source files include any more but the source files are available as a Flex 4 project (.fxp).

The application can be download here.

  • Pingback: Renaun's thoughts on QTIndexSwapper v1.4.2 update

  • Pingback: Renaun's thoughts on QTIndexSwapper v1.3.2

  • Pingback: Tweets that mention Renaun's thoughts on QTIndexSwapper 2 -- Topsy.com

  • http://gfsis.org Temur

    Please, explain how to run this application – QTIndexSwapper.air

    • http://www.renaun.com Renaun Erickson

      Just double click the file and it should ask you to install the Adobe AIR runtime.

  • Pingback: Clock Blogs » Blog Archive » Mooving the Atom & H.264 Video Codec - Blogs from the employees of Clock

  • http://JasonRAyers.com Jason R. Ayers

    Thank you so much for creating this application. I spent a lot of time trying to figure out why my H.264 files would not start as quickly as my FLV files.

  • http://www.mountainbikerides.co.uk Mad Pierre

    A great little app but it still doesn’t seem to work with large files? E.g. I just tried it on a 800Mb file.

    Also I’m afraid to say the new version doesn’t give any error or let you know what it’s doing when this happens unlike the old one…. it just stops with the loading progress bar at whatever percentage it gets to.

    • http://www.renaun.com Renaun Erickson

      What happens when you click on the details button? The information should be there with more details.

  • Ed H.

    I processed an .mov file through this app (I just loaded the file in, then hit “process”.), then embedded the new file on my site, and now there’s no sound. What gives?

    • http://www.renaun.com Renaun Erickson

      Can you provide a link to the original video for me to test with?

  • deepak

    Your application is good as i read. but it not working with my mp4 video please help me ….


    • http://www.renaun.com Renaun Erickson

      Your C_019.mp4 file is already progressive ready. The moov atom is located before the mdat atom.

      • deepak

        Hi Renaun Erickson,
        thanks for quick response …
        Actually i am playing this mp4 file in JWplayer 5 .it play after downloading ..
        then i read same issues at Longtail.com (they developed JWplayer) most of user talking about your application even longtail also recommend.
        now you said my mp4 file if good to run but it still downloading before playing …

        is there any problem? or do i need something else like streaming server and all that….

        Please help me out…

        Thanks in advance ….

  • http://www.artvideo.cc Dariusz

    Thanks a lot !!!!!!!!!!!!!
    Is working perfectly on win 7 ultimate 64, f4v created with Ultra Video Joiner.

    Thank you very very much.

  • http://pesenzon.ru Alexander


    Mad Pierre says:
    3:17 AM – 07/13/10
    Reply A great little app but it still doesn’t seem to work with large files? E.g. I just tried it on a 800Mb file.

    Also I’m afraid to say the new version doesn’t give any error or let you know what it’s doing when this happens unlike the old one…. it just stops with the loading progress bar at whatever percentage it gets to.

    Renaun Erickson says:
    5:39 AM – 07/13/10
    Reply What happens when you click on the details button? The information should be there with more details.

    I have the same hang-on situation when files bigger than 360mb, loading progress stops at some percentage, when click details button – details field is empty.
    It works good for the files under 260 mb.
    Once for 300mb file first time didn’t work with same hanging on, for the second try program have prosessed the file.
    Where is the problem for bigger files, in program or computer setups?

    • http://www.renaun.com Renaun Erickson

      The large file issue was fixed since release v2.1.0. Please update and let me know if that worked.

  • Dougp

    I’m trying to install QTIndex swapper on my windows 7 box. I’ve downloaded the original and the 2nd version. Both come back with the installer file is damaged. I even downloaded and installed adobe Air thinking that might help, but no luck. Any ideas what the problem is?

    • Anonymous

      Did you get the .air file from renaun.com or somewhere else?

      • Noisoli

        Hi i try to use QTIndexSwapper i imported m4v file and processed.
        The program create a new file with extension qtp.
        But a new doesn’t works correct it seems damaged.
        Could you help me?
        I download file from renaun.com i use win7 64bit

        • Anonymous

          How large is your video file?

  • http://twitter.com/jkafkaris J.Kafkaris

    Very handy app! Thanks Renaun!

  • Xt3xm

    Hello, Ranaun.

    Could you tell me how to use this app on/for my site to get MP4 files to play from the beginning?

    For some reason, I cannot open the app (I dl’d from here, your blog) and I’ve no idea what to do with it, as there’s no instructions.

    Thank you.

    • Anonymous

      It requires Adobe AIR, if you do not have it installed it should promote you to download it. Once installed you just open the mp4 files you want to swap the ATOM indexes of.

      • Xt3xm

        It didn’t prompt me to dl AIR, but I can do that.

        Is it difficult to figure out how to swap ATOM indexes? I’ve no idea how to do that.

        Also, does your program just open with AIR or does it actually install anything?

        I just install AIR, open your program, import MP4 and there’s some option to swap indexes than just export?
        I do really appreciate your help.

        • Anonymous

          The app use AIR to run, like Java uses a JVM. With the app you load mp4 that need to have the ATOM index rearranged and it does that part for you (or tells you it is done already).

  • René

    Would be interesting to know what tool to use in a Linux environment.

    • Anonymous

      ffmpeg or the original qtindexswapper.c app (you’ll have to compile it yourself).

  • Catalina

    I was so sad cause I spent all day fixing my videos to mp4 and when I got to the JW Player they didn’t load even one of only 11MB… but now they do! I’m so so happy.. this app is like a miracle for me today : )

  • Szelma

    Hi, I used the app (very user-friendly). It renamed the mp4 file with “qtp” – seemed to work as it should, but still the video won’t run in JW Player. Is there also perhaps a setting that needs attention in the admin of the player? Thanks!

    • Anonymous

      I do not know about the JW Player

  • http://www.facebook.com/shahrukh1514 Sharukh Khan

    Thankx dude… It worked finally….

  • Mark

    Looks as though the app might have problems with large files. Selecting my 4.2GB MP4 file results in a “Loading 0%” progress bar – never changes.

    Pressing Porcess results in an error, which I guess is to be expected, as it hasn’t loaded.

    • Anonymous

      That might be hitting the 32bit limit. But a file that large seems counterproductive to stream as a file anyway.

  • Jared

    I have spent countless hours, days, and even weeks trying to get my MP4′s to play on my computer without a “delay”. Longtail pointed me to this site and your quick fix has saved me from throwing my computer out the window. Thanks for making this available!

  • Simon Donaldson

    Awesome work. Thanks!

  • Jeff Rouyer

    Thank you very much Renaun for an excellent tool! It really saved me some frustration with jwplayer. Now everything is pure bliss, well until my next project :)

  • Photodj

    might have problems with large files. Selecting my 4.2GB MP4 file results in a “Loading 0%” progress bar – never changes.

    • Anonymous

      32bit issue most likely, why would you want to stream that big of a file. The ATOM for all the indexes would be so large it would take a while to download, and at that point why not look at the pseudo streaming server solutions that inject the indexes on the fly for you.

  • George

    I would like to use a Java Script to read the length of the file and then write to the page an estimated amount of time the MP4 file will play. Can you tell me how to read the file length in the index file?


    • Anonymous

      You would have to have access to the bytes of the file and then start reading them according to the MP4 container format specification.

  • http://wpcommunity.com/ Tom Ford

    The app was running great for me, yet now, it ends up stuck on loading 0% (even when I go back and try a video that I’ve already successfully converted in the past…same video, yet, loading 0%).

    I did just update Adobe Air…could this have anything to do with it? The video I did before was 60mb…and the one now is 20mb, so I don’t think it’s the file size…but can’t figure out why it was loading and now doesn’t…

    Any ideas of where to start to try and figure this out?



  • Birger

    Amassing good app. I just found it yesterday and It was what I was looking for. So happy.



  • Milan

    Thousand thanks dude, you saved the rest of my day, nice weekend!!!

  • unixnerd

    Helped me out, thanks :-)

  • http://www.facebook.com/trevor.emdon.7 Trevor Emdon

    Wow! I just can’t believe what a difference that makes. Thank you so much.

  • nick

    Is there way to have the program to replace the file it is working with? that way I dont have to go in and delete and rename the files.

  • Chris

    I have put 2 mp4 videos through your application and still my videos will not play and just show a blank black screen.
    I can hear audio but cannot see the video.
    If I paste the url of the video in the browser then they play but will not play from my WordPress site through JW Player.

  • RetroMcSmart

    Thanks a lot. Very useful indeed.

  • http://twitter.com/BrianDKarr Brian Karr

    I’ve spent days trying to figure this out and stumbled upon this post. It worked perfectly and only took a couple minutes! Thanks.

  • aisawebmaster@aistaff.org

    After conversion, do I have to rename the file back to a .mp4

    • renaun

      No, u you can leave it or rename it as you needed to the conversion is inside the file.

  • rado

    ok so my youtube works fine but every other internet video i play i have to wait until it completely buffers first before it plays plzzz tell me how can i fix this problem??

  • http://twitter.com/ImAtRave Mr.Naurelius

    How to use?

    • renaun

      Open the application and then open up the mp4 file within the application. Then start the process.

  • Jason

    Hey great job on the app! I’m running win 7, but when I use it from the command line, the output file is only 1KB…it works perfectly when I run it normally…Here’s the log:

    Version: c:videovideo.mp4 – c:videooutput
    Atom Metadata: [code: ftyp,size: 32,offset: 0]
    Atom Metadata: [code: free,size: 8,offset: 32]
    Atom Metadata: [code: mdat,size: 58287727,offset: 40]
    Atom Metadata: [code: moov,size: 323189,offset: 58287767]

    Processed 1 files

    • renaun

      Does the non command line work with that file?

      Sent from a device

      • Jason

        Yes, it works perfectly when you don’t use the command line :)

        • renaun

          What does the log on the non-command line run look like? You can get it by clicking on the process button.

  • Robin

    QTIndexSwapper is a beautiful, efficient app. It quickly relocates the moov atom on .mp4 files enabling them to play instantly through html and places the modified file next to the original when complete. I was able to modify dozens of files in only a few minutes. Thanks Renaun for this terrific product!


    Very useful – many thanks for making this available. Just one question: I “fixed” an MP4 file of 60mins and then uploaded it. It plays correctly, and starts after a few seconds, but the time indicated for the video’s duration is 5mins.. Any idea why that happens, and if I can do anything about it? Thanks.

    • renaun

      Not sure, was it showing 60mins before? how large is the file size?

      • AGREGAT

        The “fixed” file is 391MB. If I play it in a player from my hard drive (I’ve tried more than one) the duration shown is 1:02:30. When I upload the same file on my website and play it online (using JW Player) the duration shown is 5:14, although it continues to play long after that for what appears to be the full length of the video:(http://www.translationstudiesportal.org/ar/media/entry/visualising_text_present_and_future_talk_by_dr._saturnino_luz).
        It’s not a serious problem but it is a bit misleading.

        • renaun

          Sounds like a JWPlayer bug, metadata could have been messed up but unlikely.

  • Scott VK

    I have up-to-date Air on my pc. When I select an mp4 file, QTIS2 just displays “loading” without any progress – even after 20 minutes. The file is about 3 minutes and the dimensions are 1280 x 720. I am using Win7 64 bit.

    • renaun

      Any log data you can retrieve will help, there might be a log file in your documents. But if its hanging not sure if it will finish up writing the log.

  • Victoria Whitehead

    Thank you. Saved me hours and hours of work. Much appreciated. x