Featured Articles
Stitch
Rhythmic Walk
Major Project - Divine Application
Generi Rig for Blender
KWrite/Kate MEL Syntax Highlighting
Improving the Maya Linux File Browser
Latest News
Search

Improving the Maya Linux File Browser PDF

ImageThere are parts of Maya that I think are pure 100% distilled brilliance. The wire deformer, dynamic curves and the commandPort all rate very highly in my book of awesomeness. Unfortunately, to keep the universe in balance, there are therefore also parts that are pure 100% effete crap. Maya's Linux file browser falls neatly into the latter category. It has no bookmarks, it can't autocomplete, and (my personal favourite) it doesn't display image previews when you're loading in textures. Loading or saving MEL scripts from the script editor has been known to reduce grown men to tears. So, using the magic of MEL, I replaced it with something a bit more capable

 

REQUIREMENTS

- kdialog or zenity must be installed
- Linux Maya 8.5 or higher; whilst earlier versions might work, they are untested.
- netcat (or "nc"); this is a standard utility present on Linux since, like, forever

 

HOW TO INSTALL THIS SET OF SCRIPTS; PLEASE READ CAREFULLY!

1) Using your favourite Linux package manager, make sure that you have "kdialog" installed if you want to use the KDE file browser, or "zenity" installed if you want to use the Gnome file browser. To check if you have kdialog installed, run "which kdialog" from the shell, or "which zenity" for zenity - if it prints a path to your screen, then it's already installed on your system. If it doesn't print anything out, then get installing...

2) Download this zip file (http://www.kreanimate.co.uk/Tools/KE_MayaFileBrowser1_4.zip). Extract all .mel and .sh files from this zip file to your scripts folder ($HOME/maya/(maya version)/scripts/).

3) Create the file $HOME/maya/(maya version)/scripts/userSetup.mel if it doesn't already exist, and then using a text editor, paste the following two lines into it and save it:

KE_ScriptEditor();
KE_FileBrowser();


4) Restart Maya; check the script editor for errors. If nothing went wrong and no errors appeared, a new toggle item should appear in your File menu named "External File Browser", which is on by default. Switching it off will make Maya use the old MEL-based dialog, keeping it on will make Maya use kdialog if you're using KDE, and zenity if you're using Gnome. The option box next to it will open a dialog to let you configure whether you use kdialog or zenity, or just whatever's default on your desktop. This new improved file browser will also be used automatically by the script editor, the attribute editor, the render view, and pretty much anywhere else in Maya that uses the file browser.

 

HOT TIPS

- When using the KDE file dialog, press F10 to open an image preview window
- Right click on the side-bar on the left hand side of the file browser window to add/remove bookmarks

 

A NOTE FOR SYSADMINS AND TDS

I realise that installing a copy of these shell scripts and MEL scripts in the local scripts folder for every user in a company is impractical. The MEL scripts can in fact be put anywhere in the MAYA_SCRIPT_PATH (like any MEL script really), just make sure that you modify your userSetup.mel to include the required lines mentioned above. The shell script "KE_FileBrowserWrapper.sh" normally has to go in the "$HOME/maya/(maya version)/scripts/" folder; however you can put it anywhere you like as long as you set the environment variable KE_FILEBROWSER_WRAPPER to point to its new location - the file browser code will try to use that instead.

An example .cshrc line would be:
setenv KE_FILEBROWSER_WRAPPER "/usr/scripts/KE_FileBrowserWrapper.sh"

And an example .bashrc line:
export KE_FILEBROWSER_WRAPPER="/usr/scripts/KE_FileBrowserWrapper.sh"

 

VERSION HISTORY

- 1.4; Additional bugfix for Ubuntu. Removed error suppression from the shell script to help users with installation issues. Bugfixes for KDE4; KDE4 is now supported. 64-bit Linux distros are also now supported.

- 1.3; Fix for incompatibility with menus in Maya 2009; Maya 2009 is now supported.

- 1.2; Bugfix for distros with Qt libraries in non-standard locations, and a bugfix for older, less capable versions of Zenity (thanks Ivan!)

- 1.1; Bugfix for broken shells that ignore the #!/bin/bash shebang and try to use /bin/sh instead
(thanks Simon!). Also added a new config dialog in the file menu to allow users to
force kdialog on Gnome, or zenity on KDE.

- 1.0; Initial public release.

Questions? Bug reports? Comments? I always like to hear feedback at my usual email address. Hope this proves useful, happy animating!

 
Comments

You must javascript enabled to use this form

Awesome!

Posted by Drake, whose homepage is here on 03/11/2009 at 07:42

A lot of thanks, for this great tool, i was tired for the old window


Muchas gracias por una herramienta tan util, ya estaba cansado de la antigua ventana

Posted by jaime, whose homepage is here on 06/11/2009 at 15:27

wow, amazing. it really helped and worked like a charm on ubuntu 9 x64. all of things were already installed;)

thanks for nice solution

Posted by lala, whose homepage is here on 08/24/2009 at 05:24

Hi,

Looks very good, does it work with xfce also ?

Posted by Sebastien, on 08/30/2009 at 09:08

:
Looks very good, does it work with xfce also ?

Hey Sebastien - it'll work on any desktop. It'll use the Gnome/KDE file browser (since I don't think there's a xfce-specific file browser), but apart from that should work perfectly :)

Karl

Posted by Karl, whose homepage is here on 09/05/2009 at 10:25

Thanks for making my life a little bit easier. I was so sick of being ripped back in time to computing circa 1992 every time I had to open something in Maya. May you be graced with good Karma for many lifetimes to come!

Posted by ChrisB, on 01/14/2010 at 04:02

This is great, thanks so much!

Posted by Leif3d, on 02/25/2010 at 01:19

 1 
Page 1 of 1 ( 7 Comments )


Designed by: Drupal hosting Mambo templates Best web hosting
http://www.kreanimate.co.uk/site, Powered by Joomla and designed by SiteGround web hosting