[vlc-commits] [Git][videolan/vlc][3.0.x] 12 commits: contrib: pthreads: use a mingw-w64 version from git

François Cartegnie (@fcartegnie) gitlab at videolan.org
Sat Mar 19 15:22:05 UTC 2022



François Cartegnie pushed to branch 3.0.x at VideoLAN / VLC


Commits:
d9196e86 by Steve Lhomme at 2022-03-19T14:37:32+00:00
contrib: pthreads: use a mingw-w64 version from git

(cherry picked from commit b8731a6096b59404c6cd8f4c034c04532cee9977) (edited)
edited:
- IApplicationData2 is not added

Signed-off-by: Steve Lhomme <robux4 at ycbcr.xyz>

- - - - -
78ec27d7 by Steve Lhomme at 2022-03-19T14:37:32+00:00
contrib: extract the dxvahd header from mingw64 directly

If we build with mingw64 8+ we didn't generate it, and we still won't.
Otherwise mingw64 was already extracted for winpthread, so we just use the
header from there.

(cherry picked from commit b16e3e7e5bcaaa34ec0bdf08c53f93ccaf869f41) (edited)
edited:
- 3.0 doesn't have winrt_headers

Signed-off-by: Steve Lhomme <robux4 at ycbcr.xyz>

- - - - -
17b93f58 by Steve Lhomme at 2022-03-19T14:37:32+00:00
contrib: pthreads: use mingw64 9.0.0 instead of an interim 8.0 hash

(cherry picked from commit 5b9beae04210dcbd6f33c6f8c3869c8b483d4151)

Signed-off-by: Steve Lhomme <robux4 at ycbcr.xyz>

- - - - -
f711c9db by Steve Lhomme at 2022-03-19T14:37:32+00:00
contrib: pthreads: only require windows headers when building for win32

And only check for HAVE_MINGW64_V8 use when not using MSVC.

(cherry picked from commit f7447e6a61b5925843f136d8ca1a98e81ae218cc) (rebased)
rebased:
- 3.0 doesn't have winrt_headers

Signed-off-by: Steve Lhomme <robux4 at ycbcr.xyz>

- - - - -
9d90a9da by Steve Lhomme at 2022-03-19T14:37:32+00:00
contrib: win32: allow checking more versions of mingw-w64

(cherry picked from commit 6d2a311585b40bd1a43db3bccc7219c1ede7f570) (edited)
edited:
- 3.0 already had MINGW_W64_VERSION

Signed-off-by: Steve Lhomme <robux4 at ycbcr.xyz>

- - - - -
4feba41c by Steve Lhomme at 2022-03-19T14:37:32+00:00
contrib: pthread: don't rebuild winpthread

We don't have any local patch for this library.

A normal mingw-w64 install has both libpthread.a and libpthread.dll.a, contribs
will use the former.

(cherry picked from commit de493a1d254468296c89d1fbb8163dd8820a744e) (rebased)
rebased:
- 3.0 uses mingw_at_least instead of HAVE_MINGW64_V8

Signed-off-by: Steve Lhomme <robux4 at ycbcr.xyz>

- - - - -
8f4b55fc by Steve Lhomme at 2022-03-19T14:37:32+00:00
contrib: pthread: use a recent mingw-w64 to get proper dcomp.h

We can't detect it based on a version of mingw until v10 is released and in our
images.

(cherry picked from commit 50e71ad6fb43c710d64ac4f3945cdd11ccfe5aa5) (edited)
edited:
- 3.0 doesn't have dcomp but wants the newer hash

Signed-off-by: Steve Lhomme <robux4 at ycbcr.xyz>

- - - - -
387470d8 by Steve Lhomme at 2022-03-19T14:37:32+00:00
contrib: pthreads: stop pretending we download just winpthreads

(cherry picked from commit 2d3539835d34dede150ca69d990b50422fd8400b) (edited)
edited:
- 3.0 doesn't have winrt_headers, dcomp

Signed-off-by: Steve Lhomme <robux4 at ycbcr.xyz>

- - - - -
cd70cb35 by Steve Lhomme at 2022-03-19T14:37:32+00:00
contrib: win32: only preprocess _mingw.h once

(cherry picked from commit 8a191b4cf3b18a4558f7f00d027e0c863e5fc026)

Signed-off-by: Steve Lhomme <robux4 at ycbcr.xyz>

- - - - -
7fac6112 by Steve Lhomme at 2022-03-19T14:37:32+00:00
contrib: pthreads: get the latest dxva header from mingw

In mingw 10 they are up to date with HEVC and AV1. Even in all the win32 images
we use.

If we ever need to patch it again we can do it on the mingw version

(cherry picked from commit 7e4e0b1f3d3363c9df715c9d3a01fe005ea664f0) (edited)
edited:
- 3.0 doesn't have winrt_headers, d3d9, dcomp

Signed-off-by: Steve Lhomme <robux4 at ycbcr.xyz>

- - - - -
ca10c672 by Steve Lhomme at 2022-03-19T14:37:32+00:00
contrib: slighty faster to get the mingw-w64 major version

It doesn't involve grep nor sed.

Co-authored-by: Stephen Kitt <steve at sk2.org>
(cherry picked from commit 4f73bdde05db0f2ce50dc146826086cc78297788)

Signed-off-by: Steve Lhomme <robux4 at ycbcr.xyz>

