Code covered by the BSD License  

Highlights from
Composing multiple BW images to one color image

Be the first to rate this file! 5 Downloads (last 30 days) File Size: 1.67 KB File ID: #25973
image thumbnail

Composing multiple BW images to one color image

by David Silver

 

29 Nov 2009

Composing n binary images to a colored image while each image is layer of some color.

| Watch this File

File Information
Description

function [c_img] = RGB_layers(imgs,RGBs)

RGB_layers - Visualize n gray/binary images in pseudo color

INPUT: (imgs,RGBs)
  imgs: m*k*n matrix. imgs(:,:,i) is a grayscale/BW image.
  RGBs: n*3 matrix, each row represents what color the layer will be.
(Optional. By default it will be the jet colormap)

 OUTPUT: m*k*3 color image.

 EXAMPLE:

I=imread('cameraman.tif');
imgs(:,:,1)=I>180;
imgs(:,:,2)=I<70;
imgs(:,:,3)=mod(I,40)==0;
imgs(:,:,4)=mod(I,70)==0;

RGBs=[1,0,0;0,0.6,0;0,0,1;0.2,0,0.3];
c_img=RGB_layers(imgs,RGBs);
imshow(c_img);

 BUG REPORT:
 Please send your bug reports, comments and suggestions to
dsilver@tx.technion.ac.il .
Thanks.

 Author: David Silver
          Department of Computer Science
          Technion - Israel Institute of Technology, Haifa, Israel
          dsilver@tx.technion.ac.il
 Version: 1.00

MATLAB release MATLAB 7.6 (R2008a)
Tags for This File  
Everyone's Tags
Tags I've Applied
Add New Tags Please login to tag files.
Please login to add a comment or rating.
Tag Activity for this File
Tag Applied By Date/Time
pseudo color David Silver 30 Nov 2009 11:29:46
visualization David Silver 30 Nov 2009 11:29:46
color David Silver 30 Nov 2009 11:29:46
multiple images David Silver 30 Nov 2009 11:29:46
layers David Silver 30 Nov 2009 11:29:46
image processing David Silver 30 Nov 2009 11:29:46
data exploration David Silver 30 Nov 2009 11:29:46

Contact us at files@mathworks.com