Archive

Archive for the ‘Macintosh’ Category

Connecting Mavericks to a Freebox: Oh the pain!

I’m very frustrated. Today, I wasted basically two or three hours fighting unreliable software implementing one of the most basic features in the world of networking, namely file sharing. I ought to be simple, it used to work, but if my experience is representative, it’s complexly broken nowadays. Grenouille bouillie.

What I tried to do is not that complicated. We have a Freebox at home, it’s basically a DSL modem with many features, including the possibility to act as a NAS. So I connected my external drives, and tried to connect to them with my Macs.

It worked. I was happy. I started copying my files around. I noticed that it was very reactive. For example, I could eject a disk from the NAS user interface (a web GUI that is relatively well designed), and instantly, the file server would restart. I saw a message on the Macs saying that the server had shut down, and a couple of seconds later, I was back in business.

Then something happened, and everything stopped working at once.

It’s frustrating, because I know exactly what I did at that moment. I reformatted a disk with the NAS user interface. That disk was initially formatted as HFS+, which the NAS would expose as read only. So I reformatted it as Ext4.

And suddenly, the file server stopped working, even when I removed the disk in question. That leads me to believe I changed something else without knowing it. Maybe the GUI changed some configuration behind my back? I have no idea. All I know is that I spent the last two hours trying to understand how to revert my configuration so that I would be able to share disks again.

Symptoms: I connect to the NAS, and it refuses to show my disks. If I disable Mac sharing (AFP) and only enable PC sharing (SMB), then I can connect to the NAS, but somewhat unreliably.

I suspect the problem is on the Mavericks side of things, because connexions to another NAS I have at home are equally flaky. One minute it transfers dozen of files per second, the next it’s as if I was writing to a floppy disk. Transfers from other protocols (e.g. using a web browser) are fast and reliable, so I don’t think it’s a Wifi or network issue.

How annoying.

 

Apple backups and RAID are not reliable

You’d think that if you use RAID1 and multiple redundant, distributed backups with hourly backups, daily backups, etc, you’d be safe? Think again. If your backup software lies to you, you may not realize it until it’s way too late. If you RAID software does not deem it worthy to mention that a disk failed, what good is it?

Read more…

Adding chapter numbering in Apple Pages

At Taodyne, we mostly use Apple Pages to create our documents. For large documents, I’d like to be able to create numbered chapters, something like “Chapter 1″, “Chapter 2″, and so on. Apple Pages does not seem to have that feature. Let’s not get used to it,  and let’s fix it.

Apple Pages can read numbered chapters from Word

One thing that I observed is that when you read a Microsoft Word document that contains numbered chapters, Apple Pages preserves that formatting. In other words, if the user interface may not know how to edit numbered lists with text in them, the rendering engine knows how to render them, and the regular editing within Pages will correctly renumber these documents.

To verify that my recollection of this capability of Pages was correct, I first created a document in Microsoft Word that looks like this:

Section 1 – Hello

Chapter 1 – This is a chapter

I. This is a numbered section

1. This is a numbered sub-section

It doesn’t just “look like” this. The Section and Chapter text were edited in the Numbering section of Microsoft Word, so this is auto-numbering.

Then I saved this document to disk, and imported it into Pages. And indeed, when I edit it in Pages, numbering works just like in Microsoft Word.

The Pages XML format

Let’s look inside the document to see what’s there. A quick tour through the command line shows that Apple Pages documents are really zipped collections of files, including XML files representing the document itself:

% unzip Hello.pages 
Archive:  Hello.pages
 extracting: thumbs/PageCapThumbV2-1.tiff  
 extracting: QuickLook/Thumbnail.jpg  
 extracting: QuickLook/Preview.pdf   
 extracting: buildVersionHistory.plist  
  inflating: index.xml

The most interesting of these documents is the index.xml file. It contains the actual description of the document in XML format. And if I look inside, I see something interesting:

<sf:list-label-typeinfo sf:type="text"><sf:text-label sf:type="decimal" sf:format="Section %L -" sf:first="1"/>

So this sf:format= accepts a rather general format, with %L serving as the marker for where the number should go.

The solution for adding chapter numbers

So the solution for adding chapter numbers is simple:

  1. Once, you will need Microsoft Word to create a document that has the kind of chapter numbering that you need. You may have multiple levels of numbering (e.g. chapter, section, etc).
  2. Import this document in Pages. This will give you a new list style.
  3. When you want to number chapters, select the given list style.
  4. To edit the formatting of the numbering text, select the whole line, change colors or fonts, and in the list style, select “Redefine style for selection”. In other words, the list style defines the font and color for the numbering independently from the paragraph style, and can do that for multiple levels.

