Sha256: 99f84b5c9d67d8a7fbb11b5a7704d00920d5375102e04d1186c50b0935aea491
Contents?: true
Size: 888 Bytes
Versions: 1
Compression:
Stored size: 888 Bytes
Contents
module GLFW ## # Object describing a raw image with uncompressed pixel data, with 32-bytes per pixel in RGBA byte order. # # This class may also be used for creating textures with OpenGL, simply use `GL_RGBA` as the pixel format # and pass the value of the {pixels} method. class Image ## # @return [Integer] the width of the image, in pixel units. attr_reader :width ## # @return [Integer] the height of the image, in pixel units. attr_reader :height ## # @overload initialize(width, height, pixels = nil) # # @overload initialize(filename) # def initialize(width, height, pixels) end ## # Gets the pixel data as a binary blob. # # @return [String] the pixel data. def pixels end alias_method :columns, :width alias_method :rows, :height alias_method :to_blob, :pixels end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
glfw-3.3.2.0 | lib/glfw/stubs/image.rb |