Let you control the glass state and parameters: openGlass() closeGlass() setDistortion(double distortion, double magnification) setDiameter(int diameter) refresh()
glassPosition
enum
enum to set the touch behavior or sticky position
glassParams
GlassParams
class to set lens parameters
borderColor
Color
border color
borderThickness
double
border thickness
elevation
double
shadow elevation
shadowOffset
Offset
shadow offset
GlassPosition class
Name
Description
touchPosition
move the glass with finger touch
topLeft
sticky position to top left corner of the screen
topRight
sticky position to top rigth corner of the screen
bottomLeft
sticky position to bottom left corner of the screen
bottomRight
sticky position to bottom right corner of the screen
GlassParams class
Name
Description
startingPosition
the startin glass position. If not given the lens will be placed at the center of the screen.
diameter
the diameter of the glass
magnification
the magnification of the lens 1 means no magnification >1 means magnification <1 means shrinking
distortion
Barrel/Pincushion distortion power 0 means no distortion
padding
the padding surrounding the glass to enlarge touching area