Interactively...

You can add clipping planes to a 3D image to display a cropped image without actually removing data from the image.

Select the clipping tool

Click a 3D image to expose the image toolbar and select the clipping tool:

Position the clipping planes

Choose a clipping direction and drag the sliders to position the clipping planes:

Add more clipping planes if desired

Click New clipping panes to add another pair of clipping planes:

Click outside the image to turn off the toolbar

Programmatically to Remove a Uniform Border...

Automatically trim a uniform border from a 3D image with ImageCrop:

In[1]:=
Click for copyable input
Out[1]=

Programmatically to a Given Size...

Crop a 256×256×110 image to 128×256×110 pixels, revealing the internal structure:

Out[1]=
  • A cropping fraction of 1 means crop on the negative axis side, 0 means crop equally on both sides and 1 means crop on the positive axis side.

Programmatically, Trimming a Given Amount...

Trim 128 pixels from the positive x axis side using ImagePad with a negative value:

Out[2]=

Programmatically, Extracting a Subimage...

Extract image planes 128 to 256 in the y axis direction:

Out[3]=

Negative values indicate planes, counting backward from the end:

Out[4]=

Programmatically to Remove a Uniform Border...

Automatically trim a uniform border from a 3D image with ImageCrop:

In[5]:=
Click for copyable input
Out[5]=

Programmatically to a Given Size...

Crop a 256×256×110 image to 128×256×110 pixels, revealing the internal structure:

Out[5]=
  • A cropping fraction of 1 means crop on the negative axis side, 0 means crop equally on both sides and 1 means crop on the positive axis side.

Programmatically, Trimming a Given Amount...

Trim 128 pixels from the positive x axis side using ImagePad with a negative value:

Out[6]=

Programmatically, Extracting a Subimage...

Extract image planes 128 to 256 in the y axis direction:

Out[7]=

Negative values indicate planes, counting backward from the end:

Out[8]=

Programmatically to Remove a Uniform Border...

Automatically trim a uniform border from a 3D image with ImageCrop:

In[9]:=
Click for copyable input
Out[9]=

Programmatically to a Given Size...

Crop a 256×256×110 image to 128×256×110 pixels, revealing the internal structure:

Out[9]=
  • A cropping fraction of 1 means crop on the negative axis side, 0 means crop equally on both sides and 1 means crop on the positive axis side.

Programmatically, Trimming a Given Amount...

Trim 128 pixels from the positive x axis side using ImagePad with a negative value:

Out[10]=

Programmatically, Extracting a Subimage...

Extract image planes 128 to 256 in the y axis direction:

Out[11]=

Negative values indicate planes, counting backward from the end:

Out[12]=