RetroArch
Classes | Macros | Typedefs | Functions | Variables
ffmpeg_fft.c File Reference
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <math.h>
#include <glsym/glsym.h>
#include <libretro.h>
#include <retro_miscellaneous.h>
#include <retro_inline.h>
#include <filters.h>
#include <math/complex.h>
#include <gfx/math/matrix_4x4.h>
#include <gfx/math/vector_2.h>
#include "ffmpeg_fft.h"
#include "gl_shaders/fft_heightmap.glsl.vert.h"
#include "gl_shaders/fft_heightmap.glsl.frag.h"
#include "gl_shaders/fft_vertex_program.glsl.vert.h"
#include "gl_shaders/fft_fragment_program_resolve.glsl.frag.h"
#include "gl_shaders/fft_fragment_program_real.glsl.frag.h"
#include "gl_shaders/fft_fragment_program_complex.glsl.frag.h"
#include "gl_shaders/fft_fragment_program_blur.glsl.frag.h"
Include dependency graph for ffmpeg_fft.c:

Classes

struct  target
 
class  Pass
 
struct  GLFFT
 
struct  GLFFT::Block
 

Macros

#define GL_CHECK_ERROR()
 
#define M_HALF_PI   1.57079632679489661923132169163975144
 
#define KAISER_BETA   12.0
 

Typedefs

typedef float stub_matrix4x4[4][4]
 

Functions

static GLuint fft_compile_shader (fft_t *fft, GLenum type, const char *source)
 
static GLuint fft_compile_program (fft_t *fft, const char *vertex_source, const char *fragment_source)
 
static INLINE unsigned log2i (unsigned x)
 
static INLINE unsigned bitinverse (unsigned x, unsigned size)
 
static fft_complex_t exp_imag (float phase)
 
void fft_build_params (fft_t *fft, GLuint *buffer, unsigned step, unsigned size)
 
static void fft_init_quad_vao (fft_t *fft)
 
static void fft_init_texture (fft_t *fft, GLuint *tex, GLenum format, unsigned width, unsigned height, unsigned levels, GLenum mag, GLenum min)
 
static void fft_init_target (fft_t *fft, struct target *target, GLenum format, unsigned width, unsigned height, unsigned levels, GLenum mag, GLenum min)
 
static void fft_init (fft_t *fft)
 
static void fft_init_block (fft_t *fft)
 
static bool fft_context_reset (fft_t *fft, unsigned fft_steps, rglgen_proc_address_t proc, unsigned fft_depth)
 
fft_tfft_new (unsigned fft_steps, rglgen_proc_address_t proc)
 
void fft_init_multisample (fft_t *fft, unsigned width, unsigned height, unsigned samples)
 
static void fft_context_destroy (fft_t *fft)
 
void fft_free (fft_t *fft)
 
void fft_step_fft (fft_t *fft, const GLshort *audio_buffer, unsigned frames)
 
void fft_render (fft_t *fft, GLuint backbuffer, unsigned width, unsigned height)
 

Variables

retro_log_printf_t log_cb
 

Macro Definition Documentation

◆ GL_CHECK_ERROR

#define GL_CHECK_ERROR ( )

◆ KAISER_BETA

#define KAISER_BETA   12.0

◆ M_HALF_PI

#define M_HALF_PI   1.57079632679489661923132169163975144

Typedef Documentation

◆ stub_matrix4x4

typedef float stub_matrix4x4[4][4]

Function Documentation

◆ bitinverse()

static INLINE unsigned bitinverse ( unsigned  x,
unsigned  size 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ exp_imag()

static fft_complex_t exp_imag ( float  phase)
static
Here is the caller graph for this function:

◆ fft_build_params()

void fft_build_params ( fft_t fft,
GLuint buffer,
unsigned  step,
unsigned  size 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ fft_compile_program()

static GLuint fft_compile_program ( fft_t fft,
const char *  vertex_source,
const char *  fragment_source 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ fft_compile_shader()

static GLuint fft_compile_shader ( fft_t fft,
GLenum  type,
const char *  source 
)
static
Here is the caller graph for this function:

◆ fft_context_destroy()

static void fft_context_destroy ( fft_t fft)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ fft_context_reset()

static bool fft_context_reset ( fft_t fft,
unsigned  fft_steps,
rglgen_proc_address_t  proc,
unsigned  fft_depth 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ fft_free()

void fft_free ( fft_t fft)
Here is the caller graph for this function:

◆ fft_init()

static void fft_init ( fft_t fft)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ fft_init_block()

static void fft_init_block ( fft_t fft)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ fft_init_multisample()

void fft_init_multisample ( fft_t fft,
unsigned  width,
unsigned  height,
unsigned  samples 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ fft_init_quad_vao()

static void fft_init_quad_vao ( fft_t fft)
static
Here is the caller graph for this function:

◆ fft_init_target()

static void fft_init_target ( fft_t fft,
struct target target,
GLenum  format,
unsigned  width,
unsigned  height,
unsigned  levels,
GLenum  mag,
GLenum  min 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

◆ fft_init_texture()

static void fft_init_texture ( fft_t fft,
GLuint tex,
GLenum  format,
unsigned  width,
unsigned  height,
unsigned  levels,
GLenum  mag,
GLenum  min 
)
static
Here is the caller graph for this function:

◆ fft_new()

fft_t* fft_new ( unsigned  fft_steps,
rglgen_proc_address_t  proc 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ fft_render()

void fft_render ( fft_t fft,
GLuint  backbuffer,
unsigned  width,
unsigned  height 
)
Here is the caller graph for this function:

◆ fft_step_fft()

void fft_step_fft ( fft_t fft,
const GLshort audio_buffer,
unsigned  frames 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ log2i()

static INLINE unsigned log2i ( unsigned  x)
static
Here is the caller graph for this function:

Variable Documentation

◆ log_cb