Anti-Grain Geometry Tutorial
agg_conv_shorten_path.h
1
//----------------------------------------------------------------------------
2
// Anti-Grain Geometry - Version 2.4
3
// Copyright (C) 2002-2005 Maxim Shemanarev (http://www.antigrain.com)
4
//
5
// Permission to copy, use, modify, sell and distribute this software
6
// is granted provided this copyright notice appears in all copies.
7
// This software is provided "as is" without express or implied
8
// warranty, and with no claim as to its suitability for any purpose.
9
//
10
//----------------------------------------------------------------------------
11
// Contact: mcseem@antigrain.com
12
// mcseemagg@yahoo.com
13
// http://www.antigrain.com
14
//----------------------------------------------------------------------------
15
16
#ifndef AGG_CONV_SHORTEN_PATH_INCLUDED
17
#define AGG_CONV_SHORTEN_PATH_INCLUDED
18
19
#include "agg_basics.h"
20
#include "agg_conv_adaptor_vcgen.h"
21
#include "agg_vcgen_vertex_sequence.h"
22
23
namespace
agg
24
{
25
26
//=======================================================conv_shorten_path
27
template
<
class
VertexSource>
class
conv_shorten_path
:
28
public
conv_adaptor_vcgen
<VertexSource, vcgen_vertex_sequence>
29
{
30
public
:
31
typedef
conv_adaptor_vcgen<VertexSource, vcgen_vertex_sequence>
base_type
;
32
33
conv_shorten_path
(VertexSource& vs) :
34
conv_adaptor_vcgen<VertexSource, vcgen_vertex_sequence>
(vs)
35
{
36
}
37
38
void
shorten(
double
s) { base_type::generator().shorten(s); }
39
double
shorten()
const
{
return
base_type::generator().shorten(); }
40
41
private
:
42
conv_shorten_path
(
const
conv_shorten_path<VertexSource>
&);
43
const
conv_shorten_path<VertexSource>
&
44
operator = (
const
conv_shorten_path<VertexSource>
&);
45
};
46
47
48
}
49
50
#endif
agg::conv_shorten_path
Definition:
agg_conv_shorten_path.h:27
agg::conv_adaptor_vcgen
Definition:
agg_conv_adaptor_vcgen.h:38
agg
Definition:
agg_arc.cpp:24
agg-2.4
include
agg_conv_shorten_path.h
Generated by
1.8.13