Sha256: 0834a5300d83353178cb40a0e844141bcb6a39576585d4924942e8d58ab7b444
Contents?: true
Size: 805 Bytes
Versions: 4
Compression:
Stored size: 805 Bytes
Contents
# encoding: UTF-8 require './test_helper' require 'test/unit' class TrasformsTest < Test::Unit::TestCase def test_rotate bitmap1 = FreeImage::Bitmap.open(image_path('sample.png')) bitmap2 = bitmap1.rotate(45) assert_kind_of(FreeImage::Bitmap, bitmap2) end def test_rotate_ex bitmap1 = FreeImage::Bitmap.open(image_path('sample.png')) bitmap2 = bitmap1.rotate_ex(45, 0, 0, 0, 0) assert_kind_of(FreeImage::Bitmap, bitmap2) end def test_flip_horizontal bitmap1 = FreeImage::Bitmap.open(image_path('sample.png')) result = bitmap1.flip_horizontal! assert_kind_of(TrueClass, result) end def test_flip_vertical bitmap1 = FreeImage::Bitmap.open(image_path('sample.png')) result = bitmap1.flip_vertical! assert_kind_of(TrueClass, result) end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
free-image-0.6.2 | test/test_transforms.rb |
free-image-0.6.1 | test/test_transforms.rb |
free-image-0.6.0 | test/test_transforms.rb |
free-image-0.5.0 | test/test_transforms.rb |