Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
F
ffmpeg.wasm-core
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Linshizhi
ffmpeg.wasm-core
Commits
eaff1aa0
Commit
eaff1aa0
authored
Jan 08, 2017
by
Steinar H. Gunderson
Committed by
Paul B Mahol
Jan 11, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avcodec: move bitswap_32() into a header file
Allows more codecs than mpeg12video to make use of it.
parent
107b3064
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
8 deletions
+8
-8
bitstream.c
libavcodec/bitstream.c
+0
-8
mathops.h
libavcodec/mathops.h
+8
-0
No files found.
libavcodec/bitstream.c
View file @
eaff1aa0
...
...
@@ -128,14 +128,6 @@ static int alloc_table(VLC *vlc, int size, int use_static)
return
index
;
}
static
av_always_inline
uint32_t
bitswap_32
(
uint32_t
x
)
{
return
(
uint32_t
)
ff_reverse
[
x
&
0xFF
]
<<
24
|
(
uint32_t
)
ff_reverse
[(
x
>>
8
)
&
0xFF
]
<<
16
|
(
uint32_t
)
ff_reverse
[(
x
>>
16
)
&
0xFF
]
<<
8
|
(
uint32_t
)
ff_reverse
[
x
>>
24
];
}
typedef
struct
VLCcode
{
uint8_t
bits
;
uint16_t
symbol
;
...
...
libavcodec/mathops.h
View file @
eaff1aa0
...
...
@@ -249,4 +249,12 @@ static inline int8_t ff_u8_to_s8(uint8_t a)
return
b
.
s8
;
}
static
av_always_inline
uint32_t
bitswap_32
(
uint32_t
x
)
{
return
(
uint32_t
)
ff_reverse
[
x
&
0xFF
]
<<
24
|
(
uint32_t
)
ff_reverse
[(
x
>>
8
)
&
0xFF
]
<<
16
|
(
uint32_t
)
ff_reverse
[(
x
>>
16
)
&
0xFF
]
<<
8
|
(
uint32_t
)
ff_reverse
[
x
>>
24
];
}
#endif
/* AVCODEC_MATHOPS_H */
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