Good news!

Shortly after I wrote that last email I found that the cause of many (but not 
all,) of my major artifacts was my coding error in decoding the adaptation 
field length.

After re-reading the MPEG2 spec, I realized that I was one byte too short in 
calculating the byte offset of the payload when a adapation field was present 
in the TS packet. Hence, the frequent major artifacts were a result of one 
extra byte of data before the actual mpeg2 frame.

So, I am an idiot! How exciting is that? :-)

Anyway, the image is much more stable. However I still get a *lot* of artifacts 
when displaying a live shot of the ocean waves crashing onto a beach in 
California. (I work for a satellite company and we have some hi-def, fixed 
cameras at this particular beach...)

The edges of the waves, along with white caps on the waves definitely cause 
grief, but the biggest problem is the OSD of the clock-time superimposed on the 
frames (it changes every second,) - it looks like the time gets washed torwards 
the shore every time a wave passes through it. Also, the digits of the numbers 
are supposed to be white and they keep turning rainbow colors...

But, as sanity check, I a comparing the same satellite feed coming through 
libavcodec versus a commercial mpeg2 receiver, and the mpeg2 receiver has 
zero-problems with the OSD clock overlay. The time-digits are steady and white 
and the blockiness of the waves is finer grained.

Michael, I respect your work, knowledge and contributions to ffmpeg and would 
happy to post a stream capture of the live beach video tomorrow for folks to 
test with.

Based on the above descripton, do you have any recommendations for tweaking the 
CodecContext (or applying a post-processing filter to smooth-out the wave 
edges?)

Best Regards,
Bob Ingraham


----- Original Message -----
From: "Michael Niedermayer" <michae...@gmx.at>
To: "Bob Ingraham" <b...@brin.com>
Cc: libmpeg2-devel@lists.sourceforge.net
Sent: Thursday, March 19, 2009 6:39:05 PM GMT -07:00 US/Canada Mountain
Subject: Re: [mpeg2-dev] Decoding MPEG-TS stream

On Thu, Mar 19, 2009 at 05:55:09PM -0600, Bob Ingraham wrote:
> Thanks Måns.
> 
> The better result that I am seeking from libmpeg2 is better error detection 
> and concealment.

I belive libmpeg2 does no error concealment


> 
> I don't know if it is better in this way or not, but I have tweaked various 
> CodecContext variables in libavcodec and I am still getting too many 
> artifacts.

This is strange, could you make a short piece of the stream available
for other to check (that is a part which shows too many artifacts)

also you should be able to test the stream with mplayer, mplayer supports
both libmpeg2 and libavcodec

[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Democracy is the form of government in which you can choose your dictator

------------------------------------------------------------------------------
Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are
powering Web 2.0 with engaging, cross-platform capabilities. Quickly and
easily build your RIAs with Flex Builder, the Eclipse(TM)based development
software that enables intelligent coding and step-through debugging.
Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com
_______________________________________________
Libmpeg2-devel mailing list
Libmpeg2-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/libmpeg2-devel

Reply via email to