Maple Professional
Maple Academic
Maple Student Edition
Maple Personal Edition
Maple Player
Maple Player for iPad
MapleSim Professional
MapleSim Academic
Maple T.A. - Testing & Assessment
Maple T.A. MAA Placement Test Suite
Möbius - Online Courseware
Machine Design / Industrial Automation
Aerospace
Vehicle Engineering
Robotics
Power Industries
System Simulation and Analysis
Model development for HIL
Plant Modeling for Control Design
Robotics/Motion Control/Mechatronics
Other Application Areas
Mathematics Education
Engineering Education
High Schools & Two-Year Colleges
Testing & Assessment
Students
Financial Modeling
Operations Research
High Performance Computing
Physics
Live Webinars
Recorded Webinars
Upcoming Events
MaplePrimes
Maplesoft Blog
Maplesoft Membership
Maple Ambassador Program
MapleCloud
Technical Whitepapers
E-Mail Newsletters
Maple Books
Math Matters
Application Center
MapleSim Model Gallery
User Case Studies
Exploring Engineering Fundamentals
Teaching Concepts with Maple
Maplesoft Welcome Center
Teacher Resource Center
Student Help Center
Image Types - test for an image type
Calling Sequence
type( x, Image )
type( x, GrayImage )
type( x, ColorImage )
type( x, ColorAImage )
Parameters
x
-
anything; expression to test.
Description
The type(x, ImageType) function call returns true if x is of type ImageType, where ImageType is one of Image, GrayImage, ColorImage, or ColorAImage.
Within the ImageTools package, images are represented as dense, rectangular rtables of 64-bit hardware floating-point numbers. Grayscale images are 2D, color images are 3D.
The first index of the rtable is the row (height) index. The second index is the column (width) index. The row and column indices do not have to start at 1. The first element in the structure corresponds to the upper-left pixel of the image.
All images must have datatype = float[8], storage = rectangular, and have no indexing function.
Either C_order or Fortran_order can be used to store the elements in the rtable, however, operations on two images generally require that they have the same order.
These types are assigned by loading the ImageTools package.
Image
The Image type corresponds to any of the three specific types: GrayImage, ColorImage, or ColorAImage.
Grayscale Image (single layer)
The GrayImage type corresponds to a single layer image. A Matrix with the previously mentioned attributes may be used in place of an Array.
Color Image (three layers)
The ColorImage type corresponds to a three layer image. A ColorImage has three indices. The third index, which ranges from 1 to 3, corresponds to the three color layers (red, green, blue).
Color/Alpha Image (four layers)
The ColorAImage type corresponds to a four layer image. A ColorAImage has three indices. The third index, which ranges from 1 to 4, corresponds to the three color layers (red, green, blue) and an alpha channel.
See Also
Array, ImageTools, ImageTools[Create], ImageTools[WhatTypeImage], Matrix
Download Help Document