Skip to content

Commit

Permalink
Merge pull request xbmc#17461 from AlwinEsch/few-changes
Browse files Browse the repository at this point in the history
[addons][inputstream] addon "C" style fixes and doxygen define add
  • Loading branch information
AlwinEsch authored and Maven85 committed Mar 12, 2020
1 parent 271b7be commit 0fabe98
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 2 deletions.
3 changes: 2 additions & 1 deletion docs/doxygen/Doxyfile.doxy
Original file line number Diff line number Diff line change
Expand Up @@ -2108,7 +2108,8 @@ INCLUDE_FILE_PATTERNS =
# This tag requires that the tag ENABLE_PREPROCESSING is set to YES.

PREDEFINED = DOXYGEN_SHOULD_SKIP_THIS \
DOXYGEN_SHOULD_USE_THIS
DOXYGEN_SHOULD_USE_THIS \
__cplusplus

# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then this
# tag can be used to specify a list of macro names that should be expanded. The
Expand Down
6 changes: 5 additions & 1 deletion xbmc/addons/kodi-addon-dev-kit/doxygen/Doxyfile
Original file line number Diff line number Diff line change
Expand Up @@ -828,6 +828,9 @@ INPUT = main.txt \
Modules/modules_python.dox \
Skin/skin.dox \
../../../../cmake/scripts/common/AddonHelpers.dox \
../../../cores/VideoPlayer/Interface/Addon/DemuxPacket.h \
../../../cores/VideoPlayer/Interface/Addon/InputStreamConstants.h \
../../../cores/VideoPlayer/Interface/Addon/TimingConstants.h \
../../../guilib/GUIRenderingControl.dox \
../../../guilib/GUIButtonControl.dox \
../../../guilib/GUIEditControl.dox \
Expand Down Expand Up @@ -2208,7 +2211,8 @@ INCLUDE_FILE_PATTERNS =
# This tag requires that the tag ENABLE_PREPROCESSING is set to YES.

PREDEFINED = DOXYGEN_SHOULD_SKIP_THIS \
DOXYGEN_SHOULD_USE_THIS
DOXYGEN_SHOULD_USE_THIS \
__cplusplus

# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then this
# tag can be used to specify a list of macro names that should be expanded. The
Expand Down
3 changes: 3 additions & 0 deletions xbmc/addons/kodi-addon-dev-kit/include/kodi/StreamCrypto.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@

#pragma once

#include <inttypes.h>
#include <string.h>

typedef struct CRYPTO_INFO
{
enum CRYPTO_KEY_SYSTEM : uint8_t
Expand Down
6 changes: 6 additions & 0 deletions xbmc/cores/VideoPlayer/Interface/Addon/TimingConstants.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,15 @@
#define DVD_TIME_BASE 1000000
#define DVD_NOPTS_VALUE 0xFFF0000000000000

#ifdef __cplusplus
constexpr int DVD_TIME_TO_MSEC(double x) { return static_cast<int>(x * 1000 / DVD_TIME_BASE); }
constexpr double DVD_SEC_TO_TIME(double x) { return x * DVD_TIME_BASE; }
constexpr double DVD_MSEC_TO_TIME(double x) { return x * DVD_TIME_BASE / 1000; }
#else
#define DVD_TIME_TO_MSEC(x) ((int)((double)(x) * 1000 / DVD_TIME_BASE))
#define DVD_SEC_TO_TIME(x) ((double)(x) * DVD_TIME_BASE)
#define DVD_MSEC_TO_TIME(x) ((double)(x) * DVD_TIME_BASE / 1000)
#endif

#define DVD_PLAYSPEED_PAUSE 0 // frame stepping
#define DVD_PLAYSPEED_NORMAL 1000

0 comments on commit 0fabe98

Please sign in to comment.