class PNM::PPM

Defined in:

pnm/ppm.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(width : Int32, height : Int32, maxval : Int32, data : Slice(UInt8)) #

[View source]
def self.new(red : PNM::PGM, green : PNM::PGM, blue : PNM::PGM) #

takes 3 PGM objects as red, green and blue channels and outputs 1 PPM object


[View source]
def self.new(data : Slice(UInt8)) #

[View source]

Instance Method Detail

def *(other : self) #

[View source]
def +(other : self) #

[View source]
def -(other : self) #

[View source]
def /(other : self) #

[View source]
def blue #

[View source]
def crop(new_width : Int32, new_height : Int32) #

probably doesnt work but eh


[View source]
def data : Slice(UInt8) #

[View source]
def green #

[View source]
def height : Int32 #

[View source]
def invert #

[View source]
def maxval : Int32 #

[View source]
def maxval=(new_maxval : Int32) #

[View source]
def red #

[View source]
def to_pbm(threshold : Int32) #

[View source]
def to_pbm #

[View source]
def to_pgm #

[View source]
def width : Int32 #

[View source]
def write(filename : String) #

[View source]