Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
F
ffmpeg
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
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
ffmpeg
Commits
39211cb9
Commit
39211cb9
authored
Aug 02, 2016
by
Timothy Gu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
murmur3: Add Doxygen documentation
The interface has been stable for some time now.
parent
0a7a4e33
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
64 additions
and
0 deletions
+64
-0
murmur3.h
libavutil/murmur3.h
+64
-0
No files found.
libavutil/murmur3.h
View file @
39211cb9
...
@@ -34,13 +34,77 @@
...
@@ -34,13 +34,77 @@
* @ingroup lavu_hash
* @ingroup lavu_hash
* MurmurHash3 hash function implementation.
* MurmurHash3 hash function implementation.
*
*
* MurmurHash3 is a non-cryptographic hash function, of which three
* incompatible versions were created by its inventor Austin Appleby:
*
* - 32-bit output
* - 128-bit output for 32-bit platforms
* - 128-bit output for 64-bit platforms
*
* FFmpeg only implements the last variant: 128-bit output designed for 64-bit
* platforms. Even though the hash function was designed for 64-bit platforms,
* the function in reality works on 32-bit systems too, only with reduced
* performance.
*
* @anchor lavu_murmur3_seedinfo
* By design, MurmurHash3 requires a seed to operate. In response to this,
* libavutil provides two functions for hash initiation, one that requires a
* seed (av_murmur3_init_seeded()) and one that uses a fixed arbitrary integer
* as the seed, and therefore does not (av_murmur3_init()).
*
* To make hashes comparable, you should provide the same seed for all calls to
* this hash function -- if you are supplying one yourself, that is.
*
* @{
* @{
*/
*/
/**
* Allocate an AVMurMur3 hash context.
*
* @return Uninitialized hash context or `NULL` in case of error
*/
struct
AVMurMur3
*
av_murmur3_alloc
(
void
);
struct
AVMurMur3
*
av_murmur3_alloc
(
void
);
/**
* Initialize or reinitialize an AVMurMur3 hash context with a seed.
*
* @param[out] c Hash context
* @param[in] seed Random seed
*
* @see av_murmur3_init()
* @see @ref lavu_murmur3_seedinfo "Detailed description" on a discussion of
* seeds for MurmurHash3.
*/
void
av_murmur3_init_seeded
(
struct
AVMurMur3
*
c
,
uint64_t
seed
);
void
av_murmur3_init_seeded
(
struct
AVMurMur3
*
c
,
uint64_t
seed
);
/**
* Initialize or reinitialize an AVMurMur3 hash context.
*
* Equivalent to av_murmur3_init_seeded() with a built-in seed.
*
* @param[out] c Hash context
*
* @see av_murmur3_init_seeded()
* @see @ref lavu_murmur3_seedinfo "Detailed description" on a discussion of
* seeds for MurmurHash3.
*/
void
av_murmur3_init
(
struct
AVMurMur3
*
c
);
void
av_murmur3_init
(
struct
AVMurMur3
*
c
);
/**
* Update hash context with new data.
*
* @param[out] c Hash context
* @param[in] src Input data to update hash with
* @param[in] len Number of bytes to read from `src`
*/
void
av_murmur3_update
(
struct
AVMurMur3
*
c
,
const
uint8_t
*
src
,
int
len
);
void
av_murmur3_update
(
struct
AVMurMur3
*
c
,
const
uint8_t
*
src
,
int
len
);
/**
* Finish hashing and output digest value.
*
* @param[in,out] c Hash context
* @param[out] dst Buffer where output digest value is stored
*/
void
av_murmur3_final
(
struct
AVMurMur3
*
c
,
uint8_t
dst
[
16
]);
void
av_murmur3_final
(
struct
AVMurMur3
*
c
,
uint8_t
dst
[
16
]);
/**
/**
...
...
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