scaler.cpp
00001 00002 /*************************************************************************** 00003 * scaler.cpp - Scaler interface 00004 * 00005 * Generated: Thu Mar 29 11:04:03 2007 00006 * Copyright 2005-2007 Tim Niemueller [www.niemueller.de] 00007 * 00008 ****************************************************************************/ 00009 00010 /* This program is free software; you can redistribute it and/or modify 00011 * it under the terms of the GNU General Public License as published by 00012 * the Free Software Foundation; either version 2 of the License, or 00013 * (at your option) any later version. A runtime exception applies to 00014 * this software (see LICENSE.GPL_WRE file mentioned below for details). 00015 * 00016 * This program is distributed in the hope that it will be useful, 00017 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00018 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00019 * GNU Library General Public License for more details. 00020 * 00021 * Read the full text in the LICENSE.GPL_WRE file in the doc directory. 00022 */ 00023 00024 #include <fvutils/scalers/scaler.h> 00025 00026 /** @class Scaler <fvutils/scalers/scaler.h> 00027 * Image scaler interface. 00028 * Image scalers allow for scaling images by a given factor. 00029 * @author Tim Niemueller 00030 * 00031 * @fn void Scaler::set_scale_factor(float factor) 00032 * Set scale factor. 00033 * @param factor scale factor 00034 * 00035 * @fn void Scaler::set_original_dimensions(unsigned int width, unsigned int height) 00036 * Set original image dimensions. 00037 * @param width image width 00038 * @param height height 00039 * 00040 * @fn void Scaler::set_scaled_dimensions(unsigned int width, unsigned int height) 00041 * Set dimenins of scaled image buffer. 00042 * @param width image width 00043 * @param height height 00044 * 00045 * @fn void Scaler::set_original_buffer(unsigned char *buffer) 00046 * Set original image buffer. 00047 * @param buffer YUV 422 planar buffer 00048 * 00049 * @fn void Scaler::set_scaled_buffer(unsigned char *buffer) 00050 * Set scaled image buffer. 00051 * @param buffer YUV 422 planar buffer 00052 * 00053 * @fn void Scaler::scale() 00054 * Scale image. 00055 * 00056 * @fn unsigned int Scaler::needed_scaled_width() 00057 * Minimum needed width of scaled image depending on factor and original image width. 00058 * @return minimum needed width 00059 * 00060 * @fn unsigned int Scaler::needed_scaled_height() 00061 * Minimum needed height of scaled image depending on factor and original image height. 00062 * @return minimum needed height 00063 * 00064 * @fn float Scaler::get_scale_factor() 00065 * Returns the scale factor. 00066 * @return the scale factor 00067 */ 00068 00069 /** Virtual empty destructor. */ 00070 Scaler::~Scaler() 00071 { 00072 }

