VertexCoordRemapper Class Reference

#include <VertexCoordRemapper.h>

Inheritance diagram for VertexCoordRemapper:

Inheritance graph
[legend]
List of all members.

Public Member Functions

 VertexCoordRemapper (HuginBase::Panorama *m_pano, HuginBase::SrcPanoImage *image, VisualizationState *visualization_state)
virtual void UpdateAndResetIndex ()
virtual bool GetNextFaceCoordinates (Coords *result)
 Get the texture and vertex coordinates for the next face.

Private Member Functions

void RecursiveUpdate (unsigned int node_id, unsigned int stretch_x, unsigned int stretch_y)
void TestSubdivide (unsigned int node_id)
void DiscontinuityFlip (double vertex_c[2])
void SetLengthAndAngle (TreeNode *node)

Private Attributes

double tex_coords [2][2][2]
double s_vertex_coords [2][2][2]
double o_width
double o_height
double radius
double lower_bound
double upper_bound
double lower_bound_h
double upper_bound_h
double x_midpoint
double y_midpoint
double x_add_360
double y_add_360
bool done_node
unsigned int tree_node_id
unsigned short int discontinuity_flags
HuginBase::PanoramaOptions::ProjectionFormat output_projection
Tree tree

Constructor & Destructor Documentation

VertexCoordRemapper::VertexCoordRemapper HuginBase::Panorama m_pano,
HuginBase::SrcPanoImage image,
VisualizationState visualization_state
 

Definition at line 105 of file VertexCoordRemapper.cpp.


Member Function Documentation

void VertexCoordRemapper::DiscontinuityFlip double  vertex_c[2]  )  [private]
 

viewer) is not drawn.

Definition at line 257 of file VertexCoordRemapper.cpp.

References VisualizationState::GetProjectionInfo(), and OutputProjectionInfo::GetXAdd360().

Referenced by GetNextFaceCoordinates().

bool VertexCoordRemapper::GetNextFaceCoordinates Coords *  result  )  [virtual]
 

Get the texture and vertex coordinates for the next face.

The coordinates are ordered [left / right][top / bottom][x coord / y coord].

Returns:
false once specified all faces, true otherwise.

Implements MeshRemapper.

Definition at line 157 of file VertexCoordRemapper.cpp.

References MeshRemapper::ClipFace(), discontinuity_flags, DiscontinuityFlip(), done_node, VertexCoordRemapper::TreeNode::flags, VertexCoordRemapper::Tree::GetInputCoordinates(), VertexCoordRemapper::Tree::GetNext(), MeshRemapper::GiveClipFaceResult(), HuginBase::SrcPanoImage::isInside(), VertexCoordRemapper::Tree::nodes, s_vertex_coords, tex_coords, transform_fail_flag, tree, tree_node_id, and VertexCoordRemapper::TreeNode::verts.

void VertexCoordRemapper::RecursiveUpdate unsigned int  node_id,
unsigned int  stretch_x,
unsigned int  stretch_y
[private]
 

Referenced by UpdateAndResetIndex().

void VertexCoordRemapper::SetLengthAndAngle TreeNode node  )  [private]
 

Definition at line 775 of file VertexCoordRemapper.cpp.

References VertexCoordRemapper::TreeNode::angle_x, VertexCoordRemapper::TreeNode::angle_y, VertexCoordRemapper::TreeNode::length_x, VertexCoordRemapper::TreeNode::length_y, hugin_utils::sqr(), and VertexCoordRemapper::TreeNode::verts.

Referenced by TestSubdivide().

void VertexCoordRemapper::TestSubdivide unsigned int  node_id  )  [private]
 

Definition at line 477 of file VertexCoordRemapper.cpp.

References VertexCoordRemapper::TreeNode::angle_x, VertexCoordRemapper::TreeNode::angle_y, VertexCoordRemapper::TreeNode::flags, OutputProjectionInfo::GetLowerX(), VertexCoordRemapper::Tree::GetParentId(), VertexCoordRemapper::Tree::GetPosition(), VisualizationState::GetProjectionInfo(), VertexCoordRemapper::Tree::GetTransform(), OutputProjectionInfo::GetUpperX(), VisualizationState::GetVisibleArea(), VertexCoordRemapper::TreeNode::length_x, VertexCoordRemapper::TreeNode::length_y, lower_bound, lower_bound_h, M_PI, min_angle, VertexCoordRemapper::Tree::nodes, offscreen_safety_margin, SetLengthAndAngle(), split_flag_x, split_flag_y, tree, upper_bound, upper_bound_h, vertex_side_flag_start, and VertexCoordRemapper::TreeNode::verts.

void VertexCoordRemapper::UpdateAndResetIndex  )  [virtual]
 

Reimplemented from MeshRemapper.

Definition at line 113 of file VertexCoordRemapper.cpp.

