VSTGUI onWheel never got called?
-
- KVRer
- 3 posts since 18 Jul, 2009
Hi
I'm trying to create an interface for my VST in VSTGUI. First I like to say how poor the documentation for this is (for the 3.0 anyway). I had to keep refering to yvan grabit's 2.2 documenation for some more clarity. But it still doesn't clear everything. There are two many overlapping functions that just seemed unnecessary. And the drawtest does not give examples of some of the more "useful" functions.
Anyway, I can't get the onWheel event to happen at all. Am I missing something here? I've placed a debug trace string in the original vstgui sdk code and it still doesn't get called.
Any help would be appreciated.
I'm trying to create an interface for my VST in VSTGUI. First I like to say how poor the documentation for this is (for the 3.0 anyway). I had to keep refering to yvan grabit's 2.2 documenation for some more clarity. But it still doesn't clear everything. There are two many overlapping functions that just seemed unnecessary. And the drawtest does not give examples of some of the more "useful" functions.
Anyway, I can't get the onWheel event to happen at all. Am I missing something here? I've placed a debug trace string in the original vstgui sdk code and it still doesn't get called.
Any help would be appreciated.
-
- KVRist
- 150 posts since 25 Jan, 2008 from Oregon, USA
I haven't used the wheel functions in VSTGUI so I'm sorry to say I can't help you there. However, I do suggesting upgrading to the latest version, probably beta 3.5 or 3.6 instead of the 3.0 version. You'll find the code to be greatly cleaned up as well as having quite a bit snappier performance on drawing and control manipulation. As far as the lack of documentation that isn't really addressed but it is a good exercise in being able to interpret code based on its own merits. Think of it as a learning experience 
-
- KVRer
- Topic Starter
- 3 posts since 18 Jul, 2009
Hmm, I just tried 3.5 and GUI does seem to perform a little better.
Guess I'll give the code a read.
Thanks.
Guess I'll give the code a read.
Thanks.
-
- KVRAF
- 1940 posts since 16 Aug, 2004 from Vienna, Austria
It also depends on the host's capabilities in the versions of VSTGui that come with the VST SDK 2.x, since this uses an undocumented "feature" of the VST protocol, where the host has to send wheel informations using the rather cryptic call
... and not every host sends that.
Code: Select all
pEffect->dispatcher(pEffect, effVendorSpecific, 'stCA', 'Whee', NULL, value);-
- KVRist
- 211 posts since 11 Feb, 2006
Wheel works fine for me in OSX as is in 3.0-3.6, but in windows i found i had to add SetFocus((HWND)pHwnd); to the end of CFrame::initFrame in vstgui.cpp to get it to work.
-
- KVRer
- Topic Starter
- 3 posts since 18 Jul, 2009
That solved the problem. But the focus is lost as soon as I switch to another window.gnjp wrote:Wheel works fine for me in OSX as is in 3.0-3.6, but in windows i found i had to add SetFocus((HWND)pHwnd); to the end of CFrame::initFrame in vstgui.cpp to get it to work.
-
- KVRist
- 211 posts since 11 Feb, 2006
I put the SetFocus((HWND)pHwnd) in the event main handler for
CFrame too in on mousedown, so when you click on the GUI again it re-focuses
the window.
CFrame too in on mousedown, so when you click on the GUI again it re-focuses
the window.
-
- KVRian
- 523 posts since 30 Jan, 2009 from UK
Post-digging here a little, but just in case anybody stumbles on this thread in future wondering why their VSTGUI mouse wheel events are not coming through in some hosts on PC and finds this doesn't quite fix their problem, it may be worth trying the code out in this link where the WM_NCHITTEST section is, as it helped me out.
