Esempio n. 1
0
 public void MergeFrom(SEVData other)
 {
     if (other == null)
     {
         return;
     }
     if (other.header_ != null)
     {
         if (header_ == null)
         {
             header_ = new global::Header();
         }
         Header.MergeFrom(other.Header);
     }
     if (other.leftImage_ != null)
     {
         if (leftImage_ == null)
         {
             leftImage_ = new global::Image();
         }
         LeftImage.MergeFrom(other.LeftImage);
     }
     if (other.rightImage_ != null)
     {
         if (rightImage_ == null)
         {
             rightImage_ = new global::Image();
         }
         RightImage.MergeFrom(other.RightImage);
     }
     if (other.pointCloud_ != null)
     {
         if (pointCloud_ == null)
         {
             pointCloud_ = new global::PointCloud2();
         }
         PointCloud.MergeFrom(other.PointCloud);
     }
     if (other.navSatFix_ != null)
     {
         if (navSatFix_ == null)
         {
             navSatFix_ = new global::NavSatFix();
         }
         NavSatFix.MergeFrom(other.NavSatFix);
     }
     if (other.odometry_ != null)
     {
         if (odometry_ == null)
         {
             odometry_ = new global::Odometry();
         }
         Odometry.MergeFrom(other.Odometry);
     }
 }
Esempio n. 2
0
    public void MergeFrom(pb::CodedInputStream input)
    {
        uint tag;

        while ((tag = input.ReadTag()) != 0)
        {
            switch (tag)
            {
            default:
                input.SkipLastField();
                break;

            case 10: {
                if (header_ == null)
                {
                    header_ = new global::Header();
                }
                input.ReadMessage(header_);
                break;
            }

            case 18: {
                if (leftImage_ == null)
                {
                    leftImage_ = new global::Image();
                }
                input.ReadMessage(leftImage_);
                break;
            }

            case 26: {
                if (rightImage_ == null)
                {
                    rightImage_ = new global::Image();
                }
                input.ReadMessage(rightImage_);
                break;
            }

            case 34: {
                if (pointCloud_ == null)
                {
                    pointCloud_ = new global::PointCloud2();
                }
                input.ReadMessage(pointCloud_);
                break;
            }

            case 42: {
                if (navSatFix_ == null)
                {
                    navSatFix_ = new global::NavSatFix();
                }
                input.ReadMessage(navSatFix_);
                break;
            }

            case 50: {
                if (odometry_ == null)
                {
                    odometry_ = new global::Odometry();
                }
                input.ReadMessage(odometry_);
                break;
            }
            }
        }
    }