Now, you have proper chapter numbering in Apple Pages.

Stereoscopy: What works, what doesn’t

In the past months, we have been looking for a relatively cheap way to present the output of a 3D application using stereoscopy. Our objective was to see how an application could generate stereoscopic output using commercially-available low-cost hardware. Our expectation was that a budget 3D laptop and a budget 3D projector would make for a budget 3D presentation solution.

The solution that ended up working was a total surprise to us, so I thought I’d share…

Budget 3D laptop and projector

We recently purchased two pieces of equipment with a “3D” sticker on them. One was an ACER Aspire 5740D laptop, the other was an Optoma DW318 projector. Both can be considered entry level hardware, around $700 each with glasses.

This family of Acer laptops uses a polarized display and passive glasses. Even and odd scan-lines are polarized differently, meaning that you get half the vertical resolution when using stereoscopy. Native resolution is 1366×768. It comes equipped with an ATI Radeon 4570 and some 3D software from TriDef. It is also covered with at least 5 stickers and littered with various nagware (software based on the “we’ll bug you until you pay” school of design) and other software nuisances, almost guaranteeing a supremely annoying unpacking experience.

The Optoma is labelled as “3D-ready”. It uses active glasses based on Texas Instrument’s DLP-Link technology. Native resolution is 1280×800. The active glasses mean that you get the full resolution with 120Hz frame-sequential input, with only a barely noticeable decrease in frame rate (60Hz for each eye). It can also reportedly take 60Hz field-sequential input up to 480i, but we didn’t test that. There is practically no manual (at least as far as 3D is concerned), and the manual that came with the glasses didn’t help much either (I’m still not sure I know how to switch the glasses off).

No OpenGL stereoscopy on Windows

Our test application uses standard OpenGL quad-buffer support. We need OpenGL because we want the application to run on Macs and Linux machines as well, not just Windows. So DirectX is a no-go. However, we also evaluated how things worked with DirectX just in case we had no other choice.

With the Acer, the ATI “Catalyst” drivers simply tell us that there is no OpenGL quad buffer support. As soon as we try to use the buffers, we get an error (1282: Invalid operation). This is a disappointment, as quad-buffer support for DirectX was one of the advertised features for recent Catalyst drivers. Apparently, this only means that a third-party driver, either from iZ3D or TriDef, can silently convert non-stereoscopic games into stereoscopic games.

It makes sense from a business point of view, since all the majority of users will care about is 3D games, which mostly use DirectX nowadays. But if you want to programmatically produce stereoscopic 3D-accelerated output using OpenGL, which should theoretically be simpler, it just doesn’t work out of the box.

I spent a little bit of time trying to find drivers from iZ3D or TriDef that would support OpenGL quad-buffer on this machine. No such luck.

  • The iZ3D setup page prominently shows “OpenGL QB driver for iZ3D”. However, when I installed the driver, it didn’t work for me. Only DirectX would show up. It took me a while to see this little note somewhere:

Note! OpenGL QB is for 32-bit systems only and can not be run properly on 64-bit systems.

You guessed it: my system is 64-bit, so no OpenGL for me.

  • The experience with the TriDef setup was exactly similar. At first, it looks promising: “The DDD TriDef Visualizer Program is ideal for anyone interested in enabling their application for output to stereoscopic displays.” That is, until you click on the link to get the SDK, only to be told:

PLEASE NOTE: TriDef Visualizer OpenGL SDK has been RETIRED and is no longer available for sale.

If someone at Microsoft has been tasked with the job of killing OpenGL on Windows, it looks like they have been doing a rather good job. In any case, we were unable to find any combination of drivers on 64-bit Windows that would allow us to use 3D stereoscopy from OpenGL. If you know of any combination that works, please comment here.

Working around lackluster OpenGL support

The structure of the screen on the Acer is really simple. Every other line on the screen is polarized differently. So in order to produce a stereoscopic image, you don’t really need a driver. All you need is the good old OpenGL stencil buffer, as explained here. You then render one eye with all even lines masked out, and then another eye with all odd lines masked out.

This worked well, and we were soon able to get some basic stereoscopy working. It only took a couple of hours of coding. I only wish this coding had not been necessary on a machine that came littered with 3D stickers and pictures of 3D pirates on the box!

Then, we could start experimenting with stereoscopic rendering and judge by ourselves how the effect played out. Unfortunately, while it worked to some extent, it was not entirely satisfying…