- - - - -
296b3a03 by Steve Lhomme at 2022-03-19T14:37:32+00:00
contrib: test pthread availability for Windows even without mingw-w64

If anyone has a pthread with a different Windows SDK it should work.

It will also avoid bogus pthread.h missing reports when mingw-w64 is not
detected properly. HAVE_WINPTHREAD is not checked and assumed to be
available.

(cherry picked from commit 4acd34bce8928ee68d4c1307bcbda172ec6e31ee)

Signed-off-by: Steve Lhomme <robux4 at ycbcr.xyz>

- - - - -


6 changed files:

- − contrib/src/dxvahd/SHA512SUMS
- − contrib/src/dxvahd/dxvahd.idl
- − contrib/src/dxvahd/rules.mak
- contrib/src/main.mak
- contrib/src/pthreads/SHA512SUMS
- contrib/src/pthreads/rules.mak


Changes:

=====================================
contrib/src/dxvahd/SHA512SUMS deleted
=====================================
@@ -1 +0,0 @@
-6c1ad18f38402751ec2bd8b9a1b4d669591de2f301205aa61431ba1671229cc38bf836f8fd1c87a488eeb603de671da7e27d0bb0a71599705a5cbbdab113e9df  dxvahd.idl


=====================================
contrib/src/dxvahd/dxvahd.idl deleted
=====================================
@@ -1,423 +0,0 @@
-/**
- * This file has no copyright assigned and is placed in the Public Domain.
- * This file is part of the mingw-w64 runtime package.
- * No warranty is given; refer to the file DISCLAIMER.PD within this package.
- */
-
-cpp_quote("#include <winapifamily.h>")
-cpp_quote("")
-cpp_quote("#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP)")
-cpp_quote("")
-cpp_quote("#if (_WIN32_WINNT >= 0x0601)")
-
-import "unknwn.idl";
-
-cpp_quote("#if 0")
-interface IDirect3DSurface9;
-interface IDirect3DDevice9Ex;
-typedef DWORD D3DFORMAT;
-typedef DWORD D3DPOOL;
-typedef struct { char dummy; } D3DCOLOR;
-cpp_quote("#endif")
-
-interface IDXVAHD_Device;
-interface IDXVAHD_VideoProcessor;
-
-typedef enum _DXVAHD_ALPHA_FILL_MODE {
-    DXVAHD_ALPHA_FILL_MODE_OPAQUE          = 0,
-    DXVAHD_ALPHA_FILL_MODE_BACKGROUND      = 1,
-    DXVAHD_ALPHA_FILL_MODE_DESTINATION     = 2,
-    DXVAHD_ALPHA_FILL_MODE_SOURCE_STREAM   = 3 
-} DXVAHD_ALPHA_FILL_MODE;
-
-typedef struct _DXVAHD_COLOR_YCbCrA {
-    FLOAT Y;
-    FLOAT Cb;
-    FLOAT Cr;
-    FLOAT A;
-} DXVAHD_COLOR_YCbCrA;
-
-typedef struct _DXVAHD_COLOR_RGBA {
-    FLOAT R;
-    FLOAT G;
-    FLOAT B;
-    FLOAT A;
-} DXVAHD_COLOR_RGBA;
-
-typedef union _DXVAHD_COLOR {
-    DXVAHD_COLOR_RGBA   RGB;
-    DXVAHD_COLOR_YCbCrA YCbCr;
-} DXVAHD_COLOR;
-
-typedef struct _DXVAHD_BLT_STATE_BACKGROUND_COLOR_DATA {
-    WINBOOL         YCbCr;
-    DXVAHD_COLOR BackgroundColor;
-} DXVAHD_BLT_STATE_BACKGROUND_COLOR_DATA;
-
-typedef enum _DXVAHD_BLT_STATE {
-  DXVAHD_BLT_STATE_TARGET_RECT          = 0,
-  DXVAHD_BLT_STATE_BACKGROUND_COLOR     = 1,
-  DXVAHD_BLT_STATE_OUTPUT_COLOR_SPACE   = 2,
-  DXVAHD_BLT_STATE_ALPHA_FILL           = 3,
-  DXVAHD_BLT_STATE_CONSTRICTION         = 4,
-  DXVAHD_BLT_STATE_PRIVATE              = 1000 
-} DXVAHD_BLT_STATE;
-
-typedef enum _DXVAHD_DEVICE_CAPS {
-  DXVAHD_DEVICE_CAPS_LINEAR_SPACE              = 0x1,
-  DXVAHD_DEVICE_CAPS_xvYCC                     = 0x2,
-  DXVAHD_DEVICE_CAPS_RGB_RANGE_CONVERSION      = 0x4,
-  DXVAHD_DEVICE_CAPS_YCbCr_MATRIX_CONVERSION   = 0x8 
-} DXVAHD_DEVICE_CAPS;
-
-typedef enum _DXVAHD_DEVICE_TYPE {
-  DXVAHD_DEVICE_TYPE_HARDWARE    = 0,
-  DXVAHD_DEVICE_TYPE_SOFTWARE    = 1,
-  DXVAHD_DEVICE_TYPE_REFERENCE   = 2,
-  DXVAHD_DEVICE_TYPE_OTHER       = 3 
-} DXVAHD_DEVICE_TYPE;
-
-typedef enum _DXVAHD_DEVICE_USAGE {
-  DXVAHD_DEVICE_USAGE_PLAYBACK_NORMAL   = 0,
-  DXVAHD_DEVICE_USAGE_OPTIMAL_SPEED     = 1,
-  DXVAHD_DEVICE_USAGE_OPTIMAL_QUALITY   = 2 
-} DXVAHD_DEVICE_USAGE;
-
-
-typedef enum _DXVAHD_FEATURE_CAPS {
-  DXVAHD_FEATURE_CAPS_ALPHA_FILL      = 0x1,
-  DXVAHD_FEATURE_CAPS_CONSTRICTION    = 0x2,
-  DXVAHD_FEATURE_CAPS_LUMA_KEY        = 0x4,
-  DXVAHD_FEATURE_CAPS_ALPHA_PALETTE   = 0x8 
-} DXVAHD_FEATURE_CAPS;
-
-typedef enum _DXVAHD_FILTER {
-  DXVAHD_FILTER_BRIGHTNESS           = 0,
-  DXVAHD_FILTER_CONTRAST             = 1,
-  DXVAHD_FILTER_HUE                  = 2,
-  DXVAHD_FILTER_SATURATION           = 3,
-  DXVAHD_FILTER_NOISE_REDUCTION      = 4,
-  DXVAHD_FILTER_EDGE_ENHANCEMENT     = 5,
-  DXVAHD_FILTER_ANAMORPHIC_SCALING   = 6 
-} DXVAHD_FILTER;
-
-typedef enum _DXVAHD_FILTER_CAPS {
-  DXVAHD_FILTER_CAPS_BRIGHTNESS           = 0x1,
-  DXVAHD_FILTER_CAPS_CONTRAST             = 0x2,
-  DXVAHD_FILTER_CAPS_HUE                  = 0x4,
-  DXVAHD_FILTER_CAPS_SATURATION           = 0x8,
-  DXVAHD_FILTER_CAPS_NOISE_REDUCTION      = 0x10,
-  DXVAHD_FILTER_CAPS_EDGE_ENHANCEMENT     = 0x20,
-  DXVAHD_FILTER_CAPS_ANAMORPHIC_SCALING   = 0x40 
-} DXVAHD_FILTER_CAPS;
-
-typedef enum _DXVAHD_FRAME_FORMAT {
-  DXVAHD_FRAME_FORMAT_PROGRESSIVE                     = 0,
-  DXVAHD_FRAME_FORMAT_INTERLACED_TOP_FIELD_FIRST      = 1,
-  DXVAHD_FRAME_FORMAT_INTERLACED_BOTTOM_FIELD_FIRST   = 2 
-} DXVAHD_FRAME_FORMAT;
-
-typedef enum _DXVAHD_INPUT_FORMAT_CAPS {
-  DXVAHD_INPUT_FORMAT_CAPS_RGB_INTERLACED       = 0x1,
-  DXVAHD_INPUT_FORMAT_CAPS_RGB_PROCAMP          = 0x2,
-  DXVAHD_INPUT_FORMAT_CAPS_RGB_LUMA_KEY         = 0x4,
-  DXVAHD_INPUT_FORMAT_CAPS_PALETTE_INTERLACED   = 0x8 
-} DXVAHD_INPUT_FORMAT_CAPS;
-
-typedef enum _DXVAHD_ITELECINE_CAPS {
-  DXVAHD_ITELECINE_CAPS_32             = 0x1,
-  DXVAHD_ITELECINE_CAPS_22             = 0x2,
-  DXVAHD_ITELECINE_CAPS_2224           = 0x4,
-  DXVAHD_ITELECINE_CAPS_2332           = 0x8,
-  DXVAHD_ITELECINE_CAPS_32322          = 0x10,
-  DXVAHD_ITELECINE_CAPS_55             = 0x20,
-  DXVAHD_ITELECINE_CAPS_64             = 0x40,
-  DXVAHD_ITELECINE_CAPS_87             = 0x80,
-  DXVAHD_ITELECINE_CAPS_222222222223   = 0x100,
-  DXVAHD_ITELECINE_CAPS_OTHER          = 0x80000000 
-} DXVAHD_ITELECINE_CAPS;
-
-typedef enum _DXVAHD_OUTPUT_RATE {
-  DXVAHD_OUTPUT_RATE_NORMAL   = 0,
-  DXVAHD_OUTPUT_RATE_HALF     = 1,
-  DXVAHD_OUTPUT_RATE_CUSTOM   = 2 
-} DXVAHD_OUTPUT_RATE;
-
-typedef enum _DXVAHD_PROCESSOR_CAPS {
-  DXVAHD_PROCESSOR_CAPS_DEINTERLACE_BLEND                 = 0x1,
-  DXVAHD_PROCESSOR_CAPS_DEINTERLACE_BOB                   = 0x2,
-  DXVAHD_PROCESSOR_CAPS_DEINTERLACE_ADAPTIVE              = 0x4,
-  DXVAHD_PROCESSOR_CAPS_DEINTERLACE_MOTION_COMPENSATION   = 0x8,
-  DXVAHD_PROCESSOR_CAPS_INVERSE_TELECINE                  = 0x10,
-  DXVAHD_PROCESSOR_CAPS_FRAME_RATE_CONVERSION             = 0x20 
-} DXVAHD_PROCESSOR_CAPS;
-
-typedef enum _DXVAHD_STREAM_STATE {
-  DXVAHD_STREAM_STATE_D3DFORMAT                   = 0,
-  DXVAHD_STREAM_STATE_FRAME_FORMAT                = 1,
-  DXVAHD_STREAM_STATE_INPUT_COLOR_SPACE           = 2,
-  DXVAHD_STREAM_STATE_OUTPUT_RATE                 = 3,
-  DXVAHD_STREAM_STATE_SOURCE_RECT                 = 4,
-  DXVAHD_STREAM_STATE_DESTINATION_RECT            = 5,
-  DXVAHD_STREAM_STATE_ALPHA                       = 6,
-  DXVAHD_STREAM_STATE_PALETTE                     = 7,
-  DXVAHD_STREAM_STATE_LUMA_KEY                    = 8,
-  DXVAHD_STREAM_STATE_ASPECT_RATIO                = 9,
-  DXVAHD_STREAM_STATE_FILTER_BRIGHTNESS           = 100,
-  DXVAHD_STREAM_STATE_FILTER_CONTRAST             = 101,
-  DXVAHD_STREAM_STATE_FILTER_HUE                  = 102,
-  DXVAHD_STREAM_STATE_FILTER_SATURATION           = 103,
-  DXVAHD_STREAM_STATE_FILTER_NOISE_REDUCTION      = 104,
-  DXVAHD_STREAM_STATE_FILTER_EDGE_ENHANCEMENT     = 105,
-  DXVAHD_STREAM_STATE_FILTER_ANAMORPHIC_SCALING   = 106,
-  DXVAHD_STREAM_STATE_PRIVATE                     = 1000 
-} DXVAHD_STREAM_STATE;
-
-typedef enum _DXVAHD_SURFACE_TYPE {
-  DXVAHD_SURFACE_TYPE_VIDEO_INPUT           = 0,
-  DXVAHD_SURFACE_TYPE_VIDEO_INPUT_PRIVATE   = 1,
-  DXVAHD_SURFACE_TYPE_VIDEO_OUTPUT          = 2 
-} DXVAHD_SURFACE_TYPE;
-
-typedef struct _DXVAHD_VPDEVCAPS {
-  DXVAHD_DEVICE_TYPE DeviceType;
-  UINT               DeviceCaps;
-  UINT               FeatureCaps;
-  UINT               FilterCaps;
-  UINT               InputFormatCaps;
-  D3DPOOL            InputPool;
-  UINT               OutputFormatCount;
-  UINT               InputFormatCount;
-  UINT               VideoProcessorCount;
-  UINT               MaxInputStreams;
-  UINT               MaxStreamStates;
-} DXVAHD_VPDEVCAPS;
-
-typedef struct _DXVAHD_BLT_STATE_ALPHA_FILL_DATA {
-  DXVAHD_ALPHA_FILL_MODE Mode;
-  UINT                   StreamNumber;
-} DXVAHD_BLT_STATE_ALPHA_FILL_DATA;
-
-typedef struct _DXVAHD_BLT_STATE_CONSTRICTION_DATA {
-  WINBOOL Enable;
-  SIZE Size;
-} DXVAHD_BLT_STATE_CONSTRICTION_DATA;
-
-typedef struct _DXVAHD_BLT_STATE_OUTPUT_COLOR_SPACE_DATA {
-  UINT Usage  :1;
-  UINT RGB_Range  :1;
-  UINT YCbCr_Matrix  :1;
-  UINT YCbCr_xvYCC  :1;
-} DXVAHD_BLT_STATE_OUTPUT_COLOR_SPACE_DATA;
-
-typedef struct _DXVAHD_BLT_STATE_PRIVATE_DATA {
-  GUID Guid;
-  UINT DataSize;
-  void *pData;
-} DXVAHD_BLT_STATE_PRIVATE_DATA;
-
-typedef struct _DXVAHD_BLT_STATE_TARGET_RECT_DATA {
-  WINBOOL Enable;
-  RECT TargetRect;
-} DXVAHD_BLT_STATE_TARGET_RECT_DATA;
-
-typedef struct _DXVAHD_RATIONAL {
-  UINT Numerator;
-  UINT Denominator;
-} DXVAHD_RATIONAL;
-
-typedef struct _DXVAHD_CONTENT_DESC {
-  DXVAHD_FRAME_FORMAT InputFrameFormat;
-  DXVAHD_RATIONAL     InputFrameRate;
-  UINT                InputWidth;
-  UINT                InputHeight;
-  DXVAHD_RATIONAL     OutputFrameRate;
-  UINT                OutputWidth;
-  UINT                OutputHeight;
-} DXVAHD_CONTENT_DESC;
-
-typedef struct _DXVAHD_CUSTOM_RATE_DATA {
-  DXVAHD_RATIONAL CustomRate;
-  UINT            OutputFrames;
-  WINBOOL         InputInterlaced;
-  UINT            InputFramesOrFields;
-} DXVAHD_CUSTOM_RATE_DATA;
-
-typedef struct _DXVAHD_FILTER_RANGE_DATA {
-  INT   Minimum;
-  INT   Maximum;
-  INT   Default;
-  FLOAT Multiplier;
-} DXVAHD_FILTER_RANGE_DATA;
-
-typedef struct _DXVAHD_STREAM_DATA {
-  WINBOOL           Enable;
-  UINT              OutputIndex;
-  UINT              InputFrameOrField;
-  UINT              PastFrames;
-  UINT              FutureFrames;
-  IDirect3DSurface9 **ppPastSurfaces;
-  IDirect3DSurface9 *pInputSurface;
-  IDirect3DSurface9 **ppFutureSurfaces;
-} DXVAHD_STREAM_DATA;
-
-typedef struct _DXVAHD_VPCAPS {
-  GUID VPGuid;
-  UINT PastFrames;
-  UINT FutureFrames;
-  UINT ProcessorCaps;
-  UINT ITelecineCaps;
-  UINT CustomRateCount;
-} DXVAHD_VPCAPS;
-
-typedef struct _DXVAHD_STREAM_STATE_ALPHA_DATA {
-  WINBOOL Enable;
-  FLOAT   Alpha;
-} DXVAHD_STREAM_STATE_ALPHA_DATA;
-
-typedef struct _DXVAHD_STREAM_STATE_ASPECT_RATIO_DATA {
-  WINBOOL         Enable;
-  DXVAHD_RATIONAL SourceAspectRatio;
-  DXVAHD_RATIONAL DestinationAspectRatio;
-} DXVAHD_STREAM_STATE_ASPECT_RATIO_DATA;
-
-typedef struct _DXVAHD_STREAM_STATE_D3DFORMAT_DATA {
-  D3DFORMAT Format;
-} DXVAHD_STREAM_STATE_D3DFORMAT_DATA;
-
-typedef struct _DXVAHD_STREAM_STATE_DESTINATION_RECT_DATA {
-  WINBOOL Enable;
-  RECT    DestinationRect;
-} DXVAHD_STREAM_STATE_DESTINATION_RECT_DATA;
-
-typedef struct _DXVAHD_STREAM_STATE_FILTER_DATA {
-  WINBOOL Enable;
-  INT     Level;
-} DXVAHD_STREAM_STATE_FILTER_DATA;
-
-typedef struct _DXVAHD_STREAM_STATE_FRAME_FORMAT_DATA {
-  DXVAHD_FRAME_FORMAT FrameFormat;
-} DXVAHD_STREAM_STATE_FRAME_FORMAT_DATA;
-
-typedef struct _DXVAHD_STREAM_STATE_INPUT_COLOR_SPACE_DATA {
-  UINT Type  :1;
-  UINT RGB_Range  :1;
-  UINT YCbCr_Matrix  :1;
-  UINT YCbCr_xvYCC  :1;
-} DXVAHD_STREAM_STATE_INPUT_COLOR_SPACE_DATA;
-
-typedef struct _DXVAHD_STREAM_STATE_LUMA_KEY_DATA {
-  WINBOOL Enable;
-  FLOAT   Lower;
-  FLOAT   Upper;
-} DXVAHD_STREAM_STATE_LUMA_KEY_DATA;
-
-typedef struct _DXVAHD_STREAM_STATE_OUTPUT_RATE_DATA {
-  WINBOOL            RepeatFrame;
-  DXVAHD_OUTPUT_RATE OutputRate;
-  DXVAHD_RATIONAL    CustomRate;
-} DXVAHD_STREAM_STATE_OUTPUT_RATE_DATA;
-
-typedef struct _DXVAHD_STREAM_STATE_SOURCE_RECT_DATA {
-  WINBOOL Enable;
-  RECT    SourceRect;
-} DXVAHD_STREAM_STATE_SOURCE_RECT_DATA;
-
-typedef struct _DXVAHD_STREAM_STATE_PRIVATE_IVTC_DATA {
-  WINBOOL Enable;
-  UINT    ITelecineFlags;
-  UINT    Frames;
-  UINT    InputField;
-} DXVAHD_STREAM_STATE_PRIVATE_IVTC_DATA;
-
-typedef struct _DXVAHD_STREAM_STATE_PRIVATE_DATA {
-  GUID Guid;
-  UINT DataSize;
-  void *pData;
-} DXVAHD_STREAM_STATE_PRIVATE_DATA;
-
-typedef struct _DXVAHD_STREAM_STATE_PALETTE_DATA {
-  UINT     Count;
-  D3DCOLOR *pEntries;
-} DXVAHD_STREAM_STATE_PALETTE_DATA;
-
-cpp_quote("typedef HRESULT ( STDMETHODCALLTYPE *PDXVAHDSW_CreateDevice )(IDirect3DDevice9Ex *pD3DDevice,HANDLE *phDevice);")
-cpp_quote("typedef HRESULT ( STDMETHODCALLTYPE *PDXVAHDSW_ProposeVideoPrivateFormat )(HANDLE hDevice,D3DFORMAT *pFormat);")
-cpp_quote("typedef HRESULT ( STDMETHODCALLTYPE *PDXVAHDSW_GetVideoProcessorDeviceCaps )(HANDLE hDevice,const DXVAHD_CONTENT_DESC *pContentDesc,DXVAHD_DEVICE_USAGE Usage,DXVAHD_VPDEVCAPS *pCaps);")
-cpp_quote("typedef HRESULT ( STDMETHODCALLTYPE *PDXVAHDSW_GetVideoProcessorOutputFormats )(HANDLE hDevice,const DXVAHD_CONTENT_DESC *pContentDesc,DXVAHD_DEVICE_USAGE Usage,UINT Count,D3DFORMAT *pFormats);")
-cpp_quote("typedef HRESULT ( STDMETHODCALLTYPE *PDXVAHDSW_GetVideoProcessorInputFormats )(HANDLE hDevice,const DXVAHD_CONTENT_DESC *pContentDesc,DXVAHD_DEVICE_USAGE Usage,UINT Count,D3DFORMAT *pFormats);")
-cpp_quote("typedef HRESULT ( STDMETHODCALLTYPE *PDXVAHDSW_GetVideoProcessorCaps )(HANDLE hDevice,const DXVAHD_CONTENT_DESC *pContentDesc,DXVAHD_DEVICE_USAGE Usage,UINT Count,DXVAHD_VPCAPS *pCaps);")
-cpp_quote("typedef HRESULT ( STDMETHODCALLTYPE *PDXVAHDSW_GetVideoProcessorCustomRates )(HANDLE hDevice,const GUID *pVPGuid,UINT Count,DXVAHD_CUSTOM_RATE_DATA *pRates);")
-cpp_quote("typedef HRESULT ( STDMETHODCALLTYPE *PDXVAHDSW_SetVideoProcessBltState )(HANDLE hVideoProcessor,DXVAHD_BLT_STATE State,UINT DataSize,const void *pData);")
-cpp_quote("typedef HRESULT ( STDMETHODCALLTYPE *PDXVAHDSW_CreateVideoProcessor )(HANDLE hDevice,const GUID *pVPGuid,HANDLE *phVideoProcessor);")
-cpp_quote("typedef HRESULT ( STDMETHODCALLTYPE *PDXVAHDSW_DestroyDevice )(HANDLE hDevice);")
-cpp_quote("typedef HRESULT ( STDMETHODCALLTYPE *PDXVAHDSW_GetVideoProcessorFilterRange )(HANDLE hDevice,DXVAHD_FILTER Filter,DXVAHD_FILTER_RANGE_DATA *pRange);")
-cpp_quote("typedef HRESULT ( STDMETHODCALLTYPE *PDXVAHDSW_DestroyVideoProcessor )(HANDLE hVideoProcessor);")
-cpp_quote("typedef HRESULT ( STDMETHODCALLTYPE *PDXVAHDSW_VideoProcessBltHD )(HANDLE hVideoProcessor,IDirect3DSurface9 *pOutputSurface,UINT OutputFrame,UINT StreamCount,const DXVAHD_STREAM_DATA *pStreams);")
-cpp_quote("typedef HRESULT ( STDMETHODCALLTYPE *PDXVAHDSW_GetVideoProcessStreamStatePrivate )(HANDLE hVideoProcessor,UINT StreamNumber,DXVAHD_STREAM_STATE_PRIVATE_DATA *pData);")
-cpp_quote("typedef HRESULT ( STDMETHODCALLTYPE *PDXVAHDSW_SetVideoProcessStreamState )(HANDLE hVideoProcessor,UINT StreamNumber,DXVAHD_STREAM_STATE State,UINT DataSize,const void *pData);")
-cpp_quote("typedef HRESULT ( STDMETHODCALLTYPE *PDXVAHDSW_GetVideoProcessBltStatePrivate )(HANDLE hVideoProcessor,DXVAHD_BLT_STATE_PRIVATE_DATA *pData);")
-cpp_quote("typedef HRESULT ( STDMETHODCALLTYPE *PDXVAHDSW_Plugin )(UINT Size,void *pCallbacks);")
-cpp_quote("")
-cpp_quote("typedef struct _DXVAHDSW_CALLBACKS {")
-cpp_quote("  PDXVAHDSW_CreateDevice                      CreateDevice;")
-cpp_quote("  PDXVAHDSW_ProposeVideoPrivateFormat         ProposeVideoPrivateFormat;")
-cpp_quote("  PDXVAHDSW_GetVideoProcessorDeviceCaps       GetVideoProcessorDeviceCaps;")
-cpp_quote("  PDXVAHDSW_GetVideoProcessorOutputFormats    GetVideoProcessorOutputFormats;")
-cpp_quote("  PDXVAHDSW_GetVideoProcessorInputFormats     GetVideoProcessorInputFormats;")
-cpp_quote("  PDXVAHDSW_GetVideoProcessorCaps             GetVideoProcessorCaps;")
-cpp_quote("  PDXVAHDSW_GetVideoProcessorCustomRates      GetVideoProcessorCustomRates;")
-cpp_quote("  PDXVAHDSW_GetVideoProcessorFilterRange      GetVideoProcessorFilterRange;")
-cpp_quote("  PDXVAHDSW_DestroyDevice                     DestroyDevice;")
-cpp_quote("  PDXVAHDSW_CreateVideoProcessor              CreateVideoProcessor;")
-cpp_quote("  PDXVAHDSW_SetVideoProcessBltState           SetVideoProcessBltState;")
-cpp_quote("  PDXVAHDSW_GetVideoProcessBltStatePrivate    GetVideoProcessBltStatePrivate;")
-cpp_quote("  PDXVAHDSW_SetVideoProcessStreamState        SetVideoProcessStreamState;")
-cpp_quote("  PDXVAHDSW_GetVideoProcessStreamStatePrivate GetVideoProcessStreamStatePrivate;")
-cpp_quote("  PDXVAHDSW_VideoProcessBltHD                 VideoProcessBltHD;")
-cpp_quote("  PDXVAHDSW_DestroyVideoProcessor             DestroyVideoProcessor;")
-cpp_quote("} DXVAHDSW_CALLBACKS;")
-cpp_quote("")
-cpp_quote("HRESULT DXVAHD_CreateDevice(IDirect3DDevice9Ex *pD3DDevice,const DXVAHD_CONTENT_DESC *pContentDesc,DXVAHD_DEVICE_USAGE Usage,PDXVAHDSW_Plugin pPlugin,IDXVAHD_Device **ppDevice);")
-cpp_quote("")
-cpp_quote("#ifdef __GNUC__")
-cpp_quote("#warning COM interfaces layout in this header has not been verified.")
-cpp_quote("#warning COM interfaces with incorrect layout may not work at all.")
-cpp_quote("__MINGW_BROKEN_INTERFACE(INTERFACE)")
-cpp_quote("#endif")
-[
-    object,
-    local
-]
-interface IDXVAHD_Device : IUnknown
-{
-    HRESULT CreateVideoSurface(UINT Width,UINT Height,D3DFORMAT Format,D3DPOOL Pool,DWORD Usage,DXVAHD_SURFACE_TYPE Type,UINT NumSurfaces,IDirect3DSurface9 **ppSurfaces,HANDLE *pSharedHandle);
-    HRESULT GetVideoProcessorDeviceCaps(DXVAHD_VPDEVCAPS *pCaps);
-    HRESULT GetVideoProcessorOutputFormats(UINT Count,D3DFORMAT *pFormats);
-    HRESULT GetVideoProcessorInputFormats(UINT Count,D3DFORMAT *pFormats);
-    HRESULT GetVideoProcessorCaps(UINT Count,DXVAHD_VPCAPS *pCaps);
-    HRESULT GetVideoProcessorCustomRates(const GUID *pVPGuid,UINT Count,DXVAHD_CUSTOM_RATE_DATA *pRates);
-    HRESULT GetVideoProcessorFilterRange(DXVAHD_FILTER Filter,DXVAHD_FILTER_RANGE_DATA *pRange);
-    HRESULT CreateVideoProcessor(const GUID *pVPGuid,IDXVAHD_VideoProcessor **ppVideoProcessor);
-};
-
-cpp_quote("#ifdef __GNUC__")
-cpp_quote("#warning COM interfaces layout in this header has not been verified.")
-cpp_quote("#warning COM interfaces with incorrect layout may not work at all.")
-cpp_quote("__MINGW_BROKEN_INTERFACE(INTERFACE)")
-cpp_quote("#endif")
-[
-    object,
-    local
-]
-interface IDXVAHD_VideoProcessor : IUnknown
-{
-    HRESULT SetVideoProcessBltState(DXVAHD_BLT_STATE State,UINT DataSize,const void *pData);
-    HRESULT GetVideoProcessBltState(DXVAHD_BLT_STATE State,UINT DataSize,void *pData);
-    HRESULT SetVideoProcessStreamState(UINT StreamNumber,DXVAHD_STREAM_STATE State,UINT DataSize,const void *pData);
-    HRESULT GetVideoProcessStreamState(UINT StreamNumber,DXVAHD_STREAM_STATE State,UINT DataSize,void *pData);
-    HRESULT VideoProcessBltHD(IDirect3DSurface9 *pOutputSurface,UINT OutputFrame,UINT StreamCount,const DXVAHD_STREAM_DATA *pStreams);
-};
-
-cpp_quote("#endif /*(_WIN32_WINNT >= 0x0601)*/")
-cpp_quote("#endif /*WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP)*/")


