Ets_Nt_Pixel_Pos_Get()

Abstract

Translates the position within a bounding box to pixel coordinates.

Syntax

Ets_Nt_Pixel_Pos_Get (ul_x, ul_y, lr_x, lr_y, x_pos, y_pos, pixel_width, units, x_pixel_ptr, y_pixel_ptr)
Argument Type Description
ul_x double upper left x coordinate of the subnet
ul_y double upper left y coordinate of the subnet
lr_x double lower right x coordinate of the subnet
lr_y double lower right y coordinate of the subnet
x_pos double x position of the point to translate
y_pos double y position of the point to translate
pixel_width int width of the image map
units EtsT_Nt_Grid_Unit units of the bounding box, as given in Table 15 General Sub-Package Symbolic Constants
x_pixel_ptr int * pointer to return value of x-pixel position
y_pixel_ptr int * pointer to return value of y-pixel position

Return Type

EtsT_Compcode

EtsC_Compcode_Success when function succeeded, EtsC_Compcode_Failure when failed

ets_api_nt.h

Details

Given a bounding box in subnet coordinates, this function translates a position within that bounding box to pixel coordinates. Use this function to construct an HTML image map after capturing a specific portion of a subnet as a bitmap.

The first four arguments define the portion of the subnet that was captured. The next two arguments define the point you want to translate. pixel_width indicates the width of the image map (the height is inferred by the aspect ratio of the bounding box). units indicates the units of the bounding box (so that degrees can be handled properly). Finally, the results are passed back via the integer pointers passed to this function.

本站文档由 北京智网畅联科技有限公司 整理、翻译并提供 · Documentation compiled and provided by Beijing ZNetLink Technology Co., Ltd.

交流群 · QQ Group:OPNET/智网妙算网络仿真交流群(群号 486383494)

原文档 © 2017 Riverbed Technology · 本站为公益翻译,由 AI 辅助完成,请仔细甄别

Original documentation © 2017 Riverbed Technology. Community translation, AI-assisted. Contact: jiazequn@znetlink.com