Mdc Tools; Image Scaling Calculation Imgcpy_Calcscaling.exe - Epson S1C31D01 Software Manual

Cmos 32-bit single chip microcontroller peripheral circuit sample software manual
Table of Contents

Advertisement

2.5 MDC Tools

2.5.1

Image Scaling Calculation imgcpy_calcscaling.exe

The MDC image copying hardware has a round-off error limitation in which certain combinations of source
image size, destination image size, and scaling values will produce a result in which the full width and height of
the source image pixels are not copied.
The "imgcpy_calcscaling.exe" program is intended to provide a pre-calculation tool to generate the properly
compensated size, centers of transformation, and scaling values to program the MDC with given the original
source and destination dimensions. This utility tool takes into account the method of scaling calculations done in
the hardware, and provides values that should produce the desired results.
Example of use:
If the source image is 208x208 and destination image is also 208x208 (1:1 ratio), the calculated
left/right/top/bottom scaling value is 256. However, if these scaling values are used, the result is that only
207x207 pixels of the source image are copied to the destination image, and the right and bottom edge of the
source image are not copied. In order to compensate for this hardware limitation and copy 208x208 pixels to
the destination image, please use the compensated values calculated by this utility tool.
The usage of this utility tool is as follows.
1. Run the imgcpy_calcscaling.exe. Then, the console screen will open.
2. Input the original source image size and the original destination image size on the console screen(see Table
2.5.1.1). Then, the console screen will be output the compensated values(see Table 2.5.1.2).
Enter source image width: 208
Enter source image height: 208
Enter destination image width: 208
Enter destination image height: 208
Original source width = 208
Original source height = 208
Source width =
Source height =
Source Center X =
Source Center Y =
Destination width =
Destination height =
Destination Center X =
Destination Center Y =
XLSCALE =
XRSCALE =
YTSCALE =
YBSCALE =
S1C31D01 Peripheral Circuit
Sample Software Manual (Rev.3.00)
Table 2.5.1.1 Input of the original image size
Table 2.5.1.2 Output of the compensated values
210
210
104
104
208
208
104
104
257
252
257
252
Seiko Epson Corporation
Original source image size
Original destination image size
Compensated size for the source image
Compensated center coordinate of transformation for
the source image
Compensated size for the destination image
Compensated center coordinate of transformation for
the destination image
Compensated scaling values
23

Advertisement

Table of Contents
loading

Table of Contents