edu.utexas.cs.sdao.reyes.core

Texture

class Texture extends ColorMap

A wrapper around Java's BufferedImage that provides texture-specific functionality, such as bilinear filtering and coordinate flipping.

Linear Supertypes
ColorMap, AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. Texture
  2. ColorMap
  3. AnyRef
  4. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Instance Constructors

  1. new Texture(backingImage: BufferedImage, flipped: Boolean = true)

    backingImage

    the buffered image backing the wrapper

    flipped

    whether the origin should start at the bottom-left instead of the top-left

Value Members

  1. final def !=(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  2. final def !=(arg0: Any): Boolean

    Definition Classes
    Any
  3. final def ##(): Int

    Definition Classes
    AnyRef → Any
  4. final def ==(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  5. final def ==(arg0: Any): Boolean

    Definition Classes
    Any
  6. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  7. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  8. def drawInGraphics(g2: Graphics2D, drawWidth: Int, drawHeight: Int): Boolean

    Draws the image in the specified graphics context.

    Draws the image in the specified graphics context.

    g2

    the graphics context

    drawWidth

    the width to draw the image in

    drawHeight

    the height to draw the image in

    returns

    whether the image has been completely drawn, or whether pixels are still changing

  9. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  10. def equals(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  11. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  12. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  13. def getColor(x: Int, y: Int): Color

    Gets the color at the specified pixel.

    Gets the color at the specified pixel.

    x

    the pixel X-coordinate

    y

    the pixel Y-coordinate

    returns

    the color at the pixel

  14. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  15. val height: Int

    The height of the image, in pixels.

  16. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  17. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  18. final def notify(): Unit

    Definition Classes
    AnyRef
  19. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  20. def resize(newDims: (Int, Int)): Texture

  21. def resize(newWidth: Int, newHeight: Int): Texture

    Produces a new image with the current image's picture data scaled to the new width and height.

    Produces a new image with the current image's picture data scaled to the new width and height. Bilinear interpolation will be used in forming the scaled image.

    newWidth

    the width of the new scaled image

    newHeight

    the height of the new scaled image

    returns

    the new scaled image

  22. def sampleColor(uv: Vector2): Color

    Samples a pixel from the texture using bilinear filtering.

    Samples a pixel from the texture using bilinear filtering.

    uv

    the UV coordinate to sample; the coordinates must be in the range [0, 1]

    returns

    the sampled color

    Definition Classes
    TextureColorMap
  23. def setColor(x: Int, y: Int, c: Color): Unit

    Sets the color at the specified pixel.

    Sets the color at the specified pixel.

    x

    the pixel X-coordinate

    y

    the pixel Y-coordinate

    c

    the color to set at the pixel

  24. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  25. def toString(): String

    Definition Classes
    AnyRef → Any
  26. final def wait(): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  27. final def wait(arg0: Long, arg1: Int): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  28. final def wait(arg0: Long): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  29. val width: Int

    The width of the image, in pixels.

  30. def writeToFile(name: String): Boolean

    Writes the image to a PNG file.

    Writes the image to a PNG file.

    name

    the name of the image file, preferably ending in ".png"

    returns

    whether the write succeeded

Inherited from ColorMap

Inherited from AnyRef

Inherited from Any

Ungrouped