VC-1 test source

May 23rd, 2008

To my great surprise there are people working with reference decoder and asking for files with some features and digestable by it. Well, here is an ultimate answer – RCV muxer for FFmpeg (hey, writing a muxer and patching FFmpeg build system were two things I haven’t done yet).

You can get FFmpeg sources, apply this patch, compile and try ffmpeg -i file.wmv -vcodec copy out.rcv. Good luck!

BIG FAT WARNING. It is not guaranteed to work with reference decoder on all files. Try files with smaller dimensions.
Or hack reference decoder to ignore image dimensions (ffplay would play those files correctly while reference decoder complains on something about “image size is too big for this level”).

RV: present state

May 18th, 2008

If you are interested in what’s going with my RV decoder from GSoC 2007 then here are your answers.

What works:

  • RV30 decoding mostly works
  • RV40 decoding mostly works
  • Pictures are quite recognizable

What needs to be resolved:

  • RV40 loop filter
  • RV30 loop filter (a bit easier)
  • RV30 motion vectors in B-frames (sometimes they are a bit jumpy)
  • RV30 chroma problems (colours are always moving to the upper left corner of the frame – incorrect rounding?)
  • RV30 slice uniting problem (some splitted slices should be united by decoder – at least I know how and when to do this)

If you want to help with loop filter then loop at
loop filter work scheme (SVG, ~128Kb) and give your proposals on how it works.
Legend (macroblock is 4×4 subblocks, no borders as they will ruin this scheme):

  • numbers at the top and left eddge – macroblock numbers
  • black lines – subblock edges where loop filtering took place
  • hex number at the top left corner of macroblock – coded block pattern, it’s red for intra types macroblocks and for P macroblocks with DC coeffs coded separately
  • blue square – coded subblock

Any suggestions (and pointers to the information about H.264 loop filtering explained clearer than in standard) are welcome.

I’d like to finish it before starting my work on AAC encoder…

BTW, you can use ffmpeg-rv.patch from soc/rv40 repository to enable RV30/40 decoding in ffmpeg.

Subtitles

May 6th, 2008

I consider subtitles to be more of evil. Why? Because they steal precious screen space, create a distraction and usually of a bad quality. Also external subtitles can create a lot of problems with synchronization, especially when movie is cut into parts. Our television channels have extremely small subtitles translating Russian speech into Ukrainian but nobody reads them anyway (and I don’t watch TV at all). Those subtitles can provide some amusement though because of very crooked translation (I’ve heard that “Vienna ball” was translated like “Vienna jumpings”, it’s hard to translate that word back).

I know, newer container formats like Matroska and OGM (both are not good) have support for subtitles and there are ‘advanced’ subtitle formats designed for them (like ASS) with a lot of features — font family/size/style selection, placing text in different parts of the screen, etc (backscratching is not there yet). Well, one day they will achieve what DVD subtitles already have – information overlay over moving picture.

Another issue with subtitles is the quality of translation. Well, usually translations are bad, especially low-budget when they don’t even have money for dub (fansubbing is a different thing). Personally I’ve found that neither Spanish, French nor Italian subtitles had helped me with understanding Wagner operas. And Chinese subtitles are hard to read (and impossible without the dictionary or Chinese man).
It’s better to learn language instead.

And now for something completely different – good examples of subtitles.
Read the rest of this entry »

A New Record

April 23rd, 2008

Well, this is not development-related in any way but worth mentioning anyway.
I was overoptimistic choosing UPS instead of diesel generator. There is no electricity at home and whole block for at least 22(twenty two) hours and not sure they will finish fixing power line today. Please don’t ask naive question “Don’t you have backup power lines?” – obviously we don’t.

Update. No power from about 9:00 April 22 to about 14:00 April 23. Not an experience I want to have again.

FFmpeg Hall of Shame

April 2nd, 2008

Following Mike’s example and with intention to spread the word, I welcome you to look at our Hall of Shame where you can find those, who use FFmpeg and probably other products but fail to comply to (L)GPL, giving no credit and/or sources.

So, if you want a bit of publicity follow their example. But don’t be surprised later.

Profiles and FFmpeg

March 26th, 2008

I think I ought to tell about the idea that fellow FFmpeg participant Robert Swain (I still wait for him to complete AMR-NB decoder) tries to champion. I mean encoding profiles.

The idea is quite simple – allow users use convenient presets instead of command line black magic, so simple commands like

ffmpeg -i input.vob -preset dvdrip -preset hq_mp3 output.avi
ffmpeg -i input.avi -preset flash_youtube output.flv
ffmpeg -i input.vob -preset ipod_vid output.mp4

can be used without bothering about bitrate/flags/gop size/whatever.

I also think this will be useful. It will be easier to change options meaning without making additional complications (we still get questions from users that do not know recent ffmpeg expects bitrate to be specified in bits, not in kilobits as before). Just don’t make frontend for it named ffclippy, okay?

Protected: Roads

March 26th, 2008

This content is password protected. To view it please enter your password below:

A new iron at work

March 25th, 2008

Tech support effect has worked – after I showed my new toy to familiar computer repairman it began to work. RAM installation is a black magic indeed.

So now I have a working x86-compatible box with 1GHz CPU and more RAM and harddrive space than on other boxes combined. I’ve already installed Ubuntu (just the first distro I reached, no actual preferences) and debug environment is almost ready, so I may continue RV[34] development soon.

Here is a photo of it with a piece of paper where its name is written. Try to guess it (and no, it is not related to anime).

My new box

A New Box

March 22nd, 2008

I’ve finally got an x86 box. Thanks to immeasurable efforts of Henning NorĂ©n who sent it to me.

On this poor quality photo you can see it. This box contains Pico-ITX based computer with more memory than on my other boxes together.

My New Box

The only bad moment is that though I’ve assembled it (and I believe assembled it properly) I can’t make it start up. DC converter (a small board to the right) produces voltages all right, so it’s not a power failure. Hopefully I will resolve this issue in a week, install Linux and resume my work on codecs development.

RV30/40 – status

March 4th, 2008

Just for curious people who really want to know what’s happening in rv30/40 decoder for libavcodec implementation.

I have implemented all main parts of decoder including loop filters, but some of the finer details are missing like parameters that should be passed to loop filters or motion vector prediction. This results into jerky picture in case of B-frames present (and they are often present) and dirty tails after moving objects. See for yourself.

Screenshot of decoder performance

Some example of my rv40 decoder work

Currently the work on this decoder is stalled. In order to fix bugs I have to verify decoded data against reference decoder and that’s not easy. It takes a whole night to get the needed debug data for 70 frames from 320×240 video on my ThinkPad 390. And it takes a lot of space too considering I have about a hundred megabytes of free disk space there.

I want to obtain a small (I don’t have enough space to fit standard desktop), low-power (less than 20-30 Wt power consumption, power blackouts are quite common here) x86-based computer. I know they exist in many variations, but it’s next to impossible to buy one here.

Well, I will finish both encoders. Eventually. Especially if I have enough content to test it with – most files I’ve met (including samples.mplayerhq.hu) are either Japanese TV recordings (anime often bears Chinese subtitles) or Simpsons with crappy translation into Russian (for example, “you rock” was translated as it if was “you are a rock”). Oh, there are also some movie trailers but I fear the need to watch them won’t motivate even Mike.

If you are curious why I chose that shot. I believe it features the character main MPlayer server is named after.