Acrobat plugin to get separated colorvalues

Hello Everyone,
I try to "develop" a plugin that get the colorvalues of the current mouseposition and compare these values with colorvalues in a text file.
If the values are equal the name of the predefined color in the text-file will be shown in a message box.
I am sorry that this sounds quite simple but I am very new to the sdk. I try the samples, but I cannot find a Funktion/Method to get the CMYK or separated colorvalues of the current mouseposition in the document. I think that is possible, because of the "separation preview" in Acrobat.
1. Can anyone give me some hints about getting the separated colorvalues and spot colors?
2. Is it possible to extend the functionality of the "separation preview"?
Thanks for help.
Steve

Hi nkpmnwn,
I tried to render the given data as a bitmap, but that fails for me.
I solved my problem by the getting the PDEImage Data (raw data) from the PDF document and read out the first "pixel". I did this only for CMYK colorspaces.
Here is my code to print out the cmyk colorvalues from a PDEImage (Sometimes it is very slow):
    ASFixedRect bboxP;
    PDEElementGetBBox (pdeElement,&bboxP);
    // convert/cast  PDEElement to PDEImage
    PDEImage pdeImage = (PDEImage) pdeElement;
    //defining buffer size
    ASInt32 len = PDEImageGetDataLen(pdeImage);
    //create buffer
    ASUns8* data = (ASUns8*)ASmalloc(sizeof(ASUns8)*len);
    ASUns32* encodedLen;
    ASBool isEncoded = PDEImageDataIsEncoded(pdeImage, encodedLen);
    //Get the Colorspace of the image
    PDEColorSpace pdeColorSpace = PDEImageGetColorSpace(pdeImage);
    ASAtom colorSpaceName = PDEColorSpaceGetName(pdeColorSpace);
    const char* cs = ASAtomGetString(colorSpaceName);
    char c[200];
    sprintf(c,"Colorspace: %s Numberr %d", cs, colorSpaceName);
    // show the values in Acrobat
    // AVAlertNote(c);
    // write raw data to var - maybe very slow but it works for me
    PDEImageGetData (pdeImage,0,data);
    // init vars for cyan, magenta yellow and black
    int cyan,magenta,yellow,black;
// just for CMYK
if (colorSpaceName == ASAtomFromString("DeviceCMYK")){
        // read out the first pixel from raw data dump
        // looks really simple
        cyan = data[0];
        magenta = data[1];
        yellow = data[2];
        black = data[3];
        // I cannot remember why I did this????  Perhaps it is more accurate
        char colors[200];
        sprintf(colors,"Cyan: %2d Magenta: %2d Yellow: %2d Black: %2d", cyan, magenta, yellow, black);
        AVAlertNote(colors);
        // cast the int color values to float
        float c = (float)cyan;
        float m = (float)magenta;
        float y = (float)yellow;
        float k = (float)black;
        // getting the % CMYK values to compare it with photoshop values
        char colors2[200];
        sprintf(colors2,"Cyan: %f Magenta: %f Yellow: %f Black: %f", c/2.55, m/2.55, y/2.55, k/2.55);
        AVAlertNote(colors2);
sorry for my c programming style and syntax and my english too. :-)
I hope this helps?!

