[libbluray-devel] Group BDJ_EVENT_*
hpi1
git at videolan.org
Mon May 16 13:58:03 CEST 2016
libbluray | branch: master | hpi1 <hpi1 at anonymous.org> | Mon May 16 09:20:41 2016 +0300| [d49a48f827e930f858f8a0a76c37c44093ee666e] | committer: hpi1
Group BDJ_EVENT_*
Add values for BJ_EVENT_* enums.
> http://git.videolan.org/gitweb.cgi/libbluray.git/?a=commit;h=d49a48f827e930f858f8a0a76c37c44093ee666e
---
src/libbluray/bdj/bdj.c | 43 ++++++++--------
src/libbluray/bdj/bdj.h | 54 ++++++++++++--------
src/libbluray/bdj/java/org/videolan/Libbluray.java | 38 +++++++-------
3 files changed, 77 insertions(+), 58 deletions(-)
diff --git a/src/libbluray/bdj/bdj.c b/src/libbluray/bdj/bdj.c
index ef82ee4..6e87f96 100644
--- a/src/libbluray/bdj/bdj.c
+++ b/src/libbluray/bdj/bdj.c
@@ -680,26 +680,29 @@ void bdj_close(BDJAVA *bdjava)
int bdj_process_event(BDJAVA *bdjava, unsigned ev, unsigned param)
{
static const char * const ev_name[] = {
- "NONE",
- "CHAPTER",
- "PLAYITEM",
- "ANGLE",
- "SUBTITLE",
- "END_OF_PLAYLIST",
- "PTS",
- "VK_KEY",
- "MARK",
- "PSR102",
- "PLAYLIST",
-
- "START",
- "STOP",
-
- "RATE",
- "AUDIO_STREAM",
- "SECONDARY_STREAM",
- "UO_MASKED",
- "SEEK",
+ /* 0 */ "NONE",
+
+ /* 1 */ "START",
+ /* 2 */ "STOP",
+ /* 3 */ "PSR102",
+
+ /* 4 */ "PLAYLIST",
+ /* 5 */ "PLAYITEM",
+ /* 6 */ "CHAPTER",
+ /* 7 */ "MARK",
+ /* 8 */ "PTS",
+ /* 9 */ "END_OF_PLAYLIST",
+
+ /* 10 */ "SEEK",
+ /* 11 */ "RATE",
+
+ /* 12 */ "ANGLE",
+ /* 13 */ "AUDIO_STREAM",
+ /* 14 */ "SUBTITLE",
+ /* 15 */ "SECONDARY_STREAM",
+
+ /* 16 */ "VK_KEY",
+ /* 17 */ "UO_MASKED",
};
JNIEnv* env;
diff --git a/src/libbluray/bdj/bdj.h b/src/libbluray/bdj/bdj.h
index 8c9feaf..4258470 100644
--- a/src/libbluray/bdj/bdj.h
+++ b/src/libbluray/bdj/bdj.h
@@ -23,26 +23,40 @@
#include "util/attributes.h"
typedef enum {
- BDJ_EVENT_NONE = 0,
- BDJ_EVENT_CHAPTER,
- BDJ_EVENT_PLAYITEM,
- BDJ_EVENT_ANGLE,
- BDJ_EVENT_SUBTITLE,
- BDJ_EVENT_END_OF_PLAYLIST,
- BDJ_EVENT_PTS,
- BDJ_EVENT_VK_KEY,
- BDJ_EVENT_MARK,
- BDJ_EVENT_PSR102,
- BDJ_EVENT_PLAYLIST,
-
- BDJ_EVENT_START, /* param: title number */
- BDJ_EVENT_STOP,
-
- BDJ_EVENT_RATE,
- BDJ_EVENT_AUDIO_STREAM,
- BDJ_EVENT_SECONDARY_STREAM,
- BDJ_EVENT_UO_MASKED,
- BDJ_EVENT_SEEK,
+ /* Note: these must be in sync with Libbluray.java ! */
+
+ BDJ_EVENT_NONE = 0,
+
+ /* Application control */
+
+ BDJ_EVENT_START = 1, /* param: title number */
+ BDJ_EVENT_STOP = 2,
+ BDJ_EVENT_PSR102 = 3,
+
+ /* Playback status */
+
+ BDJ_EVENT_PLAYLIST = 4,
+ BDJ_EVENT_PLAYITEM = 5,
+ BDJ_EVENT_CHAPTER = 6,
+ BDJ_EVENT_MARK = 7,
+ BDJ_EVENT_PTS = 8,
+ BDJ_EVENT_END_OF_PLAYLIST = 9,
+
+ BDJ_EVENT_SEEK = 10,
+ BDJ_EVENT_RATE = 11,
+
+ BDJ_EVENT_ANGLE = 12,
+ BDJ_EVENT_AUDIO_STREAM = 13,
+ BDJ_EVENT_SUBTITLE = 14,
+ BDJ_EVENT_SECONDARY_STREAM = 15,
+
+ /* User interaction */
+
+ BDJ_EVENT_VK_KEY = 16,
+ BDJ_EVENT_UO_MASKED = 17,
+
+ BDJ_EVENT_LAST = 17,
+
} BDJ_EVENT;
typedef struct {
diff --git a/src/libbluray/bdj/java/org/videolan/Libbluray.java b/src/libbluray/bdj/java/org/videolan/Libbluray.java
index a3c7e78..93e8f31 100644
--- a/src/libbluray/bdj/java/org/videolan/Libbluray.java
+++ b/src/libbluray/bdj/java/org/videolan/Libbluray.java
@@ -607,25 +607,27 @@ public class Libbluray {
}
}
- public static final int BDJ_EVENT_CHAPTER = 1;
- public static final int BDJ_EVENT_PLAYITEM = 2;
- public static final int BDJ_EVENT_ANGLE = 3;
- public static final int BDJ_EVENT_SUBTITLE = 4;
- public static final int BDJ_EVENT_END_OF_PLAYLIST = 5;
- public static final int BDJ_EVENT_PTS = 6;
- private static final int BDJ_EVENT_VK_KEY = 7;
- public static final int BDJ_EVENT_MARK = 8;
- private static final int BDJ_EVENT_PSR102 = 9;
- public static final int BDJ_EVENT_PLAYLIST = 10;
-
- private static final int BDJ_EVENT_START = 11;
- private static final int BDJ_EVENT_STOP = 12;
-
- public static final int BDJ_EVENT_RATE = 13;
- public static final int BDJ_EVENT_AUDIO_STREAM = 14;
+ private static final int BDJ_EVENT_START = 1;
+ private static final int BDJ_EVENT_STOP = 2;
+ private static final int BDJ_EVENT_PSR102 = 3;
+
+ public static final int BDJ_EVENT_PLAYLIST = 4;
+ public static final int BDJ_EVENT_PLAYITEM = 5;
+ public static final int BDJ_EVENT_CHAPTER = 6;
+ public static final int BDJ_EVENT_MARK = 7;
+ public static final int BDJ_EVENT_PTS = 8;
+ public static final int BDJ_EVENT_END_OF_PLAYLIST = 9;
+
+ public static final int BDJ_EVENT_SEEK = 10;
+ public static final int BDJ_EVENT_RATE = 11;
+
+ public static final int BDJ_EVENT_ANGLE = 12;
+ public static final int BDJ_EVENT_AUDIO_STREAM = 13;
+ public static final int BDJ_EVENT_SUBTITLE = 14;
public static final int BDJ_EVENT_SECONDARY_STREAM = 15;
- public static final int BDJ_EVENT_UO_MASKED = 16;
- public static final int BDJ_EVENT_SEEK = 17;
+
+ private static final int BDJ_EVENT_VK_KEY = 16;
+ public static final int BDJ_EVENT_UO_MASKED = 17;
/* TODO: use org/bluray/system/RegisterAccess instead */
public static final int PSR_IG_STREAM_ID = 0;
More information about the libbluray-devel
mailing list