Download Shareware and Freeware Software for Windows, Linux, Macintosh, PDA

line Home  |  About Us  |  Link To Us  |  FAQ  |  Contact

Serving Software Downloads in 956 Categories, Downloaded 50.183.573 Times

mat2im 1.0

  Date Added: June 24, 2013  |  Visits: 398

mat2im

Report Broken Link
Printer Friendly Version


Product Homepage
Download (40 downloads)



This code snippet converts a 2D matrix to a 3D matrix where the values in the 3rd dimension correspond to pixel intensity in the red, green, and blue domains. This is the format used by many functions in the Image Processing Toolbox (which is not required for this function to run).The code works by mapping the values of matrix "mat" onto the rows of colormap "cmap" using a fast vectorised operation. function im=mat2im(mat,cmap,maxVal) PURPOSE Uses vectorized code to convert matrix "mat" to an m-by-n-by-3 image matrix which can be handled by the Mathworks image-processing functions. The the image is created using a specified color-map and, optionally, a specified maximum value. Note that it discards negative values! INPUTS mat - an m-by-n matrix cmap - an m-by-3 color-map matrix. e.g. hot(100). If the colormap has few rows (e.g. less than 20 or so) then the image will appear contour-like. limits - by default the image is normalised to it's max and min values so as to use the full dynamic range of the colormap. Alternatively, it may be normalised to between limits(1) and limits(2). Nan values in limits are ignored. So to clip the max alone you would do, for example, [nan, 2] OUTPUTS im - an m-by-n-by-3 image matrix Example 1 - combine multiple color maps on one figure clf, colormap jet, r=rand(40); subplot(1,3,1),imagesc(r), axis equal off , title('jet') subplot(1,3,2),imshow(mat2im(r,hot(100))) , title('hot') subplot(1,3,3),imshow(mat2im(r,summer(100))), title('summer') colormap winter %changes colormap in only the first panel Example 2 - clipping p=peaks(128); J=jet(100); subplot(2,2,1), imshow(mat2im(p,J)); title('Unclipped') subplot(2,2,2), imshow(mat2im(p,J,[0,nan])); title('Remove pixels 0') subplot(2,2,4), imshow(mat2im(p,J,[-1,3])); title('Plot narrow pixel range') Rob Campbell - April 2009 See Also: ind2rgb

Requirements: No special requirements
Platforms: Matlab
Keyword: Color Drand Equal Figure Multiple Subplot Imagescr Title Hot Title Jet Title Summer Winter
Users rating: 0/10

License: Shareware Size: 10 KB
USER REVIEWS
More Reviews or Write Review


