wrong aspect ratio in some m4v files



I have another little issue.
This time I can tell for sure, that it is happening in the Taygeta lib - and not in the nVLC part ;-)

I tried to play a m4v video and I noticed, that the aspect ration was wrong.
In VLC itself it was correct. Then I tested your test apps which came with nVLC. In the WinForm implementation it was also correct.
The error happens only in the WPF sample.

Here is an example video: http://www.der-knob.de/temp/vlcTest2.zip

WinForm (correct aspect ration)

WPF (wrong aspect ration)

Taygeta MainSample (wrong aspect ration)


roman_gin wrote Sep 10, 2013 at 4:37 PM


Both libVLC and Taygeta assume that video SAR (Sample Aspect Ratio) is 1:1.
While I can fix it in Taygeta, the libVLC does not provide this value (you can submit a change request to VLC developers).

Therefore, video files with SAR other than 1:1 are not supported for now.


Der_Knob wrote Sep 11, 2013 at 7:13 AM

H Roman,

but in VLC it is correct, isn't it?
When I play the video in VLC direct, it is displayed correct.
And also if you look at your WinForm example, it has the correct aspect ration.

Only when you use the Taygeta lib, the aspect ration is wrong...

Christian Knobloch

roman_gin wrote Sep 15, 2013 at 7:02 AM

Hi Christian,

VLC and Winforms example use internal rendering module which obviously aware of the video stream SAR (storage aspect ratio)
Taygeta samples use memory renderer (based on libVLC vmem module) and taygeta renderer.
I will add support for non square pixels (SAR != 1) in Taygeta project, however it will still not work for you since libVLC memory renderer does not provide SAR information.

Hope this is more clear now.


Der_Knob wrote Sep 15, 2013 at 7:40 AM

Ok, now I understood the problem :)
Thanks for your help!


Der_Knob wrote Oct 11, 2013 at 2:25 PM

Hi Roman,

I just tested with v. 2.1 from VLC and your latest version of nVLC and now it works correct :-)

Thanks for your help!