Skip to content
Snippets Groups Projects

msdkvp9enc: output video/x-vp9 raw data

Merged Haihao Xiang requested to merge haihao/gst-plugins-bad:msdk-vp9enc-src into master

video/x-vp9 is required in the src pad, however the output includes a IVF header, which makes the pipeline below doesn't work

gst-launch-1.0 videotestsrc ! msdkvp9enc ! msdkvp9dec ! fakesink

Since mfx 1.26, the VP9 encoder supports bitstream without IVF header, so in this patch, the mfx version is checked and msdkvp9enc is enabled only if mfx 1.26+ is available

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Víctor Manuel Jáquez Leal
  • Haihao Xiang added 13 commits

    added 13 commits

    Compare with previous version

  • mentioned in issue #1207 (closed)

  • Haihao Xiang resolved all threads

    resolved all threads

  • Haihao Xiang added 54 commits

    added 54 commits

    Compare with previous version

  • This breaks the build on my machine (Fedora 30). MFX_VERSION is 1026, pkg-config --modversion libmfx shows 1.23 :)

  • Author Developer

    I tested it with version 1025 (forced MFX_VERSION to 1025 in mfxdefs.h) on Ubuntu 18.04, gstmsdkvp9enc.c was excluded from source file list and I didn't see any compiler error. Is gstmsdkvp9enc.c still included in your environment? What's the version of your meson?

    I saw a compiler error below when I forced MFX_VERSION to 1023, which is not caused by this MR.

    ../../gst-plugins-bad/sys/msdk/gstmsdkallocator_libva.c:109:22: error: ‘MFX_MEMTYPE_VIDEO_MEMORY_ENCODER_TARGET’ undeclared (first use in this function); did you mean ‘MFX_MEMTYPE_VIDEO_MEMORY_DECODER_TARGET’?

    Could you attach your compiler error?

  • Author Developer

    Did you mean MFX_VERSION is 1026 in your environment but the mfx package version is 1.23? It is weird to me, usually MFX_VERSION should be matched with mfx package version. So is mfxExtVP9Param not defined in your environment?

  • Author Developer

    Could you give a try with haihao/gst-plugins-bad@1fd61d1c ? I added check for mfxExtVP9Param in meson.build

    • Did you mean MFX_VERSION is 1026 in your environment but the mfx package version is 1.23? It is weird to me, usually MFX_VERSION should be matched with mfx package version. So is mfxExtVP9Param not defined in your environment?

      Yes, that is what I meant. Re haihao/gst-plugins-bad@1fd61d1c I reckon it should work, but isn't the actual problem that libmfx's API version doesn't match the package version, and that you should check the former here? ie, check when the feature you're looking for was merged, and what was the next API version at the time?

    • Author Developer

      Sorry I don't understand you clearly. I checked the API version instead of package version in this patch. According to https://github.com/Intel-Media-SDK/MediaSDK/blob/master/api/include/mfxstructures.h#L2089-L2184, the feature is guarded for MFX_VERSION 1026, so I think the feature was merged for MFX_VERSION 1026. Why should I check the next API version?

    • I don't really know tbh :) All I can tell is that with my distro-provided package (Fedora 30), the version of the package is 1.23, and MFX_VERSION is 1026, and your comment (mfx 1.26+ is required to support raw VP9 stream) makes it seem MFX_VERSION == 1026 should match with pkg-config --modversion == 1.26, but it doesn't on my end :( Do you think the fedora package is broken?

    • Author Developer

      Maybe your package comes from somewhere else. According to https://src.fedoraproject.org/rpms/intel-mediasdk, intel-mediasdk was integrated into Fedora since Fedora 31 and the version was 1.30.

    • I don't think that is correct no:

       meh   libmicrodns  ~  devel  gst-build  sandbox  130  sudo dnf whatprovides /usr/lib64/pkgconfig/libmfx.pc
      [sudo] password for meh: 
      Last metadata expiration check: 1:50:36 ago on Fri 14 Feb 2020 02:40:23 PM CET.
      libmfx-devel-1.25-2.fc30.x86_64 : Intel hardware video acceleration dispatcher library - development files
      Repo        : @System
      Matched from:
      Filename    : /usr/lib64/pkgconfig/libmfx.pc
      
      libmfx-devel-1.25-2.fc30.x86_64 : Intel hardware video acceleration dispatcher library - development files
      Repo        : fedora
      Matched from:
      Filename    : /usr/lib64/pkgconfig/libmfx.pc
      
       meh   libmicrodns  ~  devel  gst-build  sandbox 
    • Author Developer

      The package name implies the package version is 1.25, however it seems you have header from 1.26 and package config from 1.23. It is really confused.

    • Author Developer

      BTW does haihao/gst-plugins-bad@1fd61d1c work for you? If yes, I will update the comment to make it more clear.

    • Please register or sign in to reply
  • Haihao Xiang mentioned in merge request !1066 (merged)

    mentioned in merge request !1066 (merged)

  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Please register or sign in to reply
    Loading