You copied the Doc URL to your clipboard.

Visual Annotate overview

In addition to simple text overlays using Annotate, Streamline supports the annotation of images, providing further application-level context to the Timeline view.

In the same way as textual annotation, the application writes to the gator annotate socket and Streamline integrates this data and its timestamp into the sample and trace capture report.

Figure 9-2 Visual Annotation in the Timeline view

Visual Annotation in the Timeline view

To include images in the data sent to the host during a capture session, use the ANNOTATE_VISUAL macro in your source code instead of the ANNOTATE and ANNOTATE_COLOR macros used in textual annotation. ANNOTATE_VISUAL provides a parameter for image data.

Note

Visual Annotation supports images in the following formats:
  • GIF.
  • PNG.
  • JPEG.
  • TIFF.
  • ICO.
  • BMP +RLE.
There is no limit to the image size but the larger the image, the greater the impact on system performance. Increasing the amount of data sent to the host in this way increases the probe effect for the applications you are profiling.

The following example function is from the Streamline_annotate example project, included in the Linux_examples archive in the examples directory of your DS-5 installation:

void displayImage() {
	char filename[32];
	char* image;
	unsigned int size;

	// Supported formats include gif, png, jpeg, tiff, ico, bmp (+rle)
	strcpy(filename, "splash.bmp");
	image = readFromDisk(filename, &size);
	if (image == NULL) {
		printf("error loading image %s\n", filename);
		exit(1);
	}

	// Add text along with the image annotation
	ANNOTATE_VISUAL(image, size, filename);
	free(image);
}

You can see the effects of visual annotation in the Timeline and Log views of your Streamline Analysis Reports. With visual annotations, the Timeline view data includes a chart that contains the annotated images. In the Log view, any annotation event that includes an image has an icon in the message field. Hover over the icon to see the image.

Related reference

Was this page helpful? Yes No