INTEGRATION: CWS mav19 (1.127.16); FILE MERGED 2006/01/10 18:40:48 mav 1.127.16.3: RESYNC: (1.127-1.128); FILE MERGED 2005/12/14 15:03:17 mav 1.127.16.2: #i52224# get BLIP size on import 2005/12/07 12:18:55 sj 1.127.16.1: #i52224# using correct visarea when importing ole objects

--- svx/source/msfilter/msdffimp.cxx
+++ svx/source/msfilter/msdffimp.cxx
@@ -4,9 +4,9 @@
  *
  *  $RCSfile: msdffimp.cxx,v $
  *
- *  $Revision: 1.128 $
+ *  $Revision: 1.129 $
  *
- *  last change: $Author: rt $ $Date: 2005-12-14 15:55:23 $
+ *  last change: $Author: kz $ $Date: 2006-02-01 19:01:26 $
  *
  *  The Contents of this file are made available subject to
  *  the terms of GNU Lesser General Public License Version 2.1.
@@ -1885,10 +1885,10 @@
             {
                 Graphic aGraf;
                 // first try to get BLIP from cache
-                BOOL bOK = rManager.GetBLIP( GetPropertyValue( DFF_Prop_fillBlip ), aGraf );
+                BOOL bOK = rManager.GetBLIP( GetPropertyValue( DFF_Prop_fillBlip ), aGraf, NULL );
                 // then try directly from stream (i.e. Excel chart hatches/bitmaps)
                 if ( !bOK )
-                    bOK = SeekToContent( DFF_Prop_fillBlip, rIn ) && rManager.GetBLIPDirect( rIn, aGraf );
+                    bOK = SeekToContent( DFF_Prop_fillBlip, rIn ) && rManager.GetBLIPDirect( rIn, aGraf, NULL );
                 if ( bOK )
                 {
                     Bitmap aBmp( aGraf.GetBitmap() );
@@ -4379,6 +4379,7 @@
     SdrObject*  pRet = NULL;
     String      aFilename;
     String      aLinkFileName, aLinkFilterName;
+    Rectangle   aVisArea;

     MSO_BlipFlags eFlags = (MSO_BlipFlags)GetPropertyValue( DFF_Prop_pibFlags, mso_blipflagDefault );
     sal_uInt32 nBlipId = GetPropertyValue( DFF_Prop_pib, 0 );
@@ -4394,7 +4395,7 @@
         //   UND, ODER folgendes:
         if( !( eFlags & mso_blipflagDoNotSave ) ) // Grafik embedded
         {
-            if (!(bGrfRead = GetBLIP(nBlipId, aGraf)))
+            if ( !( bGrfRead = GetBLIP( nBlipId, aGraf, &aVisArea ) ) )
             {
                 /*
                 Still no luck, lets look at the end of this record for a FBSE pool,
@@ -4415,7 +4416,7 @@
                     {
                         rSt.SeekRel(nSkip);
                         if (0 == rSt.GetError())
-                            bGrfRead = GetBLIPDirect( rSt, aGraf );
+                            bGrfRead = GetBLIPDirect( rSt, aGraf, &aVisArea );
                     }
                 }
             }
@@ -4556,8 +4557,7 @@
         if( bGrfRead && !bLinkGrf && IsProperty( DFF_Prop_pictureId ) )
         {
             // --> OD 2004-12-14 #i32596# - pass <nCalledByGroup> to method
-            pRet = ImportOLE( GetPropertyValue( DFF_Prop_pictureId ), aGraf,
-                              aBoundRect, rObjData.nCalledByGroup );
+            pRet = ImportOLE( GetPropertyValue( DFF_Prop_pictureId ), aGraf, aBoundRect, aVisArea, rObjData.nCalledByGroup );
             // <--
         }
         if( !pRet )
@@ -4594,6 +4594,11 @@
                 aLinkFilterName = aFilterName;
             }
         }
+
+        // set the size from BLIP if there is one
+        if ( pRet && bGrfRead && !aVisArea.IsEmpty() )
+            pRet->SetBLIPSizeRectangle( aVisArea );
+
         if ( !pRet->GetName().Len() )                   // SJ 22.02.00 : PPT OLE IMPORT:
         {                                               // name is already set in ImportOLE !!
             // JP 01.12.99: SetName before SetModel - because in the other order the Bug 70098 is active
@@ -6827,7 +6832,7 @@
 /*      Zugriff auf ein BLIP zur Laufzeit (bei bereits bekannter Blip-Nr)
     ---------------------------------
 ******************************************************************************/
-BOOL SvxMSDffManager::GetBLIP(ULONG nIdx_, Graphic& rData) const
+BOOL SvxMSDffManager::GetBLIP( ULONG nIdx_, Graphic& rData, Rectangle* pVisArea ) const
 {
     BOOL bOk = FALSE;       // Ergebnisvariable initialisieren
     if ( pStData )
@@ -6877,7 +6882,7 @@
             if( pStData->GetError() )
                 pStData->ResetError();
             else
-                bOk = GetBLIPDirect( *pStData, rData );
+                bOk = GetBLIPDirect( *pStData, rData, pVisArea );
             if( pStData2 && !bOk )
             {
                 // Fehler, aber zweite Chance: es gibt noch einen zweiten
@@ -6891,7 +6896,7 @@
                 if( pStData2->GetError() )
                     pStData2->ResetError();
                 else
-                    bOk = GetBLIPDirect( *pStData2, rData );
+                    bOk = GetBLIPDirect( *pStData2, rData, pVisArea );
                 // alte FilePos des zweiten Daten-Stream restaurieren
                 pStData2->Seek( nOldPosData2 );
             }
@@ -6917,7 +6922,7 @@
 /*      Zugriff auf ein BLIP zur Laufzeit (mit korrekt positioniertem Stream)
     ---------------------------------
 ******************************************************************************/
-BOOL SvxMSDffManager::GetBLIPDirect(SvStream& rBLIPStream, Graphic& rData) const
+BOOL SvxMSDffManager::GetBLIPDirect( SvStream& rBLIPStream, Graphic& rData, Rectangle* pVisArea ) const
 {
     ULONG nOldPos = rBLIPStream.Tell();

@@ -6948,6 +6953,9 @@

                 // scale to 1/100mm
                 aMtfSize100.Width() /= 360, aMtfSize100.Height() /= 360;
+
+                if ( pVisArea )     // seem that we currently are skipping the visarea position
+                    *pVisArea = Rectangle( Point(), aMtfSize100 );

                 // skip rest of header
                 nSkip = 6;
@@ -7157,6 +7165,7 @@
 SdrObject* SvxMSDffManager::ImportOLE( long nOLEId,
                                        const Graphic& rGrf,
                                        const Rectangle& rBoundRect,
+                                       const Rectangle& rVisArea,
                                        const int _nCalledByGroup ) const
 // <--
 {
@@ -7167,7 +7176,7 @@
     uno::Reference < embed::XStorage > xDstStg;
     if( GetOLEStorageName( nOLEId, sStorageName, xSrcStg, xDstStg ))
         pRet = CreateSdrOLEFromStorage( sStorageName, xSrcStg, xDstStg,
-                                        rGrf, rBoundRect, pStData, nError,
+                                        rGrf, rBoundRect, rVisArea, pStData, nError,
                                         nSvxMSDffOLEConvFlags );
     return pRet;
 }
@@ -7631,6 +7640,7 @@
                 const uno::Reference < embed::XStorage >& xDestStorage,
                 const Graphic& rGrf,
                 const Rectangle& rBoundRect,
+                const Rectangle& rVisArea,
                 SvStream* pDataStrm,
                 ErrCode& rError,
                 UINT32 nConvertFlags )
@@ -7746,14 +7756,30 @@
                 sal_Int64 nAspect = embed::Aspects::MSOLE_CONTENT;

                 // working with visual area can switch the object to running state
-                MapUnit aMapUnit = VCLUnoHelper::UnoEmbed2VCLMapUnit( xObj->getMapUnit( nAspect ) );
-                Size aSz(lcl_GetPrefSize(rGrf, MapMode(aMapUnit)));
-                //xInplaceObj->EnableSetModified( FALSE );
                 awt::Size aAwtSz;
-                aAwtSz.Width = aSz.Width();
-                aAwtSz.Height = aSz.Height();
-                xObj->setVisualAreaSize( nAspect, aAwtSz );
-                //xInplaceObj->EnableSetModified( TRUE );*/
+                try
+                {
+                    // the provided visual area should be used, if there is any
+                    if ( rVisArea.IsEmpty() )
+                    {
+                        MapUnit aMapUnit = VCLUnoHelper::UnoEmbed2VCLMapUnit( xObj->getMapUnit( nAspect ) );
+                        Size aSz(lcl_GetPrefSize(rGrf, MapMode(aMapUnit)));
+                        aAwtSz.Width = aSz.Width();
+                        aAwtSz.Height = aSz.Height();
+                    }
+                    else
+                    {
+                        aAwtSz.Width = rVisArea.GetWidth();
+                        aAwtSz.Height = rVisArea.GetHeight();
+                    }
+                    //xInplaceObj->EnableSetModified( FALSE );
+                    xObj->setVisualAreaSize( nAspect, aAwtSz );
+                    //xInplaceObj->EnableSetModified( TRUE );*/
+                }
+                catch( uno::Exception& )
+                {
+                    OSL_ENSURE( sal_False, "Could not set visual area of the object!\n" );
+                }

                 svt::EmbeddedObjectRef aObj( xObj, nAspect );


remove another unnecessary std::move

remove another unnecessary std::move

--- html_generator/main.cpp
+++ html_generator/main.cpp
@@ -173,13 +173,11 @@
 		    title(site_title) + tag("link", href("stylesheets.css") +
 		                                        attribute("rel", "stylesheet"),
 		                            empty));
-		auto body_content =
-		    body(std::move(
+		auto body_content = body(
 #include "pages/menu.hpp"
-		             ) +
-		         h1(text(site_title)) + std::move(page_content) +
+		    +h1(text(site_title)) + std::move(page_content) +
 #include "pages/footer.hpp"
-		         );
+		    );
 		auto const document =
 		    raw("<!DOCTYPE html>") +
 		    html(std::move(head_content) + std::move(body_content));


Fix edge cases around syncing AnimationPlayers

--- src/engine/core/src/graphics/sprite/animation_player.cpp
+++ src/engine/core/src/graphics/sprite/animation_player.cpp
@@ -282,7 +282,7 @@
 	setSequence(masterAnimator.getCurrentSequenceName());
 	setDirection(masterAnimator.getCurrentDirectionName());
 	visibleOverride = !hideIfNotSynchronized || getCurrentSequenceName() == masterAnimator.getCurrentSequenceName();
-	curFrame = clamp(masterAnimator.curFrame, 0, static_cast<int>(curSeq->numFrames()) - 1);
+	curFrame = clamp(masterAnimator.curFrame, 0, curSeq ? static_cast<int>(curSeq->numFrames()) - 1 : 0);
 	curFrameTime = masterAnimator.curFrameTime;

 	resolveSprite();
@@ -302,10 +302,12 @@
 {
 	updateIfNeeded();

-	const auto& frame = curSeq->getFrame(curFrame);
-	curFrameLen = std::max(1, frame.getDuration()) * 0.001; // 1ms minimum
-	spriteData = &frame.getSprite(dirId);
-	hasUpdate = true;
+	if (curSeq) {
+		const auto& frame = curSeq->getFrame(curFrame);
+		curFrameLen = std::max(1, frame.getDuration()) * 0.001; // 1ms minimum
+		spriteData = &frame.getSprite(dirId);
+		hasUpdate = true;
+	}
 }

 void AnimationPlayer::onSequenceStarted()


Adding explicit type conversion to overloaded log function as ARMCC fails to compile

--- TESTS/block_device/i2cee/main.cpp
+++ TESTS/block_device/i2cee/main.cpp
@@ -50,7 +50,7 @@
     uint8_t *write_block = new uint8_t[block_size];
     uint8_t *read_block = new uint8_t[block_size];
     uint8_t *error_mask = new uint8_t[TEST_ERROR_MASK];
-    unsigned addrwidth = ceil(log(bd.size()-1) / log(16))+1;
+    unsigned addrwidth = ceil(log(float(bd.size()-1)) / log(float(16)))+1;

     for (int b = 0; b < TEST_BLOCK_COUNT; b++) {
         // Find a random block


replaced rand() with better qt equivalent

--- examples/ex_clustered_inverse_pwl_rap_music_raw/main.cpp
+++ examples/ex_clustered_inverse_pwl_rap_music_raw/main.cpp
@@ -74,6 +74,7 @@
 #include <QElapsedTimer>
 #include <QCommandLineParser>
 #include <QVector3D>
+#include <QRandomGenerator>

 //#define BENCHMARK

@@ -448,11 +449,10 @@
     // Calculate the average
     // Option 1 - Random selection
     VectorXi vecSel(2);
-    srand (time(NULL)); // initialize random seed

     for(qint32 i = 0; i < vecSel.size(); ++i)
     {
-        qint32 val = rand() % count;
+        qint32 val = QRandomGenerator::global()->bounded(1,count);
         vecSel(i) = val;
     }


#88265# #89866# using SdrRectObj type OBJ_RECT instead of OBJ_TEXT, setting SdrModel earlier so that method SetVerticalWriting will not crash

--- svx/source/msfilter/msdffimp.cxx
+++ svx/source/msfilter/msdffimp.cxx
@@ -2,9 +2,9 @@
  *
  *  $RCSfile: msdffimp.cxx,v $
  *
- *  $Revision: 1.34 $
+ *  $Revision: 1.35 $
  *
- *  last change: $Author: ka $ $Date: 2001-07-30 12:23:30 $
+ *  last change: $Author: sj $ $Date: 2001-08-09 09:12:56 $
  *
  *  The Contents of this file are made available subject to the terms of
  *  either of the following licenses
@@ -3087,7 +3087,7 @@
                         if ( ( GetPropertyValue( DFF_Prop_fNoLineDrawDash ) & 8 )
                             || ( GetPropertyValue( DFF_Prop_fNoFillHitTest ) & 0x10 ) )
                         {
-                            pRet = new SdrRectObj( OBJ_TEXT, aBoundRect );
+                            pRet = new SdrRectObj( aBoundRect );  // SJ: changed the type from OBJ_TEXT to OBJ_RECT (#88277#)
                         }
                     }
                     else if (
@@ -3391,7 +3391,10 @@
             if( bTextFrame && pObj )
                 pTextObj = PTR_CAST(SdrRectObj, pObj);
             if( !pTextObj )
+            {
                 pTextObj = new SdrRectObj( OBJ_TEXT, rTextRect );
+                pTextObj->SetModel( pSdrModel );
+            }

             if( pTextObj != pObj )
                 pTextImpRec = new SvxMSDffImportRec( *pImpRec );
@@ -3534,8 +3537,6 @@
             }
             aSet.Put( SdrTextMinFrameHeightItem( rTextRect.Bottom() - rTextRect.Top() ) );
             aSet.Put( SdrTextMinFrameWidthItem( rTextRect.Right() - rTextRect.Left() ) );
-
-            pTextObj->SetModel( pSdrModel );
             pTextObj->SetItemSet(aSet);

             // rotate text with shape ?


Fix the random UT failure for RNN/GRU cases which have padded sequenc… (#1361)

Fix the random UT failure for RNN/GRU cases which have padded sequence. e.g. max_seq = 2. batch_size =2, sequence_lengths = {2, 1}. For the output beyond the shorter sequence {1}, we should initialize the value to 0.

Root cause:
Cudnn library doesn't guarantee the value beyond the shorter sequence.
Fix:
Initialize the output Y data to all 0 before calling cudnn library.

--- onnxruntime/core/providers/cuda/rnn/cudnn_rnn_base.cc
+++ onnxruntime/core/providers/cuda/rnn/cudnn_rnn_base.cc
@@ -220,6 +220,7 @@
     x_data = x_reversed_data.get();
   }

+  auto byte_size = X->DataType()->Size();
   const T* hx_data = (initial_h == nullptr) ? nullptr : initial_h->template Data<T>();
   const T* cx_data = (initial_c == nullptr) ? nullptr : initial_c->template Data<T>();
   T* y_h_data = (Y_h == nullptr) ? nullptr : Y_h->template MutableData<T>();
@@ -233,11 +234,12 @@
     y_alloc_data = GetScratchBuffer<T>(output_size);
     y_data = y_alloc_data.get();
   }
+  // Cudnn library doesn't guarantee the data beyond the shorter sequence will be initialized to 0, so we need to do it manually.
+  cudaMemset(y_data, 0, output_size * byte_size);
   const int32_t* sequence_lens_data = (sequence_lens == nullptr) ? nullptr : sequence_lens->template Data<int32_t>();

   size_t workspace_bytes;
   CUDNN_RETURN_IF_ERROR(cudnnGetRNNWorkspaceSize(CudnnHandle(), rnn_desc_, gsl::narrow_cast<int>(seq_length), x_desc.data(), &workspace_bytes));
-  workspace_bytes *= num_directions_;
   auto workspace_cuda = GetScratchBuffer<void>(workspace_bytes);

   if (CUDNN_RNN_RELU == rnn_mode_ || CUDNN_RNN_TANH == rnn_mode_ || nullptr == sequence_lens_data) {


add -D and -P option

add -D and -P option

git-svn-id: 5398946ba177a3e438c2dae55e2cdfc2fb96c905@2806 a9d63959-f2ad-4865-b262-bf0e56cfafb6

--- apps/src/openni_tracking.cpp
+++ apps/src/openni_tracking.cpp
@@ -91,7 +91,8 @@
   typedef typename ParticleFilter::CoherencePtr CoherencePtr;
   typedef typename pcl::search::KdTree<PointType> KdTree;
   typedef typename KdTree::Ptr KdTreePtr;
-  OpenNISegmentTracking (const std::string& device_id, int thread_nr, bool use_convex_hull, bool use_cog)
+  OpenNISegmentTracking (const std::string& device_id, int thread_nr, bool use_convex_hull, bool use_cog,
+                         bool visualize_non_downsample, bool visualize_particles)
   : viewer_ ("PCL OpenNI Tracking Viewer")
   , device_id_ (device_id)
   , new_cloud_ (false)
@@ -99,12 +100,18 @@
   , counter_ (0)
   , use_convex_hull_ (use_convex_hull)
   , use_cog_ (use_cog)
+  , visualize_non_downsample_ (visualize_non_downsample)
+  , visualize_particles_ (visualize_particles)
   {
     KdTreePtr tree (new KdTree (false));
     ne_.setSearchMethod (tree);
     ne_.setRadiusSearch (0.03);

     std::vector<double> default_step_covariance = std::vector<double> (6, 0.012 * 0.012);
+    default_step_covariance[3] *= 40.0;
+    default_step_covariance[4] *= 40.0;
+    default_step_covariance[5] *= 40.0;
+
     std::vector<double> initial_noise_covariance = std::vector<double> (6, 0.00001);
     std::vector<double> default_initial_mean = std::vector<double> (6, 0.0);
     tracker_ = boost::shared_ptr<ParticleFilter> (new ParticleFilter (thread_nr));
@@ -112,20 +119,16 @@

     // for KLD
     tracker_->setMaximumParticleNum (500);
-    tracker_->setDelta (0.9);
-    tracker_->setEpsilon (0.1);
+    tracker_->setDelta (0.99);
+    tracker_->setEpsilon (0.2);
     ParticleT bin_size;
     bin_size.x = 0.1;
     bin_size.y = 0.1;
     bin_size.z = 0.1;
-    bin_size.roll = 0.17;
-    bin_size.pitch = 0.17;
-    bin_size.yaw = 0.17;
+    bin_size.roll = 0.1;
+    bin_size.pitch = 0.1;
+    bin_size.yaw = 0.1;
     tracker_->setBinSize (bin_size);
-
-    default_step_covariance[3] *= 50.0;
-    default_step_covariance[4] *= 50.0;
-    default_step_covariance[5] *= 50.0;
     tracker_->setTrans (Eigen::Affine3f::Identity ());
     tracker_->setStepNoiseCovariance (default_step_covariance);
     tracker_->setInitialNoiseCovariance (initial_noise_covariance);
@@ -145,7 +148,7 @@

     boost::shared_ptr<HSVColorCoherence<RefPointType> > color_coherence
       = boost::shared_ptr<HSVColorCoherence<RefPointType> > (new HSVColorCoherence<RefPointType> ());
-    color_coherence->setWeight (0.01);
+    color_coherence->setWeight (0.1);
     coherence->addPointCoherence (color_coherence);

     //boost::shared_ptr<pcl::search::KdTree<RefPointType> > search (new pcl::search::KdTree<RefPointType> (false));
@@ -162,22 +165,25 @@
     ParticleFilter::PointCloudStatePtr particles = tracker_->getParticles ();
     if (particles)
     {
-      pcl::PointCloud<pcl::PointXYZ>::Ptr particle_cloud (new pcl::PointCloud<pcl::PointXYZ> ());
-      for (size_t i = 0; i < particles->points.size (); i++)
+      if (visualize_particles_)
       {
-        pcl::PointXYZ point;
+        pcl::PointCloud<pcl::PointXYZ>::Ptr particle_cloud (new pcl::PointCloud<pcl::PointXYZ> ());
+        for (size_t i = 0; i < particles->points.size (); i++)
+        {
+          pcl::PointXYZ point;
+
+          ParticleXYZRPY particle = particles->points[i];
+          point.x = particles->points[i].x;
+          point.y = particles->points[i].y;
+          point.z = particles->points[i].z;
+          particle_cloud->points.push_back (point);
+        }

-        ParticleXYZRPY particle = particles->points[i];
-        point.x = particles->points[i].x;
-        point.y = particles->points[i].y;
-        point.z = particles->points[i].z;
-        particle_cloud->points.push_back (point);
-      }
-
-      {
-        pcl::visualization::PointCloudColorHandlerCustom<pcl::PointXYZ> blue_color (particle_cloud, 250, 99, 71);
-        if (!viz.updatePointCloud (particle_cloud, blue_color, "particle cloud"))
-          viz.addPointCloud (particle_cloud, blue_color, "particle cloud");
+        {
+          pcl::visualization::PointCloudColorHandlerCustom<pcl::PointXYZ> blue_color (particle_cloud, 250, 99, 71);
+          if (!viz.updatePointCloud (particle_cloud, blue_color, "particle cloud"))
+            viz.addPointCloud (particle_cloud, blue_color, "particle cloud");
+        }
       }
       return true;
     }
@@ -193,9 +199,17 @@
   {
     ParticleXYZRPY result = tracker_->getResult ();
     Eigen::Affine3f transformation = tracker_->toEigenMatrix (result);
+    // move a little bit for better visualization
+    transformation.translation () += Eigen::Vector3f (0.0, 0.0, -0.005);
     RefCloudPtr result_cloud (new RefCloud ());
-
-    pcl::transformPointCloud<RefPointType> (*(tracker_->getReferenceCloud ()), *result_cloud, transformation);
+
+    if (!visualize_non_downsample_)
+      pcl::transformPointCloud<RefPointType> (*(tracker_->getReferenceCloud ()), *result_cloud, transformation);
+    else
+      pcl::transformPointCloud<RefPointType> (*reference_, *result_cloud, transformation);
+
+
+
     {
       pcl::visualization::PointCloudColorHandlerCustom<RefPointType> red_color (result_cloud, 0, 0, 255);
       if (!viz.updatePointCloud (result_cloud, red_color, "resultcloud"))
@@ -203,7 +217,7 @@
     }

   }
-
+
   void
   viz_cb (pcl::visualization::PCLVisualizer& viz)
   {
@@ -216,11 +230,19 @@
     }

     if (new_cloud_ && cloud_pass_downsampled_)
-      if (!viz.updatePointCloud (cloud_pass_downsampled_, "cloudpass"))
-      {
-        viz.addPointCloud (cloud_pass_downsampled_, "cloudpass");
-        viz.resetCameraViewpoint ("cloudpass");
-      }
+    {
+      CloudPtr cloud_pass;
+      if (!visualize_non_downsample_)
+        cloud_pass = cloud_pass_downsampled_;
+      else
+        cloud_pass = cloud_pass_;
+
+      if (!viz.updatePointCloud (cloud_pass, "cloudpass"))
+        {
+          viz.addPointCloud (cloud_pass, "cloudpass");
+          viz.resetCameraViewpoint ("cloudpass");
+        }
+    }

     if (new_cloud_ && reference_)
     {
@@ -228,6 +250,8 @@
       if (ret)
       {
         drawResult (viz);
+
+        // draw some texts
         viz.removeShape ("N");
         viz.addText ((boost::format ("number of Reference PointClouds: %d") % tracker_->getReferenceCloud ()->points.size ()).str (),
                      10, 20, 20, 1.0, 1.0, 1.0, "N");
@@ -538,10 +562,8 @@

           if (!use_cog_)
           {
-
             tracker_->setReferenceCloud (nonzero_ref);
             reference_ = ref_cloud;
-            std::cout << "N: " << ref_cloud->points.size () << std::endl;
           }
           else
           {
@@ -553,8 +575,6 @@
             trans.translation () = Eigen::Vector3f (c[0], c[1], c[2]);
             //pcl::transformPointCloudWithNormals<RefPointType> (*ref_cloud, *transed_ref, trans.inverse());
             pcl::transformPointCloud<RefPointType> (*nonzero_ref, *transed_ref, trans.inverse());
-
-            std::cout << "N: " << transed_ref->points.size () << std::endl;
             CloudPtr transed_ref_downsampled (new Cloud);
             gridSample (transed_ref, *transed_ref_downsampled, 0.01);
             tracker_->setReferenceCloud (transed_ref_downsampled);
@@ -604,10 +624,9 @@

     while (!viewer_.wasStopped ())
       boost::this_thread::sleep(boost::posix_time::seconds(1));
-    //interface->stop ();
-  }
-
-  //pcl::ApproximateVoxelGrid<PointType> grid_;
+    interface->stop ();
+  }
+
   pcl::visualization::CloudViewer viewer_;
   pcl::PointCloud<pcl::Normal>::Ptr normals_;
   CloudPtr cloud_pass_;
@@ -627,6 +646,8 @@
   int counter_;
   bool use_convex_hull_;
   bool use_cog_;
+  bool visualize_non_downsample_;
+  bool visualize_particles_;
   double tracking_time_;
   double computation_time_;
   double downsampling_time_;
@@ -640,6 +661,10 @@
             << std::endl;
   std::cout << "  -c: use COG of pointcloud as the origin of pointcloud to track."
             << std::endl;
+  std::cout << "  -D: visualizing with non-downsampled pointclouds."
+            << std::endl;
+  std::cout << "  -P: not visualizing particle cloud."
+            << std::endl;
 }

 int
@@ -647,11 +672,16 @@
 {
   bool use_convex_hull = true;
   bool use_cog = false;
-
+  bool visualize_non_downsample = false;
+  bool visualize_particles = true;
   if (pcl::console::find_argument (argc, argv, "-C") > 0)
     use_convex_hull = false;
   if (pcl::console::find_argument (argc, argv, "-c") > 0)
     use_cog = true;
+  if (pcl::console::find_argument (argc, argv, "-D") > 0)
+    visualize_non_downsample = true;
+  if (pcl::console::find_argument (argc, argv, "-P") > 0)
+    visualize_particles = false;

   if (argc < 2)
   {
@@ -668,6 +698,7 @@
   }

   // open kinect
-  OpenNISegmentTracking<pcl::PointXYZRGB> v (device_id, 8, use_convex_hull, use_cog);
+  OpenNISegmentTracking<pcl::PointXYZRGB> v (device_id, 8, use_convex_hull, use_cog,
+                                             visualize_non_downsample, visualize_particles);
   v.run ();
 }


used perspective resection to get the homogeneous transform from the camera to the tag

--- software/perception/car-tags/src/car-tags-driver.cpp
+++ software/perception/car-tags/src/car-tags-driver.cpp
@@ -32,6 +32,45 @@
     cv::Point2d p0, p1, p2, p3;
     Eigen::Matrix3d H;
 };
+
+
+Eigen::Matrix4d getRelativeTransform(TagMatch const& match, Eigen::Matrix3d const & K, double tag_size) {
+  std::vector<cv::Point3f> objPts;
+  std::vector<cv::Point2f> imgPts;
+  double s = tag_size/2.;
+  objPts.push_back(cv::Point3f(-s,-s, 0));
+  objPts.push_back(cv::Point3f( s,-s, 0));
+  objPts.push_back(cv::Point3f( s, s, 0));
+  objPts.push_back(cv::Point3f(-s, s, 0));
+
+
+  imgPts.push_back(match.p0);
+  imgPts.push_back(match.p1);
+  imgPts.push_back(match.p2);
+  imgPts.push_back(match.p3);
+
+  cv::Mat rvec, tvec;
+  cv::Matx33f cameraMatrix(
+                           K(0,0), 0, K(0,2),
+                           0, K(1,1), K(1,2),
+                           0,  0,  1);
+
+  cv::Vec4f distParam(0,0,0,0);
+  cv::solvePnP(objPts, imgPts, cameraMatrix, distParam, rvec, tvec);
+  cv::Matx33d r;
+  cv::Rodrigues(rvec, r);
+  Eigen::Matrix3d wRo;
+  wRo << r(0,0), r(0,1), r(0,2), r(1,0), r(1,1), r(1,2), r(2,0), r(2,1), r(2,2);
+
+  Eigen::Matrix4d T;
+  T.topLeftCorner(3,3) = wRo;
+  T.col(3).head(3) << tvec.at<double>(0), tvec.at<double>(1), tvec.at<double>(2);
+  T.row(3) << 0,0,0,1;
+
+  return T;
+}
+
+

 class AprilTagDetector {
     public:
@@ -181,6 +220,10 @@

             cv::line(image, cv::Point2d(o[0], o[1]), cv::Point2d(px[0], px[1]), cv::Scalar(255,0,255), 1, CV_AA);
             cv::line(image, cv::Point2d(o[0], o[1]), cv::Point2d(py[0], py[1]), cv::Scalar(255,255,0), 1, CV_AA);
+
+            auto T = getRelativeTransform(tags[i], K, 0.165);
+
+            //TODO: publish this transform on bot-frames
         }
         cv::imshow("detections", image);
         cv::waitKey(1);


minor cleanup

minor cleanup

--- eval/src/vespa/eval/tensor/dense/dense_xw_product_function.cpp
+++ eval/src/vespa/eval/tensor/dense/dense_xw_product_function.cpp
@@ -90,20 +90,12 @@
       _commonDimensionInnermost(matrixHasCommonDimensionInnermost)
 {}

-namespace {
-
-} // namespace <unnamed>
-
 eval::InterpretedFunction::Instruction
 DenseXWProductFunction::compile_self(Stash &stash) const
 {
     Self &self = stash.create<Self>(result_type(), _vectorSize, _resultSize, stash);
-    if (_commonDimensionInnermost) {
-        return eval::InterpretedFunction::Instruction(my_op<true>, (uint64_t)(&self));
-    } else {
-        return eval::InterpretedFunction::Instruction(my_op<false>, (uint64_t)(&self));
-    }
+    auto op = _commonDimensionInnermost ? my_op<true> : my_op<false>;
+    return eval::InterpretedFunction::Instruction(op, (uint64_t)(&self));
 }

-}
-
+} // namespace vespalib::tensor


Bug #86207#: ole counter as global static

--- svx/source/msfilter/msdffimp.cxx
+++ svx/source/msfilter/msdffimp.cxx
@@ -2,9 +2,9 @@
  *
  *  $RCSfile: msdffimp.cxx,v $
  *
- *  $Revision: 1.25 $
+ *  $Revision: 1.26 $
  *
- *  last change: $Author: sj $ $Date: 2001-04-12 10:27:55 $
+ *  last change: $Author: jp $ $Date: 2001-04-26 15:01:57 $
  *
  *  The Contents of this file are made available subject to the terms of
  *  either of the following licenses
@@ -308,6 +308,9 @@

 #define ITEMVALUE(ItemSet,Id,Cast)  ((const Cast&)(ItemSet).Get(Id)).GetValue()

+// static counter for OLE-Objects
+static sal_uInt32 nMSOleObjCntr = 0;
+
 //---------------------------------------------------------------------------
 //  Hilfs Klassen aus MSDFFDEF.HXX
 //---------------------------------------------------------------------------
@@ -4874,7 +4877,6 @@
                             String aDstStgName( String::CreateFromAscii(
                                 RTL_CONSTASCII_STRINGPARAM( "MSO_OLE_Obj" )));

-                            static sal_uInt32 nMSOleObjCntr = 0;
                             aDstStgName += String::CreateFromInt32( ++nMSOleObjCntr );

                             SvStorageRef xObjStor( rDestStorage.OpenStorage(
@@ -4916,7 +4918,6 @@
         String aDstStgName( String::CreateFromAscii(
                                 RTL_CONSTASCII_STRINGPARAM( "MSO_OLE_Obj" )));

-        static sal_uInt32 nMSOleObjCntr = 0;
         aDstStgName += String::CreateFromInt32( ++nMSOleObjCntr );
         SvStorageRef xObjStor;


added tag config parsing

added tag config parsing


ARB_texture_filter_minmax tests should check if the extension is supported

Component: OpenGL
Vk-GL-CTS issue: 409

Affects:
KHR-GL45.texture_filter_minmax_tests.*

Change-Id: Ic1e63db507afb7a25f30b3309ba06fce2889cb8a

--- external/openglcts/modules/gl/gl4cTextureFilterMinmaxTests.cpp
+++ external/openglcts/modules/gl/gl4cTextureFilterMinmaxTests.cpp
@@ -519,6 +519,12 @@
  */
 tcu::TestNode::IterateResult TextureFilterMinmaxParameterQueriesTestCase::iterate()
 {
+	if (!m_context.getContextInfo().isExtensionSupported("GL_ARB_texture_filter_minmax"))
+	{
+		m_testCtx.setTestResult(QP_TEST_RESULT_NOT_SUPPORTED, "Not Supported");
+		return STOP;
+	}
+
 	const glw::Functions& gl = m_context.getRenderContext().getFunctions();

 	testReductionModeQueriesDefaultValues(gl);
@@ -647,6 +653,12 @@
 */
 tcu::TestNode::IterateResult TextureFilterMinmaxFilteringTestCaseBase::iterate()
 {
+	if (!m_context.getContextInfo().isExtensionSupported("GL_ARB_texture_filter_minmax"))
+	{
+		m_testCtx.setTestResult(QP_TEST_RESULT_NOT_SUPPORTED, "Not Supported");
+		return STOP;
+	}
+
 	const glu::RenderContext& renderContext = m_context.getRenderContext();
 	const glw::Functions&	 gl			= renderContext.getFunctions();

@@ -766,6 +778,12 @@
 */
 tcu::TestNode::IterateResult TextureFilterMinmaxSupportTestCase::iterate()
 {
+	if (!m_context.getContextInfo().isExtensionSupported("GL_ARB_texture_filter_minmax"))
+	{
+		m_testCtx.setTestResult(QP_TEST_RESULT_NOT_SUPPORTED, "Not Supported");
+		return STOP;
+	}
+
 	const glu::RenderContext& renderContext = m_context.getRenderContext();
 	const glw::Functions&	 gl			= renderContext.getFunctions();


Implement real code emission, at least for Instruction patterns,
next up: support for expanders

git-svn-id: a4a6f32337ebd29ad4763b423022f00f68d1c7b7@7710 91177308-0d34-0410-b5e6-96231b3b80d8

--- TableGen/InstrSelectorEmitter.cpp
+++ TableGen/InstrSelectorEmitter.cpp
@@ -777,18 +777,31 @@
 static void ReduceAllOperands(TreePatternNode *N, const std::string &Name,
              std::vector<std::pair<TreePatternNode*, std::string> > &Operands,
                               std::ostream &OS) {
-  if (!N->isLeaf()) {
+  if (N->isLeaf()) {
+    // If this is a leaf, register or nonterminal reference...
+    std::string SlotName = Pattern::getSlotName(N->getValueRecord());
+    OS << "    ReducedValue_" << SlotName << " *" << Name << "Val = Reduce_"
+       << SlotName << "(" << Name << ", MBB);\n";
+    Operands.push_back(std::make_pair(N, Name+"Val"));
+  } else if (N->getNumChildren() == 0) {
+    // This is a reference to a leaf tree node, like an immediate or frame
+    // index.
+    if (N->getType() != MVT::isVoid) {
+      std::string SlotName =
+        getNodeName(N->getOperator()) + "_" + getName(N->getType());
+      OS << "    ReducedValue_" << SlotName << " *" << Name << "Val = "
+         << Name << "->getValue<ReducedValue_" << SlotName << ">(ISD::"
+         << SlotName << "_Slot);\n";
+      Operands.push_back(std::make_pair(N, Name+"Val"));
+    }
+  } else {
+    // Otherwise this is an interior node...
     for (unsigned i = 0, e = N->getNumChildren(); i != e; ++i) {
       std::string ChildName = Name + "_Op" + utostr(i);
       OS << "    SelectionDAGNode *" << ChildName << " = " << Name
          << "->getUse(" << i << ");\n";
       ReduceAllOperands(N->getChild(i), ChildName, Operands, OS);
     }
-  } else {
-    std::string SlotName = Pattern::getSlotName(N->getValueRecord());
-    OS << "    ReducedValue_" << SlotName << " *" << Name << "Val = Reduce_"
-       << SlotName << "(" << Name << ", MBB);\n";
-    Operands.push_back(std::make_pair(N, Name+"Val"));
   }
 }

@@ -818,6 +831,7 @@

   EmitSourceFileHeader("Instruction Selector for the " + Target.getName() +
                        " target", OS);
+  OS << "#include \"llvm/CodeGen/MachineInstrBuilder.h\"\n";

   // Output the slot number enums...
   OS << "\nenum { // Slot numbers...\n"
@@ -1007,9 +1021,68 @@
         std::vector<std::pair<TreePatternNode*, std::string> > Operands;
         ReduceAllOperands(P->getTree(), "N", Operands, OS);

+        // Now that we have reduced all of our operands, and have the values
+        // that reduction produces, perform the reduction action for this
+        // pattern.
+        std::string Result;
+
+        // If the pattern produces a register result, generate a new register
+        // now.
+        if (Record *R = P->getResult()) {
+          assert(R->isSubClassOf("RegisterClass") &&
+                 "Only handle register class results so far!");
+          OS << "    unsigned NewReg = makeAnotherReg(" << Target.getName()
+             << "::" << R->getName() << "RegisterClass);\n";
+          Result = "NewReg";
+          DEBUG(OS << "    std::cerr << \"%reg\" << NewReg << \" =\t\";\n");
+        } else {
+          DEBUG(OS << "    std::cerr << \"\t\t\";\n");
+          Result = "0";
+        }
+
+        // Print out the pattern that matched...
+        DEBUG(OS << "    std::cerr << \"  " << P->getRecord()->getName() <<'"');
+        DEBUG(for (unsigned i = 0, e = Operands.size(); i != e; ++i)
+                if (Operands[i].first->isLeaf()) {
+                  Record *RV = Operands[i].first->getValueRecord();
+                  assert(RV->isSubClassOf("RegisterClass") &&
+                         "Only handles registers here so far!");
+                  OS << " << \" %reg\" << " << Operands[i].second
+                     << "->Val";
+                } else {
+                  OS << " << ' ' << " << Operands[i].second
+                     << "->Val";
+                });
+        DEBUG(OS << " << \"\\n\";\n");

-        OS << "    std::cerr << \"  " << P->getRecord()->getName()<< "\\n\";\n";
-        OS << "    Val = new ReducedValue_" << SlotName << "(0);\n"
+        // Generate the reduction code appropriate to the particular type of
+        // pattern that this is...
+        switch (P->getPatternType()) {
+        case Pattern::Instruction:
+          OS << "    BuildMI(MBB, " << Target.getName() << "::"
+             << P->getRecord()->getName() << ", " << Operands.size();
+          if (P->getResult()) OS << ", NewReg";
+          OS << ")";
+
+          for (unsigned i = 0, e = Operands.size(); i != e; ++i)
+            if (Operands[i].first->isLeaf()) {
+              Record *RV = Operands[i].first->getValueRecord();
+              assert(RV->isSubClassOf("RegisterClass") &&
+                     "Only handles registers here so far!");
+              OS << ".addReg(" << Operands[i].second << "->Val)";
+            } else {
+              OS << ".addZImm(" << Operands[i].second << "->Val)";
+            }
+          OS << ";\n";
+
+          break;
+        case Pattern::Expander:
+          break;
+        default:
+          assert(0 && "Reduction of this type of pattern not implemented!");
+        }
+
+        OS << "    Val = new ReducedValue_" << SlotName << "(" << Result<<");\n"
            << "    break;\n"
            << "  }\n";
       }


back port from 3.1 agency fixes

back port from 3.1 agency fixes

--- arangod/Agency/Inception.cpp
+++ arangod/Agency/Inception.cpp
@@ -468,7 +468,7 @@
       }
     }

-    maxmean = 1.e-3*std::ceil(1.e3*(.1 + 1.0e-3*(maxmean+3*maxstdev)));
+    maxmean = 1.e-3*std::ceil(1.e3*(.5 + 1.0e-3*(maxmean+3*maxstdev)));

     LOG_TOPIC(INFO, Logger::AGENCY)
       << "Auto-adapting RAFT timing to: {" << maxmean


add get_cg_event_flags

add get_cg_event_flags

--- src/core/grabber/include/manipulator/modifier_flag_manager.hpp
+++ src/core/grabber/include/manipulator/modifier_flag_manager.hpp
@@ -1,6 +1,7 @@
 #pragma once

 #include "types.hpp"
+#include <CoreGraphics/CoreGraphics.h>
 #include <vector>

 namespace manipulator {
@@ -148,6 +149,39 @@
     return bits;
   }

+  CGEventFlags get_cg_event_flags(CGEventFlags original_flags) const {
+    original_flags = static_cast<CGEventFlags>(original_flags & ~(kCGEventFlagMaskAlphaShift |
+                                                                  kCGEventFlagMaskControl |
+                                                                  kCGEventFlagMaskShift |
+                                                                  kCGEventFlagMaskAlternate |
+                                                                  kCGEventFlagMaskCommand |
+                                                                  kCGEventFlagMaskSecondaryFn));
+
+    if (pressed(krbn::modifier_flag::caps_lock)) {
+      original_flags = static_cast<CGEventFlags>(original_flags | kCGEventFlagMaskAlphaShift);
+    }
+    if (pressed(krbn::modifier_flag::left_control) ||
+        pressed(krbn::modifier_flag::right_control)) {
+      original_flags = static_cast<CGEventFlags>(original_flags | kCGEventFlagMaskControl);
+    }
+    if (pressed(krbn::modifier_flag::left_shift) ||
+        pressed(krbn::modifier_flag::right_shift)) {
+      original_flags = static_cast<CGEventFlags>(original_flags | kCGEventFlagMaskShift);
+    }
+    if (pressed(krbn::modifier_flag::left_option) ||
+        pressed(krbn::modifier_flag::right_option)) {
+      original_flags = static_cast<CGEventFlags>(original_flags | kCGEventFlagMaskAlternate);
+    }
+    if (pressed(krbn::modifier_flag::left_command) ||
+        pressed(krbn::modifier_flag::right_command)) {
+      original_flags = static_cast<CGEventFlags>(original_flags | kCGEventFlagMaskCommand);
+    }
+    if (pressed(krbn::modifier_flag::fn)) {
+      original_flags = static_cast<CGEventFlags>(original_flags | kCGEventFlagMaskSecondaryFn);
+    }
+    return original_flags;
+  }
+
 private:
   class state final {
   public:


Added call to delete the security database object upon SM reset. This allows the file to be closed by the OS and flushed to disk.

--- features/FEATURE_BLE/source/generic/GenericSecurityManager.tpp
+++ features/FEATURE_BLE/source/generic/GenericSecurityManager.tpp
@@ -137,6 +137,7 @@

 template<template<class> class TPalSecurityManager, template<class> class SigningMonitor>
 ble_error_t GenericSecurityManager<TPalSecurityManager, SigningMonitor>::reset_(void) {
+    delete _db;
     _pal.reset();
     SecurityManager::reset_();


correction

correction

git-svn-id: b7791fb0f5d07d96612766859ad70a13be88ea96@2723 305cdda6-5ce1-45b3-a98d-dfc68c8b3305

--- solvers/ADRSolver/EquationSystems/UnsteadySystem.cpp
+++ solvers/ADRSolver/EquationSystems/UnsteadySystem.cpp
@@ -135,14 +135,6 @@
             fields[i]  = m_fields[i]->UpdatePhys();
         }

-		for(int i = 0; i < nvariables; i++)
-		{
-			NekDouble InitialError;
-			InitialError = L2Error(i);
-			cout << "\n\nInitial L2 Error = " << InitialError << endl << endl;
-		}
-
-
         // Declare an array of TimeIntegrationSchemes For multi-stage
         // methods, this array will have just one entry containing the
         // actual multi-stage method...


Fixes #682 Orb of Golden Death infinite Earth Elemental summoning

--- TemplePlus/fixes/generalfixes.cpp
+++ TemplePlus/fixes/generalfixes.cpp
@@ -23,14 +23,19 @@

 struct TigTextStyle;

-// fixes size_colossal (was misspelled as size_clossal)
-class SizeColossalFix : public TempleFix {
+
+class HexFixes : public TempleFix {
 public:

 	void apply() override {
+
+		// fixes size_colossal (was misspelled as size_clossal)
 		writeHex(0x10278078, "73 69 7A 65 5F 63 6F 6C 6F 73 73 61 6C");
-	}
-} sizeColossalFix;
+
+		// fixes Orb of Golden Death infinite Earth Elementals
+		writeHex(0x101034D9, "C1 E0 10"); // was 08, a wrong shift (looks like a typo error, all the others are shifted by 0x10: radMenuEntry.d20ActionData1 = (invIdxFromCondArg2 << 16) | [spellIdx]
+	}
+} hexFixes;

 // Makes Kukri Proficiency Martial
 class KukriFix : public TempleFix {


fixed compile error

fixed compile error

--- arangod/VocBase/datafile.cpp
+++ arangod/VocBase/datafile.cpp
@@ -749,7 +749,7 @@
   int fd;
   int res;
   ssize_t len;
-  struct stat status;
+  TRI_stat_t status;
   TRI_df_header_marker_t header;
   void* mmHandle;

@@ -785,7 +785,7 @@
   }

   // check that file is not too small
-  size = status.st_size;
+  size = static_cast<TRI_voc_size_t>(status.st_size);

   if (size < sizeof(TRI_df_header_marker_t) + sizeof(TRI_df_footer_marker_t)) {
     TRI_set_errno(TRI_ERROR_ARANGO_CORRUPTED_DATAFILE);


INTEGRATION: CWS sb59 (1.9.452); FILE MERGED 2006/08/03 13:51:53 cl 1.9.452.1: removed compiler warnings

--- svx/source/outliner/outleeng.hxx
+++ svx/source/outliner/outleeng.hxx
@@ -4,9 +4,9 @@
  *
  *  $RCSfile: outleeng.hxx,v $
  *
- *  $Revision: 1.9 $
+ *  $Revision: 1.10 $
  *
- *  last change: $Author: kz $ $Date: 2005-10-05 13:25:43 $
+ *  last change: $Author: obo $ $Date: 2006-10-12 13:01:38 $
  *
  *  The Contents of this file are made available subject to
  *  the terms of GNU Lesser General Public License Version 2.1.
@@ -43,7 +43,7 @@
 #endif

 typedef EENotify* EENotifyPtr;
-SV_DECL_PTRARR_DEL( NotifyList, EENotifyPtr, 1, 1 );
+SV_DECL_PTRARR_DEL( NotifyList, EENotifyPtr, 1, 1 )

 class OutlinerEditEng : public EditEngine
 {


Fix gradients gm

Fix gradients gm

Some of my local changes slipped into the tree.

BUG=skia:

Change-Id: I6e452f12608db6b80c5887ccd3cac199cfbf9494
Reviewed-on: https://skia-review.googlesource.com/7625
Reviewed-by: Matt Sarett <bb43c9b8214fcf1292f134c9714ba8a0e7075913@google.com>
Reviewed-by: Mike Klein <14574f09dfa9b4e14759b88c3426a495a0e627b0@chromium.org>
Commit-Queue: Matt Sarett <bb43c9b8214fcf1292f134c9714ba8a0e7075913@google.com>

--- gm/gradients.cpp
+++ gm/gradients.cpp
@@ -170,7 +170,7 @@
 class GradientsGM : public GM {
 public:
     GradientsGM(bool dither) : fDither(dither) {
-        //this->setBGColor(sk_tool_utils::color_to_565(0xFFDDDDDD));
+        this->setBGColor(sk_tool_utils::color_to_565(0xFFDDDDDD));
     }

 protected:
@@ -185,10 +185,10 @@

         SkPoint pts[2] = {
             { 0, 0 },
-            { SkIntToScalar(500), SkIntToScalar(500) }
+            { SkIntToScalar(100), SkIntToScalar(100) }
         };
         SkShader::TileMode tm = SkShader::kClamp_TileMode;
-        SkRect r = { 0, 0, SkIntToScalar(500), SkIntToScalar(500) };
+        SkRect r = { 0, 0, SkIntToScalar(100), SkIntToScalar(100) };
         SkPaint paint;
         paint.setAntiAlias(true);
         paint.setDither(fDither);
@@ -207,10 +207,8 @@
                 paint.setShader(gGradMakers[j](pts, gGradData[i], tm, scale));
                 canvas->drawRect(r, paint);
                 canvas->translate(0, SkIntToScalar(120));
-                break;
             }
             canvas->restore();
-            break;
             canvas->translate(SkIntToScalar(120), 0);
         }
     }


llvm has the N_AST defined now.

llvm has the N_AST defined now.

--- source/Plugins/ObjectFile/Mach-O/ObjectFileMachO.cpp
+++ source/Plugins/ObjectFile/Mach-O/ObjectFileMachO.cpp
@@ -4158,7 +4158,7 @@
                         type = eSymbolTypeAdditional;
                         break;

-                    case 0x32u: // N_AST TODO: remove 0x32u constant once we verify that clang 600 has the define in its MachO.h
+                    case N_AST:
                         // A path to a compiler AST file
                         type = eSymbolTypeASTFile;
                         break;


chg wxLogMessage to VTLOG, fixed problem with tick_size

--- TerrainApps/VTBuilder/RoadFix.cpp
+++ TerrainApps/VTBuilder/RoadFix.cpp
@@ -13,6 +13,8 @@
 #ifndef WX_PRECOMP
 #include "wx/wx.h"
 #endif
+
+#include "vtdata/vtLog.h"

 #include "RoadMapEdit.h"
 #include "assert.h"
@@ -74,7 +76,7 @@
 	int nodes = NumNodes();
 	float total = nodes * nodes / 2;
 	int count1 = 0, count = 0, count_tick, count_last_tick = 0;
-	int tick_size = (int) (total / 100);
+	float tick_size = (float)total / 100;
 	double tolerance, tolerance_squared;

 	if (bDegrees)
@@ -131,7 +133,7 @@
 		else
 			prev = pN;
 	}
-//	wxLogMessage("Removed %i nodes\n", removed);
+	VTLOG(" Removed %i nodes\n", removed);
 	return removed;
 }

@@ -172,7 +174,7 @@
 		else
 			prevR = pR;
 	}
-//	wxLogMessage("Removed %i degenerate roads.\n", count);
+	VTLOG(" Removed %i degenerate roads.\n", count);
 	return count;
 }

@@ -367,8 +369,8 @@
 		}
 	}

