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
5596a281
Commit
5596a281
authored
Dec 25, 2012
by
Rafaël Carré
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add block_CopyProperties() helper
parent
ea98fcfc
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
5 deletions
+11
-5
include/vlc_block.h
include/vlc_block.h
+11
-5
No files found.
include/vlc_block.h
View file @
5596a281
...
...
@@ -139,6 +139,16 @@ VLC_API void block_Init( block_t *, void *, size_t );
VLC_API
block_t
*
block_Alloc
(
size_t
)
VLC_USED
VLC_MALLOC
;
VLC_API
block_t
*
block_Realloc
(
block_t
*
,
ssize_t
i_pre
,
size_t
i_body
)
VLC_USED
;
VLC_USED
static
inline
void
block_CopyProperties
(
block_t
*
dst
,
block_t
*
src
)
{
dst
->
i_flags
=
src
->
i_flags
;
dst
->
i_nb_samples
=
src
->
i_nb_samples
;
dst
->
i_dts
=
src
->
i_dts
;
dst
->
i_pts
=
src
->
i_pts
;
dst
->
i_length
=
src
->
i_length
;
}
VLC_USED
static
inline
block_t
*
block_Duplicate
(
block_t
*
p_block
)
{
...
...
@@ -146,11 +156,7 @@ static inline block_t *block_Duplicate( block_t *p_block )
if
(
p_dup
==
NULL
)
return
NULL
;
p_dup
->
i_flags
=
p_block
->
i_flags
;
p_dup
->
i_nb_samples
=
p_block
->
i_nb_samples
;
p_dup
->
i_dts
=
p_block
->
i_dts
;
p_dup
->
i_pts
=
p_block
->
i_pts
;
p_dup
->
i_length
=
p_block
->
i_length
;
block_CopyProperties
(
p_dup
,
p_block
);
memcpy
(
p_dup
->
p_buffer
,
p_block
->
p_buffer
,
p_block
->
i_buffer
);
return
p_dup
;
...
...
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