=====================================
contrib/src/dxvahd/rules.mak deleted
=====================================
@@ -1,26 +0,0 @@
-# generate Direct3D11 temporary include
-
-ifdef HAVE_CROSS_COMPILE
-IDL_INCLUDES = -I/usr/include/wine/windows/ -I/usr/include/wine/wine/windows/
-else
-#ugly way to get the default location of standard idl files
-IDL_INCLUDES = -I/`echo $(MSYSTEM) | tr A-Z a-z`/$(BUILD)/include
-endif
-
-DST_DXVAHD_H = $(PREFIX)/include/dxvahd.h
-
-ifdef HAVE_WIN32
-PKGS += dxvahd
-endif
-
-.sum-dxvahd: $(TARBALLS)/dxvahd.idl
-
-$(TARBALLS)/dxvahd.idl: $(SRC)/dxvahd/dxvahd.idl
-	cp $< $@
-
-$(DST_DXVAHD_H): $(TARBALLS)/dxvahd.idl .sum-dxvahd
-	mkdir -p -- "$(PREFIX)/include/"
-	$(WIDL) -DBOOL=WINBOOL -I$(PREFIX)/include $(IDL_INCLUDES) -h -o $@ $<
-
-.dxvahd: $(DST_DXVAHD_H)
-	touch $@