The drawbacks of interlaced stereoscopy

The most annoying issue with this setup, as we quickly discovered, is that you lose half of the vertical resolution. It may not seem like much, but this actually makes text totally unreadable. “Who needs text in a stereoscopic display?“, you may wonder. Well, Google Earth, for one, uses a lot of text. And this is practically the only non-game application I managed to get working on the Acer with the built-in software.

The problem is that the Windows user interface itself uses a fair amount of text and small drawings. Since the glasses actually block every other line, here is what your desktop looks like when you wear the glasses:

Windows 7 desktop, as seen through passive glasses

Windows 7 desktop, as seen through passive glasses

The effect is actually much more annoying than that, because what your left eye and your right eye see is different. I just can’t stand looking at my desktop like this for long. So what happens is that you spend your time putting the glasses on, then removing them, then putting them back on. After a short while, the game stops being funny and you wish you had bought active glasses instead. This probably doesn’t impact gamers much, but in our case, it is almost a deal breaker…

No stereoscopy on Windows with a low-cost projector

In order to address this issue, our next experiment was with the Optoma DW318 projector. I got this projector from Saturn at a bargain price. The vendor was actually quite honest that they had not tried 3D and didn’t know if it worked. Also, this projector is marketed as “3D-ready”, so I wasn’t entirely sure that we’d get anywhere. But we naively hoped that if we connected a “3D-ready” projector to a laptop that has stereoscopic 3D support as its main selling point, we stood a decent change of getting a stereoscopic image on the projector.

Boy! Were we naive last week!

If the built-in stereoscopic software on the Acer laptop has any kind of support for the Optoma projector, it is rather well hidden. I tried various options, but as far as I can tell, stereoscopy on the Acer is meant to be restricted to the built-in screen. That’s rather odd! What would you think of a color laptop than can only supply black-and-white pictures to external displays?

I tried supplementing the anemic built-in software. Downloading drivers from iZ3D, I was able to get a 3D image from their test and setup application. But still, I was not able to get a stereoscopic image from Google maps on the projector, however, something that works on the built-in screen of the Acer laptop.

The overall feeling is that this stuff was rushed out of the door before it’s really ready.

The Good Surprise: on a Mac, It Just Works!

We also have Apple Macbook Pro notebooks and Linux laptops and virtual machines. During testing, Linux didn’t do much better than Windows. However, OpenGL on the Mac accepted quad-buffer (stereoscopic) mode. Compared to Windows, the primary difference was that we did not get the 0×502 = 1282 error (OpenGL invalid operation) when selecting the back-left or back-right buffers. Tweaking a bit, we had gotten what looked like a stereoscopic output on the built-in display of the Mac laptops or on external displays, with fuzzy blurry images.

Of course, without glasses, that’s all these were: fuzzy blurry images, not that useful unless you can blink really really fast.

Actually, everything was not all smooth and fuzzy at first. OpenGL was apparently doing something smart there, but we were clearly pushing it a bit. For example, if running an OpenGL application under the debugger and putting the laptop to sleep, MacOSX would die a little too often for my taste (like: almost every single time). Another interesting issue was that if you had any stereoscopic application running, switching desktops with Spaces would just kill the window server (the MacOSX blue screen of death). That was really annoying. I filed a couple of bug reports with Apple. Stereoscopy was apparently working to some extent, but it still made for a very un-Apple dangerous user experience.

That was last month, when MacOSX 10.6.4 was all the rage. Imagine my surprise when 10.6.5 came out. All the issues I had were fixed with 10.6.5. And this certainly took some work from Apple engineers. Now, when you switch spaces with a stereoscopic application (and only a stereoscopic application), something happens that you can notice visually, almost as if some part of the window server was rebooted or something. It’s just weird, but at least, it’s just solid now. Kudos, Apple for fixing something that could easily have passed for a corner case with exactly one user in the world.

Anyway, I figured that it was worth trying to hook a Macbook Pro to the projector and see what we got. And IT JUST WORKED! We got perfect, high quality stereoscopic images the first time we tried.

Or almost.

How can you make glasses complicated?

Clearly, I had two pictures on the screen. And when I wore the glasses, I had only one picture. So something was working. But the result was still disappointing. It looked boringly flat, nothing like what I expected.

I tried several settings on the projector, checked that 3D was enabled in the firmware menu. I adjusted the eye distance to try to increase the depth. The effect of increasing eye distance was clearly visible with the naked eye, as the left and right pictures became more distant from one another. But with the glasses, still no feeling of depth.

