us.ihmc.graphicsDescription.yoGraphics.YoGraphicsList.getYoGraphics()方法的使用及代码示例

x33g5p2x  于2022-02-05 转载在 其他  
字(6.6k)|赞(0)|评价(0)|浏览(66)

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

YoGraphicsList.getYoGraphics介绍

暂无

代码示例

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

public void update()
{
 for (YoGraphic yoGraphic : yoGraphicsList.getYoGraphics())
 {
   yoGraphic.update();
 }
}

代码示例来源:origin: us.ihmc/ihmc-graphics-description

private void setGlobalScaleProvider(YoGraphicsList yoGraphicsList, DoubleProvider globalScaleProvider)
{
 ArrayList<YoGraphic> yoGraphics = yoGraphicsList.getYoGraphics();
 for (YoGraphic yoGraphic : yoGraphics)
 {
   yoGraphic.setGlobalScaleProvider(globalScaleProvider);
 }
}

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

public void update()
{
 for (YoGraphic yoGraphic : yoGraphicsList.getYoGraphics())
 {
   yoGraphic.update();
 }
}

代码示例来源:origin: us.ihmc/ihmc-graphics-description

private boolean doesNameExistInYoGraphicsList(String nameToCheck)
{
 for (YoGraphicsList yoGraphicsList : yoGraphicsLists)
 {
   ArrayList<YoGraphic> yoGraphics = yoGraphicsList.getYoGraphics();
   for (YoGraphic yoGraphic : yoGraphics)
   {
    String name = yoGraphic.getName();
    if (name.equals(nameToCheck))
    {
      return true;
    }
   }
 }
 return false;
}

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

private boolean doesNameExistInYoGraphicsList(String nameToCheck)
{
 for (YoGraphicsList yoGraphicsList : yoGraphicsLists)
 {
   ArrayList<YoGraphic> yoGraphics = yoGraphicsList.getYoGraphics();
   for (YoGraphic yoGraphic : yoGraphics)
   {
    String name = yoGraphic.getName();
    if (name.equals(nameToCheck))
    {
      return true;
    }
   }
 }
 return false;
}

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

private void checkForRepeatNames(YoGraphicsList yoGraphicsList)
{
 ArrayList<YoGraphic> yoGraphics = yoGraphicsList.getYoGraphics();
 for (YoGraphic yoGraphic : yoGraphics)
 {
   if (doesNameExistInYoGraphicsList(yoGraphic.getName()))
   {
    throw new RuntimeException("Repeat Name: " + yoGraphic.getName() + " in YoGraphic!");
   }
 }
}

代码示例来源:origin: us.ihmc/ihmc-graphics-description

public void registerYoGraphicsList(YoGraphicsList yoGraphicsList)
{
 if (alreadyAddedToSimulationConstructionSet)
   throw new RuntimeException("Graphics have already been added to the SimulationConstructionSet. Cannot register more objects after this.");
 if (yoGraphicsLists.contains(yoGraphicsList))
 {
   throw new RuntimeException("Already registered YoGraphicsList " + yoGraphicsList);
 }
 checkForRepeatNames(yoGraphicsList);
 for (YoGraphicsList list : yoGraphicsLists)
 {
   if (list.getLabel().equals(yoGraphicsList.getLabel()))
   {
    // Combine them:
    ArrayList<YoGraphic> yoGraphics = yoGraphicsList.getYoGraphics();
    list.addAll(yoGraphics);
    return;
   }
 }
 yoGraphicsLists.add(yoGraphicsList);
}

代码示例来源:origin: us.ihmc/ihmc-graphics-description

private void checkForRepeatNames(YoGraphicsList yoGraphicsList)
{
 ArrayList<YoGraphic> yoGraphics = yoGraphicsList.getYoGraphics();
 for (YoGraphic yoGraphic : yoGraphics)
 {
   if (doesNameExistInYoGraphicsList(yoGraphic.getName()))
   {
    throw new RuntimeException("Repeat Name: " + yoGraphic.getName() + " in YoGraphic!");
   }
 }
}

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

public void registerYoGraphicsList(YoGraphicsList yoGraphicsList)
{
 if (alreadyAddedToSimulationConstructionSet)
   throw new RuntimeException("Graphics have already been added to the SimulationConstructionSet. Cannot register more objects after this.");
 if (yoGraphicsLists.contains(yoGraphicsList))
 {
   throw new RuntimeException("Already registered YoGraphicsList " + yoGraphicsList);
 }
 checkForRepeatNames(yoGraphicsList);
 for (YoGraphicsList list : yoGraphicsLists)
 {
   if (list.getLabel().equals(yoGraphicsList.getLabel()))
   {
    // Combine them:
    ArrayList<YoGraphic> yoGraphics = yoGraphicsList.getYoGraphics();
    list.addAll(yoGraphics);
    return;
   }
 }
 yoGraphicsLists.add(yoGraphicsList);
}

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

private void updateYoGraphics()
  {
   if (yoGraphicsListRegistry == null)
     return;

   List<YoGraphicsList> yoGraphicsLists = yoGraphicsListRegistry.getYoGraphicsLists();
   for (YoGraphicsList yoGraphicsList : yoGraphicsLists)
   {
     ArrayList<YoGraphic> yoGraphics = yoGraphicsList.getYoGraphics();
     for (YoGraphic yoGraphic : yoGraphics)
      yoGraphic.update();
   }
   yoGraphicsListRegistry.update();
  }
}

代码示例来源:origin: us.ihmc/ihmc-robot-data-visualizer

private void updateYoGraphics(YoGraphicsListRegistry yoGraphicsListRegistry)
{
 if (yoGraphicsListRegistry == null)
   return;
 List<YoGraphicsList> yoGraphicsLists = yoGraphicsListRegistry.getYoGraphicsLists();
 for (YoGraphicsList yoGraphicsList : yoGraphicsLists)
 {
   ArrayList<YoGraphic> yoGraphics = yoGraphicsList.getYoGraphics();
   for (YoGraphic yoGraphic : yoGraphics)
    yoGraphic.update();
 }
 yoGraphicsListRegistry.update();
}

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

private void updateYoGraphics(YoGraphicsListRegistry yoGraphicsListRegistry)
{
 if (yoGraphicsListRegistry == null)
   return;
 List<YoGraphicsList> yoGraphicsLists = yoGraphicsListRegistry.getYoGraphicsLists();
 for (YoGraphicsList yoGraphicsList : yoGraphicsLists)
 {
   ArrayList<YoGraphic> yoGraphics = yoGraphicsList.getYoGraphics();
   for (YoGraphic yoGraphic : yoGraphics)
    yoGraphic.update();
 }
 yoGraphicsListRegistry.update();
}

代码示例来源:origin: us.ihmc/ihmc-robot-data-visualizer

private void updateYoGraphics()
  {
   if (yoGraphicsListRegistry == null)
     return;

   List<YoGraphicsList> yoGraphicsLists = yoGraphicsListRegistry.getYoGraphicsLists();
   for (YoGraphicsList yoGraphicsList : yoGraphicsLists)
   {
     ArrayList<YoGraphic> yoGraphics = yoGraphicsList.getYoGraphics();
     for (YoGraphic yoGraphic : yoGraphics)
      yoGraphic.update();
   }
   yoGraphicsListRegistry.update();
  }
}

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

for (YoGraphicsList yoGraphicsList : yoGraphicsLists)
  for (YoGraphic yoGraphic : yoGraphicsList.getYoGraphics())

代码示例来源:origin: us.ihmc/ihmc-common-walking-control-modules-test

@ContinuousIntegrationTest(estimatedDuration = 0.1)
@Test(timeout = 30000)
public void testVisualization()
{
 YoGraphicsList dummyGraphicsList = new YoGraphicsList("DummyGraphics");
 ArtifactList dummyArtifactList = new ArtifactList("DummyArtifacts");
 copPointsInFoot.setupVisualizers(dummyGraphicsList, dummyArtifactList, 0.05);
 assertEquals(dummyArtifactList.getArtifacts().size(), 10);
 assertEquals(dummyGraphicsList.getYoGraphics().size(), 10);
 copPointsInFoot.addWaypoint(CoPPointName.MIDFOOT_COP, 1.0, new FramePoint3D(footSpoof.getSoleFrame(), 1.0, 2.1, 3.1));
 YoGraphicPosition graphic = (YoGraphicPosition) dummyGraphicsList.getYoGraphics().get(0);
 assertEquals(1.0 - xToAnkle, graphic.getX(), 1e-5);
 assertEquals(2.1 - yToAnkle, graphic.getY(), 1e-5);
 assertEquals(3.1 - zToAnkle, graphic.getZ(), 1e-5);
}

代码示例来源:origin: us.ihmc/ihmc-robot-data-logger

for (YoGraphicsList yoGraphicsList : yoGraphicsLists)
  for (YoGraphic yoGraphic : yoGraphicsList.getYoGraphics())

相关文章