Advanced Question Creating VC/Panel Manipulators

Hurricane

Grinfeld Aerospace guy
Joined
Sep 16, 2011
Messages
211
Reaction score
0
Points
0
Hello everyone :hello:

I don't know how many of you here use X-Plane, but I wanted to ask you something:
Does the Orbiter SDK support manipulators,
?
Essentially, what manipulators do in X-Plane is making every grab-able object grab-able inside the simulator (at least the ones that have defined manipulators), for example: the throttles, flap levers, the 'eyeball air vents', the sun-glare shield on airliners, or the chairs on airliners, you get the point.
The manipulators are operated by clicking the manipulated object and dragging the mouse.

So, my question is: can I do something similar in Orbiter?

~Thanks in advance, Oz. :tiphat:
 

NovaSilisko

The Siliskoiest of Siliskos
Addon Developer
Joined
Jan 11, 2012
Messages
577
Reaction score
0
Points
0
The Shuttle-A has throttle sliders quite a bit like that, so it seems to be quite possible.
 

Pipcard

mikusingularity
Addon Developer
Donator
Joined
Nov 7, 2009
Messages
3,709
Reaction score
39
Points
88
Location
Negishima Space Center
The default DG's virtual cockpit lets you do that for the throttle. I don't know how, though.
 

Hielor

Defender of Truth
Donator
Beta Tester
Joined
May 30, 2008
Messages
5,580
Reaction score
2
Points
0
I don't have the SDK in front of me, but I'm pretty sure that it supports 3d "regions" that can respond to mouse input and perform an action accordingly.
 

Urwumpe

Not funny anymore
Addon Developer
Donator
Joined
Feb 6, 2008
Messages
37,663
Reaction score
2,383
Points
203
Location
Wolfsburg
Preferred Pronouns
Sire
Yes, it does, you can define regions in 3D space, that react to mouse clicks. Spheres and quads to be precise.
 

Hurricane

Grinfeld Aerospace guy
Joined
Sep 16, 2011
Messages
211
Reaction score
0
Points
0
The Shuttle-A has throttle sliders quite a bit like that, so it seems to be quite possible.

Thanks :thumbup:

The default DG's virtual cockpit lets you do that for the throttle. I don't know how, though.

All very well :)

I don't have the SDK in front of me, but I'm pretty sure that it supports 3d "regions" that can respond to mouse input and perform an action accordingly.

Ok. Thanks everyone! :)

---------- Post added at 07:16 PM ---------- Previous post was at 07:16 PM ----------

Yes, it does, you can define regions in 3D space, that react to mouse clicks. Spheres and quads to be precise.

Spheres and quads?
 

Urwumpe

Not funny anymore
Addon Developer
Donator
Joined
Feb 6, 2008
Messages
37,663
Reaction score
2,383
Points
203
Location
Wolfsburg
Preferred Pronouns
Sire
Spheres and quads?

Yes, a spherical region in the cockpit, defined by center and radius, or a quad, a flat polygon with 4 vertexes.
 

Mandella

Space Cultist
Donator
Joined
Apr 5, 2008
Messages
368
Reaction score
0
Points
0
You are going to want to read the Orbiter API Guide, found in the doc folder in the OrbiterSDK folder within your Orbiter installation.

It's going to involve coding....
 

Hurricane

Grinfeld Aerospace guy
Joined
Sep 16, 2011
Messages
211
Reaction score
0
Points
0
Yes, a spherical region in the cockpit, defined by center and radius, or a quad, a flat polygon with 4 vertexes.

Oh, that. [And the plural for vertex is vertices :)]
So, I define a sphere or a quad that reacts to my mouse?

---------- Post added at 07:30 PM ---------- Previous post was at 07:25 PM ----------

You are going to want to read the Orbiter API Guide, found in the doc folder in the OrbiterSDK folder within your Orbiter installation.

It's going to involve coding....

Okay, thanks. Coding, well I've started learning. Modelling is my expertise-after 5 years you've GOT to be good at something :lol:

Anyway, thanks! :)
 

Urwumpe

Not funny anymore
Addon Developer
Donator
Joined
Feb 6, 2008
Messages
37,663
Reaction score
2,383
Points
203
Location
Wolfsburg
Preferred Pronouns
Sire
And the plural for vertex is vertices :)

