Sha256: da9b60e14e29a38967a21a3c0c280f5cd557eb6a1b8c2b036f701d688626de92

Contents?: true

Size: 593 Bytes

Versions: 74

Compression:

Stored size: 593 Bytes

Contents

require 'fox16'
require 'test/unit'
require 'testcase'

class TC_FXBMPImage < Fox::TestCase
  include Fox

  def setup
    super(self.class.name)
  end

  def test_fileExt
    assert_equal("bmp", FXBMPImage.fileExt)
  end

  def test_image_from_pixel_data
    img = FXBMPImage.new app
    img.setPixels "rgbaRGBA", 0, 1, 2
    bmp_data = FXMemoryStream.open(FXStreamSave, nil) do |outfile|
      img.savePixels(outfile)
      outfile.takeBuffer
    end
    assert_not_equal "rgbaRGBA", bmp_data

    img2 = FXBMPImage.new app, bmp_data
    assert_equal "rgbaRGBA", img2.pixel_string
  end
end

Version data entries

74 entries across 74 versions & 1 rubygems

Version Path
fxruby-1.6.48 test/TC_FXBMPImage.rb
fxruby-1.6.48-x64-mingw32 test/TC_FXBMPImage.rb
fxruby-1.6.48-x64-mingw-ucrt test/TC_FXBMPImage.rb
fxruby-1.6.48-x86-mingw32 test/TC_FXBMPImage.rb
fxruby-1.6.47 test/TC_FXBMPImage.rb
fxruby-1.6.47-x64-mingw-ucrt test/TC_FXBMPImage.rb
fxruby-1.6.47-x64-mingw32 test/TC_FXBMPImage.rb
fxruby-1.6.47-x86-mingw32 test/TC_FXBMPImage.rb
fxruby-1.6.46 test/TC_FXBMPImage.rb
fxruby-1.6.46-x64-mingw32 test/TC_FXBMPImage.rb
fxruby-1.6.46-x64-mingw-ucrt test/TC_FXBMPImage.rb
fxruby-1.6.46-x86-mingw32 test/TC_FXBMPImage.rb
fxruby-1.6.45 test/TC_FXBMPImage.rb
fxruby-1.6.45-x64-mingw32 test/TC_FXBMPImage.rb
fxruby-1.6.45-x64-mingw-ucrt test/TC_FXBMPImage.rb
fxruby-1.6.45-x86-mingw32 test/TC_FXBMPImage.rb
fxruby-1.6.44 test/TC_FXBMPImage.rb
fxruby-1.6.44-x64-mingw32 test/TC_FXBMPImage.rb
fxruby-1.6.44-x86-mingw32 test/TC_FXBMPImage.rb
fxruby-1.6.43 test/TC_FXBMPImage.rb