References HuginBase::PTools::Transform::createInvTransform(), DEBUG_DEBUG, done_node, HuginBase::PanoramaOptions::getHeight(), OutputProjectionInfo::GetLowerX(), OutputProjectionInfo::GetLowerY(), OutputProjectionInfo::GetMiddleX(), OutputProjectionInfo::GetMiddleY(), VisualizationState::GetOptions(), HuginBase::PanoramaOptions::getProjection(), VisualizationState::GetProjectionInfo(), OutputProjectionInfo::GetRadius(), OutputProjectionInfo::GetUpperX(), OutputProjectionInfo::GetUpperY(), HuginBase::PanoramaOptions::getWidth(), OutputProjectionInfo::GetXAdd360(), OutputProjectionInfo::GetYAdd360(), lower_bound, lower_bound_h, o_height, o_width, output_projection, radius, RecursiveUpdate(), VertexCoordRemapper::Tree::ResetIndex(), MeshRemapper::SetCrop(), tree, MeshRemapper::UpdateAndResetIndex(), upper_bound, upper_bound_h, x_add_360, VertexCoordRemapper::Tree::x_crop_offs, VertexCoordRemapper::Tree::x_crop_scale, x_midpoint, y_add_360, VertexCoordRemapper::Tree::y_crop_offs, VertexCoordRemapper::Tree::y_crop_scale, and y_midpoint.


Member Data Documentation

unsigned short int VertexCoordRemapper::discontinuity_flags [private]
 

Definition at line 91 of file VertexCoordRemapper.h.

Referenced by GetNextFaceCoordinates().

bool VertexCoordRemapper::done_node [private]
 

Definition at line 88 of file VertexCoordRemapper.h.

Referenced by GetNextFaceCoordinates(), and UpdateAndResetIndex().

double VertexCoordRemapper::lower_bound [private]
 

Definition at line 75 of file VertexCoordRemapper.h.

Referenced by TestSubdivide(), and UpdateAndResetIndex().

double VertexCoordRemapper::lower_bound_h [private]
 

Definition at line 75 of file VertexCoordRemapper.h.

Referenced by TestSubdivide(), and UpdateAndResetIndex().

double VertexCoordRemapper::o_height [private]
 

Definition at line 75 of file VertexCoordRemapper.h.

Referenced by UpdateAndResetIndex().

double VertexCoordRemapper::o_width [private]
 

Definition at line 75 of file VertexCoordRemapper.h.

Referenced by UpdateAndResetIndex().

HuginBase::PanoramaOptions::ProjectionFormat VertexCoordRemapper::output_projection [private]
 

Definition at line 94 of file VertexCoordRemapper.h.

Referenced by UpdateAndResetIndex().

double VertexCoordRemapper::radius [private]
 

Definition at line 75 of file VertexCoordRemapper.h.

Referenced by UpdateAndResetIndex().

double VertexCoordRemapper::s_vertex_coords[2][2][2] [private]
 

Definition at line 75 of file VertexCoordRemapper.h.

Referenced by GetNextFaceCoordinates().

double VertexCoordRemapper::tex_coords[2][2][2] [private]
 

Definition at line 75 of file VertexCoordRemapper.h.

Referenced by GetNextFaceCoordinates().

Tree VertexCoordRemapper::tree [private]
 

Definition at line 175 of file VertexCoordRemapper.h.

Referenced by GetNextFaceCoordinates(), TestSubdivide(), and UpdateAndResetIndex().

unsigned int VertexCoordRemapper::tree_node_id [private]
 

Definition at line 89 of file VertexCoordRemapper.h.

Referenced by GetNextFaceCoordinates().

double VertexCoordRemapper::upper_bound [private]
 

Definition at line 75 of file VertexCoordRemapper.h.

Referenced by TestSubdivide(), and UpdateAndResetIndex().

double VertexCoordRemapper::upper_bound_h [private]
 

Definition at line 75 of file VertexCoordRemapper.h.

Referenced by TestSubdivide(), and UpdateAndResetIndex().

double VertexCoordRemapper::x_add_360 [private]
 

Definition at line 75 of file VertexCoordRemapper.h.

Referenced by UpdateAndResetIndex().

double VertexCoordRemapper::x_midpoint [private]
 

Definition at line 75 of file VertexCoordRemapper.h.

Referenced by UpdateAndResetIndex().

double VertexCoordRemapper::y_add_360 [private]
 

Definition at line 75 of file VertexCoordRemapper.h.

Referenced by UpdateAndResetIndex().

double VertexCoordRemapper::y_midpoint [private]
 

Definition at line 75 of file VertexCoordRemapper.h.

Referenced by UpdateAndResetIndex().


The documentation for this class was generated from the following files:
Generated on Tue Jul 29 01:25:51 2014 for Hugintrunk by  doxygen 1.3.9.1