-/*! ========================================================================
-** Synfig
-** Template File
-** $Id: region.cpp,v 1.1.1.1 2005/01/04 01:23:10 darco Exp $
+/* === S Y N F I G ========================================================= */
+/*! \file region.cpp
+** \brief Implementation of the "Region" layer
**
** This package is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License as
**
** This package is free software; you can redistribute it and/or
** modify it under the terms of the GNU General Public License as
** but WITHOUT ANY WARRANTY; without even the implied warranty of
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
** General Public License for more details.
** but WITHOUT ANY WARRANTY; without even the implied warranty of
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
** General Public License for more details.
SYNFIG_LAYER_INIT(Region);
SYNFIG_LAYER_SET_NAME(Region,"region");
SYNFIG_LAYER_INIT(Region);
SYNFIG_LAYER_SET_NAME(Region,"region");
-SYNFIG_LAYER_SET_LOCAL_NAME(Region,_("Region"));
-SYNFIG_LAYER_SET_CATEGORY(Region,_("Geometry"));
+SYNFIG_LAYER_SET_LOCAL_NAME(Region,N_("Region"));
+SYNFIG_LAYER_SET_CATEGORY(Region,N_("Geometry"));
bline_point_list.push_back(BLinePoint());
bline_point_list.push_back(BLinePoint());
bline_point_list.push_back(BLinePoint());
bline_point_list.push_back(BLinePoint());
bline_point_list.push_back(BLinePoint());
bline_point_list.push_back(BLinePoint());
- bline_point_list[0].set_vertex(Point(0,1));
- bline_point_list[1].set_vertex(Point(0,-1));
+ bline_point_list[0].set_vertex(Point(0,1));
+ bline_point_list[1].set_vertex(Point(0,-1));
- bline_point_list[0].set_tangent(bline_point_list[1].get_vertex()-bline_point_list[2].get_vertex()*0.5f);
- bline_point_list[1].set_tangent(bline_point_list[2].get_vertex()-bline_point_list[0].get_vertex()*0.5f);
- bline_point_list[2].set_tangent(bline_point_list[0].get_vertex()-bline_point_list[1].get_vertex()*0.5f);
- bline_point_list[0].set_width(1.0f);
- bline_point_list[1].set_width(1.0f);
- bline_point_list[2].set_width(1.0f);
+ bline_point_list[0].set_tangent(bline_point_list[1].get_vertex()-bline_point_list[2].get_vertex()*0.5f);
+ bline_point_list[1].set_tangent(bline_point_list[2].get_vertex()-bline_point_list[0].get_vertex()*0.5f);
+ bline_point_list[2].set_tangent(bline_point_list[0].get_vertex()-bline_point_list[1].get_vertex()*0.5f);
+ bline_point_list[0].set_width(1.0f);
+ bline_point_list[1].set_width(1.0f);
+ bline_point_list[2].set_width(1.0f);
//and start off at the first point
//move_to(last[0],last[1]);
//and start off at the first point
//move_to(last[0],last[1]);
//curve to the next end point
curve_to(iter->p1[0] + iter->t1[0]/3.0,iter->p1[1] + iter->t1[1]/3.0,
iter->p2[0] - iter->t2[0]/3.0,iter->p2[1] - iter->t2[1]/3.0,
iter->p2[0],iter->p2[1]);
//curve to the next end point
curve_to(iter->p1[0] + iter->t1[0]/3.0,iter->p1[1] + iter->t1[1]/3.0,
iter->p2[0] - iter->t2[0]/3.0,iter->p2[1] - iter->t2[1]/3.0,
iter->p2[0],iter->p2[1]);
if(iter->t1.is_equal_to(Vector(0,0)) && iter->t2.is_equal_to(Vector(0,0)))
{
vector_list.push_back(iter->p2);
if(iter->t1.is_equal_to(Vector(0,0)) && iter->t2.is_equal_to(Vector(0,0)))
{
vector_list.push_back(iter->p2);
if( (param=="segment_list" || param=="bline") && value.get_type()==ValueBase::TYPE_LIST)
{
//if(value.get_contained_type()!=ValueBase::TYPE_BLINEPOINT)
// return false;
if( (param=="segment_list" || param=="bline") && value.get_type()==ValueBase::TYPE_LIST)
{
//if(value.get_contained_type()!=ValueBase::TYPE_BLINEPOINT)
// return false;