FFmpeg
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions | Variables
murmur3.c File Reference
#include <stdint.h>
#include "mem.h"
#include "intreadwrite.h"
#include "murmur3.h"

Go to the source code of this file.

Data Structures

struct  AVMurMur3
 

Macros

#define ROT(a, b)   ((a << b) | (a >> (64 - b)))
 

Functions

AVMurMur3av_murmur3_alloc (void)
 
void av_murmur3_init_seeded (AVMurMur3 *c, uint64_t seed)
 
void av_murmur3_init (AVMurMur3 *c)
 
static uint64_t get_k1 (const uint8_t *src)
 
static uint64_t get_k2 (const uint8_t *src)
 
static uint64_t update_h1 (uint64_t k, uint64_t h1, uint64_t h2)
 
static uint64_t update_h2 (uint64_t k, uint64_t h1, uint64_t h2)
 
void av_murmur3_update (AVMurMur3 *c, const uint8_t *src, int len)
 
static uint64_t fmix (uint64_t k)
 
void av_murmur3_final (AVMurMur3 *c, uint8_t dst[16])
 

Variables

static const uint64_t c1 = UINT64_C(0x87c37b91114253d5)
 
static const uint64_t c2 = UINT64_C(0x4cf5ad432745937f)
 

Macro Definition Documentation

#define ROT (   a,
  b 
)    ((a << b) | (a >> (64 - b)))

Definition at line 52 of file murmur3.c.

Referenced by get_k1(), get_k2(), update_h1(), and update_h2().

Function Documentation

AVMurMur3* av_murmur3_alloc ( void  )
read

Definition at line 32 of file murmur3.c.

Referenced by av_hash_alloc().

void av_murmur3_init_seeded ( AVMurMur3 c,
uint64_t  seed 
)

Definition at line 37 of file murmur3.c.

Referenced by av_murmur3_init().

void av_murmur3_init ( AVMurMur3 c)

Definition at line 43 of file murmur3.c.

Referenced by av_hash_init().

static uint64_t get_k1 ( const uint8_t src)
inlinestatic

Definition at line 54 of file murmur3.c.

Referenced by av_murmur3_final(), and av_murmur3_update().

static uint64_t get_k2 ( const uint8_t src)
inlinestatic

Definition at line 63 of file murmur3.c.

Referenced by av_murmur3_final(), and av_murmur3_update().

static uint64_t update_h1 ( uint64_t  k,
uint64_t  h1,
uint64_t  h2 
)
inlinestatic

Definition at line 72 of file murmur3.c.

Referenced by av_murmur3_update().

static uint64_t update_h2 ( uint64_t  k,
uint64_t  h1,
uint64_t  h2 
)
inlinestatic

Definition at line 82 of file murmur3.c.

Referenced by av_murmur3_update().

void av_murmur3_update ( AVMurMur3 c,
const uint8_t src,
int  len 
)

Definition at line 92 of file murmur3.c.

Referenced by av_hash_update().

static uint64_t fmix ( uint64_t  k)
inlinestatic

Definition at line 131 of file murmur3.c.

Referenced by av_murmur3_final().

void av_murmur3_final ( AVMurMur3 c,
uint8_t  dst[16] 
)

Definition at line 141 of file murmur3.c.

Referenced by av_hash_final().

Variable Documentation

const uint64_t c1 = UINT64_C(0x87c37b91114253d5)
static

Definition at line 49 of file murmur3.c.

Referenced by get_k1(), and get_k2().

const uint64_t c2 = UINT64_C(0x4cf5ad432745937f)
static

Definition at line 50 of file murmur3.c.

Referenced by get_k1(), and get_k2().