std_msgs.Header.getStamp()方法的使用及代码示例

x33g5p2x  于2022-01-20 转载在 其他  
字(6.9k)|赞(0)|评价(0)|浏览(107)

本文整理了Java中std_msgs.Header.getStamp()方法的一些代码示例,展示了Header.getStamp()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Header.getStamp()方法的具体详情如下:
包路径:std_msgs.Header
类名称:Header
方法名:getStamp

Header.getStamp介绍

暂无

代码示例

代码示例来源:origin: us.ihmc/IHMCAvatarInterfaces

public void onNewMessage(JointState message)
  {
    receivedClockMessage(message.getHeader().getStamp().totalNsecs());
  }
});

代码示例来源:origin: us.ihmc/ihmc-avatar-interfaces

public void onNewMessage(JointState message)
  {
    receivedClockMessage(message.getHeader().getStamp().totalNsecs());
  }
});

代码示例来源:origin: us.ihmc/DarpaRoboticsChallenge

public void onNewMessage(JointState message)
  {
    receivedClockMessage(message.getHeader().getStamp().totalNsecs());
  }
});

代码示例来源:origin: us.ihmc/ihmc-avatar-interfaces

@Override
  public void onNewMessage(PointCloud2 pointCloud)
  {
   UnpackedPointCloud pointCloudData = unpackPointsAndIntensities(pointCloud);
   Point3D[] scanPoints = pointCloudData.getPoints();
   long timestamp = pointCloud.getHeader().getStamp().totalNsecs();
   scanDataToPublish.set(new ScanData(timestamp, scanPoints));
  }
};

代码示例来源:origin: us.ihmc/ihmc-ros-tools

public void onNewMessage(sensor_msgs.CompressedImage message)
{
 long timeStamp = message.getHeader().getStamp().totalNsecs();
 imageReceived(timeStamp, RosTools.bufferedImageFromRosMessageJpeg(colorModel, message));
}

代码示例来源:origin: us.ihmc/DarpaRoboticsChallenge

protected synchronized void handleImageLeft(CompressedImage message)
{
 timestampLeft = message.getHeader().getStamp().totalNsecs();
 imageLeft = bufferedImageFromRosMessage(message);
 checkProcessImage();
}

代码示例来源:origin: us.ihmc/DarpaRoboticsChallenge

protected synchronized void handleImageLeft(CompressedImage message)
{
 timestampLeft = message.getHeader().getStamp().totalNsecs();
 imageLeft = RosTools.bufferedImageFromRosMessageJpeg(colorModel, message);
 checkProcessImage();
}

代码示例来源:origin: us.ihmc/IHMCROSTools

public void onNewMessage(sensor_msgs.Image message)
{
 long timeStamp = message.getHeader().getStamp().totalNsecs();
 imageReceived(timeStamp, RosTools.bufferedImageFromRosMessageRaw(colorModel, message));
}

代码示例来源:origin: us.ihmc/ihmc-ros-tools

public void onNewMessage(sensor_msgs.Image message)
{
 long timeStamp = message.getHeader().getStamp().totalNsecs();
 imageReceived(timeStamp, RosTools.bufferedImageFromRosMessageRaw(colorModel, message));
}

代码示例来源:origin: us.ihmc/IHMCROSTools

public void onNewMessage(sensor_msgs.CompressedImage message)
{
 long timeStamp = message.getHeader().getStamp().totalNsecs();
 imageReceived(timeStamp, RosTools.bufferedImageFromRosMessageJpeg(colorModel, message));
}

代码示例来源:origin: us.ihmc/DarpaRoboticsChallenge

protected synchronized void handleImageRight(CompressedImage message)
{
 timestampRight = message.getHeader().getStamp().totalNsecs();
 imageRight = bufferedImageFromRosMessage(message);
 checkProcessImage();
}

代码示例来源:origin: us.ihmc/DarpaRoboticsChallenge

protected synchronized void handleImageRight(CompressedImage message)
{
 timestampRight = message.getHeader().getStamp().totalNsecs();
 imageRight = RosTools.bufferedImageFromRosMessageJpeg(colorModel, message);
 checkProcessImage();
}

代码示例来源:origin: us.ihmc/ihmc-avatar-interfaces

@Override
  public void onNewMessage(PointCloud2WithSource pointCloud)
  {
   PointCloud2 cloud = pointCloud.getCloud();
   UnpackedPointCloud pointCloudData = RosPointCloudReceiver.unpackPointsAndIntensities(cloud);
   Point3D[] scanPoints = pointCloudData.getPoints();
   long timestamp = cloud.getHeader().getStamp().totalNsecs();
   scanDataToPublish.set(new ScanData(timestamp, scanPoints));
  }
};

