Contained Within
Find More Documentation
Featured Support Resources
| Scarica il manuale in formato PDF
XIL Acceleration on Ultra/Creator
7
- This chapter describes the XIL functions that are specific to the Creator and Creator 3D Graphics Accelerators.
Introduction
- XIL is Sun's foundation imaging and video library. Several important XIL functions have been accelerated for the Ultra platforms using the UltraSPARC Visual Instruction Set (VIS) and the Creator Graphics Accelerator.
XIL Data Types
- XIL supports a very general image structure, and not all types of XIL images are accelerated using VIS and Creator. The XIL data types supported in the VIS port are:
-
- 1, 2, 3, and 4-banded unsigned byte images.
- 1, 2, 3, and 4-banded signed short images.
- Band-aligned child images.
- All regions of interest.
Accelerated Functions
-
Table 7-1 shows the XIL functions accelerated using VIS. Note that display molecules are defined for one- and three-banded XIL_BYTE images.
-
Table 7-1
| Function | VIS Acceleration
8-bit...16-bit
| Molecules
Display Other
| Comments |
| xil_absolute |
| 1 - 4 bands |
|
|
|
| xil_affine | 1 - 4 bands |
| x |
|
|
| xil_add | 1 - 4 bands | 1 - 4 bands | x |
|
|
| xil_add_constant | 1 - 4 bands | 1 - 4 bands | x |
|
|
| xil_and | 1 - 4 bands | 1 - 4 bands | x |
|
|
| xil_and_constant | 1 - 4 bands | 1 - 4 bands | x |
|
|
| xil_band_combine | 1 - 4 bands | 1 - 4 bands |
|
|
|
| xil_blend | 1 - 4 bands | 1 - 4 bands |
|
|
|
xil_cast
8 . 16
16 . 8 |
1 - 4 bands
1 - 4 bands |
1 - 4 bands
1 - 4 bands |
|
|
|
| xil_copy | 1 - 4 bands | 1 - 4 bands | x |
|
|
| xil_convolve | 1 - 4 bands | 1 - 4 bands | x | x | See Note 1 |
| xil_decompress |
|
|
|
| See Note 2 |
| xil_get_pixel | 1 - 4 bands | 1 - 4 bands |
|
|
|
| xil_lookup | 1 - 4 bands | 1 - 4 bands | x |
|
|
| xil_min | 1 - 4 bands | 1 - 4 bands | x |
|
|
| xil_max | 1 - 4 bands | 1 - 4 bands | x |
|
|
| xil_multiply | 1 - 4 bands | 1 - 4 bands | x |
|
|
| xil_multiply_constant | 1 - 4 bands | 1 - 4 bands | x |
|
|
| xil_not | 1 - 4 bands | 1 - 4 bands | x |
|
|
| xil_or | 1 - 4 bands | 1 - 4 bands | x |
|
|
| xil_or_constant | 1 - 4 bands | 1 - 4 bands | x |
|
|
-
Table 7-1 (Continued)
| Function | VIS Acceleration
8-bit...16-bit
| Molecules
Display Other
| Comments |
| xil_rescale | 1 - 4 bands |
| x | x | See Note 3 |
| xil_rotate | 1 - 4 bands |
| x |
|
|
| xil_scale | 1 - 4 bands | 1 - 4 bands | x |
|
|
| xil_set_pixel | 1 - 4 bands | 1 - 4 bands | x |
|
|
| xil_set_value | 1 - 4 bands | 1 - 4 bands | x |
|
|
| xil_subtract | 1 - 4 bands | 1 - 4 bands | x |
|
|
| xil_subtract_from_constant | 1 - 4 bands | 1 - 4 bands | x |
|
|
| xil_threshold | 1 - 4 bands | 1 - 4 bands | x |
|
|
-
Note 1: xil_convolve is accelerated for 3 . 3, 5 . 5, and 7 . 7 kernels. The XIL_EDGE_EXTEND option is not accelerated. Separable kernels are accelerated as molecules for 3 . 3, 5 . 5, and 7 . 7 kernels.
-
Note 2: xil_decompress is accelerated for the following cases:
-
- xil_decompress + color_convert (JPEG compressed image or sequence and MPEG1 compressed sequence)
- xil_decompress + color_convert + display (MPEG1 compressed sequence)
- xil_decompress + color_convert + scale + display (MPEG1 compressed sequence)
- This decoder adheres to full-precision 24-bit CCIR 601 YCC . RGB709 color space conversion.
-
Note 3: xil_rescale + xil_threshold + xil_threshold + display molecule is accelerated using the Creator depth-cueing hardware. However, some restrictions apply as follows:
-
- The first threshold must have a high value of 255. The low and map values must be equal (any number N between 0 and 255.)
- The second threshold must have a low value of 0. The high and map values must be equal (any number M between 0 and N).
-
- The parameters for xil_rescale must be chosen such that y values of the line represented must span the range of values between N and M while the x values are within 0 and 255. This is shown below.
- The images must be 1-banded XIL_BYTE images.
-

- The following code is an example of a correct call to invoke this molecule:
-
-
float scale[1] = 1.5;
float offset[1] = -10;
float t1_lo[1] = 255;
float t1_hi[1] = 240;
float t1_map[1] = 240;
float t2_lo[1] = 0;
float t2_hi[1] = 15;
float t2_map[1] = 15;
xil_rescale(src,tmp1,scale,offset);
xil_threshold(tmp1,tmp2,t1_lo,t1_hi,t1_map);
xil_threshold(tmp2,tmp3,t2_lo,t2_hi,t2_map);
xil_display(tmp3,display);
- However, if the same calling sequence is done with scale[1] = .40, the molecule will not be invoked because the line y = 0.40*x -10 only spans the range y = -10 to y = (255*0.40) - 10 = 92 between x = 0 and x = 255. For the molecule to execute, y must span at least the range y = 15 to y = 240 for x between 0 and 255.
|
|