From owner-freebsd-multimedia@freebsd.org Tue Feb 26 19:35:46 2019 Return-Path: Delivered-To: freebsd-multimedia@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7770115013D5 for ; Tue, 26 Feb 2019 19:35:46 +0000 (UTC) (envelope-from driesm.michiels@gmail.com) Received: from mail-ed1-x52a.google.com (mail-ed1-x52a.google.com [IPv6:2a00:1450:4864:20::52a]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id E1F176FD08; Tue, 26 Feb 2019 19:35:44 +0000 (UTC) (envelope-from driesm.michiels@gmail.com) Received: by mail-ed1-x52a.google.com with SMTP id f2so11757519edy.13; Tue, 26 Feb 2019 11:35:44 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:references:in-reply-to:subject:date:message-id :mime-version:content-transfer-encoding:thread-index :content-language; bh=kHuj4bNEYARWbP0X5C/8Xa2GgIPQYO0JgD8q404qLBY=; b=hS+om7I4LM9kyx9jAGfd2ZW1CRXedTkkUAxBhoFsKKjjWtIz9DaYNNdQDJ0c6hWUsQ EvW4ccl6rnG1PXL/I7F5a7C8NNRKgui8vVtvsxwho8Bt2tkF/WLP2IAyNEI6DXN7xO0M iwe0r1aEGImCUbUQ5MLJMV/1wlmyFeDjf5fxHxaxtzC9dkRqeNhvr/PvKVoOIqLItGNI bogf6+HFERLdgJaUM/u1XK7yvvz4+tbIV+b/j0wi1Xye4v/sglMUBdnw7ZVYzssU58Bd ob/OXTsGqR0Im6cL6qRLNqDFT8CSmQgFtT1ZlaWJaji7PkjmaxcbdTZEFZNiwZOR/Wnm zp0A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:references:in-reply-to:subject:date :message-id:mime-version:content-transfer-encoding:thread-index :content-language; bh=kHuj4bNEYARWbP0X5C/8Xa2GgIPQYO0JgD8q404qLBY=; b=Nw1hndbhFJ15mhUukycaPtKWSRtmJ/zGqKf/COQWJWduC1TFiBbUjz/ZElRutrOspT q1LrV4Ipwgx6EYXtzxxYb6oE3ddxTurvFfmrAb/FGIUDjEkZoE5zxjuXWaa9h+Ebar2m H8jIywn91LbS420WiIn+5eUCMXsakM9Q7ZtpryoLp+ElwiT/55c9UcM1ReFszAkTp7Ay u+weJgB7iDpfrhcI/Q2OnaE1Rw1GOX6SCuqrpk3MdVQsKG45kCHOQiUO7DPvI+j3VZyN hh7vg1UrgdL5Fyd5te2EK6yWmacPKT7j5ylJDKzBtjegQ5NducC6lcrY4UqJomz59MQm 6jsg== X-Gm-Message-State: AHQUAubzjWaDYJbD/ZiSJEb81MjdgVb5oyRiRDxKg6UG2XbBj+4BVq15 pPkYggapBn/rqUnWjesEZOmGTGPB X-Google-Smtp-Source: AHgI3IZY2LFpw4/8DAIJ+e97jopo+k4teuma4EsyX30MUutr+HL9uTcGJjTpiB87yV746ABuK0BpRw== X-Received: by 2002:a50:fa8f:: with SMTP id w15mr19511111edr.256.1551209741955; Tue, 26 Feb 2019 11:35:41 -0800 (PST) Received: from DRIESPC (ptr-8shv4ca0365qkznhf0t.18120a2.ip6.access.telenet.be. [2a02:1811:2500:a900:f571:3a4f:7e4b:94d]) by smtp.gmail.com with ESMTPSA id 31sm1048085edr.7.2019.02.26.11.35.41 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 26 Feb 2019 11:35:41 -0800 (PST) From: To: Cc: "'Jan Beich'" References: <005401d4c957$c6bbc840$543358c0$@gmail.com> In-Reply-To: Subject: RE: FFmpeg hardware transcoding Date: Tue, 26 Feb 2019 20:35:41 +0100 Message-ID: <002801d4ce0a$75c29bf0$6147d3d0$@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Outlook 16.0 Thread-Index: AQKxziGKgxekddFdaAFOvhnqau2a3AFf36BgpC13T+A= Content-Language: nl-be X-Rspamd-Queue-Id: E1F176FD08 X-Spamd-Bar: ------ Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20161025 header.b=hS+om7I4; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of driesmmichiels@gmail.com designates 2a00:1450:4864:20::52a as permitted sender) smtp.mailfrom=driesmmichiels@gmail.com X-Spamd-Result: default: False [-6.69 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; TO_DN_SOME(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2a00:1450:4000::/36]; FREEMAIL_FROM(0.00)[gmail.com]; RCVD_COUNT_THREE(0.00)[3]; MX_GOOD(-0.01)[cached: alt3.gmail-smtp-in.l.google.com]; DKIM_TRACE(0.00)[gmail.com:+]; RCPT_COUNT_TWO(0.00)[2]; NEURAL_HAM_SHORT(-0.98)[-0.979,0]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; FROM_EQ_ENVFROM(0.00)[]; RCVD_TLS_LAST(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:15169, ipnet:2a00:1450::/32, country:US]; TAGGED_FROM(0.00)[]; DWL_DNSWL_NONE(0.00)[gmail.com.dwl.dnswl.org : 127.0.5.0]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20161025]; MID_RHS_MATCH_FROM(0.00)[]; IP_SCORE(-2.70)[ip: (-9.16), ipnet: 2a00:1450::/32(-2.25), asn: 15169(-2.00), country: US(-0.07)]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[text/plain]; FROM_NO_DN(0.00)[]; RCVD_IN_DNSWL_NONE(0.00)[a.2.5.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.5.4.1.0.0.a.2.list.dnswl.org : 127.0.5.0] X-BeenThere: freebsd-multimedia@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Multimedia discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Feb 2019 19:35:46 -0000 Hi Multimedia mailing list, Here I am again with a follow-up question to this. I was wondering if hardware acceleration is possible even if I am building all ports with X11 unset (off). I noticed that when building ports related to hardware acceleration, more specifically, libva-utils to check if driver etc is detected with vainfo, it fails with this; [~]$ vainfo ld-elf.so.1: Shared object "libva-x11.so.2" not found, required by "vainfo" This fails because I build libva without X11 support. Is vainfo only supported to work on platforms that are running an X11 server? When I reinstall libva with X11 support vainfo works, although it does say its not detecting X11 server (which I'm not interested in). I am interested however in the capabilities of the detected driver and if it is detected at all. Output of vainfo: [~]$ vainfo error: XDG_RUNTIME_DIR not set in the environment. error: can't connect to X server! vainfo: VA-API version: 1.4 (libva 2.4.0) vainfo: Driver version: Intel i965 driver for Intel(R) Skylake - 2.3.0 vainfo: Supported profile and entrypoints VAProfileMPEG2Simple : VAEntrypointVLD VAProfileMPEG2Simple : VAEntrypointEncSlice VAProfileMPEG2Main : VAEntrypointVLD VAProfileMPEG2Main : VAEntrypointEncSlice VAProfileH264ConstrainedBaseline: VAEntrypointVLD VAProfileH264ConstrainedBaseline: VAEntrypointEncSlice VAProfileH264ConstrainedBaseline: VAEntrypointEncSliceLP VAProfileH264ConstrainedBaseline: VAEntrypointFEI VAProfileH264ConstrainedBaseline: VAEntrypointStats VAProfileH264Main : VAEntrypointVLD VAProfileH264Main : VAEntrypointEncSlice VAProfileH264Main : VAEntrypointEncSliceLP VAProfileH264Main : VAEntrypointFEI VAProfileH264Main : VAEntrypointStats VAProfileH264High : VAEntrypointVLD VAProfileH264High : VAEntrypointEncSlice VAProfileH264High : VAEntrypointEncSliceLP VAProfileH264High : VAEntrypointFEI VAProfileH264High : VAEntrypointStats VAProfileH264MultiviewHigh : VAEntrypointVLD VAProfileH264MultiviewHigh : VAEntrypointEncSlice VAProfileH264StereoHigh : VAEntrypointVLD VAProfileH264StereoHigh : VAEntrypointEncSlice VAProfileVC1Simple : VAEntrypointVLD VAProfileVC1Main : VAEntrypointVLD VAProfileVC1Advanced : VAEntrypointVLD VAProfileNone : VAEntrypointVideoProc VAProfileJPEGBaseline : VAEntrypointVLD VAProfileJPEGBaseline : VAEntrypointEncPicture VAProfileVP8Version0_3 : VAEntrypointVLD VAProfileVP8Version0_3 : VAEntrypointEncSlice VAProfileHEVCMain : VAEntrypointVLD VAProfileHEVCMain : VAEntrypointEncSlice Possible solution (although I'm really just guessing here and are probably not correct in many ways); - Try build vainfo without linking against libva-x11.so - Remove X11 option from libva and always enable it (only a few extra libraries that get pulled in by this) Thanks, Dries > -----Original Message----- > From: Jan Beich > Sent: woensdag 20 februari 2019 23:57 > To: driesm.michiels@gmail.com > Cc: freebsd-multimedia@freebsd.org > Subject: Re: FFmpeg hardware transcoding > > writes: > > > What is the minimum requirements for being able to utilize quick sync > > on my intel chip for ffmpeg hardware transcoding? > > I don't configure my system(s) daily to remember such things. ;) > > Quick Sync Video is exposed via MediaSDK (high-level) and libva (low-level). > MediaSDK hasn't been ported yet but media-driver (its backend) has. > FFmpeg and GStreamer support both MediaSDK and libva. > > > 1. DRM module loaded > > 2. Correct permission for the application on /dev/dri/renderD128 > > 3. FFmpeg build with libva support (VAAPI on) > > 4. Either libva-intel-driver or libva-intel-media-driver > > > Are there any more I am missing? > > Probably not. Try and report your issues. > > > I saw another driver in ports as "multimedia/libva-intel-media-driver"? > > Try both. ;) Some examples from > https://trac.ffmpeg.org/wiki/Hardware/VAAPI > don't work on iHD e.g., "Burn subtitles into the video while transcoding". > > i965 (libva-intel-driver) advantages: > - VP8 encoding on Skylake > - Partial VP8 encoding on Haswell/Broadwell > - Partial VP9 decoding on Haswell/Broadwell/Skylake > - H264 encoding profiles for Multiview and Stereo > > iHD (libva-intel-media-driver) advantages: > - Decoding on console framebuffer (e.g, mpv --gpu-context=drm) > - Better encoding performance (even without MediaSDK) > - FEI (Flexible Encoding Infrastructure) for HEVC > - JIT (Just-In-Time) compilation of media kernels (needs intel-graphics- > compiler) > - Icelake support (and maybe Xe in future) > - Actively developed upstream