-//	wxLogMessage("Eliminated %i of %i nodes\n", count, total);
-//	wxLogMessage("There are now %i nodes and %i roads\n", NumNodes(),NumLinks());
+	VTLOG(" Eliminated %i of %i nodes\n", count, total);
+	VTLOG(" There are now %i nodes and %i roads\n", NumNodes(),NumLinks());
 	return count;
 }


Small bug when detecting conflicts in logs requests

git-svn-id: 9714148d14941aebeae8d7f7841217f5ffc02bc5@3346 4143565c-f3ec-42ea-b729-f8ce0cf5cbc3

--- libs/au/log/LogCentral.cpp
+++ libs/au/log/LogCentral.cpp
@@ -94,6 +94,7 @@
                 else
                 {
                     current_thread = my_thread_id;
+                    current_thread_activated = true;
                     break;
                 }
             }
@@ -211,4 +212,4 @@
     }

-}+}


chg from using TerrainPatch to CreateRectangle

--- TerrainSDK/vtlib/core/Terrain.cpp
+++ TerrainSDK/vtlib/core/Terrain.cpp
@@ -19,7 +19,6 @@
 #include "Fence3d.h"
 #include "Route.h"
 #include "vtTin3d.h"
-#include "TerrainPatch.h"

 //#include "LKTerrain.h"
 #include "TVTerrain.h"
@@ -582,7 +581,6 @@
 	pGeom->SetMaterials(pMat_Ocean);
 	pMat_Ocean->Release();

-	TerrainPatch *mesh;
 	float width, depth;
 	int i, j;

@@ -591,6 +589,8 @@

 	width = (float) world_size.x;
 	depth = (float) world_size.y;
+	FPoint3 base, size(width, 0, depth);
+
 	for (i = -3; i < 4; i++)
 	{
 		for (j = -3; j < 4; j++)
@@ -605,10 +605,12 @@
 				if (!bHorizon) continue;
 			}

-			mesh = new TerrainPatch(VtxType, 4);
-			mesh->MakeGrid(1, 1, width/1, depth/1,
-				world_extents.left + (i * width),
-				world_extents.bottom - (j * depth), 5.0f, 5.0f);
+			base.x = world_extents.left + (i * width);
+			base.y = 0;
+			base.z = world_extents.bottom - (j * depth);
+
+			vtMesh *mesh = new vtMesh(GL_TRIANGLE_STRIP, VtxType, 4);
+			mesh->CreateRectangle(1, 1, base, size, 5.0f);

 			pGeom->AddMesh(mesh, 0);	// actually add
 			mesh->Release();	// pass ownership to the Geometry


fdo#67238: sw: fix table cell Unprotect

fdo#67238: sw: fix table cell Unprotect

SwDoc::UnProtectCells() was setting the old box format (from aFmts)
instead of the new one, and actually these 2 vectors are a map.

(regression from 772101649cf16233bbaf0900aa9ebbc915151a95)

Change-Id: I0881a1c499c51b5f3c257e9def1a2e9a00bcb639

--- sw/source/core/docnode/ndtbl.cxx
+++ sw/source/core/docnode/ndtbl.cxx
@@ -4424,22 +4424,23 @@
                 ? new SwUndoAttrTbl( *rBoxes[0]->GetSttNd()->FindTableNode() )
                 : 0;

-        std::vector<SwFrmFmt*> aFmts, aNewFmts;
+        std::map<SwFrmFmt*, SwTableBoxFmt*> aFmtsMap;
         for (size_t i = rBoxes.size(); i; )
         {
             SwTableBox* pBox = rBoxes[ --i ];
             SwFrmFmt* pBoxFmt = pBox->GetFrmFmt();
             if( pBoxFmt->GetProtect().IsCntntProtected() )
             {
-                std::vector<SwFrmFmt*>::iterator it = std::find( aFmts.begin(), aFmts.end(), pBoxFmt );
-                if( aFmts.end() != it )
-                    pBox->ChgFrmFmt( (SwTableBoxFmt*)*it );
+                std::map<SwFrmFmt*, SwTableBoxFmt*>::const_iterator const it =
+                    aFmtsMap.find(pBoxFmt);
+                if (aFmtsMap.end() != it)
+                    pBox->ChgFrmFmt(it->second);
                 else
                 {
-                    aFmts.push_back( pBoxFmt );
-                    pBoxFmt = pBox->ClaimFrmFmt();
-                    pBoxFmt->ResetFmtAttr( RES_PROTECT );
-                    aNewFmts.push_back( pBoxFmt );
+                    SwTableBoxFmt *const pNewBoxFmt(
+                        dynamic_cast<SwTableBoxFmt*>(pBox->ClaimFrmFmt()));
+                    pNewBoxFmt->ResetFmtAttr( RES_PROTECT );
+                    aFmtsMap.insert(std::make_pair(pBoxFmt, pNewBoxFmt));
                 }
                 bChgd = sal_True;
             }


bugfix

bugfix

--- NaoTHSoccer/Source/Core/Motion/SensorFilter/InertialFilter.cpp
+++ NaoTHSoccer/Source/Core/Motion/SensorFilter/InertialFilter.cpp
@@ -34,7 +34,7 @@
       && !intentionallyMoving() )
   {
     // stand and not moving
-    if ( theBlackBoard.theSupportPolygon.mode & (SupportPolygon::DOUBLE | SupportPolygon::DOUBLE_LEFT | SupportPolygon::DOUBLE) )
+    if ( theBlackBoard.theSupportPolygon.mode & (SupportPolygon::DOUBLE | SupportPolygon::DOUBLE_LEFT | SupportPolygon::DOUBLE_RIGHT) )
     {
       // both feet on the ground
       Pose3D foot = theBlackBoard.theKinematicChain.theLinks[KinematicChain::LFoot].M;
@@ -55,16 +55,17 @@
           theOffset = theNewOffset;
         }
         return;
-      }
-    }
-  }
+      }//end if
+    }//end if
+  }//end if

   calibrateNum = 0;
-}
+}//end calibrate

 // check all request joints' speed, return true if all joints are almost not moving
 bool InertialFilter::intentionallyMoving()
 {
+  // check the joints
   const double* jointSpeed = theBlackBoard.theMotorJointData.dp;
   const double* stiffness = theBlackBoard.theMotorJointData.stiffness;
   const double min_speed = Math::fromDegrees(1); // degree per second
@@ -75,7 +76,11 @@
     {
       return true;
     }
-  }
+  }//end for
+
+
+  // check the gyro
+

   return false;
-}
+}//end intentionallyMoving


typo.

typo.

git-svn-id: 28d9401aa571d5108e51b194aae6f24ca5964c06@4178 8cc4aa7f-3514-0410-904f-f2cc9021211c

--- libs/csengine/particle.cpp
+++ libs/csengine/particle.cpp
@@ -458,7 +458,7 @@
       // @@@ rain only appears in box ceiling now, should appear on
       // opposite side of rain_dir...
       pos = GetRandomDirection( rainbox.Min(), csVector3 (
-        rainbox.MaxX() - rainbox.MinX(), 0,0f,
+        rainbox.MaxX() - rainbox.MinX(), 0.0f,
         rainbox.MaxZ() - rainbox.MinZ()) );
       pos.y = rainbox.MaxY();
       GetParticle(i)->SetPosition(pos);


(split) subbox fixes, kittilabel writing

--- boost_common.cc
+++ boost_common.cc
@@ -96,7 +96,7 @@
     }
 }

-void VRandomForest__wrap_doTrain(VRandomForest *inst,
+void VRandomForest__wrap_train(VRandomForest *inst,
                                  pyarr<double> X,
                                  pyarr<double> Y)
 {
@@ -116,7 +116,8 @@
     vector<double> weights(X.dims[0], 1.0), feature_costs;
     vector<size_t> usable_features, required_features;

-    inst->doTrain(Xv, Yv, weights, usable_features, feature_costs, required_features);
+    inst->train(X.dims[1], Y.dims[1],
+                Xv, Yv, weights, usable_features, feature_costs, required_features);
     for (int i=0; i<X.dims[0]; i++) {
         delete Xv[i];
         delete Yv[i];
@@ -249,7 +250,7 @@
         .def_readwrite("m_seeds", &VRandomForest::m_seeds)
         .def_readwrite("m_trees", &VRandomForest::m_trees)
         .def("save", &VRandomForest::save)
-        .def("doTrain", VRandomForest__wrap_doTrain)
+        .def("train", VRandomForest__wrap_train)
         .def("doPredict", VRandomForest__wrap_doPredict)
         ;
     class_<vector<VRandomForest*> >("VRandomForest_vec")


std::exception doesn't have a public constructor that takes a char *

--- Tests/UnitTests/Assert.Throws.cpp
+++ Tests/UnitTests/Assert.Throws.cpp
@@ -55,7 +55,7 @@

 FACT("Can catch std::exception")
 {
-    Assert.Throws<std::exception>([]() { throw std::exception("test"); });
+    Assert.Throws<std::exception>([]() { throw std::logic_error("test"); });
 }

 }


Fix #78742#: A leaving SdrObject has to clean up

--- sw/source/core/draw/dcontact.cxx
+++ sw/source/core/draw/dcontact.cxx
@@ -2,9 +2,9 @@
  *
  *  $RCSfile: dcontact.cxx,v $
  *
- *  $Revision: 1.1.1.1 $
- *
- *  last change: $Author: hr $ $Date: 2000-09-19 00:08:18 $
+ *  $Revision: 1.2 $
+ *
+ *  last change: $Author: ama $ $Date: 2000-10-19 11:56:49 $
  *
  *  The Contents of this file are made available subject to the terms of
  *  either of the following licenses
@@ -421,8 +421,8 @@
             {
                 if( bNotify )
                     lcl_Notify( this, pOldBoundRect );
-                DisconnectFromLayout( FALSE );
                 SetMaster( NULL );
+                GetFmt()->GetDoc()->DelLayoutFmt( GetFmt() );
                 delete this;
                 break;
             }


INTEGRATION: CWS swqbugfixes10 (1.29.148); FILE MERGED 2004/11/29 10:51:36 fme 1.29.148.1: #i37476# Insert table row before table that consists of only one row that is split over two pages

--- sw/source/core/frmedt/tblsel.cxx
+++ sw/source/core/frmedt/tblsel.cxx
@@ -2,9 +2,9 @@
  *
  *  $RCSfile: tblsel.cxx,v $
  *
- *  $Revision: 1.29 $
+ *  $Revision: 1.30 $
  *
- *  last change: $Author: kz $ $Date: 2004-10-04 19:07:23 $
+ *  last change: $Author: vg $ $Date: 2004-12-23 10:05:39 $
  *
  *  The Contents of this file are made available subject to the terms of
  *  either of the following licenses
@@ -59,7 +59,6 @@
  *
  ************************************************************************/

-
 #pragma hdrstop

 #define ITEMID_BOXINFO      SID_ATTR_BORDER_INNER
@@ -2582,22 +2581,37 @@
             else //davor einfuegen
             {
                 USHORT i;
+
+                // We are looking for the frame that is behind the row frame
+                // that should be inserted.
                 for ( i = 0; !pSibling; ++i )
                 {
-                    SwTableLine *pLine = pLineBefore ? pLineBefore :
-                                                    rTable.GetTabLines()[i];
+                    SwTableLine* pLine = pLineBefore ? pLineBefore : rTable.GetTabLines()[i];

                     SwClientIter aIter( *pLine->GetFrmFmt() );
                     pSibling = (SwFrm*)aIter.First( TYPE(SwFrm) );

-                    while ( pSibling &&
-                            ( ((SwRowFrm*)pSibling)->GetTabLine() != pLine ||
-                              !lcl_IsLineOfTblFrm( *pTable, *pSibling ) ||
-                               pSibling->IsInSplitTableRow() ||
-                              ( ( !pLineBefore || pLine == rTable.GetTabLines()[0]) &&
-                                   pSibling->FindTabFrm() != pTable ) ) ) // Master finden!
+                    while ( pSibling && (
+                            // only consider row frames associated with pLineBefore:
+                            static_cast<SwRowFrm*>(pSibling)->GetTabLine() != pLine ||
+                            // only consider row frames that are in pTables Master-Follow chain:
+                            !lcl_IsLineOfTblFrm( *pTable, *pSibling ) ||
+                            // only consider row frames that are not repeated headlines:
+                            static_cast<SwRowFrm*>(pSibling)->IsRepeatedHeadline() ||
+                            // 1. case: pLineBefore == 0:
+                            // only consider row frames that are not follow flow rows
+                            // 2. case: pLineBefore != 0:
+                            // only consider row frames that are not split table rows
+                            // --> FME 2004-11-23 #i37476# If !pLineBefore,
+                            // check IsInFollowFlowRow instead of IsInSplitTableRow.
+                            ( ( !pLineBefore && pSibling->IsInFollowFlowRow() ) ||
+                              (  pLineBefore && pSibling->IsInSplitTableRow() ) ) ) )
+                            // <--
+                    {
                         pSibling = (SwFrm*)aIter.Next();
-                }
+                    }
+                }
+
                 pUpper = pSibling->GetUpper();
                 if ( pLineBefore )
                     pSibling = pSibling->GetNext();


update trolley interface

update trolley interface

--- TrolleyInterface/src/TestComm.cxx
+++ TrolleyInterface/src/TestComm.cxx
@@ -4,6 +4,8 @@
 #include "TGraph.h"
 #include "TString.h"
 #include <cstring>
+
+#define BARCODE_CH_NUM 6

 using namespace std;
 using namespace TrolleyInterface;


pT bin

pT bin

--- PWGCF/Correlations/DPhi/AliAnalysisTaskSEpPbCorrelationsYS.cxx
+++ PWGCF/Correlations/DPhi/AliAnalysisTaskSEpPbCorrelationsYS.cxx
@@ -802,11 +802,11 @@

    for(Int_t i=0;i<31;i++){
      fhFMDmult_runbyrun_cside[i]=new TH2D(Form("fhFMDmult_runbyrun_cside_%d",i),Form("fhFMDmult_runbyrun_%d",i),200,-0.5,199.5,100,0,100);
-     fOutputList2->Add(fhFMDmult_runbyrun_cside[i]);
+     //     fOutputList2->Add(fhFMDmult_runbyrun_cside[i]);
    }
    for(Int_t i=0;i<65;i++){
      fhFMDmult_runbyrun_aside[i]=new TH2D(Form("fhFMDmult_runbyrun_aside_%d",i),Form("fhFMDmult_runbyrun_%d",i),200,-0.5,199.5,100,0,100);
-     fOutputList2->Add(fhFMDmult_runbyrun_aside[i]);
+     //     fOutputList2->Add(fhFMDmult_runbyrun_aside[i]);
    }

    const Int_t ifmdbin[4]={200,20,20,20};
@@ -826,7 +826,7 @@
    const	 Double_t MinITS[4]={-4,0.,0.,-10.};
    const	 Double_t MaxITS[4]={6,2*TMath::Pi(),100.,10.};
    fhistits=new THnSparseF("fhistits","fhistits",4,iitsbin,MinITS,MaxITS);
-   fOutputList2->Add(fhistits);
+   //   fOutputList2->Add(fhistits);

    const Double_t binning_etafmd[51]={
 				      -3.4,-3.3,-3.2,-3.1,-3.0,
@@ -1068,15 +1068,15 @@
      fHistTriggerTrackMix->SetVarTitle(2,"phi");
    }else if(fAnaMode=="FMDFMD" || fAnaMode=="SECA" || fAnaMode=="SECC"){
      const Int_t nEvtVarsV0Leading=3;
-     Double_t binning_cent_trig[9] = {0., 5.,  10., 20.
-				      , 40., 60.,70.,  80.,100.1};
+     Double_t binning_cent_trig[8] = {0., 5.,  10., 20.
+				      , 40., 60.,70.,100.1};
      Double_t binning_mult_trig[10]={0,20,40,60,80,100,120,140,160,200};
      Int_t ncentbin;
      if(fCentType=="Manual") {
        ncentbin=9;
      }else {
        if(fcollisiontype=="HMPP") ncentbin=11;
-       else ncentbin=8;
+       else ncentbin=7;
      }
      const Int_t iEvtBinV0Leading[3]={ncentbin,32,10};
      fHistTriggerTrack= new AliTHn("fHistTriggerTrack", "fHistTriggerTrack", nCFStepstrig, nEvtVarsV0Leading, iEvtBinV0Leading);
@@ -1103,8 +1103,11 @@
      fHistTriggerTrackMix->SetVarTitle(1,"eta");
      //    fHistTriggerTrackMix->SetVarTitle(2,"z vertex");
    }else if(fAnaMode=="TPCFMD" ||fAnaMode=="TPCFMDC"||fAnaMode=="ITSFMD" || fAnaMode=="ITSFMDC"){
-     Double_t binning_cent_trig[9] = {0., 5.,  10., 20.
-				      , 40., 60.,70.,  80.,100.1};
+     //     Double_t binning_pt_lead_trig[10] = {0.2, 0.5, 0.75,  1.0, 1.25, 1.5,  2.0, 2.5, 3.0, 8.0};
+     Double_t binning_pt_lead_trig[6] = {0.2, 0.5, 1.0, 2.0, 4.0, 8.0};
+
+     Double_t binning_cent_trig[8] = {0., 5.,  10., 20.
+				      , 40., 60.,70.,100.1};
      Double_t binning_mult_trig[10]={0,20,40,60,80,100,120,140,160,200};

      const Int_t nEvtVarsFMD = 4;
@@ -1116,14 +1119,14 @@
        ncentbin=9;
      }else {
        if(fcollisiontype=="HMPP") ncentbin=11;
-       else ncentbin=8;
+       else ncentbin=7;
      }
-     const Int_t iEvtBinFMD[4] = {11,ncentbin,10,netabin};
+     const Int_t iEvtBinFMD[4] = {5,ncentbin,10,netabin};
      Double_t binning_eta_tpcfmd[5]={-0.8,-0.4,-0.,0.4,0.8};
      Double_t binning_eta_itsfmd[19]={-1.7, -1.6, -1.4, -1.2, -1.0, -0.8, -0.6, -0.4, -0.2, 0.,0.2,  0.4,  0.6,  0.8,  1.0,  1.2,  1.4,  1.6,  1.7};

      fHistTriggerTrack = new AliTHn("fHistTriggerTrack", "fHistTriggerTrack", nCFStepstrig, nEvtVarsFMD, iEvtBinFMD);
-     fHistTriggerTrack->SetBinLimits(0, binning_pt_lead);
+     fHistTriggerTrack->SetBinLimits(0, binning_pt_lead_trig);
      if(fCentType=="Manual"){
        fHistTriggerTrack->SetBinLimits(1,binning_mult_trig);
      }else{
@@ -1139,7 +1142,7 @@
      fHistTriggerTrack->SetVarTitle(3, "TPC/Eta eta");

      fHistTriggerTrackMix = new AliTHn("fHistTriggerTrackMix", "fHistTriggerTrackMix", nCFStepstrig, nEvtVars, iEvtBin);
-     fHistTriggerTrackMix->SetBinLimits(0, binning_pt_lead);
+     fHistTriggerTrackMix->SetBinLimits(0, binning_pt_lead_trig);
      fHistTriggerTrackMix->SetBinLimits(1, binning_cent_trig);
      fHistTriggerTrackMix->SetVarTitle(0, "leading p_{T} GeV/c");
      fHistTriggerTrackMix->SetVarTitle(1, "centrality");
@@ -1249,6 +1252,13 @@
      fHistReconstTrackMix->SetVarTitle(4,"#Delta#phi");

    }else if (fAnaMode=="TPCFMD" || fAnaMode=="TPCFMDC"){
+
+     const Double_t binning_etafmd_tpcfmda[30]={
+     1.9,
+     2.0,2.1,2.2,2.3,2.4,2.5,2.6,2.7,2.8,2.9,
+     3.0,3.1,3.2,3.3,3.4,3.5,3.6,3.7,3.8,3.9,
+     4.0,4.1,4.2,4.3,4.4,4.5,4.6,4.7,4.8};
+     /*
      Double_t binning_detaFMDTPC[49]={
 				      -5.7,-5.6,-5.5,-5.4,-5.3,-5.2,-5.1,-5.0,
 				      -4.9,-4.8,-4.7,-4.6,-4.5,-4.4,-4.3,-4.2,-4.1,-4.,
@@ -1256,6 +1266,13 @@
 				      -2.9,-2.8,-2.7,-2.6,-2.5,-2.4,-2.3,-2.2,-2.1,-2.,
 				      -1.9,-1.8,-1.7,-1.6,-1.5,-1.4,-1.3,-1.2,-1.1,-1.,
 				      -0.9};
+     */
+     Double_t binning_detaFMDTPC[46]={-5.6,-5.5,-5.4,-5.3,-5.2,-5.1,-5.0,
+				      -4.9,-4.8,-4.7,-4.6,-4.5,-4.4,-4.3,-4.2,-4.1,-4.,
+				      -3.9,-3.8,-3.7,-3.6,-3.5,-3.4,-3.3,-3.2,-3.1,-3.,
+				      -2.9,-2.8,-2.7,-2.6,-2.5,-2.4,-2.3,-2.2,-2.1,-2.,
+				      -1.9,-1.8,-1.7,-1.6,-1.5,-1.4,-1.3,-1.2,-1.1};
+
      Double_t binning_detaFMDCTPC[34]={
 				       0.9,
 				       1.0,1.1,1.2,1.3,1.4,1.5,1.6,1.7,1.8,1.9,
@@ -1265,33 +1282,35 @@
      Int_t ndetatpcfmd;
      Int_t nfmdbin;
      if(fAnaMode=="TPCFMD") {
-       ndetatpcfmd=48;
-       nfmdbin=32;
-     }else{// if(fAnaMode=="TPCFMDC") {
+       ndetatpcfmd=45;
+       nfmdbin=29;
+     }else{
        ndetatpcfmd=33;
        nfmdbin=17;
      }
-
-
-
-     Double_t binning_pt_fmdtpc[2]={0.2,3.};
-
-     const Double_t binning_cent_fmdfmd[9]={0.,5.,10.,20.,40.,60.,70,80.,100.1};
+     //     Double_t binning_pt_fmdtpc[2]={0.2,3.};
+     Double_t binning_pt_fmdtpc[6] = {0.2, 0.5, 1.0, 2.0, 4.0, 8.0};
+
+     const Double_t binning_cent_fmdfmd[8]={0.,5.,10.,20.,40.,60.,70.,100.1};
      const Double_t binning_cent_fmdfmd_HMPP[9]={0.,0.01,0.05,0.1, 0.2, 0.3, 0.4, 0.5, 0.6};

      Double_t binning_mult[10]={0,20,40,60,80,100,120,140,160,200};
      Int_t ncentbin;
      if(fCentType=="Manual")        ncentbin=9;
-     else ncentbin=8;
-     const Int_t iTrackBin_tpcfmd[7]={ndetatpcfmd,1,nfmdbin,ncentbin,72,10,4};
-     fHistReconstTrack = new AliTHn("fHistReconstTrack", "fHistReconstTrack", nCFSteps, 7, iTrackBin_tpcfmd);
-     fHistReconstTrackMix= new AliTHn("fHistReconstTrackMix", "fHistReconstTrackMix", nCFSteps, 7,iTrackBin_tpcfmd);
+     else ncentbin=7;
+
+     Int_t ntpcpt=5;
+     //     const Int_t iTrackBin_tpcfmd[7]={ndetatpcfmd,1,nfmdbin,ncentbin,72,10,4};
+     Int_t nCFStepstpcfmd=4;
+     const Int_t iTrackBin_tpcfmd[6]={ndetatpcfmd,ntpcpt,nfmdbin,ncentbin,72,10};
+     fHistReconstTrack = new AliTHn("fHistReconstTrack", "fHistReconstTrack", nCFStepstpcfmd, 6, iTrackBin_tpcfmd);
+     fHistReconstTrackMix= new AliTHn("fHistReconstTrackMix", "fHistReconstTrackMix", nCFStepstpcfmd, 6,iTrackBin_tpcfmd);
      if(fAnaMode=="TPCFMD") {
        fHistReconstTrack->SetBinLimits(0,binning_detaFMDTPC);
-       fHistReconstTrack->SetBinLimits(2,binning_etafmd);
+       fHistReconstTrack->SetBinLimits(2,binning_etafmd_tpcfmda);
        //Mixed Events
        fHistReconstTrackMix->SetBinLimits(0,binning_detaFMDTPC);
-       fHistReconstTrackMix->SetBinLimits(2,binning_etafmd);
+       fHistReconstTrackMix->SetBinLimits(2,binning_etafmd_tpcfmda);
      } else if(fAnaMode=="TPCFMDC") {
        fHistReconstTrack->SetBinLimits(0,binning_detaFMDCTPC);
        fHistReconstTrack->SetBinLimits(2,binning_etafmdc);
@@ -1301,8 +1320,6 @@
      }
      fHistReconstTrack->SetBinLimits(1,binning_pt_fmdtpc);

-
-
      if(fCentType=="Manual"){
        fHistReconstTrack->SetBinLimits(3,binning_mult);
      }else{
@@ -1312,14 +1329,14 @@

      fHistReconstTrack->SetBinLimits(4,binning_dphi);
      fHistReconstTrack->SetBinLimits(5,-10.,10.);
-     fHistReconstTrack->SetBinLimits(6,-0.8,0.8);
+     //     fHistReconstTrack->SetBinLimits(6,-0.8,0.8);
      fHistReconstTrack->SetVarTitle(0,"#Delta#eta");
      fHistReconstTrack->SetVarTitle(1,"p_{T} GeV/c");
      fHistReconstTrack->SetVarTitle(2,"FMD Eta");
      fHistReconstTrack->SetVarTitle(3,"centrality");
      fHistReconstTrack->SetVarTitle(4,"#Delta#phi");
      fHistReconstTrack->SetVarTitle(5,"z vertex");
-     fHistReconstTrack->SetVarTitle(6,"TPC eta");
+     //     fHistReconstTrack->SetVarTitle(6,"TPC eta");
      fHistReconstTrackMix->SetBinLimits(1,binning_pt_fmdtpc);
      if(fCentType=="Manual"){
        fHistReconstTrackMix->SetBinLimits(3,binning_mult);
@@ -1329,14 +1346,14 @@
      }
      fHistReconstTrackMix->SetBinLimits(4,binning_dphi);
      fHistReconstTrackMix->SetBinLimits(5,-10.,10.);
-     fHistReconstTrackMix->SetBinLimits(6,-0.8,0.8);
+     //     fHistReconstTrackMix->SetBinLimits(6,-0.8,0.8);
      fHistReconstTrackMix->SetVarTitle(0,"#Delta#eta");
      fHistReconstTrackMix->SetVarTitle(1,"p_{T} GeV/c");
      fHistReconstTrackMix->SetVarTitle(2,"FMD Eta");
      fHistReconstTrackMix->SetVarTitle(3,"centrality");
      fHistReconstTrackMix->SetVarTitle(4,"#Delta#phi");
      fHistReconstTrackMix->SetVarTitle(5,"z vertex");
-     fHistReconstTrackMix->SetVarTitle(6,"TPC eta");
+     //     fHistReconstTrackMix->SetVarTitle(6,"TPC eta");

    }else if(fAnaMode=="FMDFMD"){
      const Int_t nTrackVars_fmdfmd = 6;
@@ -1946,7 +1963,6 @@
 	   }
 	 }

-	 //	 Bool_t fmakehole=kFALSE;
 	 if(fmakehole){
 	   if((eta>-2.9 && eta<-2.7) && (5*2*TMath::Pi()/20.<phi && 7*2*TMath::Pi()/20.>phi)) continue;
 	   if((eta>-2.7 && eta<-2.5) && (1*2*TMath::Pi()/20.<phi && 2*2*TMath::Pi()/20.>phi)) continue;
@@ -1957,14 +1973,14 @@
 	   if(eta>0){
 	     Int_t nfmdetabin1=frefetaa->FindBin(eta);
 	     Double_t runbin1=ConvertRunNumber(fEvent->GetRunNumber());
-	     fhFMDmult_runbyrun_aside[nfmdetabin1-1]->Fill(runbin1,mostProbableN);
+	     //	     fhFMDmult_runbyrun_aside[nfmdetabin1-1]->Fill(runbin1,mostProbableN);

 	     if(fAnaMode=="TPCFMD" || fAnaMode=="ITSFMD") selectedTracksAssociated->Add(new AliAssociatedTrackYS(-999,eta,phi,-999,-999,-999,-999,-999,mostProbableN));
 	     if(fAnaMode=="FMDFMD") selectedTracksLeading->Add(new AliAssociatedTrackYS(-999,eta,phi,-999,-999,-999,-999,-999,mostProbableN));
 	   }else if(eta<0){
 	     Int_t nfmdetabin=frefetac->FindBin(eta);
 	     Double_t runbin=ConvertRunNumber(fEvent->GetRunNumber());
-	     fhFMDmult_runbyrun_cside[nfmdetabin-1]->Fill(runbin,mostProbableN);
+	     //	     fhFMDmult_runbyrun_cside[nfmdetabin-1]->Fill(runbin,mostProbableN);

 	     if(fAnaMode=="TPCFMDC" || fAnaMode=="ITSFMDC" ||fAnaMode=="FMDFMD") selectedTracksAssociated->Add(new AliAssociatedTrackYS(-999,eta,phi,-999,-999,-999,-999,-999,mostProbableN));
 	   }
@@ -1991,7 +2007,6 @@

      fHist_Stat->Fill(5);

-
      DumpTObjTable("End of fill fmd tracks");

      Float_t nV0A_hits = fvzero->GetMTotV0A();
@@ -2000,12 +2015,13 @@
      fFMDV0A->Fill(nFMD_fwd_hits, nV0A_hits);
      fFMDV0C->Fill(nFMD_bwd_hits, nV0C_hits);
      if(fCentType=="Manual")fh2_SPDV0_multcorr->Fill(lCentrality,nV0C_hits+nV0A_hits);
+     /*
      fHist_NeventRun->Fill(ConvertRunNumber(fEvent->GetRunNumber()));
      fHist_V0AMultRun->Fill(ConvertRunNumber(fEvent->GetRunNumber()),nV0A_hits);
      fHist_V0CMultRun->Fill(ConvertRunNumber(fEvent->GetRunNumber()),nV0C_hits);
      fHist_FMDAMultRun->Fill(ConvertRunNumber(fEvent->GetRunNumber()),nFMD_fwd_hits);
      fHist_FMDCMultRun->Fill(ConvertRunNumber(fEvent->GetRunNumber()),nFMD_bwd_hits);
-
+     */
      if(fFMDcut){
        //       if (nV0A_hits + nV0C_hits < 1.5*(nFMD_fwd_hits + nFMD_bwd_hits) - 20)
        Double_t FMDcutapar0=0.;
@@ -2046,7 +2062,6 @@
        default: break;
        }

-       //       if((nV0A_hits<(1.3*nFMD_fwd_hits-200)) || (nV0C_hits<(2.*nFMD_bwd_hits-200)) ){
        if((nV0A_hits<(FMDcutapar0*nFMD_fwd_hits-FMDcutapar1)) || (nV0C_hits<(FMDcutcpar0*nFMD_bwd_hits-FMDcutcpar1)) ){
 	 selectedTracksLeading->Clear();
 	 delete selectedTracksLeading;
@@ -2121,7 +2136,7 @@

      fh2_ITS_acceptance->Fill(tPrimaryVtxPosition[2],etaits);
      Double_t itsqa[4]={etaits,phiits,lCentrality,tPrimaryVtxPosition[2]};
-     fhistits->Fill(itsqa);
+     //     fhistits->Fill(itsqa);
      selectedTracksLeading->Add(new AliAssociatedTrackYS(-999, etaits, phiits, -999, 0, -999,-999, 0, 1));
    }
   }
@@ -3613,7 +3628,7 @@
       }
   }else if (fAnaMode=="TPCV0A" || fAnaMode=="TPCV0C" || fAnaMode=="TPCFMD" || fAnaMode=="TPCFMDC"){
     Double_t binscontTrig[4];
-    Double_t binscont[7];
+    Double_t binscont[6];
     for(Int_t i=0;i<triggerArray->GetEntriesFast();i++){
       AliAssociatedTrackYS* trigger = (AliAssociatedTrackYS*) triggerArray->At(i);
       if(!trigger)continue;
@@ -3638,13 +3653,16 @@
         binscont[3]=centrality;
         binscont[4]=RangePhi(triggerPhi-associate->Phi());
         binscont[5]=fPrimaryZVtx;
-	binscont[6]=triggerEta;
-        if (fasso == "V0" || fasso == "Phi" || fasso == "Cascade" ||  (fasso == "PID")) {
-          if (SpAsso < 0)          continue;
-          associateHist->Fill(binscont, SpAsso,(Double_t)associate->Multiplicity());
-        }else if(fasso=="hadron"){
-          associateHist->Fill(binscont, 0, (Double_t)associate->Multiplicity());
-        }
+	//	binscont[6]=triggerEta;
+	Int_t nstep=999;
+	if(triggerEta<-0.4) nstep=0;
+	else if(triggerEta>-0.4 && triggerEta<0) nstep=1;
+	else if(triggerEta>0 && triggerEta<0.4) nstep=2;
+	else if(triggerEta>0.4 && triggerEta<0.8) nstep=3;
+	else nstep=999;
+
+	if(nstep<4) associateHist->Fill(binscont, nstep, (Double_t)associate->Multiplicity());
+
       }
     }
   }else if (fAnaMode=="ITSFMD" || fAnaMode=="ITSFMDC"){
@@ -3832,7 +3850,8 @@
 	}
       }else if(fAnaMode=="TPCV0A" || fAnaMode=="TPCV0C" || fAnaMode=="TPCFMD" || fAnaMode=="TPCFMDC"){
         Double_t binscontTrig[2];
-        Double_t binscont[7];
+	//        Double_t binscont[7];
+	Double_t binscont[6];
         for(Int_t i=0;i<triggerArray->GetEntriesFast();i++){
           AliAssociatedTrackYS* trigger =(AliAssociatedTrackYS*) triggerArray->At(i);
           if(!trigger)continue;
@@ -3854,14 +3873,15 @@
             binscont[3]=centrality;
             binscont[4]=RangePhi(triggerPhi-associate->Phi());
             binscont[5]=pvxMix;
-	    binscont[6]=triggerEta;
-
-	    if (fasso == "V0" || fasso == "Phi" || fasso == "Cascade" || (fasso == "PID")) {
-              if (SpAsso < 0)   continue;
-              associateHist->Fill(binscont, SpAsso, (Double_t)associate->Multiplicity()/(Double_t)nMix);
-            }else if(fasso=="hadron"){
-              associateHist->Fill(binscont, 0,(Double_t)associate->Multiplicity()/(Double_t)nMix);
-            }
+	    //	    binscont[6]=triggerEta;
+	    Int_t nstep=999;
+	    if(triggerEta<-0.4) nstep=0;
+	    else if(triggerEta>-0.4 && triggerEta<0) nstep=1;
+	    else if(triggerEta>0 && triggerEta<0.4) nstep=2;
+	    else if(triggerEta>0.4 && triggerEta<0.8) nstep=3;
+
+              associateHist->Fill(binscont, nstep,(Double_t)associate->Multiplicity()/(Double_t)nMix);
+
           }
         }
       }else if(fAnaMode=="ITSFMD" || fAnaMode=="ITSFMDC"){


Fix #96678#: Table selection in vertical environment

--- sw/source/core/frmedt/tblsel.cxx
+++ sw/source/core/frmedt/tblsel.cxx
@@ -2,9 +2,9 @@
  *
  *  $RCSfile: tblsel.cxx,v $
  *
- *  $Revision: 1.4 $
+ *  $Revision: 1.5 $
  *
- *  last change: $Author: jp $ $Date: 2001-10-25 11:33:39 $
+ *  last change: $Author: ama $ $Date: 2002-02-01 10:25:31 $
  *
  *  The Contents of this file are made available subject to the terms of
  *  either of the following licenses
@@ -401,7 +401,6 @@
         {
             SwSelUnion *pUnion = aUnions[i];
             const SwTabFrm *pTable = pUnion->GetTable();
-
             if( !pTable->IsValid() && nLoopMax )
             {
                 bTblIsValid = FALSE;
@@ -717,6 +716,15 @@

 BOOL IsFrmInTblSel( const SwRect& rUnion, const SwFrm* pCell )
 {
+#ifdef VERTICAL_LAYOUT
+    if( pCell->IsVertical() )
+        return ( rUnion.Right() >= pCell->Frm().Right() &&
+            rUnion.Left() <= pCell->Frm().Left() &&
+            (( rUnion.Top() <= pCell->Frm().Top()+20 &&
+               rUnion.Bottom() > pCell->Frm().Top() ) ||
+             ( rUnion.Top() >= pCell->Frm().Top() &&
+               rUnion.Bottom() < pCell->Frm().Bottom() )) ? TRUE : FALSE );
+#endif
     return (
         rUnion.Top() <= pCell->Frm().Top() &&
         rUnion.Bottom() >= pCell->Frm().Bottom() &&
@@ -1790,10 +1798,27 @@
             bExchange = TRUE;
         }
     }
+#ifdef VERTICAL_LAYOUT
+    else
+    {
+        SWRECTFN( pStart )
+        long nSttTop = (pStart->Frm().*fnRect->fnGetTop)();
+        long nEndTop = (pEnd->Frm().*fnRect->fnGetTop)();
+        if( nSttTop == nEndTop )
+        {
+            if( (pStart->Frm().*fnRect->fnGetLeft)() >
+                (pEnd->Frm().*fnRect->fnGetLeft)() )
+                bExchange = TRUE;
+        }
+        else if( bVert == ( nSttTop < nEndTop ) )
+            bExchange = TRUE;
+    }
+#else
     else if ( pStart->Frm().Top() > pEnd->Frm().Top() ||
              (pStart->Frm().Top() == pEnd->Frm().Top() &&
               pStart->Frm().Left() > pEnd->Frm().Left()) )
         bExchange = TRUE;
+#endif
     if ( bExchange )
     {
         const SwLayoutFrm *pTmp = pStart;
@@ -1821,6 +1846,52 @@
     const long nWish = Max( 1L, pTable->GetFmt()->GetFrmSize().GetWidth() );
     while ( pTable )
     {
+#ifdef VERTICAL_LAYOUT
+        SWRECTFN( pTable )
+        const long nOfst = (pTable->*fnRect->fnGetPrtLeft)();
+        const long nPrtWidth = (pTable->Prt().*fnRect->fnGetWidth)();
+        long nSt1 = ::lcl_CalcWish( pStart, nWish, nPrtWidth ) + nOfst;
+        long nEd1 = ::lcl_CalcWish( pEnd,   nWish, nPrtWidth ) + nOfst;
+
+        if ( nSt1 <= nEd1 )
+            nEd1 += (long)((nEdSz * nPrtWidth) / nWish) - 1;
+        else
+            nSt1 += (long)((nStSz * nPrtWidth) / nWish) - 1;
+
+        long nSt2;
+        long nEd2;
+        if( pTable->IsAnLower( pStart ) )
+            nSt2 = (pStart->Frm().*fnRect->fnGetTop)();
+        else
+            nSt2 = (pTable->Frm().*fnRect->fnGetTop)();
+        if( pTable->IsAnLower( pEnd ) )
+            nEd2 = (pEnd->Frm().*fnRect->fnGetBottom)();
+        else
+            nEd2 = (pTable->Frm().*fnRect->fnGetBottom)();
+        Point aSt, aEd;
+        if( nSt1 > nEd1 )
+        {
+            long nTmp = nSt1;
+            nSt1 = nEd1;
+            nEd1 = nTmp;
+        }
+        if( nSt2 > nEd2 )
+        {
+            long nTmp = nSt2;
+            nSt2 = nEd2;
+            nEd2 = nTmp;
+        }
+        if( bVert )
+        {
+            aSt = Point( nSt2, nSt1 );
+            aEd = Point( nEd2, nEd1 );
+        }
+        else
+        {
+            aSt = Point( nSt1, nSt2 );
+            aEd = Point( nEd1, nEd2 );
+        }
+#else
         const long nOfst = pTable->Frm().Left() + pTable->Prt().Left();
         long nSt = ::lcl_CalcWish( pStart, nWish, pTable->Prt().Width() ) + nOfst;
         long nEd = ::lcl_CalcWish( pEnd,   nWish, pTable->Prt().Width() ) + nOfst;
@@ -1837,6 +1908,7 @@
             aSt.Y() = pTable->Frm().Top();
         if ( !pTable->IsAnLower( pEnd ) )
             aEd.Y() = pTable->Frm().Bottom();
+#endif

         SwRect aUnion( aSt, aEd );
         aUnion.Justify();
@@ -1871,9 +1943,16 @@
                 pLast = ::lcl_FindCellFrm( pLast->GetPrevLayoutLeaf() );

             if ( pFirst && pLast ) //Robust
+#ifdef VERTICAL_LAYOUT
+            {
+                aUnion = pFirst->Frm();
+                aUnion.Union( pLast->Frm() );
+            }
+#else
                 aUnion = SwRect( pFirst->Frm().Pos(),
                                  Point( pLast->Frm().Right(),
                                          pLast->Frm().Bottom() ) );
+#endif
             else
                 aUnion.Width( 0 );
         }


[misc][pin] Removed unnecessary LOG_PRINT calls and other formatting changes

--- pin/pin_sim.cc
+++ pin/pin_sim.cc
@@ -278,15 +278,10 @@
             PIN_LockClient();
             IMG img = IMG_FindByAddress(reg_eip);
             PIN_UnlockClient();
-
-            LOG_PRINT("Process: 0, Start Copying Static Data");
             copyStaticData(img);
-            LOG_PRINT("Process: 0, Finished Copying Static Data");

             // 2) Copying over initial stack data
-            LOG_PRINT("Process: 0, Start Copying Initial Stack Data");
             copyInitialStackData(reg_esp, Tile::getMainCoreId(0));
-            LOG_PRINT("Process: 0, Finished Copying Initial Stack Data");
          }
          else
          {
@@ -298,9 +293,7 @@
             // main thread clock is not affected by start-up time of other processes
             core->getTile()->getNetwork()->netRecv(Tile::getMainCoreId(0), core->getId(), SYSTEM_INITIALIZATION_NOTIFY);

-            LOG_PRINT("Process: %i, Start Copying Initial Stack Data");
             copyInitialStackData(reg_esp, Tile::getMainCoreId(tile_id));
-            LOG_PRINT("Process: %i, Finished Copying Initial Stack Data");
          }
          // Set the current ESP accordingly
          PIN_SetContextReg(ctxt, REG_STACK_PTR, reg_esp);
@@ -349,7 +342,9 @@
             LOG_ASSERT_ERROR (req != NULL, "ThreadSpawnRequest is NULL !!");

             // This is an application thread
-            LOG_ASSERT_ERROR(tile_id == req->destination.tile_id, "Got 2 different tile_ids: req->destination = {%i, %i}, tile_id = %i", req->destination.tile_id, req->destination.core_type, tile_id);
+            LOG_ASSERT_ERROR(tile_id == req->destination.tile_id,
+                             "Got 2 different tile_ids: req->destination = {%i, %i}, tile_id = %i",
+                             req->destination.tile_id, req->destination.core_type, tile_id);

             Sim()->getThreadManager()->onThreadStart(req);
          }
@@ -362,7 +357,7 @@
          LOG_ASSERT_ERROR(tile, "tile(NULL)");

          // Copy over thread stack data
-         //copySpawnedThreadStackData(reg_esp);
+         // copySpawnedThreadStackData(reg_esp);

          // Wait to make sure that the spawner has written stuff back to memory
          // FIXME: What is this for(?) This seems arbitrary


PWGGA: Also Consider L0 flag or histogram

--- PWGGA/PHOSTasks/ClusterSelection/AliCaloTriggerMimicHelper.cxx
+++ PWGGA/PHOSTasks/ClusterSelection/AliCaloTriggerMimicHelper.cxx
@@ -333,19 +333,19 @@
                     fCurrentClusterTriggered=fCurrentClusterTriggeredTrigUtils;
                     fMapClusterToTriggerMap[CurrentClusterID]=fCurrentClusterTriggered;
                     if (fdo_fHist_GammaClusE){fHist_GammaClusE_Trig->Fill(clus->E());}
-                } else {
-                    if (fDoDebugOutput>=6){cout<<"Debug Output; AliCaloTriggerMimicHelper.C, UserExec, Line: "<<__LINE__<<endl;}
-                    if (fdo_fHist_GammaClusE){fHist_GammaClusE_notTrig->Fill(clus->E());}
-                }
-                if (fDoDebugOutput>=6){cout<<"Debug Output; AliCaloTriggerMimicHelper.C, UserExec, Line: "<<__LINE__<<endl;}
-                if (fCurrentClusterTriggeredTrigUtils){
-                    if (fdo_fHist_Cluster_Accepted){fHist_Cluster_Accepted->Fill(5);} //Triggered clusters
                     if (fdo_TriggeredClusters_ColumnVsRow_overThresh){
                         if (clus->E()>=fEnergyThreshold_ColumnVsRow){fHist_TriggeredClusters_ColumnVsRow_overThresh[mod-1]->Fill(ix, iz, 1.);}
                     }
                     if (fdo_TriggeredClusters_ColumnVsRow_underThresh){
                         if (clus->E()<fEnergyThreshold_ColumnVsRow){fHist_TriggeredClusters_ColumnVsRow_underThresh[mod-1]->Fill(ix, iz, 1.);}
                     }
+                } else {
+                    if (fDoDebugOutput>=6){cout<<"Debug Output; AliCaloTriggerMimicHelper.C, UserExec, Line: "<<__LINE__<<endl;}
+                    if (fdo_fHist_GammaClusE){fHist_GammaClusE_notTrig->Fill(clus->E());}
+                }
+                if (fDoDebugOutput>=6){cout<<"Debug Output; AliCaloTriggerMimicHelper.C, UserExec, Line: "<<__LINE__<<endl;}
+                if (fCurrentClusterTriggeredTrigUtils){
+                    if (fdo_fHist_Cluster_Accepted){fHist_Cluster_Accepted->Fill(5);} //Triggered clusters
                 } else {
                     if (fDoDebugOutput>=6){cout<<"Debug Output; AliCaloTriggerMimicHelper.C, UserExec, Line: "<<__LINE__<<endl;}
                     if (fdo_fHist_Cluster_Accepted){fHist_Cluster_Accepted->Fill(6);} //Not triggered clusters


New: Fly frames in vertical layout

New: Fly frames in vertical layout

--- sw/source/core/layout/flylay.cxx
+++ sw/source/core/layout/flylay.cxx
@@ -2,9 +2,9 @@
  *
  *  $RCSfile: flylay.cxx,v $
  *
- *  $Revision: 1.10 $
- *
- *  last change: $Author: ama $ $Date: 2001-12-12 14:45:02 $
+ *  $Revision: 1.11 $
+ *
+ *  last change: $Author: ama $ $Date: 2001-12-12 16:51:56 $
  *
  *  The Contents of this file are made available subject to the terms of
  *  either of the following licenses
@@ -900,7 +900,11 @@
                     if ( pBody->GetPrev() )
                         pBody->GetPrev()->Calc();
                     pBody->Calc();
+#ifdef VERTICAL_LAYOUT
+                    (rRect.*fnRect->fnSetTop)((pBody->*fnRect->fnGetPrtTop)());
+#else
                     rRect.Top( pBody->Frm().Top() + pBody->Prt().Top() );
+#endif

                     //Den Bottom setzen wir auf den unteren Rand der letzten Seite.
                     pPg = ((SwRootFrm*)pUp)->GetLastPage();
@@ -913,7 +917,12 @@
                         if ( pBody->GetPrev() )
                             pBody->GetPrev()->Calc();
                         pBody->Calc();
+#ifdef VERTICAL_LAYOUT
+                        (rRect.*fnRect->fnSetBottom)(
+                                           (pBody->*fnRect->fnGetPrtBottom)() );
+#else
                         rRect.Bottom( pBody->Frm().Top() + pBody->Prt().Bottom());
+#endif
                         if( pFly->GetFmt()->GetDoc()->IsBrowseMode() )
                         {
                             // Hier wird folgende Situation abgefangen: Im Browse-
@@ -931,9 +940,15 @@
                                 if ( pBody->GetPrev() )
                                     pBody->GetPrev()->Calc();
                                 pBody->Calc();
+#ifdef VERTICAL_LAYOUT
+                                SwTwips nBot=(pBody->*fnRect->fnGetPrtBottom)();
+                                if( (rRect.*fnRect->fnBottomDist)( nBot ) > 0 )
+                                    (rRect.*fnRect->fnSetBottom)( nBot );
+#else
                                 SwTwips nBot = pBody->Frm().Top() + pBody->Prt().Bottom();
                                 if( rRect.Bottom() < nBot )
                                     rRect.Bottom( nBot );
+#endif
                             }
                         }
                     }
@@ -1061,8 +1076,8 @@
             if( bMove )
             {
 #ifdef VERTICAL_LAYOUT
-                nTop = (*fnRect->fnYDiff)(
-                        ((SwFlyInCntFrm*)pFly)->GetRefPoint().Y(), nHeight );
+                nTop = (*fnRect->fnYInc)(
+                        ((SwFlyInCntFrm*)pFly)->GetRefPoint().Y(), -nHeight );
                 long nWidth = (pFly->Frm().*fnRect->fnGetWidth)();
                 (rRect.*fnRect->fnSetLeftAndWidth)(
                             ((SwFlyInCntFrm*)pFly)->GetRefPoint().X(), nWidth );
@@ -1070,8 +1085,8 @@
             }
             else
             {
-                nTop = (*fnRect->fnYDiff)( (pFly->Frm().*fnRect->fnGetBottom)(),
-                                            nHeight -rUL.GetLower() );
+                nTop = (*fnRect->fnYInc)( (pFly->Frm().*fnRect->fnGetBottom)(),
+                                           rUL.GetLower() - nHeight );
                 nHeight = 2*nHeight - (pFly->Frm().*fnRect->fnGetHeight)()
                           - rUL.GetLower() - rUL.GetUpper();
             }
@@ -1122,15 +1137,15 @@
             if( bMove )
             {
 #ifdef VERTICAL_LAYOUT
-                nTop = (*fnRect->fnYDiff)(pSdrObj->GetAnchorPos().Y(), nHeight);
+                nTop = (*fnRect->fnYInc)(pSdrObj->GetAnchorPos().Y(), -nHeight);
                 long nWidth = (aSnapRect.*fnRect->fnGetWidth)();
                 (rRect.*fnRect->fnSetLeftAndWidth)(
                             pSdrObj->GetAnchorPos().X(), nWidth );
             }
             else
             {
-                nTop = (*fnRect->fnYDiff)( aSnapRect.Top(), nHeight
-                                           - rUL.GetLower() - nTmpH );
+                nTop = (*fnRect->fnYInc)( aSnapRect.Top(),
+                                          rUL.GetLower() + nTmpH - nHeight );
                 nTmpH = bVert ? pSdrObj->GetBoundRect().GetWidth() :
                                 pSdrObj->GetBoundRect().GetHeight();
             }


