Adjusted Timidity++ to soundfint manager
This commit is contained in:
parent
f9893a700a
commit
6618656e7c
8 changed files with 48 additions and 178 deletions
|
|
@ -278,7 +278,7 @@ int Instruments::import_wave_discriminant(char *sample_file)
|
|||
struct timidity_file *tf;
|
||||
char buf[12];
|
||||
|
||||
if ((tf = open_file(sample_file, false, pathlist)) == NULL)
|
||||
if ((tf = open_file(sample_file, sfreader)) == NULL)
|
||||
return 1;
|
||||
if (tf_read(buf, 12, 1, tf) != 1
|
||||
|| memcmp(&buf[0], "RIFF", 4) != 0 || memcmp(&buf[8], "WAVE", 4) != 0)
|
||||
|
|
@ -309,7 +309,7 @@ int Instruments::import_wave_load(char *sample_file, Instrument *inst)
|
|||
WAVSamplerChunk samplerc = {0,};
|
||||
GeneralInstrumentInfo instc;
|
||||
|
||||
if ((tf = open_file(sample_file, false, pathlist)) == NULL)
|
||||
if ((tf = open_file(sample_file, sfreader)) == NULL)
|
||||
return 1;
|
||||
if (tf_read(buf, 12, 1, tf) != 1
|
||||
|| memcmp(&buf[0], "RIFF", 4) != 0 || memcmp(&buf[8], "WAVE", 4) != 0)
|
||||
|
|
@ -551,7 +551,7 @@ int Instruments::import_aiff_discriminant(char *sample_file)
|
|||
struct timidity_file *tf;
|
||||
char buf[12];
|
||||
|
||||
if ((tf = open_file(sample_file, false, pathlist)) == NULL)
|
||||
if ((tf = open_file(sample_file, sfreader)) == NULL)
|
||||
return 1;
|
||||
if (tf_read(buf, 12, 1, tf) != 1
|
||||
|| memcmp(&buf[0], "FORM", 4) != 0 || memcmp(&buf[8], "AIF", 3) != 0
|
||||
|
|
@ -591,7 +591,7 @@ int Instruments::import_aiff_load(char *sample_file, Instrument *inst)
|
|||
AIFFLoopInfo loop_info = {0,0,0};
|
||||
AIFFMarkerData *marker_data;
|
||||
|
||||
if ((tf = open_file(sample_file, false, pathlist)) == NULL)
|
||||
if ((tf = open_file(sample_file, sfreader)) == NULL)
|
||||
return 1;
|
||||
if (tf_read(buf, 12, 1, tf) != 1
|
||||
|| memcmp(&buf[0], "FORM", 4) != 0 || memcmp(&buf[8], "AIF", 3) != 0
|
||||
|
|
@ -1222,4 +1222,4 @@ static double ConvertFromIeeeExtended(const char *bytes)
|
|||
else
|
||||
return f;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue