Welcome to %s forums

BrainModular Users Forum

Login Register

Two question about sliders and hid?

General Discussion about whatever fits..
Post Reply
r.erorr
Member
Posts: 405
Location: Latvia
Contact:

Unread post by r.erorr » 26 Jun 2011, 13:53

Hello.
1. Is there possible to control sliders with mouse wheel even the pointer is not on slider? That is like key learn option.
2. maybe there is some not very expensive HID devices with several knobs and sliders? Like mood wheel, pitch band etc

23fx23
Member
Posts: 2545
Contact:

Unread post by 23fx23 » 26 Jun 2011, 14:11

Nope, but you can either use sendmousemessage module to force the mouse going on top of slider,

or even simpler directly use the mouse module: you can see mouse output light up each time mouse wheel changes, and
the delta output show +1 or -1 relating scrolling direction. so it can be possible to connect it to the increment value of a fader
ie only when left clic is on or other condition, delta control the fader, even if not on top of it.

i would do something like this: here fader increments of 1 or -1 so fader goes from 0 to 10, but you can add a multiplier
to delta if want fader to go from 0to 1. also here it apply scroll only when mouse midle button is on but you can choose
another condition.
Image

Floego
Member
Posts: 319
Location: Venezuela
Contact:

Unread post by Floego » 26 Jun 2011, 16:09

It would be nice to have somekind of keyboard 'sticky key' allowing the mouse wheel to control a slider while the key are down, or for a certain time period after the key was pressed. And previously being able to define a set of this 'keys' for a group of sliders or knobs.

In other words, a combo between mouse and computer keyboard for a certain action. And grouping them.:)

r.erorr
Member
Posts: 405
Location: Latvia
Contact:

Unread post by r.erorr » 27 Jun 2011, 01:53

I keep in mind, thanks

User avatar
nay-seven
Site Admin
Posts: 5684
Location: rennes France
Contact:

Unread post by nay-seven » 27 Jun 2011, 08:55

here a little idea :
using this with the poly mode you can create more shortcuts
Image

Floego
Member
Posts: 319
Location: Venezuela
Contact:

Unread post by Floego » 27 Jun 2011, 12:56

very good idea nay! :)

and instead of the keyboard, it could use (for example) the buttons of a game pad, pedal, etc.

User avatar
nay-seven
Site Admin
Posts: 5684
Location: rennes France
Contact:

Unread post by nay-seven » 27 Jun 2011, 13:30

Thanks Floego,
Here a little prototype ( for pro users only cause use the poly function )

Floego
Member
Posts: 319
Location: Venezuela
Contact:

Unread post by Floego » 27 Jun 2011, 14:17

Masterly! very useful Nay :D
just one problem: once I get inside the subpatch and press 'apply polyphony' button, 'key num-2' ...'key num-8' values gets a reset to 0 :/
I don't know why?

Image

User avatar
nay-seven
Site Admin
Posts: 5684
Location: rennes France
Contact:

Unread post by nay-seven » 27 Jun 2011, 14:35

yes, this is bastante normal amigo
cause there's nothing outside to keep the value
just add a fader outside , they'll keep the values ( until you've finish, then you can delete them)
Image

Floego
Member
Posts: 319
Location: Venezuela
Contact:

Unread post by Floego » 27 Jun 2011, 15:03

Si!
I forgot that! :P

I made a tiny mod to your patch;
Image

combo key mouse with color

User avatar
nay-seven
Site Admin
Posts: 5684
Location: rennes France
Contact:

Unread post by nay-seven » 27 Jun 2011, 15:14

well done hombre ! :)

r.erorr
Member
Posts: 405
Location: Latvia
Contact:

Unread post by r.erorr » 27 Jun 2011, 20:46

Floego wrote:Si!
I forgot that! :P

I made a tiny mod to your patch;
[img align=combo key mouse with color]http://sensomusic.com/forums/uploads.ph ... lor%20.JPG[/url]

combo key mouse with color
Hmmm... why the sliders does not reach top and bottom? when I move mouse up and down there are random variations - lowest rate varies from 11- 15 highest from 76-81, but never reach 100% or 0%

User avatar
nay-seven
Site Admin
Posts: 5684
Location: rennes France
Contact:

Unread post by nay-seven » 27 Jun 2011, 21:15

yes, depending of mouse and system, you can have bad range
you can solve this with adding a sub-patch Change Scale (out 0..1) before the send bus module
and choose values like mini=0.05 and max = 0.95
then apply poly

Floego
Member
Posts: 319
Location: Venezuela
Contact:

Unread post by Floego » 27 Jun 2011, 21:28

I think this is related to the fact that the mouse module can only capture X,Y positions when INSIDE the usine main window. And maybe windows 'steals' a tiny part of Usine space at the top and botton of the screen to 'retake' control of the mouse.

23fx23
Member
Posts: 2545
Contact:

Unread post by 23fx23 » 27 Jun 2011, 21:41

yup, mouse module has several different tagets: screen contenair, ctrl panell.

so if controlling from absolute mouse, you are not sure to reach full 0..1 range exept if adding a chg scale,
but anyway there is a risk of jumping values if using this system, this is why i would use a 'relative' system rather than absolute, using delta added to current controlled fader value. what can be done is each fader send and receive to a specific buss,
and according to pressed key the patch receive specific buss, add delta, and resend to same target buss.