MAT2IM RELATED
Development Tools  -  Link figures 1.0
The function is similar to Matlab's linkaxes, only it takes figure numbers instead of axes handles.Use the function when you want to zoom and pan multiple axes that are not on the same figure (i.e. subplot).
10 KB  
Multimedia  -  CMAPLINE 1.0
CMAPLINE finds all lines in an axis and specifies their colors according to a colormap. Also accepts custom colormaps in the form of a n x 3 matrix.EXAMPLE (generates screenshot)%generate some datax=(0:0.1:2*pi);m=50;...
10 KB  
Multimedia  -  Create Non-overlapping (cascading) Figure Windows 1.0
FIGUREC - create a figure window in a non-overlapping (cascading) locationUSAGE:figurecfigurec(...)h=figurech=figurec(...)FIGUREC acts just like the MATLAB FIGURE command, with all arguments passed through, except that the new figure is created a...
10 KB  
Development Editors  -  Horizontal Image Gallery v2 1
Dynamic XML controlled horizontal image gallery / product showcase. FEATURES INCLUDED:* XML driven Flash image gallery / product viewer* Supports multiple items defined in XML file* Dimensions (image width-height), border size, border color are...
104 KB  
Development Tools  -  raiseFigure - Intuitive alternative to figure(h) command 1.0
This is really simple, so many people will use this functionality already, but I just thought I'd make it a bit easier for everyone (and include rigorous error checking while I'm at it)...raiseFigure can be used to replace MATLAB's fh = figure()...
10 KB  
Modules  -  MReviews Advanced Module 5.0
MReviews advanced module is a exclusive reviews system with unlimited category nesting, sub-reviews, multiple images, and many other important features coded to work inside RavenNuke v2.x+. It might work with regular phpnuke website.Features:*...
92.16 KB  
Development Editors  -  Horizontal XML Image Scroller 1
Dynamic XML controlled horizontal image/swf scroller. FEATURES INCLUDED: * XML driven Flash image gallery / product viewer* Supports multiple items defined in XML file* Dimensions (image width-height), border size, border color are set via XML*...
56 KB  
Development Editors  -  Horizontal XML Image Scroller v2 1
Dynamic XML controlled horizontal smooth mouse image/swf scroller. FEATURES INCLUDED: * XML driven Flash image gallery / product viewer * Supports MULTIPLE ITEMS defined in XML file * DIMENSIONS (image width-height), border size, border color are...
65 KB  
Development Editors  -  Vertical XML Image Scroller 1
Dynamic XML controlled vertical image/swf scroller.FEATURES INCLUDED:* XML driven Flash image gallery / product viewer * Supports MULTIPLE ITEMS defined in XML file * DIMENSIONS (image width-height), border size, border color are set via XML *...
56 KB  
Development Editors  -  Vertical XML Image Scroller v2 1
Dynamic XML controlled vertical smooth mouse image/swf scroller.FEATURES INCLUDED:* XML driven Flash image gallery / product viewer * Supports MULTIPLE ITEMS defined in XML file * DIMENSIONS (image width-height), border size, border color are set...
65 KB  
NEW DOWNLOADS IN SCRIPTS, DEVELOPMENT TOOLS
Scripts  -  Freelancer Script 5.05
Main Features: 100% Secured. Email Support (3 Years). FREE Updates (3 Years). Post projects. Featured projects. Private projects. Sealed projects. Edit/delete projects. Select freelancers....
5.49 MB  
Scripts  -  B2B Script 4.20
Main Features: 100% Secured. Email Support (3 Years). FREE Updates (3 Years). Sign-up Account (Registration of account). Lead generation tools (for the sellers). Email verification to...
5.49 MB  
Scripts  -  B2C Script 5.06
Main Features: 100% Secured. Email Support (3 Years). FREE Updates (3 Years). The script comes with totally editable site colors, icons and graphics Multilevel categories allows extensive browsing Admin can change Category ordering or...
5.49 MB  
Scripts  -  Social Networking Script 2.86
Main Features: 100% Secured. Email Support (3 Years). FREE Updates (3 Years). Registration with name, email, password, date of birth etc. User can add multiple school, college, university with start...
5.49 MB  
Scripts  -  Business Networking Script 8.04
Main Features: 100% Secured. Email Support (3 Years). FREE Updates (3 Years). Ajax based interface. Profile creation. Different types of profile. Profile for jobseekers, employers and employed...
5.49 MB  
Development Tools  -  Aml2CHM 3.50
Those who use the popular Aml Pages text editor might be looking out for a way of generating help files from their text and notes. Aml2CHM is a plug-in that was developed to offer people a quick and efficient way of converting Aml Pages documents...
549.99 KB  
Development Tools  -  VMP Viewer 1.0
This is a very rudimentary tool to visualize the VMP files generated by BrainVoyager. Useful to share files with people who do not have BV.
10 KB  
Development Tools  -  Sending reports and timestamped file by emailing 1.0
main executing reference usage:[1] usage_send_mail.mIllustrates email sending with multiple separate files or single timestamped tar file. Attachment failure is properly handled, with continuation of report emailing without the attachment.[2]...
768 KB  
Development Tools  -  IrisMVC 2.0 rc1
IrisMVC is an OOP PHP framework that developers can use as a strong and secure foundation to build on various web applications following the Model-View-Controller (MVC) pattern. It provides the basic functionality developers need, without...
51.2 KB  
Development Tools  -  7-Zip for Script 4.42
7-Zip is a file archiver with a high compression ratio.Features:- High compression ratio in new 7z format with LZMA compression- Supported formats:- Packing / unpacking: 7z, ZIP, GZIP, BZIP2 and TAR- Unpacking only: RAR, CAB, ISO, ARJ, LZH, CHM,...
624.64 KB