Thumbnail/Preview Alpha Channels

Hi there,
I'd like to be able to script/set the Bridge to browse images by Alpha Channel rather than RGB (I have lots of images with similar RGB but unique Alphas).
Does anyone know if this would be possible or where to start?
Thanks in advance for any help.
Karl

Hi Andrew,
Thanks for your suggestion; however in the situation I'm working in it's important that the images themselves are not changed, I just want to be able to switch the 'view' to Alpha mode.
Karl

Similar Messages

  • Alpha channels really have messed up thumbnails and Previews

    In AP2 I use to have to put a blank (all white) layer above any alpha channels so the thumbnails would build properly. Now in Ap3 The thumbnails and Previews are screwed up so they are totaly unrecognizable or not showing up at all even after deleting and re generating them. I've placed a bug report with apple but I need a solution or a work around fast.
    Thanks to all who help.

    When you look at the songs in your Music library in iTunes, does the artist name have any punctuation in the artist column?
    I know with some MP3's I ripped from CD before iTunes was available, I had put both title and artist in the title field, and until I corrected them they didn't show up correctly on my iPod.

  • Why can't I see the Finder thumbnails for .mov files with alpha channels?

    Ever since I upgraded to Mavericks I haven't been able to see the thumbnail for or preview using spacebar any .MOV clips that contain alpha channels in Finder. PSDs and PNGs with alpha channels are fine, and I can still see their thumbnails and previews, it's just .MOV clips with alpha. Here are a couple screenshots:
    Most of these clips are using a PNG codec, but I converted on to the Animation codec and tested it in After Effects to make sure it kept the alpha channel and it did, but the same thumbnail error persists.
    Any idea why this might be or how to fix it?
    27" iMac late 2012
    1TB Fusion
    NVIDIA GeForce GTX 680MX 2048 MB
    16GB RAM
    OS X Mavericks
    Thanks.

    ok, have copied the photos again from the memory card and hey presto, it all works fine.  So in summary...for RW2 files from GF1 camera, I have no thumbnail images, couldn't view in Preview, and neither Quickview nor Coverview were working.  Ran the bit of code provided at "https://discussions.apple.com/message/18369759#18369759" (thanks to Snoop Dogg) and then recopied the photos onto my Mac (only required for photos copied since upgrading to Lion, everything from before the upgrade is fine anyway).
    Hope others find this helpful.

  • Alpha channel showing in preview

    If I import a .psd file that has an alpha channel, it shows in the preview. Does anyone know how I can eliminate the alpha channel in the preview. iView has a specific option for this but I can't seem to find anything similar in Aperture.

    You have to open the .psd file in photoshop and add a empty channel as the first one in the channel list.

  • Issue (aka bug):  File compatibility and alpha channels

    When I enable file compatibility mode on photoshop (so that previews and thumbnails show up), the thumbnail and preview will be wrong when there's an alpha channel in the channel palette. Specifically, the thumbnail will be masked by the top-most alpha channel in the channel palette. Consequently, there is sort of a work-around--if you create a plain white alpha channel and make sure it's the top-most alpha channel in the palette, then the preview and thumbnail come out fine. Luckily, this requires negligible extra memory.
    If there's no alpha channel or I don't save alpha channels, the preview/thumbnail looks fine.
    In spite of the work-around, a fix would be nice. It'd also be nice if there was a way to have a preview/thumbnails in Finder without the large memory penalty of compatibility mode.
    Bart

    Yes, everything in Bridge works great. However, the search function in Bridge is SLOW and a bit flaky (same problem on the Windows side as well) so I like to use spotlight instead for searching. Additionally, I like to use iPhoto to create collections of images that will contain photoshop files as well as others.
    For now, it is workable for me to just use compatibility mode in photoshop and make sure all images with alpha channels have an all-white alpha channel at the top of the stack. The file size penalty is tolerable for now. If Apple ever fixes things on their end, then it's a simple script to convert my psd files back again.
    Bart

  • How can I see the alpha channel in the channels palette?

    Hello, mi format plugin loads a rgba image. I see it with transparency, that's ok, but when I go to the channels tab I only see 4 items (RGB, Red, Green and Blue).
    How can I see the alpha channel of my file in the channel tab?
    Thanks!

    OK, something must be wrong... but I don't find it!
    That's my whole code (resumed). I ommit some code (saving file code (not used) or main function, where I only call te "DoSomething" functions. You can see that I use layers. The DoReadContinue function is only used to show the preview.
    In the DoReadStart function I set the parameters for the layers (and the preview), and I fill the "data" and "layerName" params in the DoReadLayerContinue function. I hope you can understand the code!
    const int32 IMAGE_DEPTH = 32;
    SPBasicSuite * sSPBasic = NULL;
    SPPluginRef gPluginRef = NULL;
    FormatRecord * gFormatRecord = NULL;
    intptr_t * gMxiInfoHandle = NULL;
    MXIInfo* gMxiInfo = NULL;
    int16 * gResult = NULL;
    #define gCountResources gFormatRecord->resourceProcs->countProc
    #define gGetResources   gFormatRecord->resourceProcs->getProc
    #define gAddResource    gFormatRecord->resourceProcs->addProc
    CmaxwellMXI* cMax;
    static void DoReadPrepare (void){
        gFormatRecord->maxData = 0;
    static void DoReadStart(void){
        char header[2];
        ReadScriptParamsOnRead (); // override params here
      if (*gResult != noErr) return;
        // Read the file header
        *gResult = SetFPos (gFormatRecord->dataFork, fsFromStart, 0);
        if (*gResult != noErr) return;
        ReadSome (sizeof( header ) * 2, &header);
        if (*gResult != noErr) return;
      // Check the magic number for avoid no-mxi files
        int headerID = CheckIdentifier (header);
        if( headerID != HEADER_MXI ) *gResult = formatCannotRead;
      if (*gResult != noErr) return;
      // The file is OK. Let's continue to obtain the data of the image.
      cMax = new CmaxwellMXI( 0 );
      strlen((char*)gFormatRecord->fileSpec->name);
      gMxiInfo->filename = _strdup((char *)gFormatRecord->fileSpec->name + 1);
      bool res = cMax->getMXIIInfo(
                    (const char*)gMxiInfo->filename,
                    gMxiInfo->width, gMxiInfo->height,
                    gMxiInfo->burn, gMxiInfo->monitorGamma, gMxiInfo->iso,
                    gMxiInfo->shutter, gMxiInfo->fStop, gMxiInfo->intensity,
                    gMxiInfo->scattering,
                    gMxiInfo->nMultilightChannels, gMxiInfo->lightNamesList,
                    gMxiInfo->availableBuffersMask,
                    gMxiInfo->widthPreview, gMxiInfo->heightPreview,
                    gMxiInfo->bufferPreview);
      if(!res) return;
      // Check the available extra buffers
      int count = 0;
      if( gMxiInfo->availableBuffersMask & CmaxwellMXI::ALPHA_BUFFER ){
        // We will use that string to obtain later the desired extra buffer.
        gMxiInfo->extraBuffersList[count] = "ALPHA";
        gMxiInfo->hasAlpha = true;
        count++;
      else{
        gMxiInfo->hasAlpha = false;
      gMxiInfo->nExtraBuffers = count;
      switch( IMAGE_DEPTH ){
      case 8:
          gMxiInfo->mode = plugInModeRGBColor;
          break;
      case 16:
          gMxiInfo->mode = plugInModeRGB48;
          break;
      case 32:
          gMxiInfo->mode = plugInModeRGB48; //96 gives me an error
          break;
      // SET UP THE DOCUMENT BASIC PARAMETERS.
      VPoint imageSize;
      if( gFormatRecord->openForPreview ){
        // Preview always RGB8.
        imageSize.v = gMxiInfo->heightPreview;
        imageSize.h = gMxiInfo->widthPreview;
        gFormatRecord->depth = 8;
        gFormatRecord->imageMode = plugInModeRGBColor;
        gFormatRecord->planes = 3;
        gFormatRecord->loPlane = 0;
        gFormatRecord->hiPlane = 2;
        gFormatRecord->colBytes = 3;
        gFormatRecord->rowBytes = imageSize.h * gFormatRecord->planes;
        gFormatRecord->planeBytes = 1;
      else{
        // Configure the layers. All RGBA32.
        imageSize.v = gMxiInfo->height;
        imageSize.h = gMxiInfo->width;
        gFormatRecord->depth = IMAGE_DEPTH;
        gFormatRecord->imageMode = gMxiInfo->mode;
        gFormatRecord->layerData =
            2 + gMxiInfo->nMultilightChannels + gMxiInfo->nExtraBuffers;
        gFormatRecord->planes = 4; // RGBA.
        gFormatRecord->loPlane = 0;
        gFormatRecord->hiPlane = 3;
        gFormatRecord->planeBytes = IMAGE_DEPTH >> 3;
        gFormatRecord->rowBytes = imageSize.h * gFormatRecord->planes * ( IMAGE_DEPTH >> 3 );
        gFormatRecord->colBytes = gFormatRecord->planes * ( IMAGE_DEPTH >> 3 );
        gFormatRecord->transparencyPlane = 3;
        gFormatRecord->transparencyMatting = 1;
        gFormatRecord->blendMode = PIBlendLinearDodge;
        gFormatRecord->isVisible = true;
      SetFormatImageSize(imageSize);
      gFormatRecord->imageHRes = FixRatio(72, 1);
      gFormatRecord->imageVRes = FixRatio(72, 1);
      VRect theRect;
      theRect.left = 0;
      theRect.right = imageSize.h;
      theRect.top = 0;
      theRect.bottom = imageSize.v;
      SetFormatTheRect(theRect);
      // No resources for now.
      if (sPSHandle->New != NULL) gFormatRecord->imageRsrcData = sPSHandle->New(0);
      gFormatRecord->imageRsrcSize = 0;
        return;  
    /// Called for prewiew only.
    static void DoReadContinue (void){
        // Dispose of the image resource data if it exists.
        DisposeImageResources ();
      if( gFormatRecord->openForPreview ){   
        VPoint imageSize = GetFormatImageSize();
        gFormatRecord->data = gMxiInfo->bufferPreview;
          if (*gResult == noErr) *gResult = gFormatRecord->advanceState();
        if( gFormatRecord->data != NULL ){
          delete[] (Crgb8*)gMxiInfo->bufferPreview;
          gMxiInfo->bufferPreview = NULL;
          gFormatRecord->data = NULL;
      // De momento nos olvidamos de los icc profiles [TODO]
        //DoReadICCProfile ();
    static void DoReadFinish (void)
        // Dispose of the image resource data if it exists.
        DisposeImageResources ();
        WriteScriptParamsOnRead (); // should be different for read/write
      // write a history comment
        AddComment ();
      // Clean some memory.
      if( gMxiInfo->lightNamesList != NULL ){
        for( unsigned int i = 0; i < gMxiInfo->nMultilightChannels; i++){
          if( gMxiInfo->lightNamesList[i] != NULL ){
            delete[] gMxiInfo->lightNamesList[i];
            gMxiInfo->lightNamesList[i] = NULL;
        delete[] gMxiInfo->lightNamesList;
        gMxiInfo->lightNamesList = NULL;
      if( gMxiInfo->bufferPreview != NULL ){
        delete[] gMxiInfo->bufferPreview;
        gMxiInfo->bufferPreview = NULL;
      if( gMxiInfo->filename != NULL ){
        delete[] gMxiInfo->filename;
        gMxiInfo->filename = NULL;
      if( cMax != NULL ){
        delete cMax;
        cMax = NULL;
    static void DoReadLayerStart(void){
      // empty
    static void DoReadLayerContinue (void){
      int32 done;
        int32 total;
      VPoint imageSize = GetFormatImageSize();
      // Set the progress bar data
      done = gFormatRecord->layerData + 1;
      total = gMxiInfo->nMultilightChannels + gMxiInfo->nExtraBuffers + 2;
      // Dispose of the image resource data if it exists.
      DisposeImageResources ();
      uint32 bufferSize = imageSize.v * gFormatRecord->rowBytes;
      int nPixels = gMxiInfo->width * gMxiInfo->height;
      char* lightName = NULL;
      // SET THE BLACK BACKGROUND
      if( gFormatRecord->layerData == 0 ){
        gFormatRecord->data = (void*)new byte[bufferSize];
        for( int i = 0; i < nPixels; i++ ){
          ((float*)gFormatRecord->data)[ i * 4 ]     =
          ((float*)gFormatRecord->data)[ i * 4 + 1 ] =
          ((float*)gFormatRecord->data)[ i * 4 + 2 ] = 0.0;
          ((float*)gFormatRecord->data)[ i * 4 + 3 ] = 1.0;
        // Set the layer name.
        gFormatRecord->layerName = new uint16[64];
        gFormatRecord->layerName[0] = 'B';
        gFormatRecord->layerName[1] = 'a';
        gFormatRecord->layerName[2] = 'c';
        gFormatRecord->layerName[3] = 'k';
        gFormatRecord->layerName[4] = 'g';
        gFormatRecord->layerName[5] = 'r';
        gFormatRecord->layerName[6] = 'o';
        gFormatRecord->layerName[7] = 'u';
        gFormatRecord->layerName[8] = 'n';
        gFormatRecord->layerName[9] = 'd';
        gFormatRecord->layerName[10] = '\0';
      // LOAD THE LIGHT LAYERS
      else if( gFormatRecord->layerData < gMxiInfo->nMultilightChannels + 1 ){
        void* lightBuffer = NULL;
        void* alphaBuffer = NULL;
        byte foob;
        dword food;
        // Get the light buffer.
        bool res = cMax->getLightBuffer(
                               (char*)gMxiInfo->filename,
                               gFormatRecord->layerData - 1, IMAGE_DEPTH,
                               lightBuffer,
                               gMxiInfo->width, gMxiInfo->height, lightName);
        if(!res){
          *gResult = readErr;
          return;
        if( gMxiInfo->hasAlpha ){
          // Get the alpha buffer.
          res = cMax->getExtraBuffer(
                                (char*)gMxiInfo->filename,
                                "ALPHA", IMAGE_DEPTH, alphaBuffer,
                                food, food, foob);
          if(!res){
            *gResult = readErr;
            return;
        else{
          alphaBuffer = (void*)new float[ gMxiInfo->width * gMxiInfo->height * 3 ];
          for( int i = 0; i < nPixels; i++ ){
            // Only need to set the red channel.
            ((float*)alphaBuffer)[ i * 3 ] = 1.0;
        // Put them together.
        gFormatRecord->data = (void*)new byte[bufferSize];
        for( int i = 0; i < nPixels; i++ ){
          ((float*)gFormatRecord->data)[ i * 4 ]     = ((float*)lightBuffer)[ i * 3 ];
          ((float*)gFormatRecord->data)[ i * 4 + 1 ] = ((float*)lightBuffer)[ i * 3 + 1 ];
          ((float*)gFormatRecord->data)[ i * 4 + 2 ] = ((float*)lightBuffer)[ i * 3 + 2 ];
          ((float*)gFormatRecord->data)[ i * 4 + 3 ] = ((float*)alphaBuffer)[ i * 3 ];
        delete[] (float*)lightBuffer;
        delete[] (float*)alphaBuffer;
        // Set the layer name.
      //LOAD THE EXTRA CHANNELS
      if( ... ){
      //READ THE RENDER BUFFER
      if( ... ){
      // User can abort.
      if (gFormatRecord->abortProc()){
          *gResult = userCanceledErr;
          return;
      // Commit the layer.
      if (*gResult == noErr) *gResult = gFormatRecord->advanceState();
      // Update the progress bar.
      (*gFormatRecord->progressProc)( done, total );
      // Free memory.
      if( gFormatRecord->data != NULL ){
        delete[] (float*)gFormatRecord->data;
        gFormatRecord->data = NULL;
      if( lightName != NULL ){
        delete[] lightName;
        lightName = NULL;
    static void DoReadLayerFinish (void)
      // Nothing to do.
    And that's the image that I obtain loading a 8 layer image:
    The layers have transparency (when I set "transparencyPlane" to  -1, or 0, or 1, or 2, or 3, or 4....., I got the same result!). The blending mode is still "normal". I had set it to "linear dodge" The "isVisible" param works OK.
    Alpha 1 is still black.
    Is possible that I need to set something in the .r file? I had to add "FormatLayerSupport { doesSupportFormatLayers }," to manage layers, for instance.

  • Alpha channel problem with Pixel Bender blendShaders

    I'm using Pixel Blender to try and create a blend shader for a Flex 4.0 app.
    It looks like this:
    <languageVersion : 1.0;>
    kernel PixelReverse
    <   namespace : "com.abc.def.filters";
        vendor : "EdAlive";
        version : 1;
    >
        input image4 foreground;
        input image4 background;
        output pixel4 dst;
        void
        evaluatePixel()
            pixel4 fgPixel = sampleNearest(foreground, outCoord());
            pixel4 bgPixel = sampleNearest(background, outCoord());
            if((bgPixel.r == 0.0) && (bgPixel.g == 0.0) && (bgPixel.b == 0.0) && (bgPixel.a == 0.0)){
                bgPixel.r = bgPixel.g = bgPixel.b = 1.0;
            dst.r = 1.0 - abs(fgPixel.r - bgPixel.r);
            dst.g = 1.0 - abs(fgPixel.g - bgPixel.g);
            dst.b = 1.0 - abs(fgPixel.b - bgPixel.b);
            dst.a = fgPixel.a;
    It looks correct in the Pixel Bender preview window.
    When I use it in a Flex project with proper 32 bit png images, the filter seems to work correctly, except it sets any partial alpha value on the images to fully opaque (like a 1 bit alpha channel).
    Because the image preview looks correct in Pixel Bender, I'm assuming it's a problem with the bitmap data that Flex is passing to the blend shader filter.
    I tried changing the filter to simply output a copy of the foreground firstly, and the background second, to test.
    When returning a copy of the foreground, the imags weren't visible on stage, either because the pixels were transparent or because it was really returning the background pixels, camouflaging the images.
    When returning a copy of the background, the images were just black rectangles.
    The images are being place on stage programmatically inside an mx Module, and having their depth property set.
    They also have draggable behaviour, where the current drag object is layered above all else during the drag.
    I'm actually using a subclass of mx.controls.Image, but am simply setting the source property with preloaded bitmap data, so I'm am fairly sure the subclass is not a factor.
    I hope this is enough information for someone to be able to provide some help.
    Thanks

    Please make sure you have installed the latest graphics drivers, from http://www.nvidia.com/Download/index.aspx?lang=en-us, for your graphics card.

  • Question: Quick Look in Finder; problems with alpha channels

    Hi
    "Quick look" in Finder is great for quick presentations of a folders selected contents but it only works with images that contains no alpha channels or masks. Is there any way to work around this to display say PhotoShop documents with alpha channels? Or any plug-ins/applications that can help?
    thanks.

    This has been broken forever in OS X, and I don't know why, because it used to work just fine. I suspect the engineers did something to QuickTime that causes this problem, but it has been borked for so long I don't remember when the ability to correctly display files went wrong. I just remember that once upon a time all sorts of things from Apple worked correctly in displaying such files, but pretty much nothing does now. This includes the Finder, Preview, QuickLook, and various third-party image browsers that use Apple's own system level image handling abilities, such as VitaminSee or CocoaViewX. When I need to actually see what's there, I browse with Adobe's Bridge.
    Francine
    Francine
    Schwieder

  • NSBitmapImageRep - how can I remove or reverse an alpha channel from tiff?

    Below is some code I cobbled together to save a square preview of an image. I am looking to figure out how to remove or inverse an alpha channel mask from a tiff image, and could really use some help....
    // I have been using 256.0 and 0.4 for the last 2 arguments, though feel free test with whatever.
    - (NSString *)savePreview: (NSString *)filePath: (NSString *)saveFilePath: (NSString *)previewSize: (NSString *)compressionRatio {
    NS_DURING
    NSAutoreleasePool *memoryPool = [[NSAutoreleasePool alloc] init];
    NSImage *myImage = [[NSImage alloc] initWithContentsOfFile: filePath];
    if (myImage == nil) {
    [myImage release];
    NSLog(@"! Error loading image");
    return @"! Error loading image";
    NSImageRep *myRep = [[myImage representations] objectAtIndex: 0];
    float hres = [myRep pixelsWide]/[myImage size].width;
    float vres = [myRep pixelsHigh]/[myImage size].height;
    float newWidth = [previewSize floatValue];
    float newHeight = newWidth;
    NSImage *thumbImage = [[NSImage alloc] initWithSize: NSMakeSize(newWidth, newHeight)];
    NSAffineTransform *at = [NSAffineTransform transform];
    [myImage setScalesWhenResized: YES];
    float heightFactor = newHeight/[myImage size].height;
    float widthFactor = newWidth/[myImage size].width;
    float scale;
    if(heightFactor > widthFactor) {
    scale = widthFactor;
    } else {
    scale = heightFactor;
    [at scaleBy: scale];
    [thumbImage lockFocus];
    [[NSGraphicsContext currentContext] setImageInterpolation: NSImageInterpolationHigh]; // NSImageInterpolationNone, NSImageInterpolationLow, NSImageInterpolationHigh
    [myImage setSize: [at transformSize: [myImage size]]];
    [myImage compositeToPoint: NSMakePoint((newWidth-[myImage size].width)/2 , (newHeight-[myImage size].height)/2) operation: NSCompositeCopy];
    NSBitmapImageRep *bitmapImageRep = [[NSBitmapImageRep alloc] initWithFocusedViewRect: NSMakeRect(0, 0, [thumbImage size].width, [thumbImage size].height)];
    [thumbImage unlockFocus];
    [myImage release];
    [thumbImage release];
    NSData *bitmapData = nil;
    NSNumber *factor = [NSNumber numberWithFloat: [compressionRatio floatValue]]; // The compression factor. Used only for JPEG files. The value is a float between 0.0 and 1.0, with 0.0 being the lowest and 1.0 being the highest. It’s set when reading in and used when writing out.
    NSDictionary *props = [NSDictionary dictionaryWithObject: factor forKey: NSImageCompressionFactor];
    bitmapData = [bitmapImageRep representationUsingType: NSJPEGFileType properties: props];
    [bitmapData writeToFile: saveFilePath atomically: YES];
    [bitmapImageRep release];
    [memoryPool release];
    return @"YES";
    NS_HANDLER
    NSLog(@"Exception occured : %@", localException);
    return @"NO";
    NS_ENDHANDLER
    }

    <bump>

  • Alpha Channel Question

    Hello,
    I have an animation with a white drop shadow on it that I animated in Aftereffects.  I export the file from Aftereffects and no matter what I try the white drop shadow shows up as a dark shadow every time in Premiere as if it's matted with black.  So I'm wondering if there is a setting I'm missing or something I need to do differently when importing to Premiere, or even when exporting from aftereffects, although I've exporting it several different way so far to no avail.
    So here is what I have,
    I'm using Adobe CS4 for AE and Premiere, on Windows 7
    When I export from AE I'm using the color setting for unmatted (and I've tried it matted with black too just for fun, clearly that didn't work out for me:)
    I've tried it as an avi and as a mov file too.
    Sooo, in case your answer is for me to use Dynamic Link, I can't get that to work either.  And I'm sure that is just user error since I've never used it before.  I can get the aftereffects sequence to show up in my project files in Premiere, I can even get the animation to show up and play in the preview monitor, but when I put it on my Premiere sequence over the background it doesn't show up, just seems like a blank layer.
    Any ideas?
    Nina

    Thanks for your replies!  So I'm not very good at explaining myself.  I did export (and by export i mean, make movie by adding it to the render queue) the file as both of you are recommending.  As a movie file, with an alpha channel, all one file.  The reason I was trying to do it separate next was because it wasn't displaying properly that way.
    Finally, what I did as a work around, is just export the background I was using from premiere, import it into aftereffects, Put everything together in aftereffects and then render the finished file without using an alpha at all.  In pic #1 so you can see how premiere cs4 won't properly display an animation with a white shadow behind it if it's imported with an alpha channel and placed on top of a background.  #2 shows how it was supposed to look.. how it looked once I put everything together in Aftereffects instead.  I just thought there should be a way to fix my problem without the extra step of exporting the background.  But I don't think there is.
    However,
    THANK YOU for your replies and trys!!
    (Oh yeah I should also mention that I did try, PSD sequence, Quicktime rgb+alpha, Lossless with alpha etc.. none of which seemed to work for what I was trying to do.)

  • Probs mit Alpha-Channel

    hallo,<br /><br />ich bin gerade dabei ein Plugin für Photoshop 6.0 zu schreiben und habe ein Problem mit dem Alpha-Channel. Wenn ich in Photoshop für den Alpha-Channel einen Wert von z.B. 172 eintrage, dann wird in meinem File ein Wert von 171 gespeichert!<br />Hier poste ich mal den Code, den ich verwende um etwas zu schreiben (ich ändere das SimpleFormat-Beispiel ab)<br /><br />FileHeader header;<br /><br />    if (gResult != noErr) return;<br />     <br />     if (!TSC ((Boolean)(!CheckForServices (globals)))) return;<br />     <br />     gResult = SetFPos (gStuff->dataFork, fsFromStart, 0);<br />     <br />     header.Width=gStuff->imageSize.h;<br />     header.Height=gStuff->imageSize.v;<br />     header.Identification=1331;<br /><br />     if(gStuff->imageMode==plugInModeRGBColor && gStuff->planes==3)<br />          header.BitCount=24;<br />     else if(gStuff->imageMode==plugInModeRGBColor && gStuff->planes==4)<br />          header.BitCount=32;<br />     else<br />     {<br />          gResult=formatCannotRead;<br />          return;<br />     }<br /><br />     WriteSome (globals, sizeof (FileHeader), &header);<br />     <br />     if (gResult != noErr) return;<br /><br />     BufferID buffer;<br /><br />     gPixelBuffer = 0;<br />     AllocateBuffer(header.Width*header.BitCount/8, &buffer);<br />     gPixelBuffer = buffer;<br />     gPixelData = LockBuffer (gPixelBuffer, FALSE);<br /><br />     gStuff->data=gPixelData;<br /><br />     if(header.BitCount==24)<br />     {<br />          gStuff->loPlane=0;<br />          gStuff->hiPlane=2;<br />          gStuff->colBytes=3;<br />          gStuff->rowBytes=3*header.Width;<br />          gStuff->planeBytes=1;<br />          <br />          for(int y=0;y<header.Height;y++)<br />          {<br />               gStuff->theRect.top = y;<br />               gStuff->theRect.left = 0;<br />               gStuff->theRect.bottom = y+1;<br />               gStuff->theRect.right = header.Width;<br />               AdvanceState ();<br />               WriteSome (globals,header.Width*header.BitCount/8,gPixelData);     <br />          }<br /><br />          if (gPixelBuffer != 0)<br />          {     <br />               FreeBuffer (gPixelBuffer);<br />               gPixelBuffer = 0;<br />               gPixelData = 0;     <br />          }<br />     }<br />     else if(header.BitCount==32)<br />     {<br />          gStuff->loPlane=0;<br />          gStuff->hiPlane=3;<br />          gStuff->colBytes=4;<br />          gStuff->rowBytes=4*header.Width;<br />          gStuff->planeBytes=1;<br />          <br />          for(unsigned int y=0;y<header.Height;y++)<br />          {<br />               gStuff->theRect.top = y;<br />               gStuff->theRect.left = 0;<br />               gStuff->theRect.bottom = y+1;<br />               gStuff->theRect.right = header.Width;<br />               AdvanceState ();<br />               WriteSome (globals,header.Width*header.BitCount/8,gPixelData);     <br />          }<br /><br />          if (gPixelBuffer != 0)<br />          {     <br />               FreeBuffer (gPixelBuffer);<br />               gPixelBuffer = 0;<br />               gPixelData = 0;     <br />          }<br />     }<br /><br />     gStuff->data = NULL;

    rdl33 wrote:
    Alpha Channel works well with solid colours but leaves a lot of "blotches" in textured surfaces. Apple forgot to include an Eraser. Do we have to move the graphic to Photoshop to finish the job?
    There are certainly images where only Photoshop or another image editor can do a clean job. However, depending on the shape of the area you want to remove, you may be able to simulate it by adding geometric shapes that cover the bad areas. There are other tricks, like taking screen shots or copying part of the picture using Preview, and so on. It really depends on the image and the shape.
    When I need a good image editor I use Photoshop. When I want a free one to install temporarily on a computer that does not belong to me, I use gimp out of old habit, but there are other ones out there.

  • Alpha channel issues

    Greetings,
    I'm trying to create a lower third using a still image that I created from a video clip using Quicktime Conversions. I then import it into FCP, drag it to a sequence and then add livetype text to it. In the preview mode on my main sequence when played is fine, but when I render it the alpha channel disappears and a black background replaces my video with the lower third material still there. What happened to my alpha channel? Is there a problem or a bug in FCP 5.1.1? I'm bewildered.
    Thanks,
    Jordan

    Editmojo,
    I exported just the text from Livetype. I'm trying to create a customized lower third, but everytime I render the lower third nested sequence after I have added it to the main sequence a black background takes over with the lower third media there. Ordinarily, when you follow the instructions that I did it automatically keys over the video behind it.What happened? I did not have this problem with FCP 4.5. Is there an issued with FCP 5.1? I just spoke to a tech at Digital Juice regarding the use of their animations and he said that there was an issue with FCP 5.1 when it came to alpha channels. Is that the case? Would the update solve the problem?
    Thanks,
    Jordan

  • Motion 5, Importing a PNG, Alpha Channel Wonky

    When I import a PNG into motion the alpha map gets brighter— brighter than it looks in photoshop, preview, pixelmator, etc.
    Then in motion if I just export the project as a movie, the alpha channel values seem to return to normal in the MOV file. It's comforting to know that the final product will turn out ok, but how am I supposed to know what it will look like wihtout having to export the project everytime I want to see what it looks like. Note: I don't ever remember encountering any problems like this with Motion 4.
    Any help appreciated. Thanks.

    Very top right of the Motion interface, 4th icon from the right, check those settings.

  • Video with alpha channel causing frame size distortion

    I have a lower-third which I built in AE. The content only occupies about 2/3 the width of the frame however I made sure I exported it at the full frame size as the rest of the video in my Premiere project. Also, I exported it as a quicktime movie with PNG settings to incl. the alpha channel.
    When I import it into Premiere CS4, I drop it in on the Video 2 layer over Video 1 which is the main VT and in the preview, it all seems to be appearing as you'd expect. If I hit enter to start rendering, when it finishes I find that the lower third has been stretched the full width of the frame and additionally, Video 1 has been stretched too. I know there's an option in Preferences > General to default everything to the frame size of the sequence but having that tickbox on or off doesn't make any difference.
    Does anyone have any ideas what's causing it?

    Windows. Alas neither of those options worked. In the end, it was terribly convoluted but I had to export the footage from Premiere without a graphics, then import the video into After Effects and layer my comp over it - then export the final version from AE rather than Premiere. It seemed a very back-to-front way of doing things but if it works...

  • Automator or Applescript using png files with alpha channel

    I have hundred of png files with alpha channel.
    I want to suppress alpha channel.
    How can i do it using Automator or Applescript ?
    Thank you very much.

    You can use the free command line image processing tool ImageMagick in your Applescripts or Automator workflows, as well as from a Terminal shell.
    You can download ImageMagick from http://www.imagemagick.org, but Cactuslab has simplified installation by putting together an installer package. It’s available at  http://cactuslab.com/imagemagick/. Download the package and double-click on it. Follow the instructions to install. It will install ImageMagick into /opt/ImageMagick and add it to your $PATH by creating a file in /etc/paths.d/. Restart your computer for the changes to take effect.
    The two ImageMagick commands we’re concerned with are “convert” and “mogrify”. Convert is more efficient for multiple and piped operations on the same image file, and mogrify is more efficient for batch processing. Generally speaking, convert will output a file separate from the input file. Unless a path is specified, mogrify will overwrite the input file with the output file. An important distinction.
    You can perform various operations on the alpha channel using arguments after either the convert or mogrify command. Two of the available arguments are:
    -alpha off - Disables the image's transparency channel. Does not delete or change the existing data, just turns off the use of that data.
    -alpha remove - Composite the image over the background color.
    Also of use are the -flatten and -background options:
    -flatten - overlay all the image layers into a final image and may be used to underlay an opaque color to remove transparency from an image.
    -background - sets the background color.
    Start off using the convert command with a single image to see the effect and adjust to your liking. Once you’ve achieved the desired outcome, then use the mogrify command to batch process the chosen images.
    Before getting into how to use Automator or Applescript in your workflow, use Terminal and the command line to see the effect on a single image. Copy one image to your ~/Desktop. In Terminal change the directory to ~/Desktop by typing the following command and pressing the Enter key:
    cd ~/Desktop
    Then choose the option you are looking for, -alpha remove for instance, type the following command and press the Enter key:
    convert input-photo.png -alpha remove output-photo.png
    You can check the alpha channel (transparency) and background in the Preview app, go View > Show Image Background from the menu bar.
    Once you’re ready to batch proces, place all the photos you want to convert with the same command into one folder. Copy the folder to your ~/Desktop. Let’s assume you’ve labeled the folder “InPhotos”. It’s prudent to manipulate copies in case something goes amiss. In that event you can copy the folder with the originals again and start over. Create a new empty folder on your ~/Desktop and call it “OutPhotos”. Let’s also assume your home directory is called “Me”. The following command will process the photos from the InPhotos folder and put them in the OutPhotos folder:
    mogrify -alpha remove -path /Users/me/Desktop/OutPhotos/ /Users/me/Desktop/InPhotos/*png
    According to Apple Technical Note TN2065:
    "when you use just a command name instead of a complete path, the shell uses a list of directories (known as your PATH) to try and find the complete path to the command. For security and portability reasons, do shell script ignores the configuration files that an interactive shell would read"
    So, you need to use the full path to to ImageMagick commands, unlike in the shell where you can just use the command name.
    To batch process using Automator, use the “Run Shell Script” action (note: retain the single space at the beginning of the last line):
    /opt/ImageMagick/bin/mogrify \
    -alpha remove \
    -path /Users/Me/Desktop/OutPhotos/ \
    /Users/Me/Desktop/InPhotos/*png
    To batch process using Script Editor (Applescript), use the “do shell script” command:
    do shell script "/opt/ImageMagick/bin/mogrify -alpha remove -path /Users/pd/Desktop/OutPhotos/ /Users/pd/Desktop/InPhotos/*png"
    Further info on ImageMagick:
    http://www.imagemagick.org/script/command-line-options.php#alpha
    http://www.imagemagick.org/Usage/masking/#remove
    http://www.imagemagick.org/index.php
    http://www.imagemagick.org/script/command-line-tools.php
    http://www.imagemagick.org/script/command-line-options.php
    Examples:
    The original PNG image:
    -alpha off:
    -alpha remove:
    -background black -flatten:
    -background blue -flatten:
    -channel alpha -evaluate Divide 2:
    -channel alpha -evaluate Divide 2 -background black -flatten:

Maybe you are looking for