diff options
author | Timo Rothenpieler <timo@rothenpieler.org> | 2017-02-27 23:57:42 +0100 |
---|---|---|
committer | Timo Rothenpieler <timo@rothenpieler.org> | 2017-03-01 12:08:34 +0100 |
commit | b27be563a88544bf0e151321f073493817048f86 (patch) | |
tree | 93d16d6fd2df9d91962d0e8c87182535d9917af7 /compat | |
parent | d100dc6c9955af8b7a7a60a37a362a51c819222e (diff) | |
download | ffmpeg-b27be563a88544bf0e151321f073493817048f86.tar.gz |
compat/cuda: fix ulong size on cygwin
Diffstat (limited to 'compat')
-rw-r--r-- | compat/cuda/dynlink_cuviddec.h | 26 | ||||
-rw-r--r-- | compat/cuda/dynlink_nvcuvid.h | 4 |
2 files changed, 18 insertions, 12 deletions
diff --git a/compat/cuda/dynlink_cuviddec.h b/compat/cuda/dynlink_cuviddec.h index 9ff274161e..4d237643a1 100644 --- a/compat/cuda/dynlink_cuviddec.h +++ b/compat/cuda/dynlink_cuviddec.h @@ -45,6 +45,12 @@ extern "C" { #endif /* __cplusplus */ +#if defined(__CYGWIN__) +typedef unsigned int tcu_ulong; +#else +typedef unsigned long tcu_ulong; +#endif + typedef void *CUvideodecoder; typedef struct _CUcontextlock_st *CUvideoctxlock; @@ -125,14 +131,14 @@ typedef enum cudaVideoCreateFlags_enum { */ typedef struct _CUVIDDECODECREATEINFO { - unsigned long ulWidth; /**< Coded Sequence Width */ - unsigned long ulHeight; /**< Coded Sequence Height */ - unsigned long ulNumDecodeSurfaces; /**< Maximum number of internal decode surfaces */ + tcu_ulong ulWidth; /**< Coded Sequence Width */ + tcu_ulong ulHeight; /**< Coded Sequence Height */ + tcu_ulong ulNumDecodeSurfaces; /**< Maximum number of internal decode surfaces */ cudaVideoCodec CodecType; /**< cudaVideoCodec_XXX */ cudaVideoChromaFormat ChromaFormat; /**< cudaVideoChromaFormat_XXX (only 4:2:0 is currently supported) */ - unsigned long ulCreationFlags; /**< Decoder creation flags (cudaVideoCreateFlags_XXX) */ - unsigned long bitDepthMinus8; - unsigned long Reserved1[4]; /**< Reserved for future use - set to zero */ + tcu_ulong ulCreationFlags; /**< Decoder creation flags (cudaVideoCreateFlags_XXX) */ + tcu_ulong bitDepthMinus8; + tcu_ulong Reserved1[4]; /**< Reserved for future use - set to zero */ /** * area of the frame that should be displayed */ @@ -145,9 +151,9 @@ typedef struct _CUVIDDECODECREATEINFO cudaVideoSurfaceFormat OutputFormat; /**< cudaVideoSurfaceFormat_XXX */ cudaVideoDeinterlaceMode DeinterlaceMode; /**< cudaVideoDeinterlaceMode_XXX */ - unsigned long ulTargetWidth; /**< Post-processed Output Width (Should be aligned to 2) */ - unsigned long ulTargetHeight; /**< Post-processed Output Height (Should be aligbed to 2) */ - unsigned long ulNumOutputSurfaces; /**< Maximum number of output surfaces simultaneously mapped */ + tcu_ulong ulTargetWidth; /**< Post-processed Output Width (Should be aligned to 2) */ + tcu_ulong ulTargetHeight; /**< Post-processed Output Height (Should be aligbed to 2) */ + tcu_ulong ulNumOutputSurfaces; /**< Maximum number of output surfaces simultaneously mapped */ CUvideoctxlock vidLock; /**< If non-NULL, context lock used for synchronizing ownership of the cuda context */ /** * target rectangle in the output frame (for aspect ratio conversion) @@ -159,7 +165,7 @@ typedef struct _CUVIDDECODECREATEINFO short right; short bottom; } target_rect; - unsigned long Reserved2[5]; /**< Reserved for future use - set to zero */ + tcu_ulong Reserved2[5]; /**< Reserved for future use - set to zero */ } CUVIDDECODECREATEINFO; /*! diff --git a/compat/cuda/dynlink_nvcuvid.h b/compat/cuda/dynlink_nvcuvid.h index 6c197e0787..53e0a7b400 100644 --- a/compat/cuda/dynlink_nvcuvid.h +++ b/compat/cuda/dynlink_nvcuvid.h @@ -173,8 +173,8 @@ typedef enum { */ typedef struct _CUVIDSOURCEDATAPACKET { - unsigned long flags; /**< Combination of CUVID_PKT_XXX flags */ - unsigned long payload_size; /**< number of bytes in the payload (may be zero if EOS flag is set) */ + tcu_ulong flags; /**< Combination of CUVID_PKT_XXX flags */ + tcu_ulong payload_size; /**< number of bytes in the payload (may be zero if EOS flag is set) */ const unsigned char *payload; /**< Pointer to packet payload data (may be NULL if EOS flag is set) */ CUvideotimestamp timestamp; /**< Presentation timestamp (10MHz clock), only valid if CUVID_PKT_TIMESTAMP flag is set */ } CUVIDSOURCEDATAPACKET; |