1 /* === S I N F G =========================================================== */
3 ** \brief Blur Helper Header file
5 ** $Id: blur.h,v 1.1.1.1 2005/01/04 01:23:14 darco Exp $
8 ** Copyright (c) 2002 Robert B. Quattlebaum Jr.
10 ** This software and associated documentation
11 ** are CONFIDENTIAL and PROPRIETARY property of
12 ** the above-mentioned copyright holder.
14 ** You may not copy, print, publish, or in any
15 ** other way distribute this software without
16 ** a prior written agreement with
17 ** the copyright holder.
20 /* ========================================================================= */
22 /* === S T A R T =========================================================== */
24 #ifndef __SINFG_BLUR_HELPER_H
25 #define __SINFG_BLUR_HELPER_H
27 /* === H E A D E R S ======================================================= */
28 #include <sinfg/surface.h>
29 #include <sinfg/color.h>
30 #include <sinfg/vector.h>
32 /* === M A C R O S ========================================================= */
34 /* === T Y P E D E F S ===================================================== */
36 /* === C L A S S E S & S T R U C T S ======================================= */
37 class sinfg::ProgressCallback;
50 FORCE_DWORD = 0x8fffffff
57 sinfg::ProgressCallback *cb;
60 sinfg::Point & set_size(const sinfg::Point &v) { return (size = v); }
61 const sinfg::Point & get_size() const { return size; }
62 sinfg::Point & get_size() { return size; }
64 int & set_type(const int &t) { return (type = t); }
65 const int & get_type() const { return type; }
66 int & get_type() { return type; }
69 Blur(const sinfg::Point &s, int t, sinfg::ProgressCallback *callb=0):size(s), type(t), cb(callb) {}
70 Blur(sinfg::Real sx, sinfg::Real sy, int t, sinfg::ProgressCallback *callb = 0): size(sx,sy), type(t), cb(callb) {}
73 sinfg::Point operator ()(const sinfg::Point &p) const;
74 sinfg::Point operator ()(sinfg::Real x, sinfg::Real y) const;
77 // input surface can be the same as output surface,
78 // though both have to be the same size
79 bool operator ()(const sinfg::Surface &surface, const sinfg::Vector &resolution, sinfg::Surface &out) const;
81 bool operator ()(const etl::surface<float> &surface, const sinfg::Vector &resolution, etl::surface<float> &out) const;
82 //bool operator ()(const etl::surface<unsigned char> &surface, const sinfg::Vector &resolution, etl::surface<unsigned char> &out) const;
85 /* === E N D =============================================================== */