Images Examples


Example: How Images use Tiles from Tables

An example showing how an image is made up from data stored in a table in tiles.

Example: Create Two Images From One Table

More than one image can show data from the same table, including from the same tile field.

Example: An Image using Computed Fields in a Table

How an image can be created from tiles where the data for the tiles is taken from a field that is computed on the fly.

Example: Change the Contrast of an Image

In this example we use the Style dialog to change the contrast of an image.

Example: Using the Assign Channels Button

The Assign Channels button in the Style pane for images allows us to assign channels to the standard three Red, Green, and Blue display outputs using frequently-desired arrangements.   The button provides a short cut way to assign all channels at once instead of doing each channel individually.

Example: Assign Channels

How to use the Style pane for images to assign channels to display outputs such as R, G, B or A.  This topic shows examples of channel combinations and the visual results.

Example: Display an NAIP Four Band Image as Color Infrared (CIR)

How to use the Style pane for images to re-assign channels in a four band NAIP image to produce a Color Infrared (CIR) image display.  

Example: Shuffle Channels with a Raster Self Join

We use the Join dialog to rearrange channels within an image,   Starting with a four channel image that has RGB plus infrared channels, we rearrange the order of channels so that infrared values are in the first channel powering the red output, red values are in the second channel powering the green output, and green values are in the third channel the blue output.   This is the classic Color Infrared (CIR) channel arrangement.  Unlike a virtual rearrangement using Style shown in the  Example: Display an NAIP Four Band Image as Color Infrared (CIR) topic, rearranging channels in this way changes the structure of the data so that any exported image will retain the new arrangement.

Example: Set Image Transparency using Alpha

The A row in the Style dialog allows us to specify what transparency we want to apply to the image, either by applying the same value for A for all pixels or by using one of the other channels to also control the A value.

Example: Autocontrast and Hill Shading Images using Style

This example shows how the Style dialog can hill shade an image using the values of pixels as heights and generating shadows as if the Sun were located at the specified azimuth and altitude.   This capability is used most frequently with raster images to give an impression of three dimensionality in cases where the values of pixels represent terrain elevations.

Example: Style Applied to an Image Server Image

Because the Style dialog simply changes the way an image is displayed and not the data, it can operate on read-only data served by various web servers such as WMS REST servers.    In this example we look at every detail of creating a data source using a WMS REST  server and then manipulating the appearance of the display with Style.  We will connect to a WMS server that provides LiDAR data in various forms, including as terrain elevation.

SQL Example: Re-tile an Image using a Different Tile Size

Starting with an image that uses a tile size of 128 x 128 pixels this SQL example creates a copy of the image using 500 x 500 pixel tiles.

Example: Merge Images

A step-by-step example using the Merge Images command showing how to merge dozens of images showing SRTM terrain elevation data into one image, with various tricks for faster workflow as an experienced Manifold user would do the job.  After creating the new image we style it with a palette and use hill shading to better show terrain elevation.

Example: Resize an Image using Merge

We can change the size of an image while maintaining georegistration by using the Merge Images command.  This example shows how to take an image that is 3,038 x 4,334 pixels in size, using approximately 36 meter pixels, and to create a re-sampled image that is 1,115 x 1,590 pixels in size, using 100 meter pixels.  

Example: Rescale a Raster Image

See how to rescale pixel values from one raster image, using a given range of values such as 8 bit unsigned integers, into a new raster image using a different range of values such as 16 bit unsigned integers, so that the relative distribution of pixel values, that is, the histogram, does not change.

SQL Example: Acquire Pixel Values within Areas

Given a map with two layers, an image layer that provides terrain elevations and a drawing with area objects, we use the TileGeomToValues function to find the three highest pixels in the image within each area object in the drawing.

SQL Example: Process Images with 3x3 Filters

Shows a step-by-step example of developing an SQL query that takes a query written by the Edit Query button and then modifies that query into a general purpose query that can apply any 3x3 filter.   This makes it easy to use matrix filters we find on the web for custom image processing.   We extend the query by using parameters and adding a function, and then show how it can be adapted to use a 5x5 filter.

SQL Example: Process Images using Dual 3x3 Filters

A continuation of the above topic, extending the example query to utilize two filters for processing, as commonly done with Sobel and Prewitt two filter processing.

SQL Example: Process RGB Images using Matrix Filters

A continuation of the above two topics, extending the example query to process three channel, RGB images.

SQL Example: Create NDVI Displays

How to create a query that creates an NDVI display from a four-band NAIP image, with tips and tricks on how to copy and paste existing information to get the result we want.

SQL Example: Create Topographic Position Index TPI Displays

In this example, we use a few short lines of SQL to create a Topographic Position Index (TPI) display.  TPI characterizes the undulations of a terrain elevation surface.  TPI value above zero show locations that are higher than then average of immediately surrounding terrain, and thus tend to show ridges.   TPI values below zero show locations that are lower than the average of immediately surrounding terrain, and thus tend to show valleys.  TPI values that are zero show areas of constant slope.

Example: Enhance Terrain with Curvatures

We enhance a terrain showing Crater Lake, Oregon, by using mean curvature calculation to bring out details.   The example uses a 4 GB project containing a large terrain elevation surface.  Using a point-and-click dialog with no SQL, we apply automatic CPU parallelism and GPU parallelism to absolutely crush a task in two and a half minutes that would take non-parallel software days.