=====================================
contrib/src/main.mak
=====================================
@@ -142,9 +142,12 @@ endif
 
 LN_S = ln -s
 ifdef HAVE_WIN32
-ifneq ($(shell $(CC) $(CFLAGS) -E -dM -include _mingw.h - < /dev/null | grep -E __MINGW64_VERSION_MAJOR),)
+MINGW_W64_VERSION := $(shell echo "__MINGW64_VERSION_MAJOR" | $(CC) $(CFLAGS) -E -include _mingw.h - | tail -n 1)
+ifneq ($(MINGW_W64_VERSION),)
 HAVE_MINGW_W64 := 1
+mingw_at_least = $(shell [ $(MINGW_W64_VERSION) -gt $(1) ] && echo true)
 endif
+HAVE_WINPTHREAD := $(shell $(CC) $(CFLAGS) -E -dM -include pthread.h - < /dev/null >/dev/null 2>&1 || echo FAIL)
 ifndef HAVE_CROSS_COMPILE
 LN_S = cp -R
 endif


=====================================
contrib/src/pthreads/SHA512SUMS
=====================================
@@ -1 +1 @@
-30e5b2824a24eeb99ab519e3fc134cc9a7f04ee8b853bc8d66a13d1ab74144bf78b93e162bfe6de2a5e61f63c0e620a933b260b02d019cd68cc4b78bd36c67fd  mingw-w64-v7.0.0.tar.bz2
+4e2ffbb6cbe59c65f60d3f0035d1c2065b14ad16a63ae7a297f5c61d83b8e1b6847e3579996b91b2b9d807e3b9c1de2c60ee01a3349c9dd5f6e13d36f25221ea  mingw-w64-2c35e8ff0d33916bd490e8932cba2049cd1af3d0.tar.xz


