Gamestudio Links
Zorro Links
Newest Posts
loading historical data 1st time
by AndrewAMD. 04/14/23 12:54
Trade at bar open
by juanex. 04/13/23 19:43
Bug in Highpass2 filter
by rki. 04/13/23 09:54
Adding Limit Orders For IB
by scatters. 04/11/23 16:16
FisherN
by rki. 04/11/23 08:38
AUM Magazine
Latest Screens
SHADOW (2014)
DEAD TASTE
Tactics of World War I
Hecknex World
Who's Online Now
3 registered members (AndrewAMD, juanex, Grant), 1,018 guests, and 8 spiders.
Key: Admin, Global Mod, Mod
Newest Members
rki, FranzIII, indonesiae, The_Judge, storrealba
18919 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
mouse_pos functions not accurate in windowed mode #325428
05/26/10 15:19
05/26/10 15:19
Joined: Oct 2004
Posts: 4,134
Netherlands
Joozey Offline OP
Expert
Joozey  Offline OP
Expert

Joined: Oct 2004
Posts: 4,134
Netherlands
Because they don't calculate from the window position but from 0,0 real screen position. At least this is what my tests show. mouse_dir3d, mouse_pos3d, they all depend on mouse_pos which is not added to the window_pos. Pardon me if I am mistaken.


Click and join the 3dgs irc community!
Room: #3dgs
Re: mouse_pos functions not accurate in windowed mode [Re: Joozey] #325464
05/26/10 19:06
05/26/10 19:06
Joined: Nov 2007
Posts: 1,143
United Kingdom
DJBMASTER Offline
Serious User
DJBMASTER  Offline
Serious User

Joined: Nov 2007
Posts: 1,143
United Kingdom
Isn't this the difference between mouse_pos and mouse_cursor? One is absolute coordinates (screen) and the other being relative coordinates (engine window)?

After 4 years of working with the engine I still get confused on what the actual difference between them is?

Re: mouse_pos functions not accurate in windowed mode [Re: DJBMASTER] #325466
05/26/10 19:45
05/26/10 19:45
Joined: Oct 2004
Posts: 4,134
Netherlands
Joozey Offline OP
Expert
Joozey  Offline OP
Expert

Joined: Oct 2004
Posts: 4,134
Netherlands
If that is so... how do I replace mouse_dir3d then?


Click and join the 3dgs irc community!
Room: #3dgs
Re: mouse_pos functions not accurate in windowed mode [Re: Joozey] #325568
05/27/10 09:35
05/27/10 09:35
Joined: Jul 2000
Posts: 27,935
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,935
Frankfurt
All mouse coordinates are always relative to the upper left corner of the client area of the engine window, ranging from 0 to screen_size.x/y. This is no "inaccuracy".

http://manual.3dgamestudio.net/ampointer.htm

Re: mouse_pos functions not accurate in windowed mode [Re: jcl] #328272
06/11/10 12:52
06/11/10 12:52
Joined: Oct 2004
Posts: 4,134
Netherlands
Joozey Offline OP
Expert
Joozey  Offline OP
Expert

Joined: Oct 2004
Posts: 4,134
Netherlands
Found my problem; was not using USE_POLYGON in the trace, resulted in strange 3D positions with even more strange conclusions.


Click and join the 3dgs irc community!
Room: #3dgs

Moderated by  HeelX, Lukas, rayp, Rei_Ayanami, Superku, Tobias, TWO, VeT 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1