tahoma2d/toonz/sources/stdfx/igs_rotate_blur.h

53 lines
2.3 KiB
C
Raw Normal View History

2016-05-17 03:04:11 +12:00
#pragma once
2016-03-19 06:57:51 +13:00
#ifndef igs_rotate_blur_h
#define igs_rotate_blur_h
#ifndef IGS_ROTATE_BLUR_EXPORT
#define IGS_ROTATE_BLUR_EXPORT
#endif
2022-02-16 17:49:00 +13:00
#include "tgeometry.h"
2016-06-15 18:43:10 +12:00
namespace igs {
namespace rotate_blur {
2016-03-19 06:57:51 +13:00
IGS_ROTATE_BLUR_EXPORT void convert(
2022-02-16 17:49:00 +13:00
const float* in, float* out, const int margin,
const TDimension out_dim, /* 求める画像(out)のサイズ */
const int channels, const float* ref, /* outと同じ高さ、幅 */
const TPointD center, const double degree = 30.0, /* ぼかしの回転角度 */
const double blur_radius = 0.0, /* ぼかしの始まる半径 */
const double spin_radius = 0.0, /* ゼロ以上でspin指定となり、
2016-06-15 18:43:10 +12:00
*/
2022-02-16 17:49:00 +13:00
const int type = 0, // 0: Accelerator, 1: Uniform Angle, 2: Uniform Length
const bool antialias_sw =
true, /* when true, sampled pixel will be bilinear-interpolated */
const bool alpha_rendering_sw = true,
const double ellipse_aspect_ratio = 1.0, const double ellipse_angle = 0.0);
2016-06-15 18:43:10 +12:00
#if 0 //------------------- comment out start ------------------------
2016-03-19 06:57:51 +13:00
IGS_ROTATE_BLUR_EXPORT int enlarge_margin(
const int height /* 求める画像(out)の高さ */
,const int width /* 求める画像(out)の幅 */
,const double xc
,const double yc
,const double degree /* ぼかしの回転角度 */
,const double blur_radius /* ぼかしの始まる半径 */
,const double spin_radius /* ゼロ以上でspin指定となり、
*/
,const int sub_div /* 1ならJaggy、2以上はAntialias */
);
2016-06-15 18:43:10 +12:00
#endif //------------------- comment out end -------------------------
2016-03-19 06:57:51 +13:00
IGS_ROTATE_BLUR_EXPORT int reference_margin(
2022-02-16 17:49:00 +13:00
const int height, /* 求める画像(out)の高さ */
const int width, /* 求める画像(out)の幅 */
const TPointD center, const double degree, /* ぼかしの回転角度 */
const double blur_radius, /* ぼかしの始まる半径 */
const double spin_radius, /* ゼロ以上でspin指定となり、
2016-06-15 18:43:10 +12:00
*/
2022-05-25 14:16:27 +12:00
const int type, // 0: Accelerator, 1: Uniform Angle, 2: Uniform Length
const double ellipse_aspect_ratio = 1.0);
2022-02-16 17:49:00 +13:00
} // namespace rotate_blur
} // namespace igs
2016-03-19 06:57:51 +13:00
#endif /* !igs_rotate_blur_h */