overlay

From DavinciWiki
Jump to: navigation, search

Description

Overlay image 2 on image 1 (must be the same dimensions) or blend the two images together. Uses thm.ramp for blending

Arguments and Return Values

Arguments: two numeric arrays

Return Value: an overlayed numeric array

Usage

Syntax: overlay(img1, img2 [, ignore = VAL][, blend = VAL])

img1 = underlying image

img2 = overlaying image

ignore = ignore value of the images (Default=-32768)

blend = blend two images together (Default=1)

Examples

Set up the arrays to be used in examples

dv> a = clone(-32768.,1000,1000,1)
1000x1000x1 array of float, bsq format [4,000,000 bytes]

dv> b = clone(-32768.,1000,1000,1)
1000x1000x1 array of float, bsq format [4,000,000 bytes]

dv> a[200:500,200:500] = 100
301x301x1 array of float, bsq format [362,404 bytes]

dv> b[400:800,400:800] = 200
401x401x1 array of float, bsq format [643,204 bytes]

Example 1 - non-blended

dv> out = overlay(a,b, blend = 0, ignore = -32768)
1000x1000x1 array of short, bsq format [2,000,000 bytes]

Example 2 - blended

dv> out = overlay(a,b, ignore = -32768)
1000x1000x1 array of short, bsq format [2,000,000 bytes]

Images

Example 1 - non-blended, Example 2 - blended

overlay1.png overlay2.png

DavinciWiki Mini-Nav Bar

Contents


Contact Developers

  • davinci-dev [AT] mars.asu.edu

All other topics

  • See navigation on the left

Major Sub-Functions

Related Functions

Recent Library Changes

Created On: 04-20-2007
Modified On: 01-17-2008

Personal tools