Similar Messages

  • Adobe Acrobat plugin keep crashing

    Every time I try to view a pdf in Firefox, I get an error message stating that the Adobe Acrobat plugin has crashed.

    '''mtnharry''' (or anyone else with this problem) maybe this will help:
    ===The Adobe Acrobat plugin has crashed===
    You can get this error when both Adobe Reader X and Adobe Acrobat are installed. You can resolve the problem as follows:
    #Open the Adobe Reader X application
    #Go to''' Edit''' -> '''Preferences'''
    #Under Categories (on the left) select '''General''' (near the top)
    #Click the button '''Select Default PDF Handler''' (at the bottom)
    #Under "Select Adobe Product", open the drop-down menu and click "Adobe Reader X".
    #Click "Apply", then close Adobe Reader X
    Ref: http://forums.mozillazine.org/viewtopic.php?p=11654747#p11654747

  • Calling a method in acrobat plugin as COM obj method

    Hi all,
    I want to call a method from my acrobat plugin as a COM objects method. Can i import i.e. add reference of plugin and call the perticular method which accepts two PDDoc parameters. For this I can use any platform (JS, C#, VB.net or anything). Please help me out.

    Consider I have exported the below plugin method via COM as Irosenth mentioned above, will I be able to see the highlighting happening visually in the PDF document which is currently active when I call this COM method from my C# Winform application?
    Also consider I have the Adobe Reader plugin license, will this functionality work in Reader?
    static ACCB1 void ACCB2 HighlightWord(void *data)
        DURING
        //Create a HiliteEntry object and set its attributes
        HiliteEntry hilite;
        hilite.offset = 3;
        hilite.length = 1;
         //Get the page number of the current page view
        AVDoc currentAVDoc = AVAppGetActiveDoc();
        PDDoc currentPDDoc = AVDocGetPDDoc(currentAVDoc);
        AVPageView currentPageView = AVDocGetPageView(currentAVDoc);
        ASInt32 pageNum = AVPageViewGetPageNum(currentPageView);
        //Highlight the tenth word
        PDPage pdPage = PDDocAcquirePage (currentPDDoc, pageNum);
        PDTextSelect textSelection = PDTextSelectCreateWordHilite(pdPage, &hilite, 1);
        AVDocSetSelection(currentAVDoc, ASAtomFromString("Text"), (void *)textSelection, true);
        AVDocShowSelection (currentAVDoc);
        PDPageRelease (pdPage);
        HANDLER
            AVAlertNote("Error highlighting word");
        END_HANDLER

  • Outdated Adobe Acrobat plugin

    Hello,
    since today, before opening a pdf document, I reach a dark page where I have to click to activate the Adobe Acrobat plugin. I have Adobe PDF Plug-In For Firefox and Netscape 10.1.5 and I knew it was outdated because I check regularly the "check plugins" page, it used to be simply paired with the yellow button and that was all. Today I get black screens whenever I try to view pdf in Firefox and I have to click on them to view pdf. From the Add-ons/Plugins control panel I know see a warning red writing above the plugin entry stating "Adobe Acrobat is known to be vulnerable and should be updated".
    I cannot seem to update because I have Adobe Acrobat X pro, and I don't want to install the reader or purchase the newest version of the pro suite. My Pc runs with WIndows XP SP3 and is quite old, all other plugins are up to date, including Java and I don't want to use the new FF built-in pdf reader.
    Any suggestion as how to disable the warnings and vulnerability screens or to update the plugin without installing Adobe Reader? Thank you

    The solution did not work for me. It had me download an msp file, but I do not have that software on my computer and do not want to download it. The description of msp on the internet sounds like downloading it will give more access to my computer than I want to give. I would appreciate clarification if I am being overly protective, but Mozilla Firefox, can you fix the problem so we can update from your button? Kindest regards, Robin

  • I have updated my Adobe Acrobat plugin three times today but the firefox plugin check says it is out of date, a problem as I repeatedly encounter "The Adobe Acrobat plugin has crashed" when I attempt to download pdfs.

    I am attempting to download pdf's from a library search on JSTOR. I can view the pdf but cannot download them as they say "The Adobe Acrobat plugin has crashed". I have been to the firefox plugin check and have updated Adobe Acrobat three times in the last hour, but it still says my plugin is not up to date. This leads me to believe that this may be the source of my crash errors.
    I updated Adobe Flash from the same firefox plugin check page and after one try it now says I am up to date, so my system is obviously accepting these updates.
    Help!!!!!

    The following solution is useful for people who have the full version of Acrobat 9, but are getting the error message "the Adobe Acrobat plugin has crashed". You probably want the features in the full version of Acrobat, but still need to be able to open PDF files from your Firefox browser.
    Go to Tools > Options > Applications. Scroll down and change all of the Adobe Acrobat files to open with Acrobat 9 (or whatever version you have) instead of "Use Adobe Acrobat (in Firefox)". This may not be as handy as having it use Acrobat inside the Firefox browser, but it will still let you open PDF files without having to uninstall the full version of Acrobat. Hope this helps.

  • Can't install acrobat plugin in Chrome?

    I cant get the acrobat plugin installed in Chrome. I deleted it from Chrome a while back but now i need it for an application that I use it every day.@

    Please see if how to make Acrobat Reader a Chrome plugin helps.

  • Acrobat Plugin and Outlook 2007 use smime certificate(s)

    Hi fellas!
    My question is more or less a verification for me whether I understand the function correctly:
    Signing/encrypting using i.e. a/the smime certificate is solely done by/via the acrobat plugin and is "handed over" from Outlook (in this case 2007) to the plugin which then controls the whole process.
    Right?
    There is no option to ask for a password to use the certificate(s) if they are configured for use with(in) Acrobat and/or the plugin like it is possible within Outlook alone.
    Greetings from Germany
    Harry

    I'm having all of those problems too and since moving from MobileMe to iCloud now I have to restart Outlook 2007 at least 10 times to get it to open correctly - VERY FRUSTRATING! Not sure im staying on the iCloud thing as it has all the same issue - and even more- than mobileMe... :-(

  • Acrobat Plugin Can be involved in Real-time processing

    Hi,
    I am implementing an acrobat plug-in solution for color separation and generation of PRN file for the given PDF file.
    Is the Plugin Architecture is good for the real time processing and RIPPIng?  I have a doubt like the Acrobat Process
    is involved in exectuing the each and every plugin HFT functions, is that would be fine for my plug-in to respond
    in realtime?
    Please suggest me.
    Thanks & Regards,
    Abdul Rasheed.

    First and foremost, Acrobat can NOT be used on a server, right?  So this is going to be a user-invoked process, correct?
    Beyond that, what do you thin would be a problem?
    From: Adobe Forums <[email protected]<mailto:[email protected]>>
    Reply-To: "[email protected]<mailto:[email protected]>" <[email protected]<mailto:[email protected]>>
    Date: Wed, 21 Sep 2011 07:29:28 -0700
    To: Leonard Rosenthol <[email protected]<mailto:[email protected]>>
    Subject: Acrobat Plugin Can be involved in Real-time processing
    Acrobat Plugin Can be involved in Real-time processing
    created by skrasheed<http://forums.adobe.com/people/skrasheed> in Acrobat SDK - View the full discussion<http://forums.adobe.com/message/3929688#3929688

  • Acrobat plugin won't load in Safari

    Running Snow Leopard. Didn't select using Acrobat plugin when Acrobat first installed. Now I cannot get Safari to recognize acrobat.plugin.
    I tried Acrobat:Help:Repair Acrobat installation but that didn't help. Tried deleting Safari plist preference file; no luck.
    How do I get Safari to recognize acrobat plugin?

    Are you running THe Computer in OSX.6?
    If so, are you running the computer in 64 bit mode?
    If so, are you Running Safari in 64 bit mode?using 64 bit version?
    If so? Then you need to switch Safari to 32bit mode. no plugin designed for 32 bit mode will work in 64 mode.
    if all the question are no or your using X.5.8 or lower then try doing Help > Repair installation.
    (Please note information is given by an Experienced User of Acrobat. I am not an employee of Adobe.)

  • Acrobat PlugIn vs. Reader - Ladezeit PDF-Datei

    Wir benutzten das Acrobat PlugIn in einer eigenen Win-Applikation. Es wird nur bei Bedarf geladen.
    Mit dem Acrobat PlugIn(4.0x) entstehen im Gegensatz zum Acrobat Reader lange Ladezeiten (bei gleicher Datei) wenn die 1. Seite einer grossen PDF-Datei (10MB) angezeigt werden soll (ca. 10s).
    Der Reader zeigt (Datei->laden) die gleiche Datei (1.Seite) in <1s an.
    Benutzt wird Visuall C++ mit der CPdf Wrapper Class und nach Initialisierung die Funktion CPdf.LoadFile(m_MyFile)
    Gibt es einen Tipp die Ladezeiten zu verringern? Das PDF-File ist schon optimiert mit dem Distiller erzeugt worden.
    Danke
    Ingo Stahl

    You said in your post:
    "However, web browsers are somewhat notorious for getting confused when their plugins change and update, so it's possible that when the two plugins updated, your selection as to which one is active has been corrupted, leaving neither plugin operational. You should be able to correct that with the options/preferences within your web browser itself."
    If this is true, that is why many users, and I am one of those, do not install both products on the same system. I do not dare to try installing Acrobat Reader because of this situation. When I tried it in the past, I got all kinds of strange error messages such that my ability to access PDFs from the web was severely hampered. I could not even start Acrobat itself at times. Why can't Adobe fix this problem?
    When you say changes preferences in the browsers, which ones in what browsers? If a Adobe could put together a list of browsers and their preferences that have to be changed, that might help.
    Ken Friedman

  • How to export acrobat plugin as a COM component

    Hi all,
    I want to export acrobat plugin and its methods as a COM objet so i could be possible to call methods from ouside of acrobat.
    Please give me any solution. I am not sure that whether it is possible or not. I am not getting any correct way to implement this.
    Please help me.

    Hi,
    maybe you should create com-object wich will call acrobat plugin via LoadLibrary ot GetModuleHandle?
    OR
    http://forums.adobe.com/thread/580494?tstart=0

  • Adobe Acrobat Plugin gHINSTANCE is undefined

    Adobe Acrobat Plugin gHINSTANCE is undefined
    Hi,
    Does anyone know the correct way to include “PIMain.c” in to a project so that gHINSTANCE is available. I’ve tried using GetModuleHandleA(NULL) but this doesn’t seem to give the correct result.
    If I try using #include “PIMain.c” on compilation I get a load of errors stating that things are already defined e.g. “RestorePlugInFrame already defined”.
    I’m trying to use gHINSTANCE to create an AVIcon object.
    Is there another way to access this object?
    Any help would be really appreciated.
    Regards
    Stuart

    There are many, many things to get right in building a plug-in and making a project. If you get them wrong, some will give errors, some will fail later, and many will make a plug-in that just doesn't load.
    So always start with an existing sample project, perhaps the STARTER project, and add your code rather than trying to reinvent this particular wheel.
    (If you are trying to use the plug-in API in your own EXE, give up, you cannot).

  • Acrobat plugin is missing.

    The Acrobat plugin does not show up in the Chrome plugins page. Neither does Adobe Reader plugin. (But I prefer Acrobat.)
        (Current plugins include AdobeAAMDetect, Adobe Flash Player, and AdobeExManDetect.)
    Same problem with previous (36 non-beta) version.
    Re-installed Acrobat CC 2014, but still neither Chrome plugin shows up.
    Re-installed Adobe Reader from get.adobe.com/reader, but still neither Chrome plugin shows up.
    Nobody on Google help forum has been able to suggest anything that works.
    Thanks in advance,
    Allen

    Hi Allen,
    What version of Chrome are you using?
    At my end it's:
    And the plugins:
    Do you have Admin privileges on the machine?
    Regards,
    Rave

  • How to read text and it's font details (Family and size) using Acrobat plugin?

    Hello,
           I have query about reading PDF, I wanted to extract text and it's font details (Family and size) using Acrobat plugin. How can I achieve that?
    Any suggestions are welcome.
    Thanks
    Rohit Shinde

    Look at the samples in the SDK around PDFEdit and the PDEdit APIs.

  • When I try to save a form as "Reader Extended PDF" in Acrobat Pro, I get an error message "This document could not be reader enabled".

    Hello,
    When I try to save a form as “Reader Extended PDF” in Acrobat Pro, I get an error message “This document could not be reader enabled”.
    The steps I’m following are described below:
    1.    Insert electronic signatures
    - In Tasks, click on “Add New Field -> Digital Signature”.
    - Move the square to the place where you want to put the signature and click.
    - Fill in the “field name” with the name of the person who has to sign here.
    - When it is done, click anywhere on the screen.
    - In Tasks, click on “Close Form editing”.
    - Go to menu “File -> Save as -> Reader Extended PDF ->Enable additional features”, click on “Save now”.
    - Fill in the file name and click on “Save”.
    2.    Save the Form
    - In Tasks, click on “Close Form editing”.
    - Go to menu “File -> Save as -> Reader Extended PDF ->Enable additional features”, click on “Save now”.
    - Fill in the file name and click on “Save”.
    I am using Adobe Acrobat Pro 10.0.0 on a W7 workstation
    Here's a screenshot of the problem.
    Thanks a lot.
    Gael

    Read the user manual that came w/the scanner and/or contact HP Support.
    http://support.apple.com/kb/PH14141 OS X Mavericks: Reset the printing system 
    http://support.apple.com/kb/HT3669 Printer and scanner software available for download 
    A scanner driver you may wish to consider:  VueScan Scanner Software

Maybe you are looking for