=====================================
contrib/src/pthreads/rules.mak
=====================================
@@ -1,18 +1,39 @@
-# winpthreads
+# winpthreads, dxvahd
 
-WINPTHREADS_VERSION := 7.0.0
-WINPTHREADS_URL := https://sourceforge.net/projects/mingw-w64/files/mingw-w64/mingw-w64-release/mingw-w64-v$(WINPTHREADS_VERSION).tar.bz2/download
+MINGW64_VERSION := 9.0.0
+MINGW64_URL := https://sourceforge.net/projects/mingw-w64/files/mingw-w64/mingw-w64-release/mingw-w64-v$(MINGW64_VERSION).tar.bz2/download
+MINGW64_HASH=2c35e8ff0d33916bd490e8932cba2049cd1af3d0
+MINGW64_GITURL := https://git.code.sf.net/p/mingw-w64/mingw-w64
 
 ifdef HAVE_WIN32
 PKGS += pthreads
+
+ifndef HAVE_VISUALSTUDIO
+PKGS += dxva dxvahd
+PKGS_ALL += dxva dxvahd
+ifeq ($(call mingw_at_least, 8), true)
+PKGS_FOUND += dxvahd
+endif # MINGW 8
+ifeq ($(call mingw_at_least, 10), true)
+PKGS_FOUND += dxva
+endif # MINGW 10
+ifeq ($(HAVE_WINPTHREAD),)
+PKGS_FOUND += pthreads
 endif
+endif # !HAVE_VISUALSTUDIO
+endif # HAVE_WIN32
+
+$(TARBALLS)/mingw-w64-$(MINGW64_HASH).tar.xz:
+	$(call download_git,$(MINGW64_GITURL),,$(MINGW64_HASH))
 
-$(TARBALLS)/mingw-w64-v$(WINPTHREADS_VERSION).tar.bz2:
-	$(call download_pkg,$(WINPTHREADS_URL),winpthreads)
+$(TARBALLS)/mingw-w64-v$(MINGW64_VERSION).tar.bz2:
+	$(call download_pkg,$(MINGW64_URL),winpthreads)
 
-.sum-pthreads: mingw-w64-v$(WINPTHREADS_VERSION).tar.bz2
+# .sum-pthreads: mingw-w64-v$(MINGW64_VERSION).tar.bz2
+.sum-pthreads: mingw-w64-$(MINGW64_HASH).tar.xz
 
-pthreads: mingw-w64-v$(WINPTHREADS_VERSION).tar.bz2 .sum-pthreads
+# pthreads: mingw-w64-v$(MINGW64_VERSION).tar.bz2 .sum-pthreads
+pthreads: mingw-w64-$(MINGW64_HASH).tar.xz .sum-pthreads
 	$(UNPACK)
 	$(MOVE)
 
