Class JoGLTextureManager.JoGLTexture

    • Constructor Detail

      • JoGLTexture

        public JoGLTexture()
        Default constructor.
    • Method Detail

      • getSScaleFactor

        public double getSScaleFactor()
        Description copied from interface: Texture
        2D-Texture coordinates must be modified according to the real texture dimension which can differ from the textureSize (with certains GC, a texture must have a size which is a power-of-two).
        Specified by:
        getSScaleFactor in interface Texture
        Overrides:
        getSScaleFactor in class AbstractTexture
        Returns:
        the scale factor for the s-coordinate
      • getTScaleFactor

        public double getTScaleFactor()
        Description copied from interface: Texture
        2D-Texture coordinates must be modified according to the real texture dimension which can differ from the textureSize (with certains GC, a texture must have a size which is a power-of-two).
        Specified by:
        getTScaleFactor in interface Texture
        Overrides:
        getTScaleFactor in class AbstractTexture
        Returns:
        the scale factor for the t-coordinate
      • glReload

        public void glReload()
        Called when gl context is gone.
      • getAnchorDeltaX

        protected double getAnchorDeltaX​(AnchorPosition anchor)
        Return the deltaX to apply to the sprite in regards to the given anchor.
        Parameters:
        anchor - the given anchor.
        Returns:
        the deltaX to apply to the sprite in regards to the given anchor.
      • getAnchorDeltaY

        protected double getAnchorDeltaY​(AnchorPosition anchor)
        Return the deltaY to apply to the sprite in regards to the given anchor.
        Parameters:
        anchor - the given anchor.
        Returns:
        the deltaY to apply to the sprite in regards to the given anchor.