Microscopy Image Browser  1.233
All Classes Files Functions Variables Pages
crop_borders.m File Reference

CROP_BORDERS Crop the borders of an image or stack of images. More...

Functions

function [ A ,
vA ,
vB ,
bb_rel ] = 
crop_borders (A, bcol, padding, crop_amounts)
 CROP_BORDERS Crop the borders of an image or stack of images. More...
 
function A = cropborders>col (A)
 

Detailed Description

CROP_BORDERS Crop the borders of an image or stack of images.

Function Documentation

function [ A , vA , vB , bb_rel ] = crop_borders (   A,
  bcol,
  padding,
  crop_amounts 
)

CROP_BORDERS Crop the borders of an image or stack of images.

[B, vA, vB, bb_rel] = crop_borders(A, bcol, [padding])

IN
A - HxWxCxN stack of images. bcol - Cx1 background colour vector. padding - scalar indicating how much padding to have in relation to the cropped-image-size (0<=padding<=1). Default: 0 crop_amounts - 4-element vector of crop amounts: [top,right,bottom,left] where NaN/Inf indicate auto-cropping, 0 means no cropping, and any other value mean cropping in pixel amounts.
OUT
B - JxKxCxN cropped stack of images. vA - coordinates in A that contain the cropped image vB - coordinates in B where the cropped version of A is placed bb_rel - relative bounding box (used for eps-cropping)

Referenced by export_fig(), and im2gif().

Here is the caller graph for this function:

function A = cropborders>col (   A)