Core Image
From Wikipedia, the free encyclopedia
| Core Image | |
| Image:Apple Core Image Icon 175px.png
<tr><th>Developer:</th><td>Apple Computer</td></tr><tr><th>OS:</th><td>Mac OS X</td></tr> | |
| Use: | System Utility
<tr><th>License:</th><td>Proprietary</td></tr> |
|---|---|
| Website: | apple.com/macosx/features/ coreimage |
Core Image is a technology in Mac OS X that heavily leverages the machine's GPU for image related effects. Demonstrated in the August 2004 WWDC, it provides access to the most common graphics filters. It adds the ability to do many common types of image processing on-the-fly (which previously required custom implementations in the developers' own code). Image units can be tested with the Core Image Fun House application.
Core Image has further implications than simple GUI enhancements, such as the ripple effect generated by Dashboard. Developers can write their own filters, Photoshop filters, and package them in bundles called Image Units. However, unlike a traditional filter that manipulates the source image, Core Image performs a manipulation as an overlay — maintaining the original image. This is called "non-destructive" manipulation. The result is the ability to do highly complex and layered image manipulations with little or no loss in quality.
Transition effects work like filters, combining two or more images to form a result image, and accepting a time value (0 < t < 1) as a parameter. By driving an animation using a timer, a transition from one image to another is easily implemented.
The components of pixels in Core Image are represented using floating point values within the designated color space. The use of floating point allows great precision. Multiple effects can be achieved by combining several Image Units into a sequence called an effects stack. However, for most Image Units, Core Image does not generate each intermediate image as it processes the stack; instead, it calculates the resulting mathematical operation once, then applies that result to the image. The upshot of this is that performance does not degrade dramatically as more effects are added - the pixels are only processed once no matter how complex the effects stack becomes.
Core Image is designed to leverage the processing abilities of certain types of graphics processor found on high-end video cards. This gives enormous performance benefits because large image data sets need not be moved across the main memory bus, which is one place where real-time image processing can become bandwidth bound.
Core Image, being only for two-dimensional graphics, uses only the pixel shaders of the GPU, not the vertex shaders. This means that the more pixel shader pipelines a GPU has, the better the performance will be. Other considerations are VRAM bandwidth, memory bus width, and GPU clock speed.
However, if a suitable graphics processor is not available, Core Image will fall back to the next best option: using SSE3+ on the Intel Core and Intel Core 2 processors, using the AltiVec vector-processing abilities of the G5 and G4 processors, or plain scalar code on a G3. Core Image will automatically adopt the fastest approach for a given machine architecture. However, realistically, real-time processing requires a compatible GPU.
When the CPU-fallback is used (as recommended by Apple for final rendering, most likely because VRAM readback over AGP is very slow), Core Image performance scales almost linearly with the number of CPUs and their clock speed.
Contents |
[edit] Core Video
Running alongside Core Image and built upon it is Core Video. In the same spirit as that of Core Image, it allows on-the-fly editing of video, as shown in the WWDC Webcast.
Both technologies depend heavily on the system's graphics card.
[edit] Compatible GPUs
Basically any Mac-compatible GPU that supports at least second-generation shaders, more specifically the ARB_fragment_program OpenGL extension, can also do Core Image. The same requirements are used by Quartz Extreme.
Namely, the following GPUs are supported (as of March 2006):
[edit] ATI
- ATI Radeon X1900 XT
- ATI (Mobility) Radeon X1600 XT
- ATI (Mobility) Radeon X1600
- ATI Radeon X800 XT
- ATI Radeon 9800 XT
- ATI Radeon 9800 Pro
- ATI Radeon 9700 Pro
- ATI Radeon 9600 XT
- ATI Radeon 9600 Pro
- ATI Radeon 9650
- ATI Radeon 9600
- ATI Mobility Radeon 9700
- ATI Mobility Radeon 9600 (only 64MB version)
- ATI Mobility Radeon 9550
[edit] Intel
- Intel GMA 900 (Developer Transition Kit)
- Intel GMA 950
[edit] NVIDIA
- NVIDIA Quadro FX 4500 DDL
- NVIDIA GeForce 7800 GT
- NVIDIA GeForce 7300 GT
- NVIDIA GeForce 6800 Ultra DDL
- NVIDIA GeForce 6800 GT DDL
- NVIDIA GeForce 6600 LE
- NVIDIA GeForce 6600 GT (flashed PC-Card)
- NVIDIA GeForce 6600
- NVIDIA GeForce 6200 (flashed PC-Card)
- NVIDIA GeForce FX 5200 Ultra
- NVIDIA GeForce FX 5200 Go
- NVIDIA GeForce FX 5200
Note: The Geforce FX 5200 is only barely suited for Core Image due to poor pixel shader performance. With most Macs, the CPU is faster than the 5200 in rendering, so Apple disabled Core Image support for it and also did not support the 5200 in Aperture.
[edit] Apple applications that use Core Image
Core Image is part of the System and can be implemented in any application. The CPU-fallback approach ensures compatibility on any system. It was introduced with Mac OS X v10.4 "Tiger", so prior versions don't support it.
Apple ships a program called Quartz Composer with its Developer Tools. Its maker is Pierre-Olivier Latour, who is now employed at Apple. Quartz Composer is basically Version 2 of his program Pixelshox, which is not supported any more, but which also runs on earlier versions of Mac OS X. Both Pixelshox and Quartz Composer support an approach similar to Apples compositing-program Shake which can generate OpenGL-based scenes by linking various building blocks with nodes, feeding the output from one module to another. A multitude of data types (e.g. Boolean, numeric, image, video, RGB) and inputs (e.g. DV, image, video, generators, mouse, RSS-feed) are supported, and in- and outputs can be mapped to programs in Xcode. People without any programming knowledge can build complex scenes by just linking various blocks in the right way.
Unlike Pixelshox, Quartz Composer now also supports Core Image Filters (delimited by a dot in front of the Module). Since Quartz Composer can export the scene as a QuickTime 7 movie, developers can embed these, and thus be able to use Core Image in web pages. Since Quartz Composer only exports the scene and its assets to QuickTime and not rendered frames of video, the resulting file is very small. This means, though, that the movie requires Core Image, so it will not work on Windows, nor on versions of Mac OS X prior to Mac OS X 10.4, even with QuickTime 7 installed.
Also in the Developer Tools is Core Image Fun House, similar to another Core Image-based program called iMaginator. Outside of the Developer Tools, Dashboard uses Core Image for the Water Ripple effect, Apple's photography software Aperture uses it for other things, and some of iMovie's filters use Core Video.
Apple's title generator Motion uses similar GPU-based-rendering techniques, but does not (yet) use Core Image, using its own frameworks instead. This is done for Mac OS X v10.3 compatibility.
[edit] Image Units
- Median, Gaussian, Motion and Zoom blurs
- Noise Reduction
- Full color, hue, temperature, white point and saturation control
- Pinch, Hole, Dump, Displacement, Glass, torus Lens, Twirl, Vortex, Circle Splash and Circular warp distortions
- Several generator filters including Star Shine, Sunbeams, Checkerboard and Lenticular Halo
- Color blends: color burn, darken, difference, exclusion, hard light, hue, lighten, luminosity, multiply, overlay, saturation, screen, soft light
- Cropping
- Scaling, rotation, shearing and translation using Affine transformations
- Several halftone filters including CMYK, dot, hatched and line
- Deconvolution
- Transition effects such as Swipe, Flash, Page Curl, Copy Machine, Disintegrate with Mask, Dissolve
[edit] External links
- Mac OS X Tiger: Core Image: preview from the Apple web site
- Core Image kernels: Some examples for beginners
- Image Tricks: a freeware program for applying Core Image effects to pictures
- LiveQuartz: graphics application using Core Image
- ChocoFlop: graphics application using Core Image
- Pixelshox: the predecessor to Apple's Core Image-using Quartz Composer.
- iMaginator: graphics application that uses Core Image
- Magma: Use Core Image filters in InDesign or Illustrator.
- Intaglio: Drawing application that uses Core Image
[edit] Broken links
- WWDC 2004 Keynote Webcast: original presentation by Steve Jobs
Applications
Address Book • Automator • Backup • Calculator • Chess • Dashboard • Dictionary •
DVD Player • Finder • Front Row • Grapher • iCal • iChat • iSync • iTunes • Mail • Photo Booth • Preview • QuickTime Player • Safari • Sherlock • Stickies • TextEdit
Utilities
Activity Monitor • AirPort Admin Utility • Audio MIDI Setup • Bluetooth File Exchange • BOMArchiveHelper • Classic • ColorSync Utility • Console • Crash Reporter • DigitalColor Meter • Directory Access • DiskImageMounter • Disk Utility • Font Book • Grab • Help Viewer • Image Capture • Installer • Internet Connect • Keychain Access • Migration Assistant • NetInfo Manager • Network Utility • ODBC Administrator • Printer Setup Utility •
Software Update • System Preferences • System Profiler • Terminal •
Universal Access • VoiceOver • X11
Technology & User interface (future features italicized)
⌘ • ⌥ • Apple Advanced Typography • AppleScript • Aqua • ATSUI • Audio Units • Bonjour • Boot Camp • Carbon • Cocoa • ColorSync • Core Animation • Core Audio • Core Data • Core Foundation • Core Image • Core Video • CUPS • Darwin • Exposé • FileVault • Inkwell • icns • Keychain • Mach-O • OpenGL • plist • Quartz • QuickTime • Rosetta • Smart folder • Spaces • Spotlight • Time Machine • Uniform Type Identifier • Universal binary • WebKit • Xgrid • XNU

