If you have a problem or need to report a bug please email : support@dsprobotics.com
There are 3 sections to this support area:
DOWNLOADS: access to product manuals, support files and drivers
HELP & INFORMATION: tutorials and example files for learning or finding pre-made modules for your projects
USER FORUMS: meet with other users and exchange ideas, you can also get help and assistance here
NEW REGISTRATIONS - please contact us if you wish to register on the forum
Users are reminded of the forum rules they sign up to which prohibits any activity that violates any laws including posting material covered by copyright
Is it possible to build a very simple SFZ creator?
48 posts
• Page 2 of 5 • 1, 2, 3, 4, 5
Re: Is it possible to build a very simple SFZ creator?
So here comes the first test (nothing which is useful in this state, but proving myself, that I'm on the right track).
Concerning that drag & drop thing: I found nothing about it for synthmaker, just discussion... so could it be, that there exists no 'simple' drag & drop feature for the GUI side so far So this has to be done with ruby too, I think, which makes things much more difficult for me as a beginner...
But anyway, my idea of building a converter for tw16xw software sampler seems to be doable.
Now I have to find out how to make ruby identify & extract those values for keyrange etc...
and after that finding out how to create a loop, which spits out the right values for all samples/regions
Concerning that drag & drop thing: I found nothing about it for synthmaker, just discussion... so could it be, that there exists no 'simple' drag & drop feature for the GUI side so far So this has to be done with ruby too, I think, which makes things much more difficult for me as a beginner...
But anyway, my idea of building a converter for tw16xw software sampler seems to be doable.
Now I have to find out how to make ruby identify & extract those values for keyrange etc...
and after that finding out how to create a loop, which spits out the right values for all samples/regions
- Attachments
-
- sfzfirsttest.fsm
- Just my first contact with ruby, being able to load/save txt, and store SFZ data in sfz file, loading a wav & txt file location and reading it in ruby window, some first experiments with ruby syntax & variables
- (2.38 KiB) Downloaded 1068 times
- mccy
- Posts: 69
- Joined: Sun Feb 27, 2011 3:20 pm
Re: Is it possible to build a very simple SFZ creator?
o.k. did some mistakes concerning the sfz structure ... will correct that soon So really NOTHING is working by now, but there is much right in it
- mccy
- Posts: 69
- Joined: Sun Feb 27, 2011 3:20 pm
Re: Is it possible to build a very simple SFZ creator?
Readable sfz output now, but strange behavior until paths are defined. Maybe I should just set c: as default.
- Attachments
-
- sfzfirsttest.fsm
- (2.34 KiB) Downloaded 1026 times
- mccy
- Posts: 69
- Joined: Sun Feb 27, 2011 3:20 pm
Re: Is it possible to build a very simple SFZ creator?
Hm, finally I guess building an editor is more easy than a converter...
But as long as I didn't manage drag & drop & multiple files it makes no sense.
Anyway, yesterday I did not think to get such thing done today in very small time windows.
But as long as I didn't manage drag & drop & multiple files it makes no sense.
Anyway, yesterday I did not think to get such thing done today in very small time windows.
- Attachments
-
- sfzfirsttest2.fsm
- (8.23 KiB) Downloaded 1058 times
- mccy
- Posts: 69
- Joined: Sun Feb 27, 2011 3:20 pm
Re: Is it possible to build a very simple SFZ creator?
good work mccy!
I use SFZ all the time and just wanted to point out that in an SFZ file you do not usualy have the full path to the waves written into the file! it is usually done like below
<group>
volume=-1
ampeg_attack=0.001
ampeg_decay=0.75
ampeg_release=1.971
resonance=0.19
<region> sample=Samples\001.wav
lovel=1
hivel=127
where the SFZ lies in dir x and dir x contains another dir (Samples in this case) which contains your wave files.
or if the SFZ file is placed in the same dir as the waves it would be <region> sample= 001.wav.
there are a number of SFZ formats around atm, you might find this page useful m8
http://www.cakewalk.com/DevXchange/article.aspx?aid=108
Best Regards
oh p.s here are a couple of small SFZ editors i sometimes use, they might be handy to look at
I use SFZ all the time and just wanted to point out that in an SFZ file you do not usualy have the full path to the waves written into the file! it is usually done like below
<group>
volume=-1
ampeg_attack=0.001
ampeg_decay=0.75
ampeg_release=1.971
resonance=0.19
<region> sample=Samples\001.wav
lovel=1
hivel=127
where the SFZ lies in dir x and dir x contains another dir (Samples in this case) which contains your wave files.
or if the SFZ file is placed in the same dir as the waves it would be <region> sample= 001.wav.
there are a number of SFZ formats around atm, you might find this page useful m8
http://www.cakewalk.com/DevXchange/article.aspx?aid=108
Best Regards
oh p.s here are a couple of small SFZ editors i sometimes use, they might be handy to look at
- Jay
- Posts: 276
- Joined: Tue Jul 13, 2010 5:42 pm
Re: Is it possible to build a very simple SFZ creator?
Hi again, mccy.
Seems you are a quick learner! - your file access and stringy routines are looking to be in good shape.
The file path errors that you're getting come down to the thing I mentioned before about Ruby being 'embedded' inside FS.
A 'bare' Ruby program would usually run like any other executable file - load up, it starts, runs through, ends.
Ruby in FS is designed to handle recalculating things when values at the inputs change, so behaves a little differently....
When you simply write a sequence of code, it will run (a) when the program first starts, and (b) every time an input value changes. The trouble here is that when (a) happens at startup, you have not yet opened the file dialogue to choose a file, so there is no path yet available - you can see this if you connect a string primitive to the output of the file dialogue primitive; just an empty string there until the dialogue is used.
What you really want is for the code to run only when there is a new input value, and the developers have given us a simple way to do this - the 'event' method. A 'method' is just a wrapped up chunk of code that can be run on demand - other programming languages might call them sub-routines, procedures or functions.
To make an event method, just 'wrap up' your code by putting "def event" at the start and "end" at the end (convention is that you would indent the code inside by one tab, to make the method boundaries easier to see.
Better still, you can also get 'event' to automatically read some values for you, by giving it three variable names to play with (this is optional)...
The variable names there, "index" etc. can be whatever you want - it is the order of them that decides what data they will get.
1st variable ("index") - will get an index value indicating which input is was that changed (starting from zero for the top input)
2nd variable ("value") - is the new value that just arrived.
3rd variable ("time") - holds the time that the event arrived (number of seconds since startup)
You don't have to use these values if you don't want to, and in fact both the time and the value are easily available in other ways. But the input index one is very useful because you can use it to make the program do different things depending which value it was that changed, using "decision making" commands like; if, unless, case...
Even just the simple "event" without variables will be useful to you here, as you can then avoid the program running until you have the input values prepared.
Re: file selector.
Yes, you are quite right, doing it one file at a time is never going to be practical - until Ruby came along, this has made constructing a proper sample browser very difficult - though even in the old SM software there were still some that came surprisingly close.
One thing that, as yet, we can't do, is to drag'n'drop files from another window, or from the desktop I am hopeful this will be one of the coming upgrades, as Ruby has a mechanism for it, and the developers have already indicated a commitment to OLE, which allows different app's to communicate with each other.
However, a file browser within the FS design that allows for operating on multiple files is definitely possible, and being able to re-arrange them by dragging with the mouse pointer could also be done.
As that would be such a useful module for a wide range of tasks in FS, its something that I've already been working on for a while now. It's a little way off being presentable just yet, but it's realistic that I might have a Beta to post within just a few weeks.
In the mean time, there is a little trick that we used to use in SM that might be of use...
The current file browser only lets you choose a file, not a folder - but in Ruby you could quite easily separate the folder name from the file path, and then create a loop that then accesses every file in that directory (or even one that only chooses files that match a particular pattern). So you are spot on to be looking into looping methods.
As you don't seem to be struggling much with the language's syntax, I'd strongly recommend investigating the Ruby API Core document.
It will look very daunting at first as it lists every single method available for every single class, and much of it will be pure gobbledy-gook. But actually most classes and methods are pretty intuitively named - look at the methods for the "Dir" class, for example, and you find all the things that you can do with directories. I still rarely understand every word of the descriptions, but usually those and the code examples will give you the gist of whether you've found something useful or not, and a few quick experiments will soon tell you one way or the other.
After a while, it becomes a very quick way to locate methods that might do what you want, good starting points for searching the many online Ruby tutorials and forums - an opportunity to shape your 'curriculum' to suit the tasks that you want to do.
Seems you are a quick learner! - your file access and stringy routines are looking to be in good shape.
The file path errors that you're getting come down to the thing I mentioned before about Ruby being 'embedded' inside FS.
A 'bare' Ruby program would usually run like any other executable file - load up, it starts, runs through, ends.
Ruby in FS is designed to handle recalculating things when values at the inputs change, so behaves a little differently....
When you simply write a sequence of code, it will run (a) when the program first starts, and (b) every time an input value changes. The trouble here is that when (a) happens at startup, you have not yet opened the file dialogue to choose a file, so there is no path yet available - you can see this if you connect a string primitive to the output of the file dialogue primitive; just an empty string there until the dialogue is used.
What you really want is for the code to run only when there is a new input value, and the developers have given us a simple way to do this - the 'event' method. A 'method' is just a wrapped up chunk of code that can be run on demand - other programming languages might call them sub-routines, procedures or functions.
To make an event method, just 'wrap up' your code by putting "def event" at the start and "end" at the end (convention is that you would indent the code inside by one tab, to make the method boundaries easier to see.
Better still, you can also get 'event' to automatically read some values for you, by giving it three variable names to play with (this is optional)...
- Code: Select all
def event index, value, time
The variable names there, "index" etc. can be whatever you want - it is the order of them that decides what data they will get.
1st variable ("index") - will get an index value indicating which input is was that changed (starting from zero for the top input)
2nd variable ("value") - is the new value that just arrived.
3rd variable ("time") - holds the time that the event arrived (number of seconds since startup)
You don't have to use these values if you don't want to, and in fact both the time and the value are easily available in other ways. But the input index one is very useful because you can use it to make the program do different things depending which value it was that changed, using "decision making" commands like; if, unless, case...
Even just the simple "event" without variables will be useful to you here, as you can then avoid the program running until you have the input values prepared.
Re: file selector.
Yes, you are quite right, doing it one file at a time is never going to be practical - until Ruby came along, this has made constructing a proper sample browser very difficult - though even in the old SM software there were still some that came surprisingly close.
One thing that, as yet, we can't do, is to drag'n'drop files from another window, or from the desktop I am hopeful this will be one of the coming upgrades, as Ruby has a mechanism for it, and the developers have already indicated a commitment to OLE, which allows different app's to communicate with each other.
However, a file browser within the FS design that allows for operating on multiple files is definitely possible, and being able to re-arrange them by dragging with the mouse pointer could also be done.
As that would be such a useful module for a wide range of tasks in FS, its something that I've already been working on for a while now. It's a little way off being presentable just yet, but it's realistic that I might have a Beta to post within just a few weeks.
In the mean time, there is a little trick that we used to use in SM that might be of use...
The current file browser only lets you choose a file, not a folder - but in Ruby you could quite easily separate the folder name from the file path, and then create a loop that then accesses every file in that directory (or even one that only chooses files that match a particular pattern). So you are spot on to be looking into looping methods.
As you don't seem to be struggling much with the language's syntax, I'd strongly recommend investigating the Ruby API Core document.
It will look very daunting at first as it lists every single method available for every single class, and much of it will be pure gobbledy-gook. But actually most classes and methods are pretty intuitively named - look at the methods for the "Dir" class, for example, and you find all the things that you can do with directories. I still rarely understand every word of the descriptions, but usually those and the code examples will give you the gist of whether you've found something useful or not, and a few quick experiments will soon tell you one way or the other.
After a while, it becomes a very quick way to locate methods that might do what you want, good starting points for searching the many online Ruby tutorials and forums - an opportunity to shape your 'curriculum' to suit the tasks that you want to do.
All schematics/modules I post are free for all to use - but a credit is always polite!
Don't stagnate, mutate to create!
Don't stagnate, mutate to create!
-
trogluddite - Posts: 1730
- Joined: Fri Oct 22, 2010 12:46 am
- Location: Yorkshire, UK
Re: Is it possible to build a very simple SFZ creator?
strange, when opening a tx16wx prg and saving it, it seems, that Flowstone/ruby can't read it... That's what is in the saved txt file... What means utf 16? Is ruby in flowstone not able to read this file although notepad can do it??
<?xml version="1.0" encoding="utf-16"?>㰀琀砀㨀瀀爀漀最爀愀洀ഀ
xmlns:tx="http://www.tx16wx.com/2.0/program"ऀ砀洀氀渀猀㨀砀猀椀㴀∀栀琀琀瀀㨀⼀⼀眀眀眀⸀眀㌀⸀漀爀最⼀㈀ ⼀堀䴀䰀匀挀栀攀洀愀ⴀ椀渀猀琀愀渀挀攀∀ഀ
xsi:schemaLocation="http://www.tx16wx.com/2.0/program txprogram.xsd"ऀ琀砀㨀挀爀攀愀琀攀搀ⴀ戀礀㴀∀㈀ ㈀∀ഀ
tx:name="1x"ऀ㸀ഀ
<tx:wave tx:id="1" tx:path="1.wav"/>ऀ㰀琀砀㨀爀愀渀最攀 琀砀㨀氀漀眀欀攀礀㴀∀䌀ⴀ∀ 琀砀㨀栀椀最栀欀攀礀㴀∀䜀㤀∀ 琀砀㨀氀漀眀瘀攀氀㴀∀ ∀ 琀砀㨀栀椀最栀瘀攀氀㴀∀㈀㜀∀⼀㸀ഀ
<tx:group tx:name="1"ऀऀ琀砀㨀挀漀愀爀猀攀㴀∀ ∀ഀ
tx:fine="0"ऀऀ琀砀㨀琀甀渀椀渀最㴀∀一漀爀洀愀氀∀ഀ
tx:glide="0.0ms"ऀऀ琀砀㨀瘀攀氀漀挀椀琀礀㴀∀⸀ ∀ഀ
tx:velocityOffset="0"ऀऀ琀砀㨀瀀愀渀㴀∀ ⸀ ∀ഀ
tx:amp="0.50"ऀऀ琀砀㨀瀀氀愀礀洀漀搀攀㴀∀一漀爀洀愀氀∀ഀ
tx:polymode="Poly"ऀऀ琀砀㨀漀甀琀瀀甀琀㴀∀⠀挀栀⤀∀ഀ
tx:start="0.0ms"ऀऀ琀砀㨀挀栀漀欀攀䜀爀漀甀瀀㴀∀ ∀ഀ
>ऀऀ㰀琀砀㨀爀愀渀最攀 琀砀㨀氀漀眀欀攀礀㴀∀䌀ⴀ∀ 琀砀㨀栀椀最栀欀攀礀㴀∀䜀㤀∀ 琀砀㨀氀漀眀瘀攀氀㴀∀ ∀ 琀砀㨀栀椀最栀瘀攀氀㴀∀㈀㜀∀⼀㸀ഀ
<tx:aeg tx:attack="0.0ms" tx:decay1="0.0ms" tx:level1="1.00" tx:decay2="0.0ms" tx:sustain="1.00" tx:release="0.0ms"/>ऀऀ㰀琀砀㨀攀渀瘀 琀砀㨀氀攀瘀攀氀 㴀∀ ⸀ ∀ 琀砀㨀琀椀洀攀㴀∀⸀ 猀∀ 琀砀㨀氀攀瘀攀氀㴀∀ ⸀ ∀ 琀砀㨀琀椀洀攀㈀㴀∀⸀ 猀∀ 琀砀㨀氀攀瘀攀氀㈀㴀∀ ⸀ ∀ 琀砀㨀琀椀洀攀㌀㴀∀⸀ 猀∀ 琀砀㨀氀攀瘀攀氀㌀㴀∀ ⸀ ∀ 琀砀㨀愀洀瀀㴀∀∀⼀㸀ഀ
<tx:env2 tx:level0="0.00" tx:time1="1.00s" tx:level1="0.00" tx:time2="1.00s" tx:level2="0.00" tx:time3="1.00s" tx:level3="0.00" tx:amp="1"/>ऀऀ㰀琀砀㨀氀昀漀 琀砀㨀爀愀琀攀㴀∀ ⸀㔀 䠀稀∀ 琀砀㨀琀礀瀀攀㴀∀匀椀渀甀猀∀ 琀砀㨀猀礀渀挀㴀∀一漀渀攀∀ 琀砀㨀琀爀椀最㴀∀刀攀琀爀椀最∀ 琀砀㨀昀愀搀攀椀渀㴀∀ ⸀ 洀猀∀ 琀砀㨀瀀漀猀㴀∀ ⸀ ∀ 琀砀㨀愀洀瀀㴀∀⸀ ∀⼀㸀ഀ
<tx:lfo2 tx:rate="0.50 Hz" tx:type="Sinus" tx:sync="None" tx:trig="Retrig" tx:fadein="0.0ms" tx:pos="0.00" tx:amp="1.00"/>ऀऀ㰀琀砀㨀猀攀焀 琀砀㨀爀愀琀攀㴀∀ ⸀㔀 䠀稀∀ 琀砀㨀猀礀渀挀㴀∀一漀渀攀∀ 琀砀㨀琀爀椀最㴀∀刀攀琀爀椀最∀ 琀砀㨀昀愀搀攀椀渀㴀∀ ⸀ 洀猀∀ 琀砀㨀瀀漀猀㴀∀ ⸀ ∀ 琀砀㨀愀洀瀀㴀∀⸀ ∀ 琀砀㨀氀攀渀最琀栀㴀∀ ∀ 琀砀㨀猀洀漀漀琀栀㴀∀ ∀ 琀砀㨀猀琀攀瀀猀礀渀挀㴀∀ ∀ ⼀㸀ഀ
<tx:seq2 tx:rate="0.50 Hz" tx:sync="None" tx:trig="Retrig" tx:fadein="0.0ms" tx:pos="0.00" tx:amp="1.00" tx:length="0" tx:smooth="0" tx:stepsync="0" />ऀऀ㰀琀砀㨀猀攀焀㌀ 琀砀㨀爀愀琀攀㴀∀ ⸀㔀 䠀稀∀ 琀砀㨀猀礀渀挀㴀∀一漀渀攀∀ 琀砀㨀琀爀椀最㴀∀刀攀琀爀椀最∀ 琀砀㨀昀愀搀攀椀渀㴀∀ ⸀ 洀猀∀ 琀砀㨀瀀漀猀㴀∀ ⸀ ∀ 琀砀㨀愀洀瀀㴀∀⸀ ∀ 琀砀㨀氀攀渀最琀栀㴀∀ ∀ 琀砀㨀猀洀漀漀琀栀㴀∀ ∀ 琀砀㨀猀琀攀瀀猀礀渀挀㴀∀ ∀ ⼀㸀ഀ
<tx:filter tx:type="Off" tx:freq="20000 Hz" tx:res="0.00" tx:drive="0.00"/>ऀऀ㰀琀砀㨀洀漀搀甀氀愀琀椀漀渀㸀ഀ
<tx:entry tx:source="Pitchbend" tx:destination="Pitch" tx:amount="+200 Ct" tx:frozen="0"/>ऀऀऀ㰀琀砀㨀攀渀琀爀礀 琀砀㨀猀漀甀爀挀攀㴀∀䔀一嘀∀ 琀砀㨀搀攀猀琀椀渀愀琀椀漀渀㴀∀倀椀琀挀栀∀ 琀砀㨀愀洀漀甀渀琀㴀∀⬀ 䌀琀∀ 琀砀㨀昀爀漀稀攀渀㴀∀ ∀⼀㸀ഀ
<tx:entry tx:source="LFO1" tx:destination="Pitch" tx:amount="+0 Ct" tx:frozen="0"/>ऀऀऀ㰀琀砀㨀攀渀琀爀礀 琀砀㨀猀漀甀爀挀攀㴀∀䔀一嘀㈀∀ 琀砀㨀搀攀猀琀椀渀愀琀椀漀渀㴀∀䘀椀氀琀攀爀 䘀爀攀焀∀ 琀砀㨀愀洀漀甀渀琀㴀∀ 䠀稀∀ 琀砀㨀昀爀漀稀攀渀㴀∀ ∀⼀㸀ഀ
<tx:entry tx:source="LFO2" tx:destination="Filter Freq" tx:amount="0 Hz" tx:frozen="0"/>ऀऀऀ㰀琀砀㨀攀渀琀爀礀 琀砀㨀猀漀甀爀挀攀㴀∀匀䔀儀∀ 琀砀㨀搀攀猀琀椀渀愀琀椀漀渀㴀∀䄀洀瀀∀ 琀砀㨀愀洀漀甀渀琀㴀∀⬀ ⸀ ∀ 琀砀㨀昀爀漀稀攀渀㴀∀ ∀⼀㸀ഀ
</tx:modulation>ऀऀ㰀琀砀㨀猀瀀氀椀琀 琀砀㨀眀愀瘀攀㴀∀∀ 琀砀㨀欀攀礀㴀∀䌀ⴀ∀ 琀砀㨀氀漀漀瀀㴀∀ⴀ∀ 琀砀㨀爀攀氀攀愀猀攀㴀∀ⴀ∀⼀㸀ഀ
</tx:group>㰀⼀琀砀㨀瀀爀漀最爀愀洀㸀ഀ
<?xml version="1.0" encoding="utf-16"?>㰀琀砀㨀瀀爀漀最爀愀洀ഀ
xmlns:tx="http://www.tx16wx.com/2.0/program"ऀ砀洀氀渀猀㨀砀猀椀㴀∀栀琀琀瀀㨀⼀⼀眀眀眀⸀眀㌀⸀漀爀最⼀㈀ ⼀堀䴀䰀匀挀栀攀洀愀ⴀ椀渀猀琀愀渀挀攀∀ഀ
xsi:schemaLocation="http://www.tx16wx.com/2.0/program txprogram.xsd"ऀ琀砀㨀挀爀攀愀琀攀搀ⴀ戀礀㴀∀㈀ ㈀∀ഀ
tx:name="1x"ऀ㸀ഀ
<tx:wave tx:id="1" tx:path="1.wav"/>ऀ㰀琀砀㨀爀愀渀最攀 琀砀㨀氀漀眀欀攀礀㴀∀䌀ⴀ∀ 琀砀㨀栀椀最栀欀攀礀㴀∀䜀㤀∀ 琀砀㨀氀漀眀瘀攀氀㴀∀ ∀ 琀砀㨀栀椀最栀瘀攀氀㴀∀㈀㜀∀⼀㸀ഀ
<tx:group tx:name="1"ऀऀ琀砀㨀挀漀愀爀猀攀㴀∀ ∀ഀ
tx:fine="0"ऀऀ琀砀㨀琀甀渀椀渀最㴀∀一漀爀洀愀氀∀ഀ
tx:glide="0.0ms"ऀऀ琀砀㨀瘀攀氀漀挀椀琀礀㴀∀⸀ ∀ഀ
tx:velocityOffset="0"ऀऀ琀砀㨀瀀愀渀㴀∀ ⸀ ∀ഀ
tx:amp="0.50"ऀऀ琀砀㨀瀀氀愀礀洀漀搀攀㴀∀一漀爀洀愀氀∀ഀ
tx:polymode="Poly"ऀऀ琀砀㨀漀甀琀瀀甀琀㴀∀⠀挀栀⤀∀ഀ
tx:start="0.0ms"ऀऀ琀砀㨀挀栀漀欀攀䜀爀漀甀瀀㴀∀ ∀ഀ
>ऀऀ㰀琀砀㨀爀愀渀最攀 琀砀㨀氀漀眀欀攀礀㴀∀䌀ⴀ∀ 琀砀㨀栀椀最栀欀攀礀㴀∀䜀㤀∀ 琀砀㨀氀漀眀瘀攀氀㴀∀ ∀ 琀砀㨀栀椀最栀瘀攀氀㴀∀㈀㜀∀⼀㸀ഀ
<tx:aeg tx:attack="0.0ms" tx:decay1="0.0ms" tx:level1="1.00" tx:decay2="0.0ms" tx:sustain="1.00" tx:release="0.0ms"/>ऀऀ㰀琀砀㨀攀渀瘀 琀砀㨀氀攀瘀攀氀 㴀∀ ⸀ ∀ 琀砀㨀琀椀洀攀㴀∀⸀ 猀∀ 琀砀㨀氀攀瘀攀氀㴀∀ ⸀ ∀ 琀砀㨀琀椀洀攀㈀㴀∀⸀ 猀∀ 琀砀㨀氀攀瘀攀氀㈀㴀∀ ⸀ ∀ 琀砀㨀琀椀洀攀㌀㴀∀⸀ 猀∀ 琀砀㨀氀攀瘀攀氀㌀㴀∀ ⸀ ∀ 琀砀㨀愀洀瀀㴀∀∀⼀㸀ഀ
<tx:env2 tx:level0="0.00" tx:time1="1.00s" tx:level1="0.00" tx:time2="1.00s" tx:level2="0.00" tx:time3="1.00s" tx:level3="0.00" tx:amp="1"/>ऀऀ㰀琀砀㨀氀昀漀 琀砀㨀爀愀琀攀㴀∀ ⸀㔀 䠀稀∀ 琀砀㨀琀礀瀀攀㴀∀匀椀渀甀猀∀ 琀砀㨀猀礀渀挀㴀∀一漀渀攀∀ 琀砀㨀琀爀椀最㴀∀刀攀琀爀椀最∀ 琀砀㨀昀愀搀攀椀渀㴀∀ ⸀ 洀猀∀ 琀砀㨀瀀漀猀㴀∀ ⸀ ∀ 琀砀㨀愀洀瀀㴀∀⸀ ∀⼀㸀ഀ
<tx:lfo2 tx:rate="0.50 Hz" tx:type="Sinus" tx:sync="None" tx:trig="Retrig" tx:fadein="0.0ms" tx:pos="0.00" tx:amp="1.00"/>ऀऀ㰀琀砀㨀猀攀焀 琀砀㨀爀愀琀攀㴀∀ ⸀㔀 䠀稀∀ 琀砀㨀猀礀渀挀㴀∀一漀渀攀∀ 琀砀㨀琀爀椀最㴀∀刀攀琀爀椀最∀ 琀砀㨀昀愀搀攀椀渀㴀∀ ⸀ 洀猀∀ 琀砀㨀瀀漀猀㴀∀ ⸀ ∀ 琀砀㨀愀洀瀀㴀∀⸀ ∀ 琀砀㨀氀攀渀最琀栀㴀∀ ∀ 琀砀㨀猀洀漀漀琀栀㴀∀ ∀ 琀砀㨀猀琀攀瀀猀礀渀挀㴀∀ ∀ ⼀㸀ഀ
<tx:seq2 tx:rate="0.50 Hz" tx:sync="None" tx:trig="Retrig" tx:fadein="0.0ms" tx:pos="0.00" tx:amp="1.00" tx:length="0" tx:smooth="0" tx:stepsync="0" />ऀऀ㰀琀砀㨀猀攀焀㌀ 琀砀㨀爀愀琀攀㴀∀ ⸀㔀 䠀稀∀ 琀砀㨀猀礀渀挀㴀∀一漀渀攀∀ 琀砀㨀琀爀椀最㴀∀刀攀琀爀椀最∀ 琀砀㨀昀愀搀攀椀渀㴀∀ ⸀ 洀猀∀ 琀砀㨀瀀漀猀㴀∀ ⸀ ∀ 琀砀㨀愀洀瀀㴀∀⸀ ∀ 琀砀㨀氀攀渀最琀栀㴀∀ ∀ 琀砀㨀猀洀漀漀琀栀㴀∀ ∀ 琀砀㨀猀琀攀瀀猀礀渀挀㴀∀ ∀ ⼀㸀ഀ
<tx:filter tx:type="Off" tx:freq="20000 Hz" tx:res="0.00" tx:drive="0.00"/>ऀऀ㰀琀砀㨀洀漀搀甀氀愀琀椀漀渀㸀ഀ
<tx:entry tx:source="Pitchbend" tx:destination="Pitch" tx:amount="+200 Ct" tx:frozen="0"/>ऀऀऀ㰀琀砀㨀攀渀琀爀礀 琀砀㨀猀漀甀爀挀攀㴀∀䔀一嘀∀ 琀砀㨀搀攀猀琀椀渀愀琀椀漀渀㴀∀倀椀琀挀栀∀ 琀砀㨀愀洀漀甀渀琀㴀∀⬀ 䌀琀∀ 琀砀㨀昀爀漀稀攀渀㴀∀ ∀⼀㸀ഀ
<tx:entry tx:source="LFO1" tx:destination="Pitch" tx:amount="+0 Ct" tx:frozen="0"/>ऀऀऀ㰀琀砀㨀攀渀琀爀礀 琀砀㨀猀漀甀爀挀攀㴀∀䔀一嘀㈀∀ 琀砀㨀搀攀猀琀椀渀愀琀椀漀渀㴀∀䘀椀氀琀攀爀 䘀爀攀焀∀ 琀砀㨀愀洀漀甀渀琀㴀∀ 䠀稀∀ 琀砀㨀昀爀漀稀攀渀㴀∀ ∀⼀㸀ഀ
<tx:entry tx:source="LFO2" tx:destination="Filter Freq" tx:amount="0 Hz" tx:frozen="0"/>ऀऀऀ㰀琀砀㨀攀渀琀爀礀 琀砀㨀猀漀甀爀挀攀㴀∀匀䔀儀∀ 琀砀㨀搀攀猀琀椀渀愀琀椀漀渀㴀∀䄀洀瀀∀ 琀砀㨀愀洀漀甀渀琀㴀∀⬀ ⸀ ∀ 琀砀㨀昀爀漀稀攀渀㴀∀ ∀⼀㸀ഀ
</tx:modulation>ऀऀ㰀琀砀㨀猀瀀氀椀琀 琀砀㨀眀愀瘀攀㴀∀∀ 琀砀㨀欀攀礀㴀∀䌀ⴀ∀ 琀砀㨀氀漀漀瀀㴀∀ⴀ∀ 琀砀㨀爀攀氀攀愀猀攀㴀∀ⴀ∀⼀㸀ഀ
</tx:group>㰀⼀琀砀㨀瀀爀漀最爀愀洀㸀ഀ
- mccy
- Posts: 69
- Joined: Sun Feb 27, 2011 3:20 pm
Re: Is it possible to build a very simple SFZ creator?
is that Japanese? looks like it!
im not sure about all this stuff but i found this http://www.ruby-forum.com/topic/140946 maybe your answer is in there or here http://blog.grayproductions.net/article ... _encodings or here http://www.w3schools.com/xml/xml_encoding.asp
best of luck!
im not sure about all this stuff but i found this http://www.ruby-forum.com/topic/140946 maybe your answer is in there or here http://blog.grayproductions.net/article ... _encodings or here http://www.w3schools.com/xml/xml_encoding.asp
best of luck!
- Jay
- Posts: 276
- Joined: Tue Jul 13, 2010 5:42 pm
Re: Is it possible to build a very simple SFZ creator?
indeed it has to do with utf-8 or 16. Converting to utf-8 before reading solves the problem.
I did not manage to read utf-16 correctly so far
I did not manage to read utf-16 correctly so far
- mccy
- Posts: 69
- Joined: Sun Feb 27, 2011 3:20 pm
Re: Is it possible to build a very simple SFZ creator?
I think this may be one to ask the developers about. I checked out Jay's links, and followed a few things up, and from what I can tell...
- The first link suggest using the Iconv module. Unfortunately, this isn't considered a "core" class, but is a "standard library" module. But FS does not include much of the standard library - and not Iconv.
It may be possible to add 'Iconv' to the FS Ruby libraries - but the file from my 'non-FS' Ruby install didn't work, and that is probably down to its code needing to be re-compiled, which is well beyond my abilities.
- Encode IS part of the standard Ruby core, and we do have that class on our system. However, when I type "Encoder.list" to find out what encodings are supported, utf-16 is not among them - they are all single byte encodings. As I have seen utf-16 used in other examples with the Encoder class, I would guess that this too is a case of the developers leaving out a few files to keep exports smaller (unless it is a Windows'y kind of thing - maybe 'Encoder.list' would show different ones on a different system?)
There may be some other way - this is not an issue that I've ever seen before - but if utf-16 is commonly used for xml files etc. it would be very nice if FS supported it. So my best suggestion would be to e-mail the developers to see if we've missed something, or otherwise, to suggest a little upgrade to add utf-16 to 'Encoder'.
Dammit, it all seemed to be going really well for a while there!
- The first link suggest using the Iconv module. Unfortunately, this isn't considered a "core" class, but is a "standard library" module. But FS does not include much of the standard library - and not Iconv.
It may be possible to add 'Iconv' to the FS Ruby libraries - but the file from my 'non-FS' Ruby install didn't work, and that is probably down to its code needing to be re-compiled, which is well beyond my abilities.
- Encode IS part of the standard Ruby core, and we do have that class on our system. However, when I type "Encoder.list" to find out what encodings are supported, utf-16 is not among them - they are all single byte encodings. As I have seen utf-16 used in other examples with the Encoder class, I would guess that this too is a case of the developers leaving out a few files to keep exports smaller (unless it is a Windows'y kind of thing - maybe 'Encoder.list' would show different ones on a different system?)
There may be some other way - this is not an issue that I've ever seen before - but if utf-16 is commonly used for xml files etc. it would be very nice if FS supported it. So my best suggestion would be to e-mail the developers to see if we've missed something, or otherwise, to suggest a little upgrade to add utf-16 to 'Encoder'.
Dammit, it all seemed to be going really well for a while there!
All schematics/modules I post are free for all to use - but a credit is always polite!
Don't stagnate, mutate to create!
Don't stagnate, mutate to create!
-
trogluddite - Posts: 1730
- Joined: Fri Oct 22, 2010 12:46 am
- Location: Yorkshire, UK
48 posts
• Page 2 of 5 • 1, 2, 3, 4, 5
Who is online
Users browsing this forum: No registered users and 76 guests