(Discussion) Why does OSX lag in UI animation when compared to Windows?

Discussion in 'OS X Yosemite (10.10)' started by narutoksa, Feb 5, 2015.

  1. narutoksa macrumors newbie

    Joined:
    Sep 12, 2014
    #1
    My first Mac experience was with the white macbook running 10.6. It was a really great experience. Everything was smooth and fluid like how IOS 6 was on iPhones and iPads. There were no sever frame drops when scrolling or browsing (I'm looking at you safari). Everything was like I mentioned above smooth and fluid. Then, everything went down hill with the release of 10.7, then 10.8, 10.9 and finally the worst of all 10.10. Why is it that simple animations like resizing a window or scrolling in the application folder lag :mad:? Why isn't the same hardware lag or drop in frames when running Windows 7 (I tested this personally):confused:? Is Apple aware of this issue? Do they not care? I thought Apple was all about the experience. Just to clarify, I went countless times to the nearby Apple store to see if the lag is present on other Macs. I tested the Mac pro, 15' and 13' Macbook Pro, 27' Imac and the Air. All lag doing the same tasks mentioned above, some less than others. By the way, this lag whatever it is a bug or an oversight by Apple is present in OS X 10.7 and above, so it is not a 10.10 issue. I hope we can have a very productive discussion away from fanboyism.
     
  2. MikhailT macrumors 601

    Joined:
    Nov 12, 2007
    #2
    They are fully aware of this. I've filed radars on this before and they said it is intentional that Yosemite is using up more resources for its new UI (the transparency itself is the biggest resource eater). They also said that they'll improve it over time. I haven't seen much improvements in the 10.10.x updates but reducing the transparency has improved a lot of the performance for me.

    Lion was worse and it got much better in Mountain Lion, Mavericks before sucking again in Yosemite, this is true especially if you're using a retina Mac.

    I really hope they improve this in 10.11 or it's back to Windows for me.
     
  3. narutoksa, Feb 5, 2015
    Last edited: Feb 5, 2015

    narutoksa thread starter macrumors newbie

    Joined:
    Sep 12, 2014
    #3
    Great, at least they're aware of the problem, but I'm still not optimistic they will fix it anytime soon, especially if they insist on their yearly upgrade cycle. 10.10 is the laggiest so far, but like I said in my original post, the lag was and still present on all OS X versions released after 10.6, so it is not unique to 10.10. Plus, Windows 7 with Aero enabled does not drop a frame, so I think it's Apple's inefficient implementation of the transparency effect that is causing the slowdown and not necessarily the transparency effect itself. Thanks for dropping by and sharing your thoughts:)
     
  4. damezumari macrumors member

    Joined:
    Dec 6, 2014
    #4
    To be frank, I started using OS X around 10.3 time (2001?) and it has been most of the time much less smooth than Windows at the time (XP then). Things improved somewhat up to 10.7, but after that, it has been just downhill.

    Sad thing is, right now my 'new' Mac Pro (even with reduced transparency) looks about as smooth as some pre-2000 Windows 2000 desktop does. Animations? I have heard of them. Haven't seen many. (2x 4k display does not help, with crappy GPU. Sorry, workstation GPU, just one of them being used.. *cough*)

    Retina Macbook Pro from 2012? Same story with 10.10. 10.9 was somewhat better, but again, I see animations mostly in VMware Fusion Windows instances, not really in OS X :p
     
  5. leman macrumors 604

    Joined:
    Oct 14, 2008
    #5
    Thats a very interesting discussion! It is true that UI drawing in Windows is generally quicker than UI drawing in OS X. I find it curious that you mention that the performance in OS X has decreased since 10.7, as it should actually have increased: this is the time where Apple started actually porting its apps to Core Animation which relies on heavy caching of images to speed up the drawing and enable new advanced effects.

    Overall, I have been programming for Windows and Linux for at least a decade, and from my experience, I can say that the programming and drawing model in OS X is just much more advanced and involved. Especially before the advent of .NET, UI in Windows was just extremely primitive. Especially things like text layout. In comparison, OS X drawing APIs take much more care of details, like text alignment and UI element styling, which is inherently also slower. Same thing goes for animations. Believe it or not, but complex animations are everywhere in OS X. They are just so subtle that it is almost not noticeable — but they result in a higher perceived quality of the interaction. Of course, it is an additional performance hit. One good example of all this is Mission Control: it shows all changes in all windows in real-time. This means that the OS has to potential redraw all windows that are changed. And if you have some applications that are redrawing slowly or too frequently, Mission Control would lag. Of course, it is possible to optimise this — drop the live update of windows that fail to finish drawing within a predetermined time interval.

    Of course, the above does not mean that it is impossible to write OS X software that can draw quickly. It is in fact very possible, but one needs to take extra care of that. The truth is, on Windows it does not really matter. As you just do dumb, primitive drawing most of the time, you can do a lot of mistakes in your code before the performance hit becomes visible. But as drawing is more expensive on OS X, you should be aware of what you are doing and optimise your code. Much of OS X lag comes from sub optimally written applications. I once had to develop a cross-platform application that was using a lot of text labels. It was extremely slow on OS X. After some digging I found out that the method I was using to draw those labels (NSString's drawAtPoint:withAttributes:) is meant as a high-level convenience utility AND not recommended for heavy usage. I have rewritten the code by directly using the OS X text layout engine and immediately received a dramatic speedup.

    So bottomline: OS X drawing is often more expensive and the developer needs to take care that it used efficiently. This is especially true for retina displays. Unfortunately, even Apple's own apps suffer from heavy efficiency issues...
     
  6. narutoksa thread starter macrumors newbie

    Joined:
    Sep 12, 2014
    #6
    lol you seem more frustrated than I am. I know I would be if I bought a $3000 computer and it still lags doing simple stuff. Thanks for sharing your thoughts and contributing to this discussion.

    I am fine with third party apps lagging. I am even fine with first party apps lagging like iphoto when you scroll through your pictures, but what I am not fine with is system apps lagging when they are not doing any complex animations like scrolling in finder. It is literally just a white background with a bunch of icons on it. What is so complex about that? And let us not forget the infamous "about this mac" tap switching. All of this does not make sense to me. I have seen more complex animations on Windows and they don't drop a frame. I even tried Windows 10 technical preview, which like the name suggests is still in development. It doesn't lag when I switch desktops or use their mission control replica. What puzzled me is why simple animations (I am not talking about complex animations) like resizing a windows or scrolling through a folder with nothing but icons in it lags in OS X and not on Windows (same hardware)? The funny thing is scrolling through the Verge with all of its complexity in Safari lags less than scrolling through a bunch of icons on a white background in Finder:confused:. Thanks for sharing your thoughts and contributing to this discussion.
     
  7. leman macrumors 604

    Joined:
    Oct 14, 2008
    #7
    Oh, but its quite complex. When you are quickly scrolling in Finder, it has to query the files and get their attributes (this is usually very quick), run a selection of plugins on them to determine the content type (this can be much slower) and generate icons for them. It renders individual icons that are based on the file content for images, movies, text files, PDF documents, office documents etc. That is a lot of work and Finder attempts to pre-load the yet invisible data, but there are limitations. Note how the scrolling is smooth when you do it slowly, but starts jerking when you scroll very fast — this is because you get to the data which has not yet been loaded and processed. It is actually amazing that Finder is fast as it is given how much stuff it has to do (e.g. when I scroll though my academic paper collection I am actually asking it to load, render and rescale several hundreds of PDF files). Again, this is something that can be optimised (and I believe Windows does something like this) — one needs to display placeholders instead of individual icons until the data can be loaded and have another look at the code to check whether unnecessary work is being performed (e.g. I have a suspicion that Finder does too much work in the list mode).

    To be fair, Windows Explorer is also not 100% smooth when scrolling folders full of images and videos. Also, Windows Explorer does much less work, as it does not render individual icons for text files and PDF documents.

    About this Mac is indeed weird, and I believe that the animation mostly appears laggy because of an unfortunate choice of transition effect. That said, it is very smooth now on my rMBP with 10.10.3. The Preferences is a mother story, but here the lag comes from two sources. First, they load each panel separately every time you click on a icon (and this can be quite slow). Second, they actually load the UI and start displaying it before it has been populated with data. So the panel starts appearing and then you get awkward jumps and quirks (e.g. very visible in the General panel). This is just lack of quality control on Apple's side.
     
  8. Eithanius macrumors 65816

    Joined:
    Nov 19, 2005
    #8
    If that is the case, why did Finder get progressively slower from Snow Leopard to Yosemite...? Mavericks and Yosemite seemed to suffered the worst... For example, long list of items on List mode where small icon previews just ends where the Finder window shows, beyond that when you scroll down, only the default icon relevant to the file attributes get shown, not the supposed content.

    And since some of these items are not displaying anything at all, scrolling on List mode is still slow...

    Snow Leopard has no such problems...

    Snapshot below taken from Mavericks...
     

    Attached Files:

  9. leman macrumors 604

    Joined:
    Oct 14, 2008
    #9
    I can't confirm or deny what you say because our Snow Leopard machine does not have an SSD — the Finder there is definitively much slower than my Yosemite MBP, but the difference is most likely the SSD vs HDD. If there is indeed a performance regression in Finder, I have no clue why. Must be a bug that was introduced into Finder at some point.

    I am not sure that I understand what you are saying. Based on your screenshot I guess files on the bottom of the list don't get individual icons? Can't see I have ever witnessed this in Yosemite. Must be a bug in Mavericks.
     
  10. Eithanius macrumors 65816

    Joined:
    Nov 19, 2005
    #10
    Interesting no...? :D

    Just taken from Yosemite...
     

    Attached Files:

  11. Eithanius macrumors 65816

    Joined:
    Nov 19, 2005
    #11
    So if the bug exist on both Mavericks and Yosemite, and whatever that was not displayed first when the Finder windows are opened loses its icon preview (meaning not drawing anything in the first place), why does Finder still doesn't scroll smoothly...?
     
  12. narutoksa thread starter macrumors newbie

    Joined:
    Sep 12, 2014
    #12

    I see, what you're saying does make sense. However, it doesn't explain why when you create a new folder and put 2 files in it, Finder still lags when you scroll. Also, we can all agree that a macbook pro is faster than an iPhone 6, right? Then why doesn't IOS lag when you scroll through the setting app? It has pretty much all the animation you find in Finder when scrolling and it is basically a white background with a bunch of icons on it just like Finder. Why? I put an ssd on my white macbook running 10.6 back in the day and I can still remember like it was yesterday how smooth scrolling is in Finder.
    I appreciate your input on the matter and I think your explanation is right on the spot, but still there are a few things that it didn't explain.

    ----------

    Indeed, very interesting. The weird thing is the same animations and effects can be found on ios, yet ios doesn't lag, even though it's running on an inferior hardware.
     
  13. leman macrumors 604

    Joined:
    Oct 14, 2008
    #13
    No idea. But as I speculated earlier, it might be that the Finder actually creates the content-based icon but for some reason does not display it. I am fairly sure that the lag while scrolling comes from some sort of disk loading/file content processing work. The scrolling lag comes in waves, its not constant, which suggests that Finder has to pause and load the next batch of data.

    BTW, did you submit bug report to Apple? They should clearly fix this. At any rate there is some issue with the Finder.

     
  14. narutoksa thread starter macrumors newbie

    Joined:
    Sep 12, 2014
    #14
    Sorry, I should've been more clear. You can actually scroll a folder with two files if you put a file in the top part of the folder and the other one in the bottom like I did in the screenshot.
     

    Attached Files:

  15. dav1dd macrumors regular

    dav1dd

    Joined:
    Oct 25, 2013
    Location:
    Oz
    #15
    I can do the same thing on Yosemite - looking at it right now. I have 130 jpegs in a folder. It can only be bothered drawing the first 30 icons. The rest display as that generic symbol.

    I also moved from an old white Macbook (2006) to a MBPr 15" top of the line expecting super snappy performance. Right from day one I was underwhelmed.
     
  16. IHelpId10t5 macrumors 6502

    Joined:
    Nov 28, 2014
    #16
    I personally wish that Apple would add a setting like this:

    [ ] No eye candy

    to iOS and Mac OS.

    I simply can't understand why UI/UX developers don't understand that the majority of users would happily give up shadows, transparency, and other eye candy for instantaneous response fro an application. If I click a button I want the result to instantly appear. I'm not at all concerned that the button pulses, and/or that the window zooms in from the side. In my opinion all transitions should be abolished in favor of instant response!

    I was actually pleasantly surprised when iOS 8, Yosemite 10.10 and even Office 2013 for Windows went "Flat" as this in one step in the right direction. However, there is a long way to go.

    The use of every kind of unnecessary GUI enhancement reminds me of the days when Font abuse was so prevalent in the early days. Just because you could use 10 fonts in a business document didn't mean that you should! The same concept applies today with UI/UX. Just because modern video chips can do shading, transparency, and transitions doesn't mean you should be using these for every interface element.
     
  17. crjackson2134 macrumors 68020

    crjackson2134

    Joined:
    Mar 6, 2013
    Location:
    Charlotte, NC
    #17
    Wow, I thught it was just me that noticed the "About this Mac" seemingly getting slower. I didn't notice it until the last update. Prior to that it just popped right out. Now not so much. I ordered a new video card yesterday for my cMP to try and speed the UI back up. I hope it will pep it up a little.
     
  18. Irishman macrumors 68030

    Joined:
    Nov 2, 2006
    #18
    How old is your Macbook?

    ----------

    I'm reluctant to fully participate further, because you have dissuaded "fanboy" posts, but yet you've addressed this "lag" that I don't experience. (I haven't experienced it on Mountain Lion, Mavericks or Yosemite).

    My experience with Apple's OSs hasn't gotten slower or choppier.

    You're offering your personal experience as though it's coming from some sort of trusted source. (I don't know you, however), so without data or a white paper of some kind, I'm not sure how seriously to take you.
     
  19. Eithanius macrumors 65816

    Joined:
    Nov 19, 2005
    #19
    I've filed this and some other Finder problems since Mavericks...
     
  20. narutoksa thread starter macrumors newbie

    Joined:
    Sep 12, 2014
    #20
    I currently have a mid 2012 Macbook air 11" (base model)

    Well, this is not a scientific study, so I don't have any data. All I have is my experience and the experience of others who agree with me. Plus, a couple of tests you can do your self with your Mac to see the lag I am talking about. If you still don't see it, then I and all the Macs in the nearby Apple store must be in the minority. Although very unlikely, It is not statistically impossible for this to happen. If you don't mind me asking, what Mac do you currently use and what OS version?

    ----------

    Nope, as far as know it is a wide spread issue. Do keep us posted when the video card arrive. What kind of video card is it?

    ----------

    I couldn't agree more. I still remember the first version of IOS 7 and how painfully slow the animation was. It was so slow that I had to jailbreak my iPhone to get rid of it. Fortunately, they (Apple) sped it up with later versions of IOS.

    ----------

    Me two, I recently filed a bug report to Apple about the lag issue. Maybe they will listen this time and fix this issue. As it stands right now, I am very reluctant to purchasing the 15" Macbook pro. I don't want to spend $2000+ on a computer that lags doing simple animations.
     
  21. crjackson2134 macrumors 68020

    crjackson2134

    Joined:
    Mar 6, 2013
    Location:
    Charlotte, NC
    #21
    I'm replacing my HD 5870 with an HD 7970 from MVC's store, but it won't arrive for a few days.
     
  22. Beavix macrumors 6502a

    Beavix

    Joined:
    Dec 1, 2010
    Location:
    Romania
    #22
    Here's something which may explain why Yosemite UI is so slow.

    Some Photoshop CC 2014 users (including myself) have noticed a couple of UI bugs in the application after upgrading to Yosemite. When asked on the Adobe support forums, the Adobe engineers have been saying something like this:

     
  23. Irishman macrumors 68030

    Joined:
    Nov 2, 2006
    #23
    I love to learn and I love the science, so yes, please share the tests!!

    Also, I'm on a late 2012 21.5" iMac with the 2.9GHz i5, and the 512 MB nVidia 650M GPU. I'm running OS 10.10.2.
     
  24. narutoksa thread starter macrumors newbie

    Joined:
    Sep 12, 2014
    #24
    Test Number 1: Open System Preferences --> Energy Saver --> go back to System Preferences. Look closely at the animation when going back to System Preferences.

    Test Number 2: Open the Application folder from within Finder (not the launchpad app) --> scroll through the apps. Look closely for any lag, especially when the bouncing effect happens. You can also try a folder with two files like I showed in an earlier post.

    Test Number 3: Open Safari --> go to any website you like (macrumors, theverge,...etc) --> resize Safari by garbing any of the corners (not with the plus button). Do it fast enough and you should see it lagging.

    If non of these tests produce lag, than it may very well be a limited issue suffered only by some percentage of users.
     
  25. leman macrumors 604

    Joined:
    Oct 14, 2008
    #25
    First of all, your statement ('majority of users would happily give up ...') is most definitively not true. The goal of the animation is to provide visual feedback and are a very important part of the usability and user experience. Second, shadows and transparency are much cheaper than many would thing. Third, animation is so deeply rooted in OS X that removing it is simply unthinkable. There is a good reason why the central drawing interface API is called Core Animation.

    If you don't like animations, I am sure that there is another OS that would fulfil your criteria better. You can configure Linux with very lightweight window managers that do not have any animations. However, this will never happen with OS X, because it goes against the very design of the OS and its programming model.
     

Share This Page