Until I tried to switch off the glasses while wearing them, using the little red button. And I noticed that the picture moved. It was still flat, but it had moved in front of me. Hmmm?!?

So I tried again to see if the picture would move again. And I almost fell on my back. The effect was intense, in no small part because I had pushed the eye distance so high. A few adjustments later, I was back to the original setting, and I had true, breathtaking stereoscopy.

Guess what: some bozo working for Optoma or whoever designed the glasses thought it was a good idea to have three settings: left eye only, right eye only and stereoscopic. I’m sure there’s a good reason for that, but as far as I can tell, the manual only talks about on and off settings.

Trying Windows on a Macintosh

Once we knew that the Macs could drive the Optoma projctor in stereoscopic mode, we thought we also had a Windows solution. See, all recent Macs can run Windows using Bootcamp. We figured that it was a simple matter of switching to Windows, installing the latest Nvidia drivers, and boom.

Well, not quite.

First, Nvidia won’t let us install drivers on a Mac. We are supposed to ask Apple. Of course, there are workarounds. So quickly, we were able to get the latest drivers to install on the Mac. These drivers that are ostensibly designed for stereoscopy. But it still doesn’t work with the Optoma projector.

See, Nvidia has their own little 3D project called 3Dvision. You’d think that since 3Dvision is about supporting stereoscopy, we stood a chance of making it work with an Optoma stereoscopic projector.

And you’d be wrong. It doesn’t work. With OpenGL, you get the same dreaded error 1282.

According to some posts on the Internet, it used to work relatively well with much older Nvidia drivers and cards. But apparently, Nvidia is now trying to leverage their position as a key provider of graphics chips to force third parties to “certify” projectors. The Optoma HD67 is certified and reportedly recognized by 3Dvision drivers. The DW318 is not certified, and therefore not recognized.

If this is a trick to try and force me to buy Nvidia glasses, it’s not just a cheap trick, it’s a stupid trick. The Nvidia solution uses a small infrared emitter. If I’m projecting on a large screen, I doubt this emitter would be good enough to cover a medium-sized room. I suspect that the technique used in DLP-Link, which uses data sent on the screen by the projector, is much better suited to sharing with a large audience.

Anyway, the very same Optoma projector just works on the very same Macbook pro when running MacOSX instead of Windows 7. So this is clearly a software block from Nvidia rather than some subtle hardware limitation. If you are the Nvidia or Microsoft bozo who is responsible for this fiasco, here is a hint: why don’t you get it fixed?

Conclusion: Don’t Trust Marketing

To summarize my experience:

  • The Acer 5740DG offers some basic stereoscopy, but support for OpenGL is underwhelming. OpenGL stereoscopy won’t work with the pre-installed 64-bit version of Windows 7. This Acer laptop is designed primarily for games, although it may be a bit underpowered for that purpose. For any windowed 3D application, or any application that shows text, dialog boxes or other small elements, the stereoscopic experience is highly frustrating because you don’t see half of the screen while wearing the glasses.
  • The Optoma DW318 is a very capable 3D projector if you can make it work in your configuration. The picture is actually much better with the glasses in stereoscopy mode, with rich deep blacks and well balanced colors. Without the glasses, the picture looks a bit washed out. Still, it’s a decent value, and a good way to demo stereoscopy to more than one person. I only wish they didn’t charge $100 or so for a pair of cheap plastic glasses with $0.0027 worth of electronics components in them.
  • Nvidia and ATI are both equally incompetent at delivering OpenGL stereoscopy on Windows 7. Part of it may be Microsoft pushing DirectX, but I believe the driver vendors are equally to blame. I couldn’t get OpenGL stereoscopy to work whether with ATI or Nvidia, whether with built-in screens or external projectors.
  • MacOSX 10.6.5 has full support for OpenGL stereoscopy, and when connected to a 3D-ready projector like the Optoma DW318, it just works the way it should. This is advertised nowhere, which makes it even sweeter.

In short, those who talk the most about 3D (Nvidia, Acer) are those who deliver the least. By contrast, Apple, who doesn’t say a word about stereoscopy, delivers flawless OpenGL stereoscopy support as far as I can tell. And Optoma, who labels its DW318 with a rather understated “3D-ready”, has made the process of projecting in 3D both inexpensive and painless.

MacOSX Leopard: disappointed…

I finally purchased MacOSX Leopard. For a long time, I had purchased every single update of MacOSX as soon as I could, because they were generally worth it. This was the first time I had some second thoughts. There were a number of mixed reviews over the net, like the excellent Ars Technica review.

