Tesseract  3.02
tesseract-ocr/ccstruct/ccstruct.cpp
Go to the documentation of this file.
00001 
00002 // File:        ccstruct.cpp
00003 // Description: ccstruct class.
00004 // Author:      Samuel Charron
00005 //
00006 // (C) Copyright 2006, Google Inc.
00007 // Licensed under the Apache License, Version 2.0 (the "License");
00008 // you may not use this file except in compliance with the License.
00009 // You may obtain a copy of the License at
00010 // http://www.apache.org/licenses/LICENSE-2.0
00011 // Unless required by applicable law or agreed to in writing, software
00012 // distributed under the License is distributed on an "AS IS" BASIS,
00013 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00014 // See the License for the specific language governing permissions and
00015 // limitations under the License.
00016 //
00018 
00019 #include "ccstruct.h"
00020 
00021 namespace tesseract  {
00022 
00023 // APPROXIMATIONS of the fractions of the character cell taken by
00024 // the descenders, ascenders, and x-height.
00025 const double CCStruct::kDescenderFraction = 0.25;
00026 const double CCStruct::kXHeightFraction = 0.5;
00027 const double CCStruct::kAscenderFraction = 0.25;
00028 const double CCStruct::kXHeightCapRatio = CCStruct::kXHeightFraction /
00029     (CCStruct::kXHeightFraction + CCStruct::kAscenderFraction);
00030 
00031 CCStruct::CCStruct()
00032   : image_(this) {
00033 }
00034 
00035 CCStruct::~CCStruct() {
00036 }
00037 
00038 }