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
preset drawing bug vertical slider!!
5 posts
• Page 1 of 1
preset drawing bug vertical slider!!
hallo, i found a preset drawing bug in the vertical slider, after presetchange it draws the slider upsidedown, the value is ok but the slider is on the wrong side, i think it has something to do with the opposite valuedirection to the drawdirection - value = 0 down / 1 up, but you always draw from the top to the bottom.. the horizontal slider works fine - here you draw in the same direction then the value goes, 0 at the left up to the right... sadly my programmingskills are not enough for that....just watch the fsm i commented inside..
- Attachments
-
- SliderDrawBug.fsm
- (12.09 KiB) Downloaded 1152 times
-
Nubeat7 - Posts: 1347
- Joined: Sat Apr 14, 2012 9:59 am
- Location: Vienna
Re: preset drawing bug vertical slider!!
Nubeat7 wrote:hallo, i found a preset drawing bug in the vertical slider, after presetchange it draws the slider upsidedown, the value is ok but the slider is on the wrong side, i think it has something to do with the opposite valuedirection to the drawdirection - value = 0 down / 1 up, but you always draw from the top to the bottom.. the horizontal slider works fine - here you draw in the same direction then the value goes, 0 at the left up to the right... sadly my programmingskills are not enough for that....just watch the fsm i commented inside..
ok i found an easy way to solve the problem, just delete the 1- at the "output 0,1-@value" -line in the "mouseMoveCaptured" definition and put it outside the code after the "preset" before the "min max" and it works fine with the presetmanager...
- Attachments
-
- SliderDrawBugSolved.fsm
- (10.38 KiB) Downloaded 1185 times
-
Nubeat7 - Posts: 1347
- Joined: Sat Apr 14, 2012 9:59 am
- Location: Vienna
Re: preset drawing bug vertical slider!!
Well spotted!
A slightly better solution would be to keep the output 0,1-@value and then reverse the value when the Ruby 'event' method gets an input...
@value = [0,1-v,1].sort[1]
This seems to do the same thing, but it has two advantages...
1) VST automation. Putting the reversal after the preset means that VST host automation lanes will be upside down - which could be a bit confusing.
2) you might want a slider where you can set the value from outside the module - for linked together controls, for example. So moving the reversal to the Ruby input event will make sure that this works as expected.
EDIT)
Three advantages...
3) The MIDI CC receiver is also inside the preset - so my code change will put the MIDI CC the right way around too.
A slightly better solution would be to keep the output 0,1-@value and then reverse the value when the Ruby 'event' method gets an input...
@value = [0,1-v,1].sort[1]
This seems to do the same thing, but it has two advantages...
1) VST automation. Putting the reversal after the preset means that VST host automation lanes will be upside down - which could be a bit confusing.
2) you might want a slider where you can set the value from outside the module - for linked together controls, for example. So moving the reversal to the Ruby input event will make sure that this works as expected.
EDIT)
Three advantages...
3) The MIDI CC receiver is also inside the preset - so my code change will put the MIDI CC the right way around too.
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: preset drawing bug vertical slider!!
Thanks trog, i knew you were the right man for it
-
Nubeat7 - Posts: 1347
- Joined: Sat Apr 14, 2012 9:59 am
- Location: Vienna
Re: preset drawing bug vertical slider!!
FYI
Reported this to Malc so that the toolbox can be updated for the next release.
Reported this to Malc so that the toolbox can be updated for the next release.
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
5 posts
• Page 1 of 1
Who is online
Users browsing this forum: No registered users and 50 guests