coronacommit

This commit is contained in:
Tonton Th 2020-05-13 12:38:06 +02:00
parent 10b2f53b85
commit 4bd4e1c43f
5 changed files with 33 additions and 12 deletions

View File

@ -4,7 +4,7 @@
function build
{
echo ============= $1 ==============
echo =================== $1 ====================
curdir=${PWD}
cd $1
make t

View File

@ -101,7 +101,6 @@ fprintf(stderr, ">>> %s ( '%s' )\n", __func__, fname);
/*
* first step : clean the current list
*/
for (foo=0; foo<26; foo++) {
memset(samples+foo, 0, sizeof(SampleRef));
}
@ -126,7 +125,7 @@ while (NULL != fgets(line, T_LINE, fp)) {
memset(&sample, 0, sizeof(SampleRef));
foo = decode_la_ligne(line, &sample);
#if DEBUG_LEVEL
#if DEBUG_LEVEL > 1
fprintf(stderr, "decode la ligne -> %d\n\n", foo);
#endif
if (!foo) {

View File

@ -3,6 +3,7 @@
*/
#include <stdio.h>
#include <unistd.h>
#include "nclooper.h"
@ -13,11 +14,32 @@ extern int verbosity;
/* --------------------------------------------------------------------- */
int enter_interactive(SampleRef *psmpl, int notused)
{
int foo, row, col;
char txt[99];
#if DEBUG_LEVEL
fprintf(stderr, ">>> %s ( %p %d )\n", __func__, psmpl, notused);
#endif
for (foo=0; foo<26; foo++) {
idx2position(foo, &row, &col);
sprintf(txt, "%3d", foo);
mvaddstr(row, col, txt);
if (psmpl[foo].key) {
standout();
mvaddch(row, col+4, psmpl[foo].key);
standend();
}
refresh();
}
sleep(3);
return -1;
}
/* --------------------------------------------------------------------- */

17
main.c
View File

@ -14,7 +14,7 @@
int verbosity;
SampleRef the_samples[26];
SampleRef the_samples[26];
/* --------------------------------------------------------------------- */
void help(int k)
@ -28,7 +28,8 @@ exit(0);
*/
int introduction(int k)
{
int foo;
int foo;
ao_device *device;
#if DEBUG_LEVEL
fprintf(stderr, ">>> %s ( %d )\n", __func__, k);
@ -37,12 +38,15 @@ fprintf(stderr, ">>> %s ( %d )\n", __func__, k);
foo = init_ecran(__func__);
sleep(1);
/* check the sound subsystem */
return -1;
}
/* --------------------------------------------------------------------- */
int conclusion(int k)
{
int foo;
int foo;
#if DEBUG_LEVEL
fprintf(stderr, ">>> %s ( %d )\n", __func__, k);
@ -75,11 +79,8 @@ fprintf(stderr, "argc = %d, optind = %d\n", argc, optind);
foo = lecture_liste_des_samples(listname, the_samples);
fprintf(stderr,"retour lecture liste '%s' -> %d\n", listname, foo);
for (foo=0; foo<26; foo++) {
printf("%2d %02x %-30s %s\n", foo, the_samples[foo].key,
the_samples[foo].text,
the_samples[foo].path);
}
foo = start_the_engine();
fprintf(stderr,"retour start engine -> %d\n", foo);
introduction(0);

View File

@ -20,5 +20,4 @@ typedef struct {
#include "ui/ncfuncs.h"
int enter_interactive(SampleRef *, int notused);