ÔPlug-in DigitizerÕ v1.2.4 The ÔPlug-in DigitizerÕ is a plug-in acquisition module for Adobeª ÔPhotoshopÕ, ÔNIH-ImageÕ or similar applications. It allows these applications to grab images from Quicktimeª compatible digitizer sources which provide a 'vdig' component. Images can now be captured at any pixel depth and at a size different to the screen preview size. It has a ÔfacelessÕ operation mode that requires no user interaction, allowing time-lapse image grabbing with suitable applications. INSTALLATION NIH-Image: Place the ÔPlug-in DigitizerÕ file in the ÔPlug-insÕ folder which should be located in the same folder as the ÔNIH-ImageÕ application. Photoshop: If there is a ÔPlug-insÕ folder in the same folder as your ÔPhotoshopÕ application then place the ÔPlug-in DigitizerÕ file in the ÔPlug-insÕ folder. Otherwise place it in the same folder as your ÔPS PrefsÕ file which is the Photoshop preferences file. Note, the location of plug-ins for different versions of ÔPhotoshopÕ appears to vary, please consult your ÔPhotoshopÕ documentation if the above procedures do not work. Others: Follow the instructions given with your application for the installation of acquisition plug-in modules. USE Starting: Launch the application. Select the ÔPlug-in DigitizerÕ from the ÔAcquireÕ sub-menu. The plug-in's window will then appear. The default video grabber component will be selected so that a video preview image is displayed in the plug-in's window. If there is no Quicktime compatible digitizer component available on your computer then an error message will occur. Window sizes: The size of the video window can be adjusted by using the set of three radio buttons located on the left side of the plug-in's window under the title ÔViewÕ. These allow selection of full size, half size and quarter size preview video images. The default is to start up at half size. Since the plug-in will not let you preview a video image that is bigger than the screen, some size buttons may be dimmed depending on which sizes are too big for the screen. For the extreme case where the quarter size view is bigger than the screen, an error message will occur and no video preview will be displayed. The plug-in's window can be dragged by its title bar to any location on the screen. It can now even be moved partially offscreen without affecting the operation of the plug-in. Note that the size buttons are disabled whenever the video preview is frozen. To change size restart the video preview with the ÔLiveÕ button to re-enable the size buttons. Digitizer settings: The video digitizer component settings can be set by clicking the ÔSettingsÕ button. This produces the standard video settings dialog that enables you to configure particular features of your video digitizer card, or to change to a different digitizer if one is available on your machine. The settings and the plug-in's window position are both saved and restored between calls to the plug-in, provided the calling application does not quit in between calls. Options: Clicking the ÔOptionsÕ button will bring-up a dialog box that allows various special operating features to be configured: ÔFaceless OperationÕ: If the ÔFaceless operationÕ checkbox is checked, then when the ÔPlug-in DigitizerÕ is next called from the host application it will use the current settings and automatically return an image without the need for user interaction. This facility is useful for time-lapse image grabbing. To cancel ÔFaceless operationÕ hold down the ÔoptionÕ key on the keyboard when selecting the plug-in from the applicationÕs ÔAcquireÕ menu, and uncheck the ÔFaceless operationÕ checkbox in the ÔOptionsÕ dialog box. Note that there is a slight delay between calling the plug-in and the return of the captured image. The length of this delay will vary depending on the model of computer the plug-in is executing on. The maximum achievable frame rate will therefore depend on the computer used, but it is likely to be about 1-2 secs per frame. If an error occurs during a faceless operation an error dialog box will appear and this will require user interaction to cancel it and correct the indicated problem. Remember to give the host application a sufficient memory allocation to store all the images to be grabbed. ÔGreyscale DigitizationÕ: If the ÔGreyscale DigitizationÕ checkbox is checked, then the ÔPlug-in DigitizerÕ will set the digitizer into greyscale mode to provide the maximum number of greys available for the digitized image. Set this checkbox if you are digitizing from a monochrome source. When it is unchecked the ÔPlug-in DigitizerÕ will set the digitizer to colour mode. The state of this option is preserved between calls to the plug-in. ÔSpecific grab depthÕ: This feature allows the plug-in to grab a video image at a pixel depth that is different from the current screen pixel depth as set in the ÔMonitorsÕ Control Panel. When the ÔSpecific grab depthÕ checkbox is not checked the captured image will have the same pixel depth as the screen. When checked, the ÔGrab depthÕ pop-up menu is activated. Choose the required pixel depth for the grab from the pop-up menu as required. Note that some video digitizer may not support all pixel depths, in which case a garbled image may be returned by the plug-in. Consult the documentation that came with the digitizer to see which pixel depth settings are valid. ÔUse digitizer sizeÕ: This feature allows the plug-in to grab a video image at a size that is different from the screen preview size. When the ÔUse digitizer sizeÕ checkbox is not checked the captured image will have the same size as the screen preview. When checked, the size buttons are activated. Choose the required digitizer size for the grab. Capturing: To capture a still from the video preview, first choose the options which you require: digitized image size, digitized image pixel depth, and greyscale or colour. Then click the ÔFreezeÕ button. The video preview will then freeze and display the captured image, and the ÔFreezeÕ button will change to a ÔLiveÕ button. If you are not happy with the captured image then click the ÔLiveÕ button to restart the video preview, and then capture a frame again with the ÔFreezeÕ button. Typing a ÔtabÕ character on the keyboard has the same effect as clicking the ÔFreezeÕ/ÔLiveÕ buttons. Exiting: To exit from the ÔPlug-in DigitizerÕ without returning an image to the calling application, click the ÔCancelÕ button or press the ÔescÕ key on the keyboard. To exit from the ÔPlug-in DigitizerÕ and to send an image to the calling application click the ÔOKÕ button or press the ÔreturnÕ key on the keyboard. If the video preview is frozen, then the frozen frame is sent to the application. If the video preview is live at the time of exit, it will freeze and send the image to the calling application in one operation. About: Clicking the ÔAboutÉÕ button will bring-up a window displaying a copy of the instructions from this ÔRead MeÕ file. NOTES In some circumstances the buttons on the left of the plug-in's window will move closer to the left-hand side of the window when particular video preview sizes are chosen. This ensures that as much of the full screen area can be used to display the video preview so that for example, full-frame PAL video can be displayed on a 16" colour monitor. When using ÔNIH-ImageÕ you must choose a suitable LUT before selecting the plug-in acquisition module. If you are grabbing a greyscale image from a greyscale source then use the ÔGreyscaleÕ option. Otherwise if you are grabbing a colour image from a colour source then select the colour ÔSystemÕ palette. If you try to capture a greyscale source with the colour ÔSystemÕ palette then the grey levels will be converted to the available greys in the palette giving less than 16 shades of grey. When using ÔPhotoshopÕ to grab greyscale images you must set your monitor to ÔGreysÕ by using the ÔMonitorsÕ Control Panel. When grabbing colour images leave the monitor set to ÔColoursÕ. When using ÔNIH-ImageÕ a simple macro can be used to start the ÔPlug-in DigitizerÕ with a simple key-press. For example: macro 'Acquire Video [A]'; begin Acquire('Plug-in Digitizer'); end; To produce a time-lapse sequence first select the ÔPlug-in DigitizerÕ from the ÔAcquireÕ menu and configure its settings to those required for the images to be grabbed. Check the ÔFaceless operationÕ checkbox in the ÔOptionsÕ dialog box. Use this simple macro example to grab 10 images with an interval of 5 seconds (plus the delay for the capture of an image) between each: macro 'Acquire Time-lapse Video [B]'; var number,count : integer; delaySecs : real; begin number := 10; delaySecs := 5; for count := 1 to number do begin Acquire('Plug-in Digitizer'); wait(delaySecs); end; end; A more complex macro that saves the sequence of images to disk is given below. Note that this example requires version 1.55 of NIH-Image, and the example is courtesy of NIH-ImageÕs author Wayne Rasband. macro 'Make AV Movie to Disk'; { Captures images using 'Plug-in Digitizer' and saves them to disk. Abort at any time by pressing the mouse button. } var nFrames,n:integer; interval,StartTicks,EndTicks:integer; time:real; path:string; begin Requiresversion(1.55); path := GetString('Folder path:','MyHD:movie'); nFrames := GetNumber('Number of Frames?',10); time := GetNumber('Delay Between Frames (seconds)?',60.0); interval := round(time*60); StartTicks := TickCount; EndTicks := TickCount+interval; for n := 1 to nFrames do begin time := (TickCount-StartTicks)/60; ShowMessage(n:3,' ',time:4:2); Acquire('Plug-in Digitizer'); MoveTo(2,12); SetFontSize(12); SetForegroundColor(255); write(n:3,' ',time:4:2); SaveAs(path,':Frame ',n); Dispose; while TickCount < EndTicks do begin if button then exit; end; EndTicks := EndTicks+interval; end; end; See the ÔNIH-ImageÕ manual for more details of programming macros. RELEASE NOTES ______________________ v1.0 - 28/01/94 - First full release ______________________ v1.0.1 - 08/02/94 - First bug fix release - Fixed bug in which compression settings were not saved and restored between calls to the plug-in. - Fixed bug where garbled image was returned in 24-bit addressing mode. - Fixed bug so that it works with Quicktime 1.5 as well as 1.6. - Full VideoSpigot PAL can now be displayed on 16" monitors. - Can capture 16/32-bit per pixel colour images. - Checks for availability of Quicktime. - Now displays the version number in the logo. - Changed name to US spelling "digitizer" instead of UK spelling "digitiser"! ______________________ v1.0.2 - 15/03/94 - Second bug fix release - When resized the centre of the window remains fixed - previously the top-left corner was fixed. The top-left corner will be adjusted to always keep it on-screen when resizing. ______________________ v1.1 - 23/03/94 - First minor upgrade - Added faceless operation mode to allow time-lapse image grabbing (by popular demand). ______________________ v1.2 - 26/10/94 - Second minor upgrade - Added support for offscreen grabs so that images can be grabbed at a pixel depth and size other than that of the screen preview. - Eliminated the need for the preview image to be completely on screen when grabbed. - Allows greyscale option to be set. ______________________ v1.2.1 - 10/2/95 - Bug fix release. - Now uses Sequence Grabber to do offscreen grab rather than direct call to the vdig. - Now erases, frames and writes error message in offscreen gworld before grab. ______________________ v1.2.2 - 18/8/95 - Bug fix beta release. - Now works correctly with devices that have a vertical holdoff in their video (eg Quadra 630). ______________________ v1.2.3 - 18/9/95 - Bug fix beta release. - Will display Quadra 630 PAL/SECAM video in NTSC sized rectangle to stop pixel-doubling. - Works correctly on 7500/8500 after change to LUT setting. ______________________ v1.2.4 - 12/6/96 - Bug fix beta release. - Fixed bugs relating to Sequence Grabber settings which sometimes caused the plug-in to claim that there was no compatible Quicktime digitizer, or not correctly restore the previous settings (for example the choice of PAL video format). - As a result of the above fix the compression settings are now correctly saved and restored. ______________________ KNOWN PROBLEMS: - Settings dialog sometimes does not display live video. - Does not return correct image when used with VideoSpigot ÔvdigÕ at full size. - Has not been tested with all the available vdigÕs. Extensive testing on AV Macs has taken place, together with limited testing on the VideoSpigot ÔvdigÕ. If you have problems with the operation of plug-in and a particular ÔvdigÕ please ensure first that you are using the latest version of the ÔvdigÕ. - Problems occur with preferences files taken from 68K machines to PPC machines. This problem is usually only significant for PPC upgraded 68K machines which are switched between 68K & PPC. The preferences file must be deleted when such a switch is made. ______________________ FUTURE ENHANCEMENTS: - Frame averaging. - Fat resource to support native PPC. - Please send your own suggestions for future enhancements to the author. ______________________ ACKNOWLEDGEMENTS Thanks to Nick Safford, Colin Ager and Wayne Rasband (author of ÔNIH-ImageÕ) for beta-testing and suggestions. ______________________ LICENSE This software is © Cyrus Daboo. This software is Freeware for personal and academic use. It may be freely distributed provided this ÔRead MeÕ file accompanies the plug-in. Commercial users may try out this software for 30 days after which a Shareware fee of $15 per copy will be payable for continued use. Users wishing to include it with their own commercial products must negotiate a fee with the author. Please send Shareware fees to the address below - an invoice will be provided on request. ______________________ BUGS Please report all bugs to Cyrus Daboo: mail: Cyrus Daboo, 64 Mulberry Close, Cambridge CB4 2AS. UK. phone: +44 1223 328240 e-mail: cd102@phy.cam.ac.uk