Announce first iteration of NaviCube for FreeCAD
Forum rules
and Helpful information
and Helpful information
IMPORTANT: Please click here and read this first, before asking for help
Also, be nice to others! Read the FreeCAD code of conduct!
Also, be nice to others! Read the FreeCAD code of conduct!
Announce first iteration of NaviCube for FreeCAD
Hi,
I've just pushed my first attempt at creating a "Navigation Cube" for FreeCAD.
You can get it from my Github repo from the "navicube" branch:
https://github.com/nyholku/FreeCAD/tree/navicube
Here is comparison against master:
https://github.com/FreeCAD/FreeCAD/comp ... u:navicube
Lots of cleanup to do and there I things I could use help with ... or perhaps the whole approach is unpalatable.
All feedback welcome.
wbr Kusti
I've just pushed my first attempt at creating a "Navigation Cube" for FreeCAD.
You can get it from my Github repo from the "navicube" branch:
https://github.com/nyholku/FreeCAD/tree/navicube
Here is comparison against master:
https://github.com/FreeCAD/FreeCAD/comp ... u:navicube
Lots of cleanup to do and there I things I could use help with ... or perhaps the whole approach is unpalatable.
All feedback welcome.
wbr Kusti
Re: Announce first iteration of NaviCube for FreeCAD
What is NaviCube?
Alone you go faster. Together we go farther
Please mark thread [Solved]
Want to contribute back to FC? Checkout:
'good first issues' | Open TODOs and FIXMEs | How to Help FreeCAD | How to report Bugs
Please mark thread [Solved]
Want to contribute back to FC? Checkout:
'good first issues' | Open TODOs and FIXMEs | How to Help FreeCAD | How to report Bugs
Re: Announce first iteration of NaviCube for FreeCAD
super exited to see this! maybe some screenshot? can you also add the 12 views (FRONT_LEFT, LEFT_REAR, REAR_RIGHT,...) that are shown at the top of this two icon sets https://forum.freecadweb.org/viewtopic. ... 484#p84623 (i am not the best when reading code, so sorry if they are already implemented )nyholku wrote: I've just pushed my first attempt at creating a "Navigation Cube" for FreeCAD.
see the next post after the one linked in the above linkKunda1 wrote:What is NaviCube?
Last edited by saso on Sat Feb 18, 2017 8:17 pm, edited 1 time in total.
Re: Announce first iteration of NaviCube for FreeCAD
Wow, this looks nice
Need help? Feel free to ask, but please read the guidelines first
Re: Announce first iteration of NaviCube for FreeCAD
Hello,
I tested your work, compiles fine for me on ubuntu. I really like the cube, very good work! Code wise I think your implementation is fine. I have no clue about openGL code, so can't comment on that, but the general idea to render the cube above the scene is just fine! Do you want some testing and bug reporting or is this too soon? If you have any questions on technical point of view just ask!
here a few observations:
1. The cube is always in perspective projection, even if the user has orthographic on in the main view. that is a bit confusing.
2. The animations are a bit laggy. I noticed that you don't use the python commands like the view toolbar. Maybe it would be wise to do that, as this would fit the freecad philosophy well (as it is recordable) and would give you all the implementation for free.
3. I find the buttons a bit hard to hit, the sensitive area is too small for me. I don't know if that is just for me cause I have a high resolution screen or if they are too small in general. I think it would help to make the sensitive area a bit larger than the actual button in any case, IMHO this would increase the user experiance as the fast click would succeed more often
4. Size of the cube should somehow be adjustable, as I could imagine that for some people the control is too small. (also resolution dependend the size may need to change)
5. The text is not translated
6. The cube works nice with a white background, but when using a dark one it gets somewhat confusing. Due to the shining-through stripes in the cube getting very dominant for dark background I sometimes lost the orientation in the cube and did not recognize anymore its square form.
7. the corner areas are a bit ahrd to see. maybe some more dominant borders on the sensitive areas could improve the seperation between the individual areas?
8. The axis labels like x,z are rendered below the button. imho it should be the other way around, as right now the labels can be hidden and that is a bit annoying.
9. The axiometric view of the view menu is different than your cube corner buttons, how comes that?
thanks for your work!
I tested your work, compiles fine for me on ubuntu. I really like the cube, very good work! Code wise I think your implementation is fine. I have no clue about openGL code, so can't comment on that, but the general idea to render the cube above the scene is just fine! Do you want some testing and bug reporting or is this too soon? If you have any questions on technical point of view just ask!
here a few observations:
1. The cube is always in perspective projection, even if the user has orthographic on in the main view. that is a bit confusing.
2. The animations are a bit laggy. I noticed that you don't use the python commands like the view toolbar. Maybe it would be wise to do that, as this would fit the freecad philosophy well (as it is recordable) and would give you all the implementation for free.
3. I find the buttons a bit hard to hit, the sensitive area is too small for me. I don't know if that is just for me cause I have a high resolution screen or if they are too small in general. I think it would help to make the sensitive area a bit larger than the actual button in any case, IMHO this would increase the user experiance as the fast click would succeed more often
4. Size of the cube should somehow be adjustable, as I could imagine that for some people the control is too small. (also resolution dependend the size may need to change)
5. The text is not translated
6. The cube works nice with a white background, but when using a dark one it gets somewhat confusing. Due to the shining-through stripes in the cube getting very dominant for dark background I sometimes lost the orientation in the cube and did not recognize anymore its square form.
7. the corner areas are a bit ahrd to see. maybe some more dominant borders on the sensitive areas could improve the seperation between the individual areas?
8. The axis labels like x,z are rendered below the button. imho it should be the other way around, as right now the labels can be hidden and that is a bit annoying.
9. The axiometric view of the view menu is different than your cube corner buttons, how comes that?
thanks for your work!
Re: Announce first iteration of NaviCube for FreeCAD
Looking good.
Re: Announce first iteration of NaviCube for FreeCAD
Hi Ickby,
thanks for the thoughtful comments.
As a general note this is just the beginning of making this into a usable feature...felt I needed to show it before I spend too much time on it.
Agree with your comments almost 100% but now it is past midnight here so I will have to leave commenting until tomorrow.
good night, Kusti
thanks for the thoughtful comments.
As a general note this is just the beginning of making this into a usable feature...felt I needed to show it before I spend too much time on it.
Agree with your comments almost 100% but now it is past midnight here so I will have to leave commenting until tomorrow.
good night, Kusti
- DeepSOIC
- Veteran
- Posts: 7896
- Joined: Fri Aug 29, 2014 12:45 am
- Location: used to be Saint-Petersburg, Russia
Re: Announce first iteration of NaviCube for FreeCAD
When I visited OnShape, and saw the cube, I immediately liked it very much. Thank you for bringing it into FreeCAD.
Re: Announce first iteration of NaviCube for FreeCAD
Admitted and originally I had not plan to have any perspective but I1. The cube is always in perspective projection, even if the user
has orthographic on in the main view. that is a bit confusing.
kind of fell for it and like it even in ortho mode. Easy to change of
course and it could be an option.
I have no idea why the animation is what it is. I took my cue from the2. The animations are a bit laggy. I noticed that you don't use
the python commands like the view toolbar. Maybe it would be wise
to do that, as this would fit the freecad philosophy well (as it is recordable)
and would give you all the implementation for free.
standard left/right etc view buttons work so I was hoping that would do it correctly.
As to why I did not use the python commands was that I could not find
python commands for the "left_rear","top_right_front" etc commands
so I thought that for the shake of consistency in the code and wanting
to keep my intrusion to the whole code base minimal I chose to do it
all by my self.
If the python commands are available I would like to change this
of course.
Agreed. However this is mostly due to the way the hit testing is implemented3. I find the buttons a bit hard to hit, the sensitive area is too small for me.
I don't know if that is just for me cause I have a high resolution screen or if they
are too small in general. I think it would help to make the sensitive area
a bit larger than the actual button in any case, IMHO this would increase the user
experiance as the fast click would succeed more often
and a small detail there that I've not been able to fix.
Hit testing is done by drawing the cube face to an offscreen buffer, each
face with different color and then reading back the pixel under the cursor.
The problem is that the off screen drawing is done with antialiasing on
so the edges of each face are not of the correct color and thus I need
to reject them which makes them smaller especially the corners.
I some one could tell how to turn off antialiasing in OpenGL so that it
actually happens (or actually not!) I would be grateful.
If you uncomment this line (about line 930) in the code:
Code: Select all
//image.save(QLatin1String("pickimage.png"));
used to draw the cube for picking are very small numerical values in
red channel so you will have to turn on the contrast a lot to see them.
Agreed. I will add something so that the size can be changed.4. Size of the cube should somehow be adjustable, as I could
imagine that for some people the control is too small.
(also resolution dependend the size may need to change)
Agreed, they should be.5. The text is not translated
Incidentally I went with 'Rear' instead of 'Back'
for the sake of consistency though I would have preferred 'Back'.
I tried to find some support for 'back' but it seems that both words are
more or less used interchangeably. My daughter who is studying English
and knows more about it than most native speakers could not find
any real difference and just said that 'Rear' is more posh way of saying
it and 'back' is what people would use when speaking cause it is
easier to pronounce.
Agreed it works best on ligth or actually white background (which I6. The cube works nice with a white background, but when using a
dark one it gets somewhat confusing. Due to the shining-through
stripes in the cube getting very dominant for dark background I
sometimes lost the orientation in the cube and did not recognize
anymore its square form.
prefer. I'm not sure the transparency effect can be made to work on
dark background so maybe that should be optional (took me moths
in Onshape to even notice that effect so I don't think it is essential).
They are a bit hard to see and I've experimented with that but never7. the corner areas are a bit ahrd to see. maybe some more dominant
borders on the sensitive areas could improve the seperation between
the individual areas?
found a way to make them better. In Onshape they somehow are
a bit easier to see IMO but I can't put my finger on it. OTH again
it took me months to notice them in Onshape and I never used
them so...
Agreed, this needs fixing and some other tweaking too.8. The axis labels like x,z are rendered below the button.
imho it should be the other way around, as right now the labels can
be hidden and that is a bit annoying.
So you mean it should look more like the navigation cube itself?9. The axiometric view of the view menu is different than your cube
corner buttons, how comes that?
Well, why not, but then I think I would need to make it with SVG
which would mean I will have to find an SVG editor and learn to
use it, this icon was hacked together with OpenGL in a few minutes.
We can change this but I'm pretty sure that for me it will take
some hours to produce an SVG icon plus a matching 'mask' icon
for the offscreen pick thing and add them as resources. So I was
thinking that won't put too much effort into details before
I know this has a chance to make it to the FreeCAD master
branch.
Also maybe if there is an icon overhaul in the process it would
make sense to have this icon designed by some proper designer
to match the style.