Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc
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
Commits
b945cfa8
Commit
b945cfa8
authored
Jul 17, 2014
by
Thomas Guillem
Committed by
Martin Storsjö
Jul 18, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
omxil: get rid of debug ifdefs
Signed-off-by:
Martin Storsjö
<
martin@martin.st
>
parent
8466eebf
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
38 deletions
+15
-38
modules/codec/omxil/omxil.c
modules/codec/omxil/omxil.c
+15
-38
No files found.
modules/codec/omxil/omxil.c
View file @
b945cfa8
...
@@ -42,7 +42,9 @@
...
@@ -42,7 +42,9 @@
#include "OMX_Broadcom.h"
#include "OMX_Broadcom.h"
#ifndef NDEBUG
#ifndef NDEBUG
# define OMXIL_EXTRA_DEBUG
# define OMX_DBG(...) msg_Dbg( p_dec, __VA_ARGS__ )
#else
# define OMX_DBG(...)
#endif
#endif
#define SENTINEL_FLAG 0x10000
#define SENTINEL_FLAG 0x10000
...
@@ -365,9 +367,7 @@ static OMX_ERRORTYPE AllocateBuffers(decoder_t *p_dec, OmxPort *p_port)
...
@@ -365,9 +367,7 @@ static OMX_ERRORTYPE AllocateBuffers(decoder_t *p_dec, OmxPort *p_port)
OMX_PARAM_PORTDEFINITIONTYPE
*
def
=
&
p_port
->
definition
;
OMX_PARAM_PORTDEFINITIONTYPE
*
def
=
&
p_port
->
definition
;
unsigned
int
i
;
unsigned
int
i
;
#ifdef OMXIL_EXTRA_DEBUG
OMX_DBG
(
"AllocateBuffers(%d)"
,
def
->
eDir
);
msg_Dbg
(
p_dec
,
"AllocateBuffers(%d)"
,
def
->
eDir
);
#endif
p_port
->
i_buffers
=
p_port
->
definition
.
nBufferCountActual
;
p_port
->
i_buffers
=
p_port
->
definition
.
nBufferCountActual
;
...
@@ -409,9 +409,7 @@ static OMX_ERRORTYPE AllocateBuffers(decoder_t *p_dec, OmxPort *p_port)
...
@@ -409,9 +409,7 @@ static OMX_ERRORTYPE AllocateBuffers(decoder_t *p_dec, OmxPort *p_port)
omx_error
,
(
int
)
p_port
->
i_port_index
);
omx_error
,
(
int
)
p_port
->
i_port_index
);
#ifdef OMXIL_EXTRA_DEBUG
OMX_DBG
(
"AllocateBuffers(%d)::done"
,
def
->
eDir
);
msg_Dbg
(
p_dec
,
"AllocateBuffers(%d)::done"
,
def
->
eDir
);
#endif
error:
error:
return
omx_error
;
return
omx_error
;
}
}
...
@@ -426,9 +424,7 @@ static OMX_ERRORTYPE FreeBuffers(decoder_t *p_dec, OmxPort *p_port)
...
@@ -426,9 +424,7 @@ static OMX_ERRORTYPE FreeBuffers(decoder_t *p_dec, OmxPort *p_port)
OMX_BUFFERHEADERTYPE
*
p_buffer
;
OMX_BUFFERHEADERTYPE
*
p_buffer
;
unsigned
int
i
;
unsigned
int
i
;
#ifdef OMXIL_EXTRA_DEBUG
OMX_DBG
(
"FreeBuffers(%d)"
,
def
->
eDir
);
msg_Dbg
(
p_dec
,
"FreeBuffers(%d)"
,
def
->
eDir
);
#endif
for
(
i
=
0
;
i
<
p_port
->
i_buffers
;
i
++
)
for
(
i
=
0
;
i
<
p_port
->
i_buffers
;
i
++
)
{
{
...
@@ -453,9 +449,7 @@ static OMX_ERRORTYPE FreeBuffers(decoder_t *p_dec, OmxPort *p_port)
...
@@ -453,9 +449,7 @@ static OMX_ERRORTYPE FreeBuffers(decoder_t *p_dec, OmxPort *p_port)
free
(
p_port
->
pp_buffers
);
free
(
p_port
->
pp_buffers
);
p_port
->
pp_buffers
=
NULL
;
p_port
->
pp_buffers
=
NULL
;
#ifdef OMXIL_EXTRA_DEBUG
OMX_DBG
(
"FreeBuffers(%d)::done"
,
def
->
eDir
);
msg_Dbg
(
p_dec
,
"FreeBuffers(%d)::done"
,
def
->
eDir
);
#endif
return
omx_error
;
return
omx_error
;
}
}
...
@@ -1255,10 +1249,7 @@ static int DecodeVideoOutput( decoder_t *p_dec, OmxPort *p_port, picture_t **pp_
...
@@ -1255,10 +1249,7 @@ static int DecodeVideoOutput( decoder_t *p_dec, OmxPort *p_port, picture_t **pp_
{
{
OMX_FIFO_GET
(
&
p_port
->
fifo
,
p_header
);
OMX_FIFO_GET
(
&
p_port
->
fifo
,
p_header
);
}
}
OMX_DBG
(
"FillThisBuffer %p, %p"
,
p_header
,
p_header
->
pBuffer
);
#ifdef OMXIL_EXTRA_DEBUG
msg_Dbg
(
p_dec
,
"FillThisBuffer %p, %p"
,
p_header
,
p_header
->
pBuffer
);
#endif
OMX_FillThisBuffer
(
p_port
->
omx_handle
,
p_header
);
OMX_FillThisBuffer
(
p_port
->
omx_handle
,
p_header
);
}
}
...
@@ -1330,10 +1321,8 @@ static int DecodeVideoInput( decoder_t *p_dec, OmxPort *p_port, block_t **pp_blo
...
@@ -1330,10 +1321,8 @@ static int DecodeVideoInput( decoder_t *p_dec, OmxPort *p_port, block_t **pp_blo
* than H.264 */
* than H.264 */
convert_h264_to_annexb
(
p_header
->
pBuffer
,
p_header
->
nFilledLen
,
convert_h264_to_annexb
(
p_header
->
pBuffer
,
p_header
->
nFilledLen
,
p_sys
->
i_nal_size_length
,
&
convert_state
);
p_sys
->
i_nal_size_length
,
&
convert_state
);
#ifdef OMXIL_EXTRA_DEBUG
OMX_DBG
(
"EmptyThisBuffer %p, %p, %i, %"
PRId64
,
p_header
,
p_header
->
pBuffer
,
msg_Dbg
(
p_dec
,
"EmptyThisBuffer %p, %p, %i, %"
PRId64
,
p_header
,
p_header
->
pBuffer
,
(
int
)
p_header
->
nFilledLen
,
FromOmxTicks
(
p_header
->
nTimeStamp
)
);
(
int
)
p_header
->
nFilledLen
,
FromOmxTicks
(
p_header
->
nTimeStamp
)
);
#endif
OMX_EmptyThisBuffer
(
p_port
->
omx_handle
,
p_header
);
OMX_EmptyThisBuffer
(
p_port
->
omx_handle
,
p_header
);
p_port
->
b_flushed
=
false
;
p_port
->
b_flushed
=
false
;
if
(
decode_more
)
if
(
decode_more
)
...
@@ -1510,9 +1499,7 @@ block_t *DecodeAudio ( decoder_t *p_dec, block_t **pp_block )
...
@@ -1510,9 +1499,7 @@ block_t *DecodeAudio ( decoder_t *p_dec, block_t **pp_block )
p_buffer
->
i_pts
;
p_buffer
->
i_pts
;
}
}
#ifdef OMXIL_EXTRA_DEBUG
OMX_DBG
(
"FillThisBuffer %p, %p"
,
p_header
,
p_header
->
pBuffer
);
msg_Dbg
(
p_dec
,
"FillThisBuffer %p, %p"
,
p_header
,
p_header
->
pBuffer
);
#endif
OMX_FIFO_GET
(
&
p_sys
->
out
.
fifo
,
p_header
);
OMX_FIFO_GET
(
&
p_sys
->
out
.
fifo
,
p_header
);
OMX_FillThisBuffer
(
p_sys
->
omx_handle
,
p_header
);
OMX_FillThisBuffer
(
p_sys
->
omx_handle
,
p_header
);
}
}
...
@@ -1553,10 +1540,8 @@ block_t *DecodeAudio ( decoder_t *p_dec, block_t **pp_block )
...
@@ -1553,10 +1540,8 @@ block_t *DecodeAudio ( decoder_t *p_dec, block_t **pp_block )
block_Release
(
p_block
);
block_Release
(
p_block
);
}
}
#ifdef OMXIL_EXTRA_DEBUG
OMX_DBG
(
"EmptyThisBuffer %p, %p, %i"
,
p_header
,
p_header
->
pBuffer
,
msg_Dbg
(
p_dec
,
"EmptyThisBuffer %p, %p, %i"
,
p_header
,
p_header
->
pBuffer
,
(
int
)
p_header
->
nFilledLen
);
(
int
)
p_header
->
nFilledLen
);
#endif
OMX_EmptyThisBuffer
(
p_sys
->
omx_handle
,
p_header
);
OMX_EmptyThisBuffer
(
p_sys
->
omx_handle
,
p_header
);
p_sys
->
in
.
b_flushed
=
false
;
p_sys
->
in
.
b_flushed
=
false
;
*
pp_block
=
NULL
;
/* Avoid being fed the same packet again */
*
pp_block
=
NULL
;
/* Avoid being fed the same packet again */
...
@@ -1621,10 +1606,8 @@ static block_t *EncodeVideo( encoder_t *p_enc, picture_t *p_pic )
...
@@ -1621,10 +1606,8 @@ static block_t *EncodeVideo( encoder_t *p_enc, picture_t *p_pic )
p_header
->
nOffset
=
0
;
p_header
->
nOffset
=
0
;
p_header
->
nFlags
=
OMX_BUFFERFLAG_ENDOFFRAME
;
p_header
->
nFlags
=
OMX_BUFFERFLAG_ENDOFFRAME
;
p_header
->
nTimeStamp
=
ToOmxTicks
(
p_pic
->
date
);
p_header
->
nTimeStamp
=
ToOmxTicks
(
p_pic
->
date
);
#ifdef OMXIL_EXTRA_DEBUG
OMX_DBG
(
"EmptyThisBuffer %p, %p, %i"
,
p_header
,
p_header
->
pBuffer
,
msg_Dbg
(
p_dec
,
"EmptyThisBuffer %p, %p, %i"
,
p_header
,
p_header
->
pBuffer
,
(
int
)
p_header
->
nFilledLen
);
(
int
)
p_header
->
nFilledLen
);
#endif
OMX_EmptyThisBuffer
(
p_sys
->
omx_handle
,
p_header
);
OMX_EmptyThisBuffer
(
p_sys
->
omx_handle
,
p_header
);
p_sys
->
in
.
b_flushed
=
false
;
p_sys
->
in
.
b_flushed
=
false
;
}
}
...
@@ -1667,9 +1650,7 @@ static block_t *EncodeVideo( encoder_t *p_enc, picture_t *p_pic )
...
@@ -1667,9 +1650,7 @@ static block_t *EncodeVideo( encoder_t *p_enc, picture_t *p_pic )
p_header
->
pAppPrivate
=
0
;
p_header
->
pAppPrivate
=
0
;
}
}
#ifdef OMXIL_EXTRA_DEBUG
OMX_DBG
(
"FillThisBuffer %p, %p"
,
p_header
,
p_header
->
pBuffer
);
msg_Dbg
(
p_dec
,
"FillThisBuffer %p, %p"
,
p_header
,
p_header
->
pBuffer
);
#endif
OMX_FillThisBuffer
(
p_sys
->
omx_handle
,
p_header
);
OMX_FillThisBuffer
(
p_sys
->
omx_handle
,
p_header
);
}
}
...
@@ -1763,9 +1744,7 @@ static OMX_ERRORTYPE OmxEmptyBufferDone( OMX_HANDLETYPE omx_handle,
...
@@ -1763,9 +1744,7 @@ static OMX_ERRORTYPE OmxEmptyBufferDone( OMX_HANDLETYPE omx_handle,
decoder_sys_t
*
p_sys
=
p_dec
->
p_sys
;
decoder_sys_t
*
p_sys
=
p_dec
->
p_sys
;
(
void
)
omx_handle
;
(
void
)
omx_handle
;
#ifdef OMXIL_EXTRA_DEBUG
OMX_DBG
(
"OmxEmptyBufferDone %p, %p"
,
omx_header
,
omx_header
->
pBuffer
);
msg_Dbg
(
p_dec
,
"OmxEmptyBufferDone %p, %p"
,
omx_header
,
omx_header
->
pBuffer
);
#endif
if
(
omx_header
->
pAppPrivate
||
omx_header
->
pOutputPortPrivate
)
if
(
omx_header
->
pAppPrivate
||
omx_header
->
pOutputPortPrivate
)
{
{
...
@@ -1786,10 +1765,8 @@ static OMX_ERRORTYPE OmxFillBufferDone( OMX_HANDLETYPE omx_handle,
...
@@ -1786,10 +1765,8 @@ static OMX_ERRORTYPE OmxFillBufferDone( OMX_HANDLETYPE omx_handle,
decoder_sys_t
*
p_sys
=
p_dec
->
p_sys
;
decoder_sys_t
*
p_sys
=
p_dec
->
p_sys
;
(
void
)
omx_handle
;
(
void
)
omx_handle
;
#ifdef OMXIL_EXTRA_DEBUG
OMX_DBG
(
"OmxFillBufferDone %p, %p, %i, %"
PRId64
,
omx_header
,
omx_header
->
pBuffer
,
msg_Dbg
(
p_dec
,
"OmxFillBufferDone %p, %p, %i, %"
PRId64
,
omx_header
,
omx_header
->
pBuffer
,
(
int
)
omx_header
->
nFilledLen
,
FromOmxTicks
(
omx_header
->
nTimeStamp
)
);
(
int
)
omx_header
->
nFilledLen
,
FromOmxTicks
(
omx_header
->
nTimeStamp
)
);
#endif
if
(
omx_header
->
pInputPortPrivate
)
if
(
omx_header
->
pInputPortPrivate
)
{
{
...
...
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