Image::ANSI::Palette::VGA - The default VGA palette


Image-ANSI documentation Contained in the Image-ANSI distribution.

Index


Code Index:

NAME

Top

Image::ANSI::Palette::VGA - The default VGA palette

SYNOPSIS

Top

	$pal = Image::ANSI::Palette::VGA->new;

METHODS

Top

new( )

Creates a new Image::ANSI::Palette:VGA object.

AUTHOR

Top

* Brian Cassidy <bricas@cpan.org>

COPYRIGHT AND LICENSE

Top


Image-ANSI documentation Contained in the Image-ANSI distribution.
package Image::ANSI::Palette::VGA;

use base qw( Image::ANSI::Palette );

use strict;
use warnings;

our $VERSION = '0.10';

my $palette = [
	[ 0x00, 0x00, 0x00 ], # black
	[ 0xaa, 0x00, 0x00 ], # red
	[ 0x00, 0xaa, 0x00 ], # green
	[ 0xaa, 0x55, 0x00 ], # yellow
	[ 0x00, 0x00, 0xaa ], # blue
	[ 0xaa, 0x00, 0xaa ], # magenta
	[ 0x00, 0xaa, 0xaa ], # cyan
	[ 0xaa, 0xaa, 0xaa ], # white
	                      # bright
	[ 0x55, 0x55, 0x55 ], # black
	[ 0xfe, 0x55, 0x55 ], # red
	[ 0x55, 0xfe, 0x55 ], # green
	[ 0xfe, 0xfe, 0x55 ], # yellow
	[ 0x55, 0x55, 0xfe ], # blue
	[ 0xfe, 0x55, 0xfe ], # magenta
	[ 0x55, 0xfe, 0xfe ], # cyan
	[ 0xfe, 0xfe, 0xfe ]  # white
];

sub new {
	my $class = shift;
	my $self  = $class->SUPER::new( $palette );

	return $self;
}

1;