r.erorr
Member
Posts: 405
Location: Latvia
Contact:

Unread post by r.erorr » 27 Jun 2011, 23:59

Yes, the problem occurs if usine window is not at full screen. But full-screen is only relative solution, because fader goes from 0-100 only if mouse is not moving too fast. Dont know how to measure "fast" , but I think that there is correlation between speed and error % , there are 0-100 on slow movement, if faster ~ 5 - 95, if very fast ~ 10 - 80.

Floego
Member
Posts: 319
Location: Venezuela
Contact:

Unread post by Floego » 28 Jun 2011, 02:05

Interesting topic!
I connected an 'Oscilloscope' module to the fader and realized that when the mouse moves at very high speed , the data generated is just too few (about 5 values per full scale) to give a reasonable value once the mouse stopped moving.

video of the oscilloscope module

Maybe it could be useful to create a module to calculate acceleration?
IMHO any mouse movement that has been finished with a positive acceleration (on Y axis) for sure got to the top/botton of the screen. So maybe it is a matter of 'detecting' this parameter to find a solution?

But, could this module steal too much processor time?

r.erorr
Member
Posts: 405
Location: Latvia
Contact:

Unread post by r.erorr » 28 Jun 2011, 09:06

There is one more thing that makes me confused about keyboard too. I want that sliders work only if key is down, therefore I turn on filter keys and set "no keyboard repeat" + add wire from keyboard "key up" to toggle. Theoretically all must work fine - when key is pressed there is message 1 and slider moves, when key is released there is message 0 and slider can't be moved. But after some clumsy key press messages changes [pressed - 0, released - 1]. Try to press two or three keys simultaneously and this happens - slider moves when key is released. Most interesting is that there is no need for perfect synchronous key press.
Any idea what Is wrong here?

23fx23
Member
Posts: 2545
Contact:

Unread post by 23fx23 » 28 Jun 2011, 14:55

try to use a 'variable' module in math and connect keypressed to both in and affect, and key up only to affect.

Floego
Member
Posts: 319
Location: Venezuela
Contact:

Unread post by Floego » 28 Jun 2011, 15:24

23fx23 wrote:try to use a 'variable' module in math and connect keypressed to both in and affect, and key up only to affect.
it seems to work :)

23fx23
Member
Posts: 2545
Contact:

Unread post by 23fx23 » 28 Jun 2011, 15:44

cool, yup i use this when something has risks to 'blink',

23fx23
Member
Posts: 2545
Contact:

Unread post by 23fx23 » 28 Jun 2011, 16:11

if interested Ive uploaded a patch variation ive made using relative delta technique

you can change letters assignations in a textfield, then if corresponding key is pressed it get the fader value, and mouse wheel controls the incr/decr.

[s]WHEEL_faderZ[/s]

edit: sorry ihad messed with contenair : here it's good:

http://www.sensomusic.com/forums/upload ... ADERSB.pat

Floego
Member
Posts: 319
Location: Venezuela
Contact:

Unread post by Floego » 28 Jun 2011, 16:44

23fx23 wrote:if interested Ive uploaded a patch variation ive made using relative delta technique

you can change letters assignations in a textfield, then if corresponding key is pressed it get the fader value, and mouse wheel controls the incr/decr.

[s]WHEEL_faderZ[/s]

edit: sorry ihad messed with contenair : here it's good:

http://www.sensomusic.com/forums/upload ... ADERSB.pat
just perfect!, very clean patch :)
I like the key personalization because of the fact the keyboard layout in Windows varies with language choosen.

Only one prob : fader-1 moves too with the pressing of every other key not defined.

r.erorr
Member
Posts: 405
Location: Latvia
Contact:

Unread post by r.erorr » 28 Jun 2011, 17:26

23fx23 wrote:if interested Ive uploaded a patch variation ive made using relative delta technique

you can change letters assignations in a textfield, then if corresponding key is pressed it get the fader value, and mouse wheel controls the incr/decr.

[s]WHEEL_faderZ[/s]

edit: sorry ihad messed with contenair : here it's good:

http://www.sensomusic.com/forums/upload ... ADERSB.pat
Thanks, very useful! all works smooth
I look inside the patch .... if this is your handwriting, you are perfectionist :)

23fx23
Member
Posts: 2545
Contact:

Unread post by 23fx23 » 28 Jun 2011, 19:49

@ floego : well spoted man, ive been a bit lasy on that one ;)

this version should fix the pb and work with only assigned keys:

Scroll_faderZ

@r.error: glad if helpful for you. ideally it would need a system to get each individual min/max and increment factor,
cause here all faders need to be same range....
il make a more advanced version if got a bit of free time..but didn't want to make it too complex first

r.erorr
Member
Posts: 405
Location: Latvia
Contact:

Unread post by r.erorr » 28 Jun 2011, 20:41

yes, scroll inc/dec factor is not so smooth as in mouse Y patch, but there are other advantages, and I use both slider methods for sure.
- waiting for improvements... thanks...

Post Reply

Who is online

Users browsing this forum: No registered users and 119 guests