Make libdebug not depend on libdisplay
This commit is contained in:
@@ -73,8 +73,6 @@ typedef struct display_spectrum {
|
||||
|
||||
#define MAX_HEIGHT_STATUS 32
|
||||
|
||||
void get_win_size(int *w, int *h);
|
||||
|
||||
void display_wave_init(dispwav_t *disp, int samplerate, int kanal);
|
||||
void display_wave_on(int on);
|
||||
void display_wave(dispwav_t *disp, sample_t *samples, int length, double range);
|
||||
|
@@ -33,24 +33,6 @@ static int num_sender = 0;
|
||||
static char screen[HEIGHT][MAX_DISPLAY_WIDTH];
|
||||
static int wave_on = 0;
|
||||
|
||||
void get_win_size(int *w, int *h)
|
||||
{
|
||||
struct winsize win;
|
||||
int rc;
|
||||
|
||||
rc = ioctl(0, TIOCGWINSZ, &win);
|
||||
if (rc) {
|
||||
*w = 80;
|
||||
*h = 25;
|
||||
return;
|
||||
}
|
||||
|
||||
*h = win.ws_row;
|
||||
*w = win.ws_col;
|
||||
if (*w > MAX_DISPLAY_WIDTH - 1)
|
||||
*w = MAX_DISPLAY_WIDTH - 1;
|
||||
}
|
||||
|
||||
void display_wave_init(dispwav_t *disp, int samplerate, int kanal)
|
||||
{
|
||||
memset(disp, 0, sizeof(*disp));
|
||||
|
Reference in New Issue
Block a user