代码示例来源:origin: us.ihmc/ihmc-avatar-interfaces

@Override
  public void onNewMessage(PointCloud2 pointCloud)
  {
   UnpackedPointCloud pointCloudData = unpackPointsAndIntensities(pointCloud);
   Point3D[] scanPoints = pointCloudData.getPoints();
   Color[] colors = pointCloudData.getPointColors();
   long timestamp = pointCloud.getHeader().getStamp().totalNsecs();
   pointCloudDataToPublish.set(new ColorPointCloudData(timestamp, scanPoints, colors));
  }
};

代码示例来源:origin: us.ihmc/IHMCAvatarInterfaces

@Override
  public void onNewMessage(PointCloud2WithSource pointCloud)
  {
   PointCloud2 cloud = pointCloud.getCloud();
   UnpackedPointCloud pointCloudData = RosPointCloudReceiver.unpackPointsAndIntensities(cloud);
   Point3d[] scanPoints = pointCloudData.getPoints();
   long timestamp = cloud.getHeader().getStamp().totalNsecs();
   scanDataToPublish.set(new ScanData(timestamp, scanPoints));
  }
};

代码示例来源:origin: rosjava/rosjava_core

public static FrameTransform fromTransformStampedMessage(
  geometry_msgs.TransformStamped transformStamped) {
 Transform transform = Transform.fromTransformMessage(transformStamped.getTransform());
 String target = transformStamped.getHeader().getFrameId();
 String source = transformStamped.getChildFrameId();
 Time stamp = transformStamped.getHeader().getStamp();
 return new FrameTransform(transform, GraphName.of(source), GraphName.of(target), stamp);
}

代码示例来源:origin: us.ihmc/ihmc-ros-tools

@Override
public synchronized void onNewMessage(sensor_msgs.Imu message)
{
 this.timeStamp = message.getHeader().getStamp().totalNsecs();
 this.seq_id = message.getHeader().getSeq();
 this.frameId = message.getHeader().getFrameId();
 RosTools.packRosQuaternionToEuclidQuaternion(message.getOrientation(), this.orientationEstimate);
 RosTools.packRosVector3ToEuclidTuple3D(message.getAngularVelocity(), this.angularVelocity);
 RosTools.packRosVector3ToEuclidTuple3D(message.getLinearAcceleration(), this.linearAcceleration);
 onNewMessage(timeStamp, seq_id, orientationEstimate, angularVelocity, linearAcceleration);
}

代码示例来源:origin: us.ihmc/IHMCROSTools

@Override
public synchronized void onNewMessage(sensor_msgs.Imu message)
{
 this.timeStamp = message.getHeader().getStamp().totalNsecs();
 this.seq_id = message.getHeader().getSeq();
 this.frameId = message.getHeader().getFrameId();
 RosTools.packRosQuaternionToQuat4d(message.getOrientation(), this.orientationEstimate);
 RosTools.packRosVector3ToVector3d(message.getAngularVelocity(), this.angularVelocity);
 RosTools.packRosVector3ToVector3d(message.getLinearAcceleration(), this.linearAcceleration);
 onNewMessage(timeStamp, seq_id, orientationEstimate, angularVelocity, linearAcceleration);
}

代码示例来源:origin: us.ihmc/ihmc-ros-tools

public void onNewMessage(LaserScan message)
{
 LidarScanParameters polarLidarScanParameters = new LidarScanParameters(message.getRanges().length, 1, message.getAngleMin(), message.getAngleMax(),
    message.getTimeIncrement(), message.getRangeMin(), message.getRangeMax(), message.getScanTime(), message.getHeader().getStamp().totalNsecs());
 if (DEBUG)
 {
   verifyDataFromGazeboRemainsTheSame(polarLidarScanParameters);
 }
 LidarScan polarLidarScan = new LidarScan(polarLidarScanParameters, message.getRanges(),sensorId);
 newScan(polarLidarScan);
}

代码示例来源:origin: us.ihmc/IHMCROSTools

public void onNewMessage(LaserScan message)
{
 LidarScanParameters polarLidarScanParameters = new LidarScanParameters(message.getRanges().length, 1, message.getAngleMin(), message.getAngleMax(),
    message.getTimeIncrement(), message.getRangeMin(), message.getRangeMax(), message.getScanTime(), message.getHeader().getStamp().totalNsecs());
 if (DEBUG)
 {
   verifyDataFromGazeboRemainsTheSame(polarLidarScanParameters);
 }
 LidarScan polarLidarScan = new LidarScan(polarLidarScanParameters, message.getRanges(),sensorId);
 newScan(polarLidarScan);
}

相关文章