libxputty
0.1
Loading...
Searching...
No Matches
xputty
header
widgets
xwaveview.h
Go to the documentation of this file.
1
/*
2
* 0BSD
3
*
4
* BSD Zero Clause License
5
*
6
* Copyright (c) 2019 Hermann Meyer
7
*
8
* Permission to use, copy, modify, and/or distribute this software for any
9
* purpose with or without fee is hereby granted.
10
11
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
12
* REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
13
* AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
14
* INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
15
* LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
16
* OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
17
* PERFORMANCE OF THIS SOFTWARE.
18
*
19
*/
20
21
#pragma once
22
23
#ifndef XWAVEVIEW_H_
24
#define XWAVEVIEW_H_
25
26
#include "
xputty.h
"
27
28
#ifdef __cplusplus
29
extern
"C"
{
30
#endif
31
32
33
typedef
struct
{
34
float
*
wave
;
35
int
size
;
36
char
pad[4];
37
}
WaveView_t
;
38
39
48
Widget_t
*
add_waveview
(
Widget_t
*parent,
const
char
* label,
49
int
x,
int
y,
int
width,
int
height);
50
51
void
update_waveview
(
Widget_t
*waveview,
float
* wave,
int
size);
52
53
void
waveview_mem_free
(
void
*w_,
void
* user_data);
54
55
#ifdef __cplusplus
56
}
57
#endif
58
59
#endif
//XWAVEVIEW_H_
WaveView_t
Definition
xwaveview.h:33
WaveView_t::wave
float * wave
Definition
xwaveview.h:34
WaveView_t::size
int size
Definition
xwaveview.h:35
Widget_t
Widget_t - struct to hold the basic Widget_t info.
Definition
xwidget.h:457
xputty.h
This file contains definitions and structs used on all platforms. Platform specific definitions are l...
waveview_mem_free
void waveview_mem_free(void *w_, void *user_data)
Definition
xwaveview.c:57
add_waveview
Widget_t * add_waveview(Widget_t *parent, const char *label, int x, int y, int width, int height)
add_waveview - add a waveview to a Widget_t
Definition
xwaveview.c:26
update_waveview
void update_waveview(Widget_t *waveview, float *wave, int size)
Definition
xwaveview.c:43
Generated by
1.9.8