Is there any 3D visualizer for NS/UIView and CALayer?

Is there any 3D visualizer for NS/UIView and CALayer?

This is HTML inspector view of Firefox ( Aurora ).
It’s very handy to see what layer/view is where in x, y and z coordinates.

Is there any tools for iOS and Mac for Cocoa application also for development purpose?

 

UPDATE : Mr. Charlie Monroe gave a URL for such a tool for iOS. http://sparkinspector.comThank you!!!! ;)

14 responses to this post.

    • Posted by jongampark on August 9, 2013 at 11:42 AM

      It’s amazing. How could they make such a tool?
      developers there must know the in & out of runtime and how Xcode interacts with the simulator.
      I wonder if it’s also possible to work with real device in debugging session.

      Reply

      • I haven’t played with it much, I’m just aware that there is such a tool. I believe it communicates with the simulator pretty much the same way Xcode does, or actually lldb does. It wouldn’t be hard to make a similar thing for OS X, but I don’t think there’s the market for it. The iOS market has grown incredibly…

        Reply

        • Posted by jongampark on August 9, 2013 at 11:58 AM

          Yes.
          Currently I’m working on am iOS project which was started by someone else. Problem is that the original developer didn’t understand transformation and layering things. It was just implemented to make it look like working. But internally there are lots of wrong things.

          For debugging purpose I painted background of each view to see what layer is displayed, but when things are overlapped it was pretty hard to figure out if an interested view is under a current view.
          – recursiveDescription helps, but sometimes it’s pain to identify which view/layer is which.

          This will help a lot.
          What’s fortunate about iOS7 is that you can run a code to host a UIImagePickerViewController even on a simulator. Although it doesn’t display live image ( probably because I don’t have a camera ), but at least it doesn’t crash. So, this can be used with my current project.

          Thanks a lot.

          Reply

      • Hey folks! I’m the author of the Spark Inspector—thanks for the shout out, I’m glad you’re happy with it.

        The Spark Inspector has two parts – a mac viewer app, and a framework that goes inside your app. The framework adds Objective-C categories to your app, and a block of code that is triggered with NSObject +initialize. The framework does two things. It compresses and sends information about the views over to the mac app, and it uses Method Swizzling (http://cocoadev.com/MethodSwizzling) to watch for changes that it should send over. (That last bit is where things get sorta hairy…)

        Enjoy the app, and let me know if you run into any issues! NSShowAllViews is a great trick too.

        Reply

        • Posted by jongampark on August 15, 2013 at 7:47 AM

          Thank you for leaving your comment!
          I wonder how you figured out things to make the wonderful tool! :)

          I didn’t use it yet. I’m about to make a sample project to report a bug to Apple. I found some serious problem with handling of rotation and presentation of views when people do it in a way that Apple doesn’t expect. So, I think your tool can help visualizing that.
          In my project at work, I painted background of engaged views with different color. However, when one view is totally overlapped with another bigger view, it’s pretty hard to see what’s happening.

          Your tool is a life savor! :)

          Thanks for the great tool!

          Reply

        • Posted by jongampark on August 15, 2013 at 7:51 AM

          BTW can you check the web site with Firefox or Auroa ( which is a dev branch of Firefox). Stylesheets of your web site doesn’t look to be applied. I made sure that I turned off all adblock add-ons and ghostery.. Still somehow Aurora doesn’t seem to recognize the stylesheets.

          Reply

  1. I wonder if there is a NSShowAllViews env variable equivalent for iOS… At least I cannot find it. But it’s quite useful on OS X. (http://borkware.com/quickies/one?topic=NSView)

    Reply

  2. Both are useful in its way, though when you have access to the running instance, NSShowAllViews is quicker and more visual… I’d bet there’s an equivalent for iOS, but just not documented…

    Reply

    • Posted by jongampark on August 9, 2013 at 12:16 PM

      Yup! On a simulator of iDevice, there is a menu item to blend layers and views to visually identify them. But they are in 2D. So, it’s kind of impossible to check if underlying views/layers are in correct manner. :)

      Reply

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: