1<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 2<html xml:lang="en-US" lang="en-US" xmlns="http://www.w3.org/1999/xhtml"> 3 <head> 4 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> 5 <meta http-equiv="Content-Style-Type" content="text/css" /> 6 <link rel="stylesheet" href="../../../css/manpage.css" type="text/css" /> 7<title>SetDetailSize</title> 8 </head> 9 <body> 10<h1><CODE>nn::camera::CTR::SetDetailSize</CODE> Function</h1> 11<h2>Syntax</h2> 12 <div class="section"> 13 <pre class="definition"> 14<a href="../../../nn/Result/Overview.html">nn::Result</a> SetDetailSize( 15<a href="../../../nn/camera/CTR/CameraSelect.html">CameraSelect</a> select, 16s16 width , 17s16 height , 18s16 cropX0 = 0, 19s16 cropY0 = 0, 20s16 cropX1 = 639, 21s16 cropY1 = 479, 22<a href="../../../nn/camera/CTR/Context.html">Context</a> context = CONTEXT_BOTH 23); 24</pre> 25 </div> 26<h2>Arguments</h2> 27 <div class="section"> 28 <table class="arguments"> 29 <thead> 30 <tr> 31 <td width="15" /> 32<th>Name</th> 33<td>Description</td> 34 </tr> 35 </thead> 36 <tr> 37<td>in</td> 38<th>select</th> 39<td>Specifies which camera to change settings for.</td> 40 </tr> 41 <tr> 42<td>in</td> 43<th>width</th> 44<td>Specifies the image width.</td> 45 </tr> 46 <tr> 47<td>in</td> 48<th>height</th> 49<td>Specifies the image width.</td> 50 </tr> 51 <tr> 52<td>in</td> 53<th>cropX0</th> 54<td>Specifies the x-coordinate of the upper-left corner of the crop region when the original 640x480 image is cropped internally by the camera module. Must be specified in the range [0, 639], regardless of the output size of the image. Specify a crop region width that is greater than or equal to the output image width. If omitted, the default value of 0 will be used.</td> 55 </tr> 56 <tr> 57<td>in</td> 58<th>cropY0</th> 59<td>Specifies the y-coordinate of the upper-left corner of the crop region when the original 640x480 image is cropped internally by the camera module. Must be specified in the range [0, 479], regardless of the output size of the image. Specify a crop region height that is greater than or equal to the output image height. If omitted, the default value of 0 will be used.</td> 60 </tr> 61 <tr> 62<td>in</td> 63<th>cropX1</th> 64<td>Specifies the x-coordinate of the lower-right corner of the crop region when the original 640x480 image is cropped internally by the camera module. Must be specified in the range [0, 639], regardless of the output size of the image. Specify a crop region width that is greater than or equal to the output image width. If omitted, the default value of 639 will be used.</td> 65 </tr> 66 <tr> 67<td>in</td> 68<th>cropY1</th> 69<td>Specifies the y-coordinate of the lower-right corner of the crop region when the original 640x480 image is cropped internally by the camera module. Must be specified in the range [0, 479], regardless of the output size of the image. Specify a crop region height that is greater than or equal to the output image height. If omitted, the default value of 479 will be used.</td> 70 </tr> 71 <tr> 72<td>in</td> 73<th>context</th> 74<td>Specifies which context to change settings for. If omitted, the settings will be applied both to context A and context B.</td> 75 </tr> </table> 76 </div> 77<h2>Return Values</h2> 78<div class="section">Returns the function's execution result. Returns one of the <a href="../../../nn/Result/Overview.html"><CODE>Result</CODE></a> values listed below. <br /> 79 <table class="arguments"> 80 <thead> 81 <tr> 82<th>Value</th> 83<td>Description</td> 84 </tr> 85 </thead> 86 <tr> 87<th><CODE>ResultSuccess</CODE></th> 88<td>Process was successful.</td> 89 </tr> 90 <tr> 91<th><CODE>ResultIsSleeping</CODE></th> 92<td>Unusable because the system is closed.</td> 93 </tr> 94 <tr> 95<th><CODE>ResultFatalError</CODE></th> 96<td>There may be something physically wrong with the camera.</td> 97 </tr> 98 </table> </div> 99<h2>Description</h2> 100 <div class="section"> 101<p>Sets the resolution (in pixels).</p><p> 102This function can be used to specify the cropping region. The cropping region is the region to be output from within the 640 x 480 image captured by the camera module. For example, if an image size of 320 x 240 is specified, and the cropping region is specified as the full 640 x 480, the output image will be the 640 x 480 image resized to 320 x 240. Meanwhile, if an image size of 320 x 240 is specified, and the cropping region is specified as the 320 x 240 region in the center of the image, the cropping region will be output at the full size without shrinking. Consequently, change the cropping region size without changing the image size to produce a digital zoom effect. Or, move the cropping region to produce a pan or tilt effect. The cropping region size must be at least as big as the image size. You cannot produce a zoom effect by specifying an image size larger than the cropping region size. Doing so will cause this function to fail. 103 </p><p> 104When the image size aspect ratio is not 4:3 and the cropping region is left as the default, the 640 x 480 image will be reduced to match the specified image size, causing distortions on output. We therefore recommend using the same aspect ratios for the cropping region and the image size. 105</p><p>Note that this function may block for an extended period if a camera is restarting.</p></div> 106<h2>Revision History</h2> 107 <div class="section"> 108 <dl class="history"> 109 <dt>2010/09/24</dt> 110<dd>Added description of the cropping region. 111 </dd> 112 <dt>2010/07/17</dt> 113<dd>Added explanation about operation during restart. 114 </dd> 115 <dt>2010/02/02</dt> 116<dd>Initial version.<br /> 117 </dd> 118 </dl> 119 </div> 120 <hr><p>CONFIDENTIAL</p></body> 121</html>