Digitizer eraser report OS X

  • 1
  • Problem
  • Updated 2 years ago
I have a problem, I want switch eraser/pen mode with standard digitizer report from Mac OS X System.

I send:
1) release current tip
2) exit proximity pen
3) enter proximity eraser 
4) set back tip state

in result:
Eraser mode switched in Autodesk Sketchbook, Mischief, but not in a Photoshop.

Can you provide me more info about photoshop specification, and communication between photoshop and digitizer devices.

Tnx.
Photo of Владислав Олегович

Владислав Олегович

  • 2 Posts
  • 0 Reply Likes

Posted 2 years ago

  • 1
Photo of Владислав Олегович

Владислав Олегович

  • 2 Posts
  • 0 Reply Likes

Photoshop CC 2015

 leftButtonRelease(descriptor, report, changes, buttonID, cursorX, cursorY); //1

        

        // Proximity event

        tabletData.proximity.vendorID               = 0x1E61;

        tabletData.proximity.tabletID               = 0x0712;

        tabletData.proximity.pointerID              = report.reportID;

        tabletData.proximity.deviceID               = 0x8000;

        tabletData.proximity.vendorPointerType      = 0x0802;

        tabletData.proximity.pointerSerialNumber    = 0;

        tabletData.proximity.uniqueID               = 0;

        tabletData.proximity.capabilityMask         = capabilityMask;

        tabletData.proximity.enterProximity         = 0; // leave

        

        if (report.buttons.invert) {

            tabletData.proximity.pointerType = NX_TABLET_POINTER_PEN;

        } else {

            tabletData.proximity.pointerType = NX_TABLET_POINTER_ERASER;

        }

        

        postSystemEvent(tabletData, NX_TABLETPROXIMITY, cursorX, cursorY); // 2

        

        tabletData.proximity.enterProximity = 1; // enter


        if (report.buttons.invert) {

            tabletData.proximity.pointerType = NX_TABLET_POINTER_ERASER;

        } else {

            tabletData.proximity.pointerType = NX_TABLET_POINTER_PEN;

        }


        postSystemEvent(tabletData, NX_TABLETPROXIMITY, cursorX, cursorY); // 2

        

        if (report.buttons.tip) {

            leftButtonPress(descriptor, report, changes, buttonID, cursorX, cursorY);

        }


simple code to switch to eraser mode

(Edited)