Jump to content

Viewing .img files on a Mac


S. Houtzager
 Share

Recommended Posts

The only way would be for you to switch the file dialog to Column View, having preview column active (I think you must set that so via Finder windows' view options for them to be active in file dialogs too). I'm in Snow Leopard and it shows .IMG previews faultlessly. I dislike OS X' Column View as implemented, though :( (I'd rather it previewed things in a separate pane in the dialog window, old-style).

Not exactly a trick (it costs a bit of money): if you purchase Default Folder X, a truly brilliant Open/Save file dialog helper, it adds to file dialogs a preview pane that understands IMGs, resizable.

(Default Folder X is a lifesaver. You can download a demo)

post-32-13269393672148_thumb.jpg

Link to comment
Share on other sites

  • 2 years later...

Richard, if you are on a Mac you can reassign which app is the creator. Find one of your graphic .img files, then press command & i or right click and select 'get info'.

Then go down to 'Open with:' and change from DiskImageMounter to Animator. Also just below that, select 'Change All..." to fix all of your other Animator files as well. -Derryl

Link to comment
Share on other sites

  • 4 weeks later...

Quick look, that works well. Mac and works also when replacing, etc textures in EIAS.

I think it is Leopard upwards though.

Can zoom as well.

It's great for all digital camera info as well. Can get focal length etc from most cameras.

http://www.macosxtips.co.uk/index_files/make-the-most-of-quick-look.php

Just a thought.

However, can check the "compute preview image" tab when placing textures in EIAS.

Link to comment
Share on other sites

Apple's quicklook system is not based on the type/creator codes from OS9, and the file extension .img is secured to be used by Apple's Disk Image Mounter (even though this is an old disk image format from OS9 that is no longer used). The file extension and preferred application are controlled by a UTI (unique type identifier) system in OSX which is simply not very good.

The easy way (on a mac) is to install the qt extension from Toby's site, and delete the .img extension- the OS will fall back to the type/creator codes, and QT will generate a preview for the file.

Alternately you can save re-save all your .img's into another format that Animator understands.

Of course neither of these options solves the problem without a major headache- you have to re-link all your files with your projects because the filenames are different.

The complicated but preferred method is to hack your system so that the .img extension is not used exclusively by Disk Image Mounter.

I will post the info here BUT BE WARNED: YOU DO THIS AT YOUR OWN RISK. I DO NOT RECOMMEND THAT YOU DO THIS, NOR DO I TAKE RESPONSIBILITY FOR THE RESULTS OF YOUR ACTIONS (I.E. HACKING YOUR COMPUTER) .

The hard way:

copied from instructions written by someone a lot smarter than me ;)

------------------------------------------------------------------------

0. This works for 10.5.x and requires that the .img QuickTime Component is installed http://telegraphics.com.au/sw

0. I have NOT tested this on 10.6,10.7, 10.8

0. Read everything before doing anything

First we will modify Animator by adding an instruction to export a UTI that include the .img extension

1. Right-click on Animator and choose "Open Package Contents" - The folder opens, showing a subfolder, "Contents"

2, Open the Contents folder

3. Open the Info.plist file in TextEdit

4. After the third-to-the-last line, "<string>© 1998-2008 EITG, Inc.</string>", add the following:

<key>UTExportedTypeDeclarations</key>

<array>

<dict>

<key>UTTypeConformsTo</key>

<array>

<string>public.movie</string>

</array>

<key>UTTypeDescription</key>

<string>EIAS Animation File</string>

<key>UTTypeIconName</key>

<string>generic</string>

<key>UTTypeIdentifier</key>

<string>com.apple.quicktime.img</string>

<key>UTTypeTagSpecification</key>

<dict>

<key>com.apple.ostype</key>

<string>EIDI</string>

<key>public.filename-extension</key>

<array>

<string>img</string>

</array>

</dict>

</dict>

</array>

5. Save the Info.plist file

Now we will remove the .img extension declaration from the DiskImageMounter.app

6. Go to the BootDrive/System/Library/CoreServices/ folder

7. Drag a copy of DiskImageMounter.app to the desktop

8. Right click on the copy on the Desktop and choose "Compress DiskImageMounter.app" - we will keep the .zip archive in case things go awry

9. Throw away the DiskImageMounter.app you coped to the Desktop and empty the trash

10. Go to the BootDrive/System/Library/CoreServices/ folder

11. Right-Click on the DiskImageMounter.app and choose "Open Package Contents" - The folder opens, showing a subfolder, "Contents"

12. Open the Contents folder by double-clicking on it. Do NOT tweak down the arrow to open the folder (to avoid confusion later)

13. Copy the Info.plist file to the desktop (keep the Contents folder open on your desktop, we will need it in step 19)

14. Open the copy of Info.plist that you copied to the desktop in TextEdit

15. Hit Command-F and enter the following into the Find edit box, <string>com.apple.disk-image-ndif</string>

16 Hit return

17. 12 lines below where the find lands, you will see the following:

<array>

<string>ndif</string>

<string>img</string>

</array>

Change this to:

<array>

<string>ndif</string>

</array>

18. Save the Info.plist file

Since the DiskImageMounter.app is in the System, you cant drag replace the old plist file with the new one.

19. Go back to the Contents folder you left open in step 13. and drag the Info.plist file to the trash (you will be asked to authenticate)

20. Drag the Info.plist file from the desktop into the Contents folder (you will be asked to authenticate)

21. Open the Terminal. Terminal is an application that can be found in your utilities folder.

22. In the open terminal window, type /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/LaunchServices.framework/Versions/A/Support/lsregister -kill -r -domain local -domain system -domain user

23. Hit return

24. Reboot

If you do not have proper QuickLook functionality at this point, the System has not acknowledged the update to Animator or DiskImageMounter.app.

The following steps will force the System to update.

1. Open the Terminal. Terminal is an application that can be found in your Utilities folder

2. Type the word touch followed by a space.

3. Drag the copy of the Animator you modified onto the Terminal window and release the mouse button

4. The Terminal window should now contain something like this: Macintosh:~ myusername$ touch /Applications/EIAS7.0.1/Animator.app

5. Hit return

6. Follow steps 22, 23, and 24 above.

It is possible you will need to perform the touch steps on the DiskImageMounter.app. Since this application is in the System, you will need root access to touch it.

1. Open the Terminal

2. type su root

3. Hit return and enter your root password followed by a return

4. If the response is "sorry", you don't have the right password. It is possible you have never set a root password on the computer.

Setting the root password:

4a. Type sudo passwd root

4b. Hit return

4c. You will have to enter in your chosen root password 3 times.

4d. Type su root in the Terminal window, hit return and enter in the password.

5. In a Terminal window, type, touch /System/Library/CoreServices/DiskImageMounter.app

6. Hit return

7. Quit Terminal

8. Follow steps 22, 23, and 24 above.

This process works. The only thing I don't know is if there are any implications to the modification of the DiskImageMounter.app. The app itself will be fine. I don't know if modifying it will cause problems the next time the system wants to update it...But we kept a copy of the original as a .zip just in case.

----------------------------------------

I have done this in the past, and it works.

I have not tried this since updating to 10.6.8

I am also using Default Folder X which seems to work reasonably well for an Open/Save dialog solution without the above hack.

Of course the above system modification is the only way to get .IMG previews directly in the finder.

If anyone at EIAS3D (Tom and the Igors especially) objects to me posting this info I will happily remove it.

Dave

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...