Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-2-2
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-2-2
Commits
9cc68b95
Commit
9cc68b95
authored
Mar 11, 2013
by
Martin Storsjö
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
omxil: Factorize event debug printing to a separate function
Signed-off-by:
Martin Storsjö
<
martin@martin.st
>
parent
369a7322
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
36 additions
and
22 deletions
+36
-22
modules/codec/omxil/omxil.c
modules/codec/omxil/omxil.c
+1
-22
modules/codec/omxil/omxil_utils.h
modules/codec/omxil/omxil_utils.h
+2
-0
modules/codec/omxil/utils.c
modules/codec/omxil/utils.c
+33
-0
No files found.
modules/codec/omxil/omxil.c
View file @
9cc68b95
...
@@ -1565,33 +1565,14 @@ static OMX_ERRORTYPE OmxEventHandler( OMX_HANDLETYPE omx_handle,
...
@@ -1565,33 +1565,14 @@ static OMX_ERRORTYPE OmxEventHandler( OMX_HANDLETYPE omx_handle,
unsigned
int
i
;
unsigned
int
i
;
(
void
)
omx_handle
;
(
void
)
omx_handle
;
PrintOmxEvent
((
vlc_object_t
*
)
p_dec
,
event
,
data_1
,
data_2
,
event_data
);
switch
(
event
)
switch
(
event
)
{
{
case
OMX_EventCmdComplete
:
switch
((
OMX_STATETYPE
)
data_1
)
{
case
OMX_CommandStateSet
:
msg_Dbg
(
p_dec
,
"OmxEventHandler (%s, %s, %s)"
,
EventToString
(
event
),
CommandToString
(
data_1
),
StateToString
(
data_2
)
);
break
;
default:
msg_Dbg
(
p_dec
,
"OmxEventHandler (%s, %s, %u)"
,
EventToString
(
event
),
CommandToString
(
data_1
),
(
unsigned
int
)
data_2
);
break
;
}
break
;
case
OMX_EventError
:
case
OMX_EventError
:
msg_Dbg
(
p_dec
,
"OmxEventHandler (%s, %s, %u, %s)"
,
EventToString
(
event
),
ErrorToString
((
OMX_ERRORTYPE
)
data_1
),
(
unsigned
int
)
data_2
,
(
const
char
*
)
event_data
);
//p_sys->b_error = true;
//p_sys->b_error = true;
break
;
break
;
case
OMX_EventPortSettingsChanged
:
case
OMX_EventPortSettingsChanged
:
msg_Dbg
(
p_dec
,
"OmxEventHandler (%s, %u, %u)"
,
EventToString
(
event
),
(
unsigned
int
)
data_1
,
(
unsigned
int
)
data_2
);
if
(
data_2
==
0
||
data_2
==
OMX_IndexParamPortDefinition
)
if
(
data_2
==
0
||
data_2
==
OMX_IndexParamPortDefinition
)
{
{
OMX_BUFFERHEADERTYPE
*
sentinel
;
OMX_BUFFERHEADERTYPE
*
sentinel
;
...
@@ -1617,8 +1598,6 @@ static OMX_ERRORTYPE OmxEventHandler( OMX_HANDLETYPE omx_handle,
...
@@ -1617,8 +1598,6 @@ static OMX_ERRORTYPE OmxEventHandler( OMX_HANDLETYPE omx_handle,
break
;
break
;
default:
default:
msg_Dbg
(
p_dec
,
"OmxEventHandler (%s, %u, %u)"
,
EventToString
(
event
),
(
unsigned
int
)
data_1
,
(
unsigned
int
)
data_2
);
break
;
break
;
}
}
...
...
modules/codec/omxil/omxil_utils.h
View file @
9cc68b95
...
@@ -158,6 +158,8 @@ OMX_ERRORTYPE WaitForOmxEvent(decoder_t *p_dec, OMX_EVENTTYPE *event,
...
@@ -158,6 +158,8 @@ OMX_ERRORTYPE WaitForOmxEvent(decoder_t *p_dec, OMX_EVENTTYPE *event,
OMX_ERRORTYPE
WaitForSpecificOmxEvent
(
decoder_t
*
p_dec
,
OMX_ERRORTYPE
WaitForSpecificOmxEvent
(
decoder_t
*
p_dec
,
OMX_EVENTTYPE
specific_event
,
OMX_U32
*
data_1
,
OMX_U32
*
data_2
,
OMX_EVENTTYPE
specific_event
,
OMX_U32
*
data_1
,
OMX_U32
*
data_2
,
OMX_PTR
*
event_data
);
OMX_PTR
*
event_data
);
void
PrintOmxEvent
(
vlc_object_t
*
p_this
,
OMX_EVENTTYPE
event
,
OMX_U32
data_1
,
OMX_U32
data_2
,
OMX_PTR
event_data
);
/*****************************************************************************
/*****************************************************************************
* Picture utility functions
* Picture utility functions
...
...
modules/codec/omxil/utils.c
View file @
9cc68b95
...
@@ -116,6 +116,39 @@ OMX_ERRORTYPE WaitForSpecificOmxEvent(decoder_t *p_dec,
...
@@ -116,6 +116,39 @@ OMX_ERRORTYPE WaitForSpecificOmxEvent(decoder_t *p_dec,
return
OMX_ErrorNone
;
return
OMX_ErrorNone
;
}
}
void
PrintOmxEvent
(
vlc_object_t
*
p_this
,
OMX_EVENTTYPE
event
,
OMX_U32
data_1
,
OMX_U32
data_2
,
OMX_PTR
event_data
)
{
switch
(
event
)
{
case
OMX_EventCmdComplete
:
switch
((
OMX_STATETYPE
)
data_1
)
{
case
OMX_CommandStateSet
:
msg_Dbg
(
p_this
,
"OmxEventHandler (%s, %s, %s)"
,
EventToString
(
event
),
CommandToString
(
data_1
),
StateToString
(
data_2
)
);
break
;
default:
msg_Dbg
(
p_this
,
"OmxEventHandler (%s, %s, %u)"
,
EventToString
(
event
),
CommandToString
(
data_1
),
(
unsigned
int
)
data_2
);
break
;
}
break
;
case
OMX_EventError
:
msg_Dbg
(
p_this
,
"OmxEventHandler (%s, %s, %u, %s)"
,
EventToString
(
event
),
ErrorToString
((
OMX_ERRORTYPE
)
data_1
),
(
unsigned
int
)
data_2
,
(
const
char
*
)
event_data
);
break
;
default:
msg_Dbg
(
p_this
,
"OmxEventHandler (%s, %u, %u)"
,
EventToString
(
event
),
(
unsigned
int
)
data_1
,
(
unsigned
int
)
data_2
);
break
;
}
}
/*****************************************************************************
/*****************************************************************************
* Picture utility functions
* Picture utility functions
*****************************************************************************/
*****************************************************************************/
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment