Free DLNA serv­er which works good with my Sony BRAVIA TV

In sev­er­al pre­vi­ous posts I wrote about my quest for the right source for­mat to stream video to my Sony BRAVIA TV (build in 2009). The last week-end I final­ly found some­thing which sat­is­fies me.

What I found was servi­io, a free UPnP-AV (DLNA) serv­er. It is writ­ten in java and runs on Win­dows, Lin­ux and FreeB­SD (it is not list­ed on the web­site, but we have an not-so-up-to-date ver­sion in the ports tree). If nec­es­sary it transcodes the input to an appro­pri­ate for­mat for the DLNA ren­der­er (in my case the TV).

I test­ed it with my slow Net­book, so that I was able to see with which input for­mat it will just remux the input con­tain­er to a MPEG trans­port stream, and which input for­mat would be real­ly re-encoded to a for­mat the TV under­stands.

The bot­tom line of the tests is, that I just need to use a sup­port­ed con­tain­er (like MKV or MP4 or AVI) with H.264-encoded video (e.g. encod­ed by x264) and AC3 audio.

The TV is able to chose between sev­er­al audio streams, but I have not test­ed if servi­io is able to serve files with mul­ti­ple audio streams (my wife has a dif­fer­ent moth­er lan­guage than me, so it is inter­est­ing for us to have mul­ti­ple audio streams for a movie), and I do not know if DLNA sup­ports some­thing like this.

Now I just have to replace minidl­na (which only works good with my TV for MP3s and Pic­tures) with servi­io on my FreeB­SD file serv­er and we can for­get about the disk-juggling.

Send to Kin­dle

Sony Bravia and HD videos (via DLNA)

I made some more tests which video res­o­lu­tions my TV accepts via DLNA. While I was look­ing before a SD res­o­lu­tions, this time I took care about some HD res­o­lu­tions.

As the Sin­tel video in the 1024×436 res­o­lu­tion did not play, I tried to reen­code it to 1024×720 (for the enabled x264 options see below). This did not work either. After that I went to the offi­cial res­o­lu­tion of 1280×720, and this works. Ini­tial­ly this video was encod­ed as High@L3.1, but with this the TV pro­duced some arti­facts on play­back. After chang­ing this to High@L4.0 (sim­ply by remux­ing instead of reen­cod­ing), the play­back was fine (warn­ing: increas­ing the H.264 lev­el is OK, decreas­ing it if the video does not com­ply to the low­ered lev­el, may cause prob­lems). I miss a set­ting in avide­mux for the lev­el, it would be nice if there would be the pos­si­bil­i­ty to set it.

I also test­ed if the 1280×544 ver­sion of the Sin­tel video plays fine on the TV or not. It does not play fine, so there is prob­a­bly a hard require­ment on the com­plete res­o­lu­tion for HD video.

While doing this I noticed that tsMux­eR is trun­cat­ing the audio, instead of the 6 chan­nel audio it was before, the remuxed file has only two chan­nels.

As I did not want to always go through all the set­tings to enter what I want, I made a lit­tle avidemux-script to set­up (ECMA script + xml) every­thing for me. This was easy, I just took an exist­ing one (the Sony PSP one) as a base and changed the encod­ing options and the tar­get con­tain­er (unluck­i­ly avide­mux 2.5.4 does not sup­port H.264 in MPEG-TS yet, so I have to use a MP4 con­tain­er and remux it into the MPEG-TS stream after­wards).

The options I used for the x264-reencoding are –8x8dct –analyse all –mixed-refs –bime –weightb –subme 9 –b‑rdo –ref 4 –b‑adapt 2 –bframes 4 –direct auto –me umh (this includes b‑pyramid, for which there are reports that it does not work).

Send to Kin­dle