@@ -20,3 +41,20 @@ pthreads: mingw-w64-v$(WINPTHREADS_VERSION).tar.bz2 .sum-pthreads
 	cd $</mingw-w64-libraries/winpthreads && $(HOSTVARS) ./configure $(HOSTCONF)
 	cd $< && $(MAKE) -C mingw-w64-libraries -C winpthreads install
 	touch $@
+
+.sum-dxvahd: .sum-pthreads
+	touch $@
+
+.dxvahd: pthreads
+	mkdir -p -- "$(PREFIX)/include"
+	cd $< && cp mingw-w64-headers/include/dxvahd.h "$(PREFIX)/include"
+	touch $@
+
+.sum-dxva: .sum-pthreads
+	touch $@
+
+.dxva: pthreads
+	mkdir -p -- "$(PREFIX)/include"
+	cd $< && cp mingw-w64-headers/include/dxva.h "$(PREFIX)/include"
+	touch $@
+



View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/cb3428a1118c60016868c5cbab05d5475416a5e5...296b3a03aec5cc650688054bf533cb9d6c89e4d7

-- 
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/cb3428a1118c60016868c5cbab05d5475416a5e5...296b3a03aec5cc650688054bf533cb9d6c89e4d7
You're receiving this email because of your account on code.videolan.org.


VideoLAN code repository instance


More information about the vlc-commits mailing list