⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 _ocr_example_image_view_8h-source.html

📁 基于symbian 平台 ocr 示例程序
💻 HTML
📖 第 1 页 / 共 3 页
字号:
<a name="l00217"></a>00217                             <span class="keyword">const</span> TInt aBlockCount);<a name="l00218"></a>00218 <span class="comment"></span><a name="l00219"></a>00219 <span class="comment">        /**</span><a name="l00220"></a>00220 <span class="comment">        * RecognizeDone writes recognition results to the datafile.</span><a name="l00221"></a>00221 <span class="comment">        * Then the text-view is activated to show the results.</span><a name="l00222"></a>00222 <span class="comment">        * @param aError  Error code to indicate the completion status</span><a name="l00223"></a>00223 <span class="comment">        * @param aBlocks  Pointer to the text information of the recognized</span><a name="l00224"></a>00224 <span class="comment">        *   image block. the memory ownership belongs to the OCR engine and</span><a name="l00225"></a>00225 <span class="comment">        *   will not be passed to your procedure after this calling</span><a name="l00226"></a>00226 <span class="comment">        * @param aBlockCount  Number of blocks identified</span><a name="l00227"></a>00227 <span class="comment">        */</span><a name="l00228"></a>00228         <span class="keywordtype">void</span> <a class="code" href="class_c_ocr_example_image_view.html#4149f35a8fe71a3b10562faddd824986">RecognizeDoneL</a>(TInt aError,<a name="l00229"></a>00229                             <span class="keyword">const</span> TOCRTextRgnInfo* aBlocks,<a name="l00230"></a>00230                             <span class="keyword">const</span> TInt aBlockCount);<a name="l00231"></a>00231 <span class="comment"></span><a name="l00232"></a>00232 <span class="comment">        /** initializes OCR Engine and sets languages according to settings */</span><a name="l00233"></a>00233         <span class="keywordtype">void</span> <a class="code" href="class_c_ocr_example_image_view.html#b32756a8fbffada316fc03085c4d0d52">InitializeOCREngineL</a>( OCREngineFactory::TEngineType aEngineType );<a name="l00234"></a>00234 <span class="comment"></span><a name="l00235"></a>00235 <span class="comment">        /** releases OCR Engine */</span><a name="l00236"></a>00236         <span class="keywordtype">void</span> <a class="code" href="class_c_ocr_example_image_view.html#b815b1b6d046be197859ca009a28a50a">ReleaseOCREngine</a>();<a name="l00237"></a>00237 <span class="comment"></span><a name="l00238"></a>00238 <span class="comment">        /**</span><a name="l00239"></a>00239 <span class="comment">        * Loads selected image file and scales it to the screen.</span><a name="l00240"></a>00240 <span class="comment">        * File selection dialog is first executed and then user-selected image</span><a name="l00241"></a>00241 <span class="comment">        * is loaded and fitted to the screen.</span><a name="l00242"></a>00242 <span class="comment">        */</span><a name="l00243"></a>00243         <span class="keywordtype">void</span> <a class="code" href="class_c_ocr_example_image_view.html#2003512dd8696219849f58d8ae1e3c37">OpenImageL</a>();<a name="l00244"></a>00244 <span class="comment"></span><a name="l00245"></a>00245 <span class="comment">        /**</span><a name="l00246"></a>00246 <span class="comment">        * closes opened image.</span><a name="l00247"></a>00247 <span class="comment">        * As a side-effect OCR Engine is also released.</span><a name="l00248"></a>00248 <span class="comment">        */</span><a name="l00249"></a>00249         <span class="keywordtype">void</span> <a class="code" href="class_c_ocr_example_image_view.html#7561e6dda22ddb24f4b8c58d0229ebc5">CloseImage</a>();<a name="l00250"></a>00250 <span class="comment"></span><a name="l00251"></a>00251 <span class="comment">        /** help function to display warning note */</span><a name="l00252"></a>00252         <span class="keywordtype">void</span> <a class="code" href="class_c_ocr_example_image_view.html#5d97b3005d7025da3ce0f8f008328e43">DisplayWarningL</a>( <span class="keyword">const</span> TDesC &amp;aDescr, TInt aErr) <span class="keyword">const</span>;<a name="l00253"></a>00253 <span class="comment"></span><a name="l00254"></a>00254 <span class="comment">        /**</span><a name="l00255"></a>00255 <span class="comment">        * help function to execute waitnote</span><a name="l00256"></a>00256 <span class="comment">        * @return ETrue, if operation completed; EFalse, if cancelled.</span><a name="l00257"></a>00257 <span class="comment">        */</span><a name="l00258"></a>00258         TBool <a class="code" href="class_c_ocr_example_image_view.html#41df03d3f25580af9a93f5af442ce677">ExecuteWaitNoteL</a>();<a name="l00259"></a>00259 <a name="l00260"></a>00260     <span class="keyword">private</span>: <span class="comment">// Data</span><span class="comment"></span><a name="l00261"></a>00261 <span class="comment">        /** image container */</span><a name="l00262"></a><a class="code" href="class_c_ocr_example_image_view.html#6dc94c8cd7c107bc61701348814020e6">00262</a>         <a class="code" href="class_c_ocr_example_image_container.html">COcrExampleImageContainer</a>   *<a class="code" href="class_c_ocr_example_image_view.html#6dc94c8cd7c107bc61701348814020e6">iContainer</a>;<a name="l00263"></a>00263 <span class="comment"></span><a name="l00264"></a>00264 <span class="comment">        /**</span><a name="l00265"></a>00265 <span class="comment">        * data needed by container to draw the screen. owned and controlled</span><a name="l00266"></a>00266 <span class="comment">        * by this class; container just refers to this</span><a name="l00267"></a>00267 <span class="comment">        */</span><a name="l00268"></a><a class="code" href="class_c_ocr_example_image_view.html#e72899bf23845a10c6b7559c2e896baa">00268</a>         <a class="code" href="class_t_screen_update_data.html">TScreenUpdateData</a>           <a class="code" href="class_c_ocr_example_image_view.html#e72899bf23845a10c6b7559c2e896baa">iData</a>;<a name="l00269"></a>00269 <span class="comment"></span><a name="l00270"></a>00270 <span class="comment">        /** file server session */</span><a name="l00271"></a><a class="code" href="class_c_ocr_example_image_view.html#7b548225db36c87401243f1080bbd0e8">00271</a>         RFs                         <a class="code" href="class_c_ocr_example_image_view.html#7b548225db36c87401243f1080bbd0e8">iFs</a>;<a name="l00272"></a>00272 <span class="comment"></span><a name="l00273"></a>00273 <span class="comment">        /** pointer to bitmap storing the original image */</span><a name="l00274"></a><a class="code" href="class_c_ocr_example_image_view.html#9eb6fa3188758350a81b83400892e787">00274</a>         CFbsBitmap                  *<a class="code" href="class_c_ocr_example_image_view.html#9eb6fa3188758350a81b83400892e787">iBitMap</a>;<a name="l00275"></a>00275 <span class="comment"></span><a name="l00276"></a>00276 <span class="comment">        /** pointer to utility object for loading and scaling the image */</span><a name="l00277"></a><a class="code" href="class_c_ocr_example_image_view.html#56132cb68e64726ad0658571e44e9644">00277</a>         <a class="code" href="class_n_o_c_r_utils_1_1_c_image_handler.html">NOCRUtils::CImageHandler</a>    *<a class="code" href="class_c_ocr_example_image_view.html#56132cb68e64726ad0658571e44e9644">iHandler</a>;<a name="l00278"></a>00278 <span class="comment"></span><a name="l00279"></a>00279 <span class="comment">        /** pointer to OCR Engine */</span><a name="l00280"></a><a class="code" href="class_c_ocr_example_image_view.html#c22846eecaea51cfb97699603e4227b3">00280</a>         MOCREngineInterface         *<a class="code" href="class_c_ocr_example_image_view.html#c22846eecaea51cfb97699603e4227b3">iEngine</a>;<a name="l00281"></a>00281 <span class="comment"></span><a name="l00282"></a>00282 <span class="comment">        /** application level settings */</span><a name="l00283"></a><a class="code" href="class_c_ocr_example_image_view.html#59c39b7488b211d41b665791026c2f7f">00283</a>         <a class="code" href="class_t_ocr_example_settings_data.html">TOcrExampleSettingsData</a>     &amp;<a class="code" href="class_c_ocr_example_image_view.html#59c39b7488b211d41b665791026c2f7f">iSettings</a>;<a name="l00284"></a>00284 <span class="comment"></span><a name="l00285"></a>00285 <span class="comment">       /**</span><a name="l00286"></a>00286 <span class="comment">        * enumeration values used for indicating in which state the application</span><a name="l00287"></a>00287 <span class="comment">        * currently is.</span><a name="l00288"></a>00288 <span class="comment">        */</span><a name="l00289"></a><a class="code" href="class_c_ocr_example_image_view.html#8e0e9e3030ee220d737a3e9e733390ec">00289</a>         <span class="keyword">enum</span> <a class="code" href="class_c_ocr_example_image_view.html#8e0e9e3030ee220d737a3e9e733390ec">TState</a><a name="l00290"></a>00290             {<a name="l00291"></a>00291             <a class="code" href="class_c_ocr_example_image_view.html#8e0e9e3030ee220d737a3e9e733390ec553253ec36b6a826ce4923c5dcf95a12">EInit</a>,              <span class="comment">///&lt; appl started; image not loaded</span><a name="l00292"></a>00292 <span class="comment"></span>            <a class="code" href="class_c_ocr_example_image_view.html#8e0e9e3030ee220d737a3e9e733390ecc7b1c96e80ea74eab865de4fc9f448ea">EImageOpened</a>,       <span class="comment">///&lt; image loaded</span><a name="l00293"></a>00293 <span class="comment"></span>            <a class="code" href="class_c_ocr_example_image_view.html#8e0e9e3030ee220d737a3e9e733390ec9a6601df59f457cc199cb4794fdbbd7b">EImageAnalyzed</a>,     <span class="comment">///&lt; layout analysis done</span><a name="l00294"></a><a class="code" href="class_c_ocr_example_image_view.html#8e0e9e3030ee220d737a3e9e733390ecc69c8b8ac41d2c6e9ecc88e4b6d684f9">00294</a> <span class="comment"></span>            <a class="code" href="class_c_ocr_example_image_view.html#8e0e9e3030ee220d737a3e9e733390ecc69c8b8ac41d2c6e9ecc88e4b6d684f9">EImageRecognized</a>    <span class="comment">///&lt; recognition done</span><a name="l00295"></a>00295 <span class="comment"></span>            };<a name="l00296"></a>00296 <span class="comment"></span><a name="l00297"></a>00297 <span class="comment">        /** state of the view */</span><a name="l00298"></a><a class="code" href="class_c_ocr_example_image_view.html#63052a309baec315239b427aa7647b76">00298</a>         <a class="code" href="class_c_ocr_example_image_view.html#8e0e9e3030ee220d737a3e9e733390ec">TState</a>                      <a class="code" href="class_c_ocr_example_image_view.html#63052a309baec315239b427aa7647b76">iState</a>;<a name="l00299"></a>00299 <span class="comment"></span><a name="l00300"></a>00300 <span class="comment">        /** indicates whether crosshair is active or not */</span><a name="l00301"></a><a class="code" href="class_c_ocr_example_image_view.html#b7e54289c236dbd01581864006b4069f">00301</a>         TBool                       <a class="code" href="class_c_ocr_example_image_view.html#b7e54289c236dbd01581864006b4069f">iCrosshairEnabled</a>;<a name="l00302"></a>00302 <span class="comment"></span><a name="l00303"></a>00303 <span class="comment">        /** flag indicating background process completion. used by waitnote. */</span><a name="l00304"></a><a class="code" href="class_c_ocr_example_image_view.html#a7f5826c4c1c2cbee83739946a8a013b">00304</a>         TBool                       <a class="code" href="class_c_ocr_example_image_view.html#a7f5826c4c1c2cbee83739946a8a013b">iBackgroundTaskDone</a>;<a name="l00305"></a>00305     };<a name="l00306"></a>00306 <a name="l00307"></a>00307 <span class="preprocessor">#endif //OCRIMAGEVIEW_H</span><a name="l00308"></a>00308 <span class="preprocessor"></span><a name="l00309"></a>00309 <span class="comment">// End of File</span></pre></div><hr><table x-use-null-cells		style="x-cell-content-align: top;				width: 100%;				border-spacing: 0px;				border-spacing: 0px;"		cellspacing=0		width=100%>  <col style="width: 50%;">  <col style="width: 50%;">  <tr style="x-cell-content-align: top;"	valign=top>  <td style="width: 50%;			padding-right: 10px;			padding-left: 10px;			border-right-style: None;			border-left-style: None;			border-top-style: None;			border-bottom-style: None;"	width=50%>  <p style="font-family: Arial;"><small style="font-size: smaller;">

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -