[mapguide-commits] r1241 - trunk/MgDev/Common/Stylization

svn_mapguide at osgeo.org svn_mapguide at osgeo.org
Thu Mar 15 12:45:47 EDT 2007


Author: traianstanev
Date: 2007-03-15 12:45:47 -0400 (Thu, 15 Mar 2007)
New Revision: 1241

Modified:
   trunk/MgDev/Common/Stylization/SE_LineBuffer.cpp
   trunk/MgDev/Common/Stylization/SE_LineBuffer.h
Log:
My previous cleanup made way for more cleanup -- got rid of unnecessary stuff in SE_LineBuffer, now that features are kept as regular LineBuffers.

Modified: trunk/MgDev/Common/Stylization/SE_LineBuffer.cpp
===================================================================
--- trunk/MgDev/Common/Stylization/SE_LineBuffer.cpp	2007-03-15 16:35:45 UTC (rev 1240)
+++ trunk/MgDev/Common/Stylization/SE_LineBuffer.cpp	2007-03-15 16:45:47 UTC (rev 1241)
@@ -356,7 +356,6 @@
     m_max_segs(size),
     m_xf_tol(-1.0),
     m_xf_weight(-1.0),
-    m_src_lb(NULL),
     m_xf_bounds(NULL),
     m_inst_bounds(NULL),
     m_compute_bounds(true)
@@ -484,7 +483,6 @@
         m_inst_bounds->Free();
         m_inst_bounds = NULL;
     }
-    m_src_lb = NULL;
     m_xf_tol = m_xf_weight = -1.0;
     m_xf.setIdentity();
     m_xf_buf->Reset();
@@ -515,9 +513,6 @@
         m_xf_bounds = NULL;
     }
 
-    if (m_src_lb)
-        return Transform(m_src_lb, xform, weight);
-
     m_xf = xform;
     m_xf_tol = tolerance;
     m_xf_weight = weight;
@@ -641,7 +636,7 @@
 
     return m_xf_buf;
 }
-
+/*
 LineBuffer* SE_LineBuffer::Transform(LineBuffer* lb, const SE_Matrix& xform, double weight)
 {
     m_src_lb = lb;
@@ -663,7 +658,7 @@
 
     return m_xf_buf;
 }
-
+*/
 LineBuffer* SE_LineBuffer::TransformInstance(const SE_Matrix& xform)
 {
     m_inst_buf->SetToTransform(xform, m_xf_buf);
@@ -686,10 +681,7 @@
 
 bool SE_LineBuffer::Empty()
 {
-    if (m_src_lb)
-        return m_src_lb->point_count() == 0;
-    else
-        return m_npts == 0;
+    return m_npts == 0;
 }
 
 void SE_LineBuffer::Free()
@@ -750,7 +742,6 @@
 SE_LineBuffer* SE_LineBuffer::Clone()
 {
     SE_LineBuffer* clone = m_pool->NewLineBuffer(m_npts);
-    clone->m_src_lb = m_src_lb;
     clone->m_start[0] = m_start[0];
     clone->m_start[1] = m_start[1];
     clone->m_last[0] = m_last[0];

Modified: trunk/MgDev/Common/Stylization/SE_LineBuffer.h
===================================================================
--- trunk/MgDev/Common/Stylization/SE_LineBuffer.h	2007-03-15 16:35:45 UTC (rev 1240)
+++ trunk/MgDev/Common/Stylization/SE_LineBuffer.h	2007-03-15 16:45:47 UTC (rev 1241)
@@ -61,13 +61,11 @@
     STYLIZATION_API void Free();
 
     STYLIZATION_API LineBuffer* Transform(const SE_Matrix& xform, double weight = 0.0, double tolerance = .25);
-    STYLIZATION_API LineBuffer* Transform(LineBuffer* srclb, const SE_Matrix& xform, double weight = 0.0);
     STYLIZATION_API LineBuffer* TransformInstance(const SE_Matrix& xform);
 
     STYLIZATION_API SE_INLINE bool& compute_bounds() { return m_compute_bounds; }
     STYLIZATION_API SE_INLINE LineBuffer* xf_buffer() { return (LineBuffer*)m_xf_buf; }
     STYLIZATION_API SE_INLINE LineBuffer* inst_buffer() { return (LineBuffer*)m_inst_buf; }
-    STYLIZATION_API SE_INLINE LineBuffer* src_buffer() { return m_src_lb; }
     STYLIZATION_API SE_INLINE SE_Bounds* xf_bounds() { return m_xf_bounds; }
     STYLIZATION_API SE_INLINE SE_Bounds* inst_bounds() { return m_inst_bounds; }
 
@@ -80,7 +78,6 @@
     SE_Bounds* ComputeConvexHull(double* pnts, int* cntrs, int ncntrs, double weight);
 
     SE_LineBufferPool* m_pool;
-    LineBuffer* m_src_lb;
 
     double* m_pts;
     SE_LB_SegType* m_segs;



More information about the mapguide-commits mailing list