![]() |
Adobe Photoshop SDK |
|
Types of plug-in modulesSections on this PageAdobe Photoshop plug-in modules are separate files containing code that extend Photoshop without modifying the base application. Photoshop supports a public interface for seven types of plug-in modules: Automation Automation modules access all Photoshop scriptable events. These modules appear under the Automate menu or Help menus. These modules are documented in Automation Module and Photoshop Actions Event Guide. Color Picker Color Picker modules provide a plug-in interface for implementation of different color picker’s in addition to Photoshop’s and the system’s color pickers. They appear whenever the user requests a unique or custom color (such as clicking on the foreground or background colors in the tools palette) and are selected in the Preferences... General dialog. These modules are documented in Color Picker Module and in Writing Color Picker Plug-ins. Export Export modules output an existing image. Export modules can be used to print to Mac OS printers that do not have Chooser-level driver support, or to save images in unsupported or compressed file formats. These modules are accessed through the Export sub-menu. These modules are documented in Export Module, and in Writing Export Plug-ins. Filter Filter modules modify a selected area of an existing image. These modules appear under the Filter menu. Filter modules are the plug-ins that the majority of Photoshop users are most familiar with. These modules are documented in Filter Module, and in Writing Filter Plug-ins. Format Format modules, also called File Format and Image Format modules, provide support for reading and writing additional image formats. These appear in the format pop-up menu in the Open, Save As and Save a Copy dialogs. These modules are documented in Format Module, and in Writing Format Plug-ins. Stack Renderer Stack Renderer modules operate on an image stack, defined as a Smart Object. These modules appear under the Layer > Image Stacks > Image Stack Rendering menu. These modules are documented in Stack Renderer Modules, and in Writing Stack Renderer Plug-ins.. Import Import modules open an image in a new window. Import modules can be used to interface to scanners or frame grabbers, read images in unsupported or compressed file formats, or to generate synthetic images. These modules are accessed through the Import sub-menu. These modules are documented in Import Modules and in Writing Import Plug-ins. Measurement Measurement modules add items to measure. Measurement items can be configured from the Analysis > Select Data Points dialog. Measurements can be performed from the measurement log palette or the Analysis > Record Measurements menu item. Selection Selection modules modify which pixels are chosen in an existing image and can return either path or pixel selections. These modules appear under the Selection menu. These modules are documented in Selection Module, and in Writing Selection Plug-ins.. 3D There is five ways to extend functionality with 3D modules. All modules work through the 3D scene description. Modules have control over cameras (perspective and orthographic), lights (spot, point, directional, infinite), meshes (made up of Faces, each with Material), animation (keyframes, position, rotation, scale)
Plug-in module filesPlug-in module files must reside in specific directories for Adobe Photoshop to recognize them. Under the Mac OS, plug-in files must be in:
Under Windows, plug in files must be in the directory "Plug-Ins" that is located next to the application. The HKEY_CURRENT_USER\Software\Adobe\Photoshop\10.0\PlugInDirectory is an optional location to install plug-ins. For older versions of Photoshop use the /c PLUGINDIRECTORY profile string in the Photoshop INI file.
Usually, a plug-in module file contains a single plug-in. You can create files with multiple plug-in modules. This is discouraged, because it reduces the user’s control of which modules are installed. There are situations when it may be appropriate to have more than one module in a single plug-in file. One example is matched import/export modules, although these are usually implemented as a file format module. Another example is a set of closely related filters, since the reduction of user control is offset by the increased ease of plug-in file management. Plug-in file types and extensionsPlug-in module files should follow the guidelines in the table below for the type identifier under the Mac OS, and the file extension under Windows. While these are only recommendations with Adobe Photoshop 3.0, these must be used if your plug-in module runs with earlier versions of Photoshop.
On the Macintosh, plug-ins with the same creator ID as Adobe Photoshop ( Basic data typesThe basic types shown in the following table are commonly used in the Photoshop plug-in API. Most of these are declared inPITypes.h .
|