Class ImageAnnotation

    • Field Detail

      • imageWidth

        protected int imageWidth
      • imageHeight

        protected int imageHeight
      • fitSizeToImage

        protected boolean fitSizeToImage
      • useImageAspectRatio

        protected boolean useImageAspectRatio
      • enableSmoothing

        protected boolean enableSmoothing
      • useMipmaps

        protected boolean useMipmaps
      • showToolTip

        protected boolean showToolTip
      • toolTipText

        protected java.lang.String toolTipText
      • toolTipPoint

        protected java.awt.Point toolTipPoint
    • Constructor Detail

      • ImageAnnotation

        public ImageAnnotation​(java.lang.Object imageSource,
                               int imageWidth,
                               int imageHeight)
      • ImageAnnotation

        public ImageAnnotation​(java.lang.Object imageSource)
      • ImageAnnotation

        public ImageAnnotation()
    • Method Detail

      • isFitSizeToImage

        public boolean isFitSizeToImage()
      • setFitSizeToImage

        public void setFitSizeToImage​(boolean fitSizeToImage)
      • isUseImageAspectRatio

        public boolean isUseImageAspectRatio()
      • setUseImageAspectRatio

        public void setUseImageAspectRatio​(boolean useImageAspectRatio)
      • isEnableSmoothing

        public boolean isEnableSmoothing()
      • setEnableSmoothing

        public void setEnableSmoothing​(boolean enable)
      • isUseMipmaps

        public boolean isUseMipmaps()
      • setUseMipmaps

        public void setUseMipmaps​(boolean useMipmaps)
      • getImageSource

        public java.lang.Object getImageSource()
      • setImageSource

        public void setImageSource​(java.lang.Object source,
                                   int imageWidth,
                                   int imageHeight)
      • setImageSource

        public void setImageSource​(java.lang.Object source)
      • getImageDimension

        public java.awt.Dimension getImageDimension()
      • isShowToolTip

        public boolean isShowToolTip()
      • setShowToolTip

        public void setShowToolTip​(boolean show)
      • getToolTipText

        public java.lang.String getToolTipText()
      • setToolTipText

        public void setToolTipText​(java.lang.String toolTipText)
      • getToolTipPoint

        public java.awt.Point getToolTipPoint()
      • setToolTipPoint

        public void setToolTipPoint​(java.awt.Point toolTipPoint)
      • getImageSize

        protected java.awt.Dimension getImageSize​(DrawContext dc)
      • drawToolTip

        protected void drawToolTip​(DrawContext dc)
      • doDrawToolTip

        protected void doDrawToolTip​(DrawContext dc,
                                     java.lang.String text,
                                     int x,
                                     int y)
      • transformBackgroundImageCoordsToAnnotationCoords

        protected void transformBackgroundImageCoordsToAnnotationCoords​(DrawContext dc,
                                                                        int width,
                                                                        int height,
                                                                        WWTexture texture)
        Description copied from class: AbstractAnnotation
        Transforms texture coordinates from Annotation background image coordinates to Annotation geometry coordinates (in screen pixels), and applies the Annotation's image scale and image offset attributes. In Annotation background image coordinates (0, 0) maps to the image's upper left corner, and (imageWidth, imageHeight) maps to the image's lower right corner. In Annotation geometry coordinates (0, 0) maps to the Annotation geometry's lower left corner (ignoring any leader geometry), and (width, height) maps to the Annotation's upper right corner in window coordinates (screen pixels). This assumes the current OGL matrix mode is GL_TEXTURE.
        Overrides:
        transformBackgroundImageCoordsToAnnotationCoords in class AbstractAnnotation
        Parameters:
        dc - the DrawContext to receive the texture coordinate transform.
        width - the Annotation's width, in window coordinates (screen pixels).
        height - the Annotation's height, in window coordinates (screen pixels).
        texture - the texture to transform from Annotation background image coordinates to Annotation geometry coordinates.
      • setupAnnotationAttributes

        protected void setupAnnotationAttributes​(Annotation annotation)