Not everywhere, in Latin and German, you would be right, but most English dictionaries use vertexes.
 

Hurricane

Grinfeld Aerospace guy
Joined
Sep 16, 2011
Messages
211
Reaction score
0
Points
0
Not everywhere, in Latin and German, you would be right, but most English dictionaries use vertexes.

Okay. Now back to our topic:
is there a limit for the number of manipulators in a cockpit?
And do the switches, knobs and dials in already existing add-ons use manipulators?
 

Urwumpe

Not funny anymore
Addon Developer
Donator
Joined
Feb 6, 2008
Messages
37,663
Reaction score
2,383
Points
203
Location
Wolfsburg
Preferred Pronouns
Sire
is there a limit for the number of manipulators in a cockpit?

None that I know, but you don't need many. You can use the event callback for telling which coordinates of your sphere (radius vector) or point on the quad (inner 2D coordinates) had been clicked.

On SSU for example, we have a quad for every panel and tell the switches by the coordinates, instead of having a quad for every switch.

And do the switches, knobs and dials in already existing add-ons use manipulators?

Yes, if it has a VC or a 2D panel. 2D panels use a similar system like VCs.
 

Hurricane

Grinfeld Aerospace guy
Joined
Sep 16, 2011
Messages
211
Reaction score
0
Points
0
None that I know, but you don't need many. You can use the event callback for telling which coordinates of your sphere (radius vector) or point on the quad (inner 2D coordinates) had been clicked.

On SSU for example, we have a quad for every panel and tell the switches by the coordinates, instead of having a quad for every switch.



Yes, if it has a VC or a 2D panel. 2D panels use a similar system like VCs.

Event callback?

And if I understand correctly, in the SSU the panel is made of a single quad, and it registers mouse clicks according to where it was on the coordinates of the quad?
 

orb

New member
News Reporter
Joined
Oct 30, 2009
Messages
14,020
Reaction score
4
Points
0
You can see an example in OrbiterSDK/samples/DeltaGlider/DeltaGlider.cpp in DeltaGlider::clbkLoadVC for defining areas in VC, and DeltaGlider::clbkVCMouseEvent for handling mouse events for these areas.


And the plural for vertex is vertices :)
Actually, the spell checker in Firefox underlines vertices as incorrect for me and treats vertexes as correct, but I prefer using vertices. :p
 

Hurricane

Grinfeld Aerospace guy
Joined
Sep 16, 2011
Messages
211
Reaction score
0
Points
0
You can see an example in OrbiterSDK/samples/DeltaGlider/DeltaGlider.cpp in DeltaGlider::clbkLoadVC for defining areas in VC, and DeltaGlider::clbkVCMouseEvent for handling mouse events for these areas.

Okay, will do sir! :thumbup:

Actually, the spell checker in Firefox underlines vertices as incorrect for me and treats vertexes as correct, but I prefer using vertices. :p

Oh, god. :p

~Thanks everyone! :tiphat:

---------- Post added 01-28-12 at 01:40 PM ---------- Previous post was 01-27-12 at 07:54 PM ----------

If I understand correctly, in the SSU the panel is made of a single quad, and it registers mouse clicks according to where it was on the coordinates of the quad?

Can anyone supply an answer about that? :thumbup:
 

Urwumpe

Not funny anymore
Addon Developer
Donator
Joined
Feb 6, 2008
Messages
37,663
Reaction score
2,383
Points
203
Location
Wolfsburg
Preferred Pronouns
Sire
And if I understand correctly, in the SSU the panel is made of a single quad, and it registers mouse clicks according to where it was on the coordinates of the quad?

Again: Every panel (= flat surface with switches and blinkenlights) is a quad in SSUs VC. There is more than one. The rest is correct, just like I already described above.
 

Hurricane

Grinfeld Aerospace guy
Joined
Sep 16, 2011
Messages
211
Reaction score
0
Points
0
Again: Every panel (= flat surface with switches and blinkenlights) is a quad in SSUs VC. There is more than one. The rest is correct, just like I already described above.

That's what I meant, it was a miscommunication (;
Thanks, I will fiddle with it!
 
Top