Sha256: c1e7b18c04cc2d1a7c79eae711a165737d49fd6b4671fe837af9059bfe36a212
Contents?: true
Size: 596 Bytes
Versions: 8
Compression:
Stored size: 596 Bytes
Contents
require 'psd/layer_info' class PSD class VectorMask < LayerInfo def self.should_parse?(key) ['vmsk', 'vsms'].include?(key) end attr_reader :invert, :not_link, :disable, :paths def parse version = @file.read_int tag = @file.read_int @invert = tag & 0x01 @not_link = (tag & (0x01 << 1)) > 0 @disable = (tag & (0x01 << 2)) > 0 # I haven't figured out yet why this is 10 and not 8. num_records = (@length - 10) / 26 @paths = [] num_records.times do @paths << PathRecord.new(@file) end end end end
Version data entries
8 entries across 8 versions & 1 rubygems