CamBam
News:
 
*
Welcome, Guest. Please login or register.
Did you miss your activation email?
June 16, 2019, 21:55:46 pm


Login with username, password and session length


Pages: [1]
  Print  
Author Topic: Get the Z position of a 3D surface under the mouse pointer  (Read 1236 times)
Mark81
Storm Trooper
***
Offline Offline

Posts: 236


View Profile
« on: October 06, 2018, 07:22:57 am »

Is there, or it's even possible to write, a plugin that shows the Z position of the 3D surface as the mouse moves? In the status bar there are the X, Y mouse coordinates, I would like to know how deep is the surface at that point.
The best would be a real-time update of this value, without have to "ask" for it (like get object extremas for example).
Logged
EddyCurrent
CNC Jedi
*****
Offline Offline

Posts: 3951



View Profile
« Reply #1 on: October 06, 2018, 17:50:54 pm »

There is now  Cheesy
http://www.cambam.co.uk/forum/index.php?topic=7631.msg61246#msg61246
Logged

Made in England
Mark81
Storm Trooper
***
Offline Offline

Posts: 236


View Profile
« Reply #2 on: October 06, 2018, 19:37:22 pm »

Wow, great! But I'm having some weird behavior with version 1.0.
When I press 'z' nothing happens, but if I press it several times then a zpos appears. Other few 'z' press and another measurement is made, but after a couple of messages it "cycles" among them. I mean it doesn't append another message, but it just highlights a previous row.

Please let me know if I can try something specific so my feedback might be more useful.
Logged
EddyCurrent
CNC Jedi
*****
Offline Offline

Posts: 3951



View Profile
« Reply #3 on: October 06, 2018, 20:06:22 pm »

Keep z pressed all the time, do not keep releasing it, and move the mouse over a surface.
Logged

Made in England
Mark81
Storm Trooper
***
Offline Offline

Posts: 236


View Profile
« Reply #4 on: October 07, 2018, 09:58:49 am »

Ok, now I get consistent readings, but the last problem is it takes a lot of time to make a measurement (about 1 per second) hence when I release the key, it continues to show messages for a lot of time! I'm afraid it's because it tries to make a measurement for each "key press/repeat" event and appends them all in a sort of queue. When I move the mouse it takes 10-15 seconds before it returns the actual value under the current position!

I think it would be better if the plugin starts a new measurement only when the previous one has completed, using the updated mouse coordinates read at that moment.

Logged
EddyCurrent
CNC Jedi
*****
Offline Offline

Posts: 3951



View Profile
« Reply #5 on: October 07, 2018, 12:17:17 pm »

You should have Tools->Options->Display Mode = OpenGL otherwise it sounds like you may have a slow computer.
In any case the values are updated only when the mouse is moved, so if you move the mouse slowly, that should solve your problem.
Logged

Made in England
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2015, Simple Machines

Valid XHTML 1.0! Valid CSS! Dilber MC Theme by HarzeM
Page created in 0.111 seconds with 19 queries.

Copyright © 2018 HexRay Ltd. | Sitemap