auto-find samples when loading EXS
-
Obsolete462444 Obsolete462444 https://www.kvraudio.com/forum/memberlist.php?mode=viewprofile&u=462444
- Banned
- Topic Starter
- 465 posts since 15 Apr, 2020
Hi,
thanks for developing TX16wx. I have used it as a playback engine for EXS formatted sample sets recently, which is nice, because you can load these libraries and further tweak them using the on-board tools and modulation options.
Whenever I load an EXS file in the browser, TX16wx will typically ask me for the location of the (I guess?) first sample in the mapping.
Sometimes, especially if the sample library consists of multiple sample folders (for example different folders for different articulations or for noise-reduced and raw samples), it's not enough to merely point to the first sample - TX16wx will keep asking for the locations of the other samples.
Since the sample folders are typically found in the same folder (one directory above or down) as the EXS file itself, I wonder - would it be possible to allow TX16wx to automatically find all the samples, instead of expecting the user to point samples out manually? I'm not a programmer, but I guess all it would take to tell TX16wx to look for the samples within the same folder as the EXS file (including all the directories / sub-folders inside that folder) is the use of some regular expressions?
Here is an example of an EXS library that TX16wx would particularly struggle with finding the samples (not sufficient to merely point out the initial sample):
https://www.pianobook.co.uk/library/soft-string-spurs/
thanks for developing TX16wx. I have used it as a playback engine for EXS formatted sample sets recently, which is nice, because you can load these libraries and further tweak them using the on-board tools and modulation options.
Whenever I load an EXS file in the browser, TX16wx will typically ask me for the location of the (I guess?) first sample in the mapping.
Sometimes, especially if the sample library consists of multiple sample folders (for example different folders for different articulations or for noise-reduced and raw samples), it's not enough to merely point to the first sample - TX16wx will keep asking for the locations of the other samples.
Since the sample folders are typically found in the same folder (one directory above or down) as the EXS file itself, I wonder - would it be possible to allow TX16wx to automatically find all the samples, instead of expecting the user to point samples out manually? I'm not a programmer, but I guess all it would take to tell TX16wx to look for the samples within the same folder as the EXS file (including all the directories / sub-folders inside that folder) is the use of some regular expressions?
Here is an example of an EXS library that TX16wx would particularly struggle with finding the samples (not sufficient to merely point out the initial sample):
https://www.pianobook.co.uk/library/soft-string-spurs/
-
- KVRAF
- 2431 posts since 27 May, 2005 from Stockholm
Not surprisingly, TX does some pretty exhaustive search for samples, even if they are not where the container says they are. Including searching based on the current folder.
However, exs files are rather special, because of Apple. If you are trying to read the exs library on Windows, you should almost expect problems locating files. If you are on OSX, pretty much the same. None of this is of course helped by the fact that the format is undocumented, and the rules for how sample references may or may no look is up in the air.
That being said (rant over), I'll look at the library and see if I can improve the importer.
However, exs files are rather special, because of Apple. If you are trying to read the exs library on Windows, you should almost expect problems locating files. If you are on OSX, pretty much the same. None of this is of course helped by the fact that the format is undocumented, and the rules for how sample references may or may no look is up in the air.
That being said (rant over), I'll look at the library and see if I can improve the importer.
TX16Wx Software Sampler:
http://www.tx16wx.com/
http://www.tx16wx.com/
-
- KVRAF
- 2431 posts since 27 May, 2005 from Stockholm
So, to get back to the library you mentioned.
It is organized like:
Now, the first sample in the file is:
Note a few things.
It is organized like:
Code: Select all
Soft String Spurs/
Samples/
NR/
SSS Harmonics/
... etc
Non NR/
...other stuff
Instruments/
<the actual exs files>
Code: Select all
SSS Harmonics.exs
Code: Select all
/Users/DanKeen/Music/Sample Making/Soft String Spurs/SSS Logic/Samples/SSS Harmonics/SSS_Harmonics_A4.wav
- It is an absolute path, referencing the authors hard drive layout. Bad enough, but TX can handle this. It simply iterates parent folders of the file being loaded (the exs) and tries to find any matching any subpath of the path in the file.
- The path is wrong. The samples are not in They are in
Code: Select all
Soft String Spurs/SSS Logic/Samples
This is where file search breaks down. Seriously. If the path in a file is decidedly wrong, we cannot just guess it.Code: Select all
NR/Soft String Spurs/SSS Logic/Samples
- It can be prohibitorily expensive. We might end up searching from the computer root, to everything mounted, without any idea of which search trees are even remotely possible
- And mainly: We could (and will) find the wrong sample. Guess how many samples are named "bass.wav"? If we ignore qualifier (path), we will load garbage without the user being the wiser.
TX16Wx Software Sampler:
http://www.tx16wx.com/
http://www.tx16wx.com/
-
Obsolete462444 Obsolete462444 https://www.kvraudio.com/forum/memberlist.php?mode=viewprofile&u=462444
- Banned
- Topic Starter
- 465 posts since 15 Apr, 2020
Thanks for looking into it. The above case seems quite special due to the wrong directories referenced, but I encountered the "show me the initial sample thing" frequently even with less erroneous or error-prone folder structures. In fact, out of the ten or so EXS libraries I tried, there was only one that would immediately load without requiring manual pointing to at least the initial sample.
Rather than searching the whole hard drive from the root, would it not be possible to tell TX to look for the samples in the immediate vicinity of the loaded EXS file?
So, in our above case, TX could go one parent level up (sorry in case I'm using the wrong term here) and from there look in all sub-directories contained in that parent folder for the missing samples. I'm aware that the folder structure could vary from one EXS library to another EXS library, but there should be a way to operationalise this abstraction in a way that would work nine times out of ten at least?
Rather than searching the whole hard drive from the root, would it not be possible to tell TX to look for the samples in the immediate vicinity of the loaded EXS file?
So, in our above case, TX could go one parent level up (sorry in case I'm using the wrong term here) and from there look in all sub-directories contained in that parent folder for the missing samples. I'm aware that the folder structure could vary from one EXS library to another EXS library, but there should be a way to operationalise this abstraction in a way that would work nine times out of ten at least?
-
- KVRAF
- 2431 posts since 27 May, 2005 from Stockholm
It does this already. Quite extensively I might add. But a portion of the relative paths must match, i.e. if you have a sample reference
/Dir1/dir2/dir3/samples/kossa.wav
and your EXS file is in
/Some/thing/different/file.exe
TX will find the sample if it is something like
/Some/thing/samples/kossa.wav
But not
/Some/thing/wakkadoodle/samples/kossa.wav
If you have a different example where you think TX is not finding something it should find, send it to me. I promise I will look at it and fix it if it is a real error (or even weakness).
/Dir1/dir2/dir3/samples/kossa.wav
and your EXS file is in
/Some/thing/different/file.exe
TX will find the sample if it is something like
/Some/thing/samples/kossa.wav
But not
/Some/thing/wakkadoodle/samples/kossa.wav
If you have a different example where you think TX is not finding something it should find, send it to me. I promise I will look at it and fix it if it is a real error (or even weakness).
TX16Wx Software Sampler:
http://www.tx16wx.com/
http://www.tx16wx.com/
-
- KVRer
- 3 posts since 1 Oct, 2022
Hi elcallio
so the 'samples' folder and the 'exs' / instruments folder have to be in the same folder ?
Maybe I don't understand...
Thanks for clearing up
and
best regards
so the 'samples' folder and the 'exs' / instruments folder have to be in the same folder ?
Maybe I don't understand...
Thanks for clearing up
and
best regards
-
- KVRAF
- 2431 posts since 27 May, 2005 from Stockholm
No, but the general sample path structure in the .exs file must remain on disk for TX to find it, and if the paths are relative each other, they must also be placed in a similar relative fashion when loaded. I.e. the two paths must
1.) share a root
2.) retain the tail end of the path
If paths are absolute, the sort-of same rules apply, that at least the trailing aspect of the actual resolvable paths must remain the same in the relocated location, otherwise the find-algo can't try to speculate and find things.
Of course, having instruments and samples with _proper_ (relative) reference paths _or_ existing absolute paths is a much easier solution, not requiring semi-clever path searches.
1.) share a root
2.) retain the tail end of the path
If paths are absolute, the sort-of same rules apply, that at least the trailing aspect of the actual resolvable paths must remain the same in the relocated location, otherwise the find-algo can't try to speculate and find things.
Of course, having instruments and samples with _proper_ (relative) reference paths _or_ existing absolute paths is a much easier solution, not requiring semi-clever path searches.
TX16Wx Software Sampler:
http://www.tx16wx.com/
http://www.tx16wx.com/
-
- KVRer
- 3 posts since 1 Oct, 2022
Thanks, hope I understand...
Best regards
Best regards
-
- KVRer
- 3 posts since 1 Oct, 2022
>
15.3.5. AKAI cd-rom image
Can TX16Wx import AKAI cd-rom's ?
( CD )
Klaus
15.3.5. AKAI cd-rom image
Can TX16Wx import AKAI cd-rom's ?
( CD )
Klaus
-
- KVRAF
- 2431 posts since 27 May, 2005 from Stockholm
Please don't hijack threads for different subjects. But to answer your question: TX16Wx can read AKAI cd-rom images (ISO), and load programs/reference samples inside the image.
TX16Wx Software Sampler:
http://www.tx16wx.com/
http://www.tx16wx.com/