libVLC 2.1.x opens 2 windows on a stream with 2 video tracks inside

This forum is about all development around libVLC.
Jo2003
Blank Cone
Blank Cone
Posts: 67
Joined: 08 Feb 2010 13:29

libVLC 2.1.x opens 2 windows on a stream with 2 video tracks inside

Postby Jo2003 » 11 Oct 2017 13:43

Hi all,

I use libVLC in a Qt application, using an embedded widget to show content there. This works fine. Now I've got a video stream with 2 video tracks inside. libVLC opens one video embedded as needed, but opens an additional window for the second video stream. I found a command line option "--preferred-resolution=[lines]" and the description sounds promising, but also if I use this, the 2nd video window is opened. Is there another way to force the usage of only one video track?

Here is the media info of the stream:

Code: Select all

General ID : 46675 (0xB653) Complete name : K:\Videos\xxxxx Format : MPEG-TS File size : 17.4 MiB Duration : 25s 400ms Overall bit rate mode : Variable Overall bit rate : 5 659 Kbps Video #1 ID : 70 (0x46) Menu ID : 1 (0x1) Format : AVC Format/Info : Advanced Video Codec Format profile : Main@L3.1 Format settings, CABAC : Yes Format settings, ReFrames : 1 frame Format settings, GOP : M=1, N=50 Codec ID : 27 Duration : 26s 960ms Width : 1 280 pixels Height : 720 pixels Display aspect ratio : 16:9 Frame rate : 25.000 fps Color space : YUV Chroma subsampling : 4:2:0 Bit depth : 8 bits Scan type : Progressive Video #2 ID : 71 (0x47) Menu ID : 1 (0x1) Format : AVC Format/Info : Advanced Video Codec Format profile : Main@L4.0 Format settings, CABAC : Yes Format settings, ReFrames : 1 frame Format settings, GOP : M=1, N=50 Codec ID : 27 Duration : 23s 620ms Width : 1 920 pixels Height : 1 080 pixels Display aspect ratio : 16:9 Frame rate : 25.000 fps Color space : YUV Chroma subsampling : 4:2:0 Bit depth : 8 bits Scan type : Progressive Audio #1 ID : 68 (0x44) Menu ID : 1 (0x1) Format : AAC Format/Info : Advanced Audio Codec Format version : Version 4 Format profile : LC Muxing mode : ADTS Codec ID : 15 Duration : 26s 986ms Bit rate mode : Variable Channel(s) : 2 channels Channel positions : Front: L R Sampling rate : 48.0 KHz Compression mode : Lossy Delay relative to video : -18ms Language : Russian Audio #2 ID : 69 (0x45) Menu ID : 1 (0x1) Format : AAC Format/Info : Advanced Audio Codec Format version : Version 4 Format profile : LC Muxing mode : ADTS Codec ID : 15 Duration : 26s 986ms Bit rate mode : Variable Channel(s) : 2 channels Channel positions : Front: L R Sampling rate : 48.0 KHz Compression mode : Lossy Delay relative to video : -17ms Language : Hebrew
Thanks in advance,
Jörg

Jean-Baptiste Kempf
Site Administrator
Site Administrator
Posts: 37523
Joined: 22 Jul 2005 15:29
VLC version: 4.0.0-git
Operating System: Linux, Windows, Mac
Location: Cone, France
Contact:

Re: libVLC 2.1.x opens 2 windows on a stream with 2 video tracks inside

Postby Jean-Baptiste Kempf » 16 Oct 2017 06:08

Use libvlc_video_set_track
Jean-Baptiste Kempf
http://www.jbkempf.com/ - http://www.jbkempf.com/blog/category/Videolan
VLC media player developer, VideoLAN President and Sites administrator
If you want an answer to your question, just be specific and precise. Don't use Private Messages.


Return to “Development around libVLC”

Who is online

Users browsing this forum: No registered users and 34 guests