11 Replies Latest reply on Aug 9, 2018 9:48 AM by Tony Tan

    Middle-Click with Drag to Rotate Problems

    Jim Sculley

      For as long as I can remember, SW would occasionally behave badly when rotating models with the standard middle-click drag operation.  The entire model would disappear completely, as though the rotation center was way off in space somewhere.

       

      Currently, I'm using SW2016 SP2, and it happened a few times today on one particular assembly model, so I decided to investigate.  The bad behavior appears to be tied in with the function that allows you to rotate a model or assembly around a particular edge or axis.  Under normal conditions, if you middle click and release an edge or axis and then move your mouse away from the selected item, the rotate icon changes into the rotate about axis icon.  You can then middle drag to rotate the model.  If you middle click on an edge or axis and don't release the mouse button, the icon should remain as the rotate icon and things rotate in the normal way.  However, sometimes when you middle click and immediately drag (no release of the button), the icon changes to Rotate about axis and that is when things can go haywire.  I say 'can' because I see three different behaviors:

       

      • sometimes it rotates as you would expect if you had the normal rotate icon
      • sometimes it rotates about some center or axis near the model but not actually part of the model
      • sometimes the model view flies off into space

       

      Zooming in or out can change the likelihood of the bad behavior.

       

      The assembly model I'm using has a simple sketch visible in a subassembly which is two levels deep.  I can repeatably (but not 100%) make the problem occur when middle clicking in the vicinity of a line in the sketch.  I can't replicate the problem if I open the immediate parent of the subassembly with the sketch, or the subassembly itself.

       

      My guess is that there are two parts of the program getting conflicting information about where the mouse is, and what has (or hasn't) been selected.  These two incongruent bits of information are then combined into 'Rotate the model around that point at infinity'.

        • Re: Middle-Click with Drag to Rotate Problems
          Jim Wilkinson

          Reposting from another thread since it came up today...just so the answer is here in case anyone else finds this in the future

           

          Here is how middle mouse rotate works:

          If the entire model is within view, it rotates about the centroid of the model. This works very well if the model is centered in the screen. It also works well if the model is smaller in the view than "fit" and is off center; try it by doing a zoom to fit and then zooming out/panning so the model is on the screen but in one corner and you will see it rotates about its centroid. Imagine what that rotation would be like if we rotated about the center of the screen (which is what a lot of systems do) instead of the centroid of the model under that condition; the part would be flying around the view. Now, if the entire part is not on the screen (i.e. you're zoomed in), you will get the most predictable results if you push the middle mouse button over the geometry to start the rotation since when you push the middle mouse button, we project a point onto the face and rotate about that face (we draw the point in magenta and highlight the edges of the entity that it is project on). If we didn't do that and used the centroid of the part, or center of the screen, again the model would always fly all over the place/off the screen. That is how it used to work about 10 releases ago or so until we came up with this approach. Lastly, if you are zoomed in and you use the middle mouse button in empty space, then we have an algorithm to try to find the geometry and project a point onto it to rotate about (again, it shows the point in magenta with the edges of the geometry on which we projected in magenta). This is probably the case you are talking about where the model flies off the screen; depending on the position and orientation of the model and how close you are to the model when you push the mouse button, the point we pick may not give good results. So, I think you will find that when zoomed in, if you simply push the middle mouse button on top of geometry instead of in blank space to rotate, you should get predictable results every single time.

           

          Although I have not heard of specific cases where it doesn't work well with visible sketches, that isn't to say there might not be a problem relating to visible sketches so if you do find something repeatable, certainly report it.

           

          Thanks,

          Jim

            • Re: Middle-Click with Drag to Rotate Problems
              Richard K.

              Thanks, Jim Wilkinson, for the very thorough description.  You mentioned:

              Although I have not heard of specific cases where it doesn't work well with visible sketches, that isn't to say there might not be a problem relating to visible sketches so if you do find something repeatable, certainly report it.

              I run into this problem all the time.  I tend to make heavy use of skeleton sketches - i.e. when creating bosses / cuts I always try to reference existing sketch elements (or make new ones) rather than geometry like edges, vertexes, etc (as the latter break my rebuilds due to their ephemeral nature in the face of changes).  That means I like to have a lot of sketches visible in my model.

               

              As soon as I have a handful of sketches visible in my scene, the middle-click-drag rotate feature starts picking up on those and trying to rotate around them - inevitably sending my model flying off the screen.  It's a real nuisance (and felt buggy until I figured out what was going on).

               

              Is there a way I can prevent the feature from using sketch elements as the axis for rotation?  Or always have it use the "empty space" approach (which despite your apprehensions seems to work really well - I rely on it all the time without even realizing it).

                • Re: Middle-Click with Drag to Rotate Problems
                  Jim Wilkinson

                  Richard K. wrote:

                   

                  As soon as I have a handful of sketches visible in my scene, the middle-click-drag rotate feature starts picking up on those and trying to rotate around them - inevitably sending my model flying off the screen. It's a real nuisance (and felt buggy until I figured out what was going on).

                   

                  Is there a way I can prevent the feature from using sketch elements as the axis for rotation? Or always have it use the "empty space" approach (which despite your apprehensions seems to work really well - I rely on it all the time without even realizing it).

                  Hi Richard,

                   

                  There isn't currently a way to change the behavior relating to sketches. However, in my testing, I find the opposite problem as you describe; the rotate only picks up the solid model, not the sketches. So if the part is zoomed so the solid is off the screen and only sketch elements are on the screen, it will rotate around some part of the solid off the screen and then the sketches fly off. Is this what you are seeing? Perhaps you can quickly make up a sample model similar to what you are seeing and post it and indicated where you are picking to rotate. Or even better, post the model and a video of the problem you are seeing so I can better understand it.

                   

                  Thanks,
                  Jim

                    • Re: Middle-Click with Drag to Rotate Problems
                      Richard K.

                      Thanks for the quick response Jim Wilkinson.

                       

                      It happens when the plane of the offending sketch is perpendicular (or just about) to the viewport, and isn't entirely contained within it.  Here's what I mean:

                       

                      yVTJUV5.gif

                       

                      First I rotate around an entity in Sketch2 and it works fine.  But you can see I leave the rotation such that we're looking just about edge-on to Sketch2. I grab the same entity but now when I try to rotate around it, the model jumps off the screen.  Finally I zoom out and repeat the last test, which now works (since Sketch2 is fully contained in the view).

                       

                      At least, that's the behavior as far as I can figure it.  Tested under Solidworks 2017 x64 SP3. File is attached.

                       

                      EDIT: In a different part file I was able to recreate the behavior even when the sketch was contained in the viewport and was at a slightly less perpendicular angle to it.

                        • Re: Middle-Click with Drag to Rotate Problems
                          Jim Wilkinson

                          Richard K. wrote:

                           

                          Thanks for the quick response Jim Wilkinson.

                           

                          It happens when the plane of the offending sketch is perpendicular (or just about) to the viewport, and isn't entirely contained within it. Here's what I mean:

                           

                          yVTJUV5.gif

                           

                          First I rotate around an entity in Sketch2 and it works fine. But you can see I leave the rotation such that we're looking just about edge-on to Sketch2. I grab the same entity but now when I try to rotate around it, the model jumps off the screen. Finally I zoom out and repeat the last test, which now works (since Sketch2 is fully contained in the view).

                           

                          At least, that's the behavior as far as I can figure it. Tested under Solidworks 2017 x64 SP3. File is attached.

                           

                          EDIT: In a different part file I was able to recreate the behavior even when the sketch was contained in the viewport and was at a slightly less perpendicular angle to it.

                          Hi Richard,

                           

                          I was now able to reproduce this with your model and animated gif and it does appear to be related to a visible sketch, the proximity to the mouse relative to the sketch, and perhaps the orientation of the sketch.  It sounds like the exact behavior Jim Sculley reported too. A workaround would be to not press your mouse over a sketch entity (or very close to one) when using the middle mouse rotate since it won't select the sketch entity anyway; it is attempting to project a point on the face "behind" the sketch entity to get the center of rotation.

                           

                          I searched the SPR database and do not find any reports of it. So, Richard, can you report the problem to your reseller and get an SPR# and then report back with the SPR# so other users encountering this problem can also attach to the SPR either through the Knowledge Base once it gets posted there, or by contacting their reseller and asking to be attached to the SPR. Your reseller should be able to reproduce it with your model and looking at the animated gif (you could even direct them to this thread to see the animated gif/discussion).

                           

                          Thanks,
                          Jim

                            • Re: Middle-Click with Drag to Rotate Problems
                              Richard K.

                              Hi Jim,

                               

                              I'm afraid I've sunk as much time into fixing your bug as I am able to spare.  If you or anyone else wants to take this and run with it from here, I'd be delighted.

                               

                              -Richard

                               

                              <rant>

                              I mean, come on... I practically gift wrapped this one for you guys!  I'm a little disappointed to hear the old report it to your VAR line being trotted out.  Between the awesome video demonstration and minimal SLDPRT file reproducing the issue, I'm not sure there's ever been a bug report so cleanly packaged and ready for a developer to gain traction on.  I did everything you asked.  You've confirmed you can reproduce the issue.  Why do you need me to dedicate more of my valuable time to it?  When will Dassault stop treating your users like free QA lackeys?  I'm convinced other folks must have run into this issue before, and the only reason there's no SPR is user fatigue stemming from a feedback process that simply has too much friction.  Ok, I know this sounds fussy, but I had to let off some steam on the topic.

                              </rant>

                                • Re: Middle-Click with Drag to Rotate Problems
                                  Jim Wilkinson

                                  Richard K. wrote:

                                   

                                  Hi Jim,

                                   

                                  I'm afraid I've sunk as much time into fixing your bug as I am able to spare. If you or anyone else wants to take this and run with it from here, I'd be delighted.

                                   

                                  -Richard

                                   

                                  <rant>

                                  I mean, come on... I practically gift wrapped this one for you guys! I'm a little disappointed to hear the old report it to your VAR line being trotted out. Between the awesome video demonstration and minimal SLDPRT file reproducing the issue, I'm not sure there's ever been a bug report so cleanly packaged and ready for a developer to gain traction on. I did everything you asked. You've confirmed you can reproduce the issue. Why do you need me to dedicate more of my valuable time to it? When will Dassault stop treating your users like free QA lackeys? I'm convinced other folks must have run into this issue before, and the only reason there's no SPR is user fatigue stemming from a feedback process that simply has too much friction. Ok, I know this sounds fussy, but I had to let off some steam on the topic.

                                  </rant>

                                  Hi Richard,

                                   

                                  I understand what you are saying but our forums are not designed as a method for technical support; that is part of what our reseller network is for and what you are paying them for with your subscription. I am sorry if you thought that the forum was for support and that I could close the full loop on it; I cannot as I don't have access to customer records, logging service requests, logging SPRs against them, etc. I interject in the forum when I think I can add clarification to forum threads that will help users understand a functionality and advise if it looks to be a problem that should be reported, but I'm afraid I can't take it further than that. I would hope if you took one minute to send a simple e-mail to your reseller pointing them to this thread and problem reported there, they should be able to create a service request on your behalf, log the SPR, etc. and then you'll get notification when it is fixed.

                                   

                                  Thanks,

                                  Jim

                                    • Re: Middle-Click with Drag to Rotate Problems
                                      Richard K.

                                      Jim - Thanks for correcting my expectations.  Despite my frustration I want to be clear I didn't mean anything against you personally, and I'm grateful for the work you do patrolling the forums and helping out where you can.  Maybe one day your bosses will see fit to acknowledge the forums as a potentially valuable source of customer feedback and connect the last mile.

                                       

                                      In the meantime, if anyone else reading this wants to run with it please feel free to grab it and submit the SPR.

                          • Re: Middle-Click with Drag to Rotate Problems
                            Dan Pihlaja

                            I have found that, if my mouse pointer happened to be over a shown sketch, then when I use the middle mouse button to rotate, the rotation center is about 100 miles away.

                             

                            And yes, I can replicate this at will.  SW 2017 SP5

                          • Re: Middle-Click with Drag to Rotate Problems
                            Andrew Miller

                            Lol this is still a problem? I'm a few years behind in my license and I can't believe this bug is hanging around. Does Daussault answer about 2 support tickets per year?

                             

                            I sure won't miss Solidworks when it disappears forever.

                            • Re: Middle-Click with Drag to Rotate Problems
                              Tony Tan

                              I have exactly the same problem with my 3 cheap Logitech mouses.  The middle "mouse click" to rotate in Solidworks sometime work or not work at all.  Searching the internet for answer with no success, so I decide to take the top cover off one of my mouse to see what is going on inside. With the top cover off I press the middle button in Solidworks and it works, the problem for me is that my mouse middle scroll/click button spring is abit worn and cannot fully reach the button.  I just but a small double side foam tape on top of the button, now my middle mouse click button rotate proper in Solidworks.

                               

                              In Windows, your mouse may work fine because middle mouse "click" is not use at default setting.