The main problems that these reviews were reporting were drops in looks and usability. Looks: folder icons that look bad, inconsistent shadows, translucent menu bar, overly bright window widgets, and so on. Usability: initially, folders placed in the dock would show as “stacks”, in other words a big pile of stuff, and fan out in a way that made it quite hard to pick up anything in the folder. Overall, the new OS was also reported to be much more resource hungry than the older ones, not a big surprise here…

To me, it was annoying to have a trade-off between features I’d get, like Time Machine or Parental Controls, and features I’d lose (something Apple does not advertise much), like Classic (the environment to run MacOS9 applications). In previous releases, there was a net gain in functionality, but the loss of Classic was a pretty big deal to me. In particular, I wanted to have Parental Controls on the kids Mac, an old Dual G4 which contains tons of MacOS9 games.

But a few weeks ago, having learned that 10.5.2 was finally giving users options about the dock icons and menu bar, I thought that it was safe to jump, at least for my Intel-based Powerbook, which can’t run Classic anyways, and which was acting weird lately. In particular, it jut can’t run straight any time I have run any virtual machine with Parallels Desktop. That was most likely a problem with Parallels, not with Apple, but I thought that the latest Apple OS might help. Another problem I kept hitting was that the machine would lock-up when I tried to unlock the screen saver. Hoping to get rid of these annoyances, I went ahead, purchased it and installed it.

The first thing I noticed is that my machine had become quite slower than before. Starting applications, in particular, seems to take quite a bit longer. This is particularly noticeable at login time. I now need something like one minute to log-in, which is too long for my taste. Unfortunately, the problems I had before were both still there: crashes or hangs after running Parallels, and even without running it, I still have the “black screen of death” way too often when I try to get out of the screen saver.

So I decided to try it on another machine, see if the experience would be any better: on the kids computer. Here, the experience is nothing but miserable. First, the installer forced my screen resolution to 640×480 on a flat-panel LCD that normally runs at 1280×1024. No big deal, it’s just the installer, right? Wrong! The screens do not fit at that resolution, so to get anything you have to hit “tab” at random and hope to hit the “Continue” button with the space bar (you can’t reach it with the mouse, since it’s out of the screen…)

Once you went through the whole installation routine, you are greeted with a screen that looks like this:

That’s right: the menu bar is a bright pink, and the background image is pink colored more or less at random. Performance is abysmal, my kids had to downgrade the various tunable parameters of World of Warcraft by a couple of notches. And I got at least one lock-up.

The upgrade process is not smooth either. To install 6 updates on the G4 took me 3 or 4 attempts. It seems to install, but after the install-and-reboot, it still wants to install the same thing. On the Intel PowerBook, I have been unable to update so far, it tells me that it “cannot write to /”. Repairing disk permissions failed. One of my disks, that reads fine with 10.4, appears as “unrepairable” with 10.5. Granted, it was probably damaged in some way, but I’d like to avoid losing 350GB of data, please?

So, overall, MacOSX 10.5 is a disappointment. Apple is probably focusing a lot of energy on the iPhone right now… Or something else happened. Regardless, the quality of that product is not what I am ready to pay for.

Update: I had the same kind of color problem on my MacBook with an external HP monitor. The colors just looked way off, and trying to adjust the ColorSync profile only made things worse. This monitor used to work really well with this machine. What’s going on here?

Categories: Macintosh

VMware soon to virtualize of 3D graphics

This started with a video on Youtube purportedly showing accelerated 3D graphics in VMware Fusion. The news was quickly spotted by Macbidouille and many others, and later confirmed.

This is interesting news, for two reasons. The first one is that graphics performance has been a main bottleneck for desktop virtualization for a long time, and more importantly, a functional bottleneck. In particular, it excluded any kind of “modern” gaming in a virtual machine. Having solved that is really neat, both technically and as a way to make virtualization more mainstream.

The second reason is that, if indeed we are talking about a fully supported feature, I believe that it appeared on the Mac version first. Granted, it has been present in a limited form in Workstation 5.0, for a little more than one year, but the feature is not even advertised in VMware Workstation 5 datasheets. With the Intel Macs, VMware found itself another mass market for its workstation products, one with presumably a much better attach rate, and more importantly, a market where they were beaten to the gates by Parallels.

Once more, innovation is fueled by competition. Good for Macintosh users…

Follow

Get every new post delivered to your Inbox.

Join 365 other followers

%d bloggers like this: