4 Replies Latest reply on Apr 16, 2007 5:13 AM by Greg Dove

    Video deblocking won't work

    Andra Veraart

      Hi there,

      I wanted to see if deblocking could improve the way my video's look. After some failed attempts to incorporate it in to my existing fla, I decided to start from scratch and simply follow the manual's example.
      Here's the part I'm talking about:

      The following example plays video1.flv in the my_video video object, and lets the user change the deblocking filter behavior on video1.flv. Add a video object called my_video and a ComboBox instance called deblocking_cb to your file, and then add the following ActionScript to your FLA or AS file.

      var deblocking_cb:mx.controls.ComboBox;
      var my_video:Video; // my_video is a Video object on the Stage
      var my_nc:NetConnection = new NetConnection();
      my_nc.connect(null);
      var my_ns:NetStream = new NetStream(my_nc);
      my_video.attachVideo(my_ns);
      my_ns.play(" video1.flv");

      deblocking_cb.addItem({data:0, label:'Auto'});
      deblocking_cb.addItem({data:1, label:'No'});
      deblocking_cb.addItem({data: 2, label:'Yes'});

      var cbListener:Object = new Object();
      cbListener.change = function(evt:Object) {
      my_video.deblocking = evt.target.selectedItem.data;
      };
      deblocking_cb.addEventListener("change", cbListener);


      Use the ComboBox instance to change the deblocking filter behavior on video1.flv.



      I added a ComboBox-component and a FLVPlayback-component to the stage, and named them as described.
      The only things I changed to the AS are the parts in bold:
      I changed the filename to http://www.multimediamatters.nl/avproductie/commercials/NuKanHetNog.flv
      I changed the third addItem data to 5, because I am using an On2 video.

      When I preview the .fla I hear the audio, but the video doesn't seem to be loaded in the FLAPlayback-instance. It just keeps buffering, and when I push play it says it can't connect to the server.

      I'm probably missing something very obvious here, but could someone point me in the right direction please?
      Thanks in advance!

      Yours,
      Andra

        • 1. Re: Video deblocking won't work
          Andra Veraart Level 1
          Uhm, anyone?
          • 2. Re: Video deblocking won't work
            Greg Dove Level 4
            Just saw your post. You need to use a video object, not the FLVPlayback component.

            right-click in your library and choose New Video.
            make sure its 'actionscript-controlled'
            once its in the library drag it to the stage and name it my_video.

            FYI I got your flv working no problems.
            • 3. Re: Video deblocking won't work
              Andra Veraart Level 1
              That's it! Thanks!

              Unfortunately, the video's bit rate is pretty low. I believe it was around 350 kb/s. So the forced deblocking doesn't seem to add much to the quality of the video.

              My boss, of course, wants to have his cake AND eat it: he wants the display the video pretty large (550 by 413), with smooth playback, audio and video in sync, a minimum amount of compression artifacts and a minimum of preload/buffering time.
              Any ideas about what bitrates are appropriate these days, and any other "best practices" for flash video?

              Thanks again!
              Yours,

              Andra
              • 4. Re: Video deblocking won't work
                Greg Dove Level 4
                I'm no expert in video. In terms of 'best practices' I would just aim for the best quality that your users can handle in terms of bandwidth. Livedocs says that deblocking is not usually necessary for highbandwidth video. I don't know at what level their reference to 'high bandwidth' kicks in.

                The other thing is that if you have users across a range of bandwidth you might want to consider mutiple encodes to accomodate different users connection speeds. You could argue the case with your boss.