|
At the crossroad of New media, Engineering, Research and Development
|
|
Archive for ‘OSX’ Category
Apr
03
2012
Get the “Bounce” command back in Mail application under OSX LionThe “Bounce” command is really useful for those times when you’re receiving spam mail that gives you no recourse to opt-out. Usually Ads and announcements have a link to unsubscribe, but if they don’t I usually just “bounce” the mail back to the sender and that usually causes the sender to take me off their mailing list. As of the release of Lion, apple (for some reason) has decided to take that functionality and the associated button away from the Mail app. To be more precise, they’ve removed the icon and the menu option, but the function is still there, buried in the guts of mail. You can get it back by creating the following Automator Service script. Follow the instructions below:
Now assuming you have two email accounts setup in Mail, send a test email from one account to the other. Then in the receiving account check for the new mail, select it, go to the “Mail” menu, under “Services” and select “Bounce Message”. This should bounce your test message back to it’s original sender (your other account) and delete it from your inbox. If you want to get really fancy you can even assign a keyboard shortcut to the “Bounce Message” Service. If for some reason you need to get rid of it, just delete the file under your personal Library directory (in finder hold down option while going to the “Go” menu and select “Library”), under Services folder. Nov
02
2011
Using iCloud to sync files just like dropboxIf you didn’t know, iCloud has a really neat feature that allows it to act just like dropbox. If you activate the “Document & Data” synching option in the iCloud pref panel, it allows you to sync any file using iCloud. This is contrary to what Apple is selling the service as being just for “Custom” Apps that have the iCloud feature (i.e.: keynote, numbers, etc.).
Aug
04
2011
Lion Tip: Adding your digital signature to PDF files….If you ever are in need of signing a PDF file, you don’t need to print/sign/scan it anymore, Lion’s new preview app lets you insert/sign those pdf docs in a flash. Here is how you get your signature “scanned”.
I had to do this twice, but it’s very easy and quick to do. You can even have multiple pics taken of your signatures (or other peoples sig in your household). Now that I’m getting settled in the latest OSX, I thought I share with you a couple of finder gems that might not be obvious right from the get go: 1) You now have the ability to select multiple files in a folder and right click on them to choose “New Folder with X Selections”. This will create a new folder and move the selected files into that folder. Kinda neat and makes the process of moving large number of files a bit simpler. 2) You can now “move” files and folders from one place to another. First “copy” the file/folder in question by selecting it and using the command-c shortcut. Then find the place you want to move them to and instead of using the usual command-v (which copies the files/folders) use command-option-v instead. Yeaaaaa, we can finally be just like our windows cousins 3) To remove something from the finder sidebar, hold the command key as you drag it out. 4) In the Finder’s “Go” menu hold the option key to reveal a “Go to Library” menu item. Although not strictly a new finder gem, Window resizing now supports standard modifier keys, so holding Shift while resizing a window constrains it to its existing aspect ratio, while holding Option resizes the window from its center point. Feb
04
2011
Adding mcrypt support to builtin php5 on OSX Leopard….I got a request to add mcrypt support to our Leopard server today and here is a brief step-by-step installation instruction. This works well under the current 10.5.8 server installation. It should also work for 10.6 (snow leopard), but I have not tried it. Before you start here are the requirements:
Please note that this will add mcrypt support to php. This is NOT the same as compiling mcrypt. Okay, so now that we have all the requirements, you need to get a command line window opened and get a root shell (sudo -i). The rest of this document assumes you’re typing the commands in a root shell. There is one dependency that we need to clear before we actually get down and dirty and that is libmcrypt. Follow the instructions below to get this installed:
This is the latest version as of this writing (Feb.04.2011). NOTE: If you’re compiling on a G5 machine you’ll need to tell the compiler that you want to build/configure for a ppc64 target so instead of the below configure command you need to use this:
The last command will simulate the installation process. Make sure the stuff is getting installed in /usr/local/lib
At this point you should have a working installation of libmcrypt. This next command prints out the current version of your php engine. In my case under 10.5.8 it’s php 5.2.14.
Grab the appropriate php-5.2.XX.tar.bz2 file from php.net. I just grabbed the stock PHP 5.2.14, since I wanted a perfect match between my php engine and the extension. I transferred the file using sftp to the /SourceCache folder on the server. NOTE: If you’re compiling on a G5 machine you’ll need to tell the compiler that you want to build/configure for a ppc64 target so instead of the below configure command you need to use this:
The last command will simulate the installation process. Make sure the stuff is getting installed in /usr/lib/php/extensions/no-debug-non-zts-20060613
Now we need to modify our php.ini file and tell the php5 engine of the availability of this new module. To do this you need to copy php.ini.default to php.ini (in /etc directory). For details of why have a look at this article.
Edit the newly created/copied php.ini using your favourite editor. Add the following line to the appropriate location (read the comments in the file to find the location):
Still in the same file find the variable “extension_dir” and change it’s value to “/usr/lib/php/extensions/no-debug-non-zts-20060613″ path instead of “./”. Save the php.ini and use the following command to see if mcrypt extensions are available:
Done. Restart Apache service from the server manager (just for the sake of completeness). Jan
16
2011
Optimizing Snow Leopard for SSD drives….I just installed a new 128GB SSD drive in my older C2D 17″ macbook Pro and let me tell you….WOW….This thing is on fire. The system is extremely responsive and apps literally jump onto the screen. The machine now boots up to full desktop in roughly 17 seconds. Now that’s nice. I did do a bunch of changes to the way Snow Leopard is setup to optimize a couple of things that are normally tuned for HDD’s.
This should do it. Have fun with your new SSD drive. Jan
16
2011
Five minute Augmented Reality via Quartz Composer….Great little video on how to setup AR marker recognition under QC. Even has a nice mellow background music
Oct
19
2010
Terminal Tip: Finding information about a mp3 audio file…Here is a quick tip for you OSX command line fans. If you want to find metadata information about a mp3 file use the “afinfo” command. Very quick and scripting friendly. Here is a example:
Sep
20
2010
say -v "Bad News" fuk fuk fuk fuk fuk fuk fuk fuk fuk fuk fuk fuk fuk fuk fuk fuk fuk fuk fuk fuk fuk fukSep
20
2010
Map any network drive to Mac OS X that auto mounts after system rebootHere is a quick recipe for making a network drive auto mount on your OSX machine. This works with pretty much any protocol supported by Finders “Connect to Server” option. Here is how you do it:
That’s it…..Enjoy Sep
02
2010
Reset iTunes 10 window control buttonsNot sure what’s happening lately in the Apple UI design department. Someone over there decided to reposition the window control buttons (you know x,-,+ aka. close,minimize,maximize) vertically in the latest itunes10 (see pics below). If you prefer the old (proper) way of having them ordered horizontally (see picture above), you can use the commands below:
If you need to reset it back, you can use the commands below:
Aug
05
2010
Restarting into Mac OS X using the command line, when running Windows…Okay so this only works in Boot Camp 3.0+ which comes with Snow Leopard (10.6). If you ever find yourself in Windows and need to quickly — using command line — change your boot option to reboot into OSX (process known under OSX as blessing) you can use the following command: Aug
05
2010
Forcing 64-bit mode when booting OSX 10.6 (Snow Leopard)…You all probably know about the trick with holding down 6 and 4 keys on your keyboard to force OSX 10.6 to boot using the 64-bit kernel. What you might not know is that it’s temporary and the next time you reboot, you’re back to using the 32 bit kernel. Now I can’t guarantee that your machine will not catch fire and blow up (just kidding)…..but if you know what you’re doing and want to have 64-bit kernel goodness all the time you can do the following: This is a neat new feature in safari 5. If you close one of your tabs by mistake you can “undo” it by pressing Cmd+z (in OSX) or Ctrl-z (in Windows). Neato Well, you learn something new everyday. I was always under the impression that you needed Apple Remote Desktop application to connect to a mac that was sharing it’s screen (or vncviewer app). Today I stumbled across another way of doing this without any of these apps……just using the build in “Screen Sharing” application. The easy way (and how I stumbled across this) was to open up Finder/Go/Connect to Server menu option (Apple-K) and type vnc://remote.server.dns.name.or.ip in the “server address” field. This is something that works nicely under Linux (gnome desktop) and I always wanted it in mac……well it was there all along….. And for the command-line junkies there is a even easier way. Open up terminal and type the following command to connect to the remote server: NICE Really cool video of Jim Reekes talking about his thought process in designing sounds for the mac, including the big fat C major chord which your mac plays every time you start it. Jim Reekes was a programmer at Apple Computer for 12 years. His work has significantly affected operating systems, most notably System 7 and QuickTime. He also is responsible for creating many of the system sounds for the Macintosh operating system. Some of the most famous creations during that time were the Mac startup sound and the system sound sosumi. Full 1 hour video can be seen on Youtube. Mar
05
2010
How to stream live HDV/DV to iphone…..In this guide I’ll show you how to stream live HDV/DV video to your iphone using a linux box (Ubuntu 9.10) with firewire input running vlc/ffmpeg and a Imac with OSX 10.6.2 running mediastreamsegmenter and apache2. Start out with the iPhone streaming media overview. Without understanding this document you’ll have a hard time getting things working. First things first, you need to have a working Ubuntu 9.10 machine. I’m using a small footprint 2.4Ghz Core2Duo machine with PCI firewire 400 card in it. For video input I’m using a Canon HV30 set to HDV mode (1080i/60) connected via firewire. Next you need to follow the instructions on this page (steps 0-5) to get a working ffmpeg with x264 and aac encoding. Without this working you’re not going anywhere….sorry. If you’re trying this on a different Ubuntu installation follow the other links to get a working ffmpeg setup. Then install vlc using “sudo apt-get install vlc“. I used vlc as my encoder frontend as I understand it better than ffmpeg. You can use just straight ffmpeg as well if you can figure out how to get it to encode the live HDV stream over firewire. You’ll also need dvgrab utility. Install it using “sudo apt-get install dvgrab“. Now we want to make sure the internal firewire module is working so type this command and see if you get a vlc window with the camera output in it (make sure you turn the camera ON and hook it up first). Next we need to create a media stream out of our linux box and ship it over UDP to the Imac. The vlc command below gets the job done. Remember you’re sudo’ing and need to provide the password after you enter the command. So now we can go over to the mac and see if we receive the video stream. For that just run VLC for OSX and open UDP network port on port 1234 (udp://). If things are working nicely you should see a 320×240 video from you HDV camera on the Imac. Now that we have the video on the mac, we need to use the “mediastreamsegmenter” command line tool to create HTML5 video stream out of it. mediastreamsegmenter listens on a UDP port for incoming transport stream chops it (by default) into 10 sec. “mini” transport stream files and writes these mini files to wherever you tell it. This location is important since it needs to be accessible to your webserver. Remember, at the end of the chain (day), the webserver is doing all the heavy lifting of delivering the mini transport stream files to your iphone. mediastreamsegmenter also produces a file of type .m3u8 Something you might not know is that apple ships standard OSX with apache builtin. All you have to do is use the following command to get it started. Now you should be able to open up your browser on your iphone/ipod touch and punch in http://192.168.1.97 (assuming the Imac is reachable from your phone) and see the streaming video (You might have to turn on “Plugins” feature under settings/safari on your device. Mine was turned off and drove me crazy until I figured it out). If Plugins is turned off, the index.html page will load, but no video. Hopefully there is enough meat here to get you guys started……btw. I hear the following command (or variations of) can be used on linux side (instead of vlc). I haven’t tried it and can’t confirm if it works. Some excellent information can be found on Carson McDonald’s blog: Feb
11
2010
iPhone Explorer turns your iPhone/iTouch into a USB stick…..One of the original reasons I bought my first ipod (first gen 5 Gig) was that I could hook it up to my mac and use it as a firewire drive. I could literally run around with this in my pocket and boot OSX off the ipod. Well that came to an end with the intro of iPhone/iTouch. Apple took the “disk mode” out. Well that was then, go grab a FREE copy of iPhone explorer and all that USB stick functionality can be your again. Oh, and did I say there is no need for Jail Break either Features:
Feb
05
2010
Movist…..will it be the next VLC for mac….The answer to that is maybe, we’ll see. But all that aside if you’re interested in a minimalistic video player that can handle more codecs than VLC and is generally faster then give Movist a try. The unique thing about the player is that it allows you to switch codec engines between ffmpeg and quicktime based on file extensions. Oh and did I say it’s FREE aswell
Jan
29
2010
._ resource fork files don’t work properly in OSX 10.6 Samba……Well the title is a bit misleading…..here are the details. I found out that if you have a NTFS native shared directory on your server, everything works fine as long as you’re using OSX 10.5 (Leopard) or below as a client. You can move files from Leopard and/or Tiger clients to the share and as long as you don’t mind the ._ files everything works. Well something new has been introduced in Snow Leopard that kinda breaks this. If you have a Snow Leopard client machine accessing a NTFS native shared directory (via smb), by default the shares are mounted with the new xattr (Extended Attribute) feature, instead of those “old” ._ files. This messes everything up if you’re in a mixed environment with 10.4, 10.5, and 10.6 clients all accessing files in a NTFS native smb share. Snow Leopards version of samba will read those old resource fork files, but files uploaded or modified by the Snow Leopard client will be unrecognizable by the older samba clients (10.5-) as far as the resource fork goes. This introduces some problems with programs that use the resource fork to store information. All this headache is related to the ‘NTFS Streams’ feature of SMB mounts, so if we disable that, everything goes back to normal. To do this you have to create a file named /etc/nsmb.conf on all your 10.6 clients with the following contents: |