Fix EMCAL cell multiplicity calculation

Fix EMCAL cell multiplicity calculation

Usage of operator!= for finding the cell ID in set prevented
any cell from being selected.

--- PWGJE/EMCALJetTasks/Tracks/AliAnalysisTaskEmcalClustersRef.cxx
+++ PWGJE/EMCALJetTasks/Tracks/AliAnalysisTaskEmcalClustersRef.cxx
@@ -391,7 +391,7 @@
   for(short icell = 0; icell < emccells->GetNumberOfCells(); icell++){
     if(emccells->GetAmplitude(icell) > ecut){
       int cellID = emccells->GetCellNumber(icell);
-      if(cellIDs.find(cellID) != cellIDs.end()) cellIDs.insert(cellID);
+      if(cellIDs.find(cellID) == cellIDs.end()) cellIDs.insert(cellID);
     }
   }
   return cellIDs.size();


INTEGRATION: CWS pdf01 (1.43.226); FILE MERGED 2004/07/12 09:59:57 fme 1.43.226.2: #i12836# Enhanced pdf export 2004/07/09 12:45:36 fme 1.43.226.1: #i12836# Enhanced pdf export

--- sw/source/core/text/frmpaint.cxx
+++ sw/source/core/text/frmpaint.cxx
@@ -2,9 +2,9 @@
  *
  *  $RCSfile: frmpaint.cxx,v $
  *
- *  $Revision: 1.44 $
- *
- *  last change: $Author: obo $ $Date: 2004-08-12 12:34:48 $
+ *  $Revision: 1.45 $
+ *
+ *  last change: $Author: hr $ $Date: 2004-09-08 16:11:01 $
  *
  *  The Contents of this file are made available subject to the terms of
  *  either of the following licenses
@@ -157,6 +157,11 @@
 #include <scrrect.hxx>
 #endif

+// --> FME 2004-06-08 #i12836# enhanced pdf export
+#ifndef _ENHANCEDPDFEXPORTHELPER_HXX
+#include <EnhancedPDFExportHelper.hxx>
+#endif
+// <--

 // steht im number.cxx
 extern const sal_Char __FAR_DATA sBulletFntName[];
@@ -387,6 +392,7 @@
 {
     if( Frm().Top() > rRect.Bottom() || Frm().Bottom() < rRect.Top() )
         return;
+
     const SwTxtNode& rTxtNode = *GetTxtNode();
     const SwDoc* pDoc = rTxtNode.GetDoc();
     const SwLineNumberInfo &rLineInf = pDoc->GetLineNumberInfo();
@@ -413,6 +419,10 @@
         SwLayoutModeModifier aLayoutModeModifier( *pSh->GetOut() );
         aLayoutModeModifier.Modify( sal_False );
 #endif
+
+        // --> FME 2004-06-24 #i16816# tagged pdf support
+        SwTaggedPDFHelper aTaggedPDFHelper( 0, 0, *pSh->GetOut() );
+        // <--

         SwExtraPainter aExtra( this, pSh, rLineInf, rRect,
             (USHORT)rLineNum.GetStartValue(), eHor, bLineNum );
@@ -677,9 +687,16 @@
  *                      SwTxtFrm::Paint()
  *************************************************************************/

-void SwTxtFrm::Paint(const SwRect &rRect ) const
+void SwTxtFrm::Paint( const SwRect &rRect ) const
 {
     ResetRepaint();
+
+    // --> FME 2004-06-24 #i16816# tagged pdf support
+    ViewShell *pSh = GetShell();
+    Frm_Info aFrmInfo( *this );
+    SwTaggedPDFHelper aTaggedPDFHelper( &aFrmInfo, 0, *pSh->GetOut() );
+    // <--
+
     DBG_LOOP_RESET;
     if( !IsEmpty() || !PaintEmpty( rRect, sal_True ) )
     {
@@ -755,7 +772,6 @@
             SwitchRTLtoLTR( (SwRect&)rRect );
 #endif

-        ViewShell *pSh = GetShell();
         SwTxtPaintInfo aInf( (SwTxtFrm*)this, rRect );
         aInf.SetWrongList( ( (SwTxtNode*)GetTxtNode() )->GetWrong() );
         aInf.GetTxtFly()->SetTopRule();


INTEGRATION: CWS sw30bf06 (1.105.90); FILE MERGED 2008/06/06 09:40:38 od 1.105.90.1: #i89179# tab portion representing the list tab of a list label has to get 	 the same ascent, height and font as its corresponding number portion

--- sw/source/core/text/itrform2.cxx
+++ sw/source/core/text/itrform2.cxx
@@ -7,7 +7,7 @@
  * OpenOffice.org - a multi-platform office productivity suite
  *
  * $RCSfile: itrform2.cxx,v $
- * $Revision: 1.105 $
+ * $Revision: 1.106 $
  *
  * This file is part of OpenOffice.org.
  *
@@ -757,6 +757,18 @@
         ((SwFldPortion*)pPor)->Height( pFldFnt->GetHeight( rInf.GetVsh(), *rInf.GetOut() ) );
         ((SwFldPortion*)pPor)->SetAscent( pFldFnt->GetAscent( rInf.GetVsh(), *rInf.GetOut() ) );
     }
+    // --> OD 2008-06-05 #i89179#
+    // tab portion representing the list tab of a list label gets the
+    // same height and ascent as the corresponding number portion
+    else if ( pPor->InTabGrp() && pPor->GetLen() == 0 &&
+              rInf.GetLast() && rInf.GetLast()->InNumberGrp() &&
+              static_cast<const SwNumberPortion*>(rInf.GetLast())->HasFont() )
+    {
+        const SwLinePortion* pLast = rInf.GetLast();
+        pPor->Height( pLast->Height() );
+        pPor->SetAscent( pLast->GetAscent() );
+    }
+    // <--
     else
     {
         const SwLinePortion *pLast = rInf.GetLast();