Tabnine Logo
BuildingModel
Code IndexAdd Tabnine to your IDE (free)

How to use
BuildingModel
in
kendzi.kendzi3d.buildings.model

Best Java code snippets using kendzi.kendzi3d.buildings.model.BuildingModel (Showing top 15 results out of 315)

origin: kendzi/kendzi3d

/**
 * Parse building model from way.
 *
 * @param way
 * @param perspective
 * @return
 */
public static BuildingModel parseBuildingWay(Way way, Perspective perspective) {
  BuildingModel bm = new BuildingModel();
  bm.setParts(parseBuildingPart(way, perspective));
  return bm;
}
origin: kendzi/kendzi3d

private static Color takeFacadeColor(BuildingModel buildingModel, NodeBuildingPart bp, BuildingElementsTextureManager tm) {
  Color c = null;
  if (bp.getFacadeColor() != null) {
    c = bp.getFacadeColor();
  } else if (buildingModel.getFacadeColor() != null) {
    c = buildingModel.getFacadeColor();
  }
  return c;
}
origin: kendzi/kendzi3d

private static Color takeFloorColor(BuildingModel buildingModel, BuildingPart bp, BuildingElementsTextureManager tm) {
  Color c = null;
  if (bp.getFloorColor() != null) {
    c = bp.getFloorColor();
  } else if (buildingModel.getFloorColor() != null) {
    c = buildingModel.getFloorColor();
  }
  return c;
}
origin: kendzi/kendzi3d

/**
 * Parse building model from node.
 *
 * @param node
 * @param perspective
 * @return
 */
public static BuildingModel parseBuildingNode(Node node, Perspective perspective) {
  BuildingModel bm = new BuildingModel();
  bm.setNodeParts(parseBuildingPart(node, perspective));
  return bm;
}
origin: kendzi/kendzi3d

BuildingModel bm = new BuildingModel();
List<BuildingPart> bps = new ArrayList<BuildingPart>();
bm.setParts(bps);
bm.setNodeParts(nbps);
origin: kendzi/kendzi3d

/**
 * Build 3d Model of building.
 *
 * @param buildingModel
 *            building model
 * @param tm
 *            texture manager
 * @return building model and debug informations
 */
public static BuildingOutput buildModel(BuildingModel buildingModel, BuildingElementsTextureManager tm) {
  List<BuildingPartOutput> partsOut = new ArrayList<BuildingPartOutput>();
  ModelFactory mf = ModelFactory.modelBuilder();
  if (buildingModel.getParts() != null) {
    for (BuildingPart bp : buildingModel.getParts()) {
      partsOut.add(buildPart(bp, buildingModel, mf, tm));
    }
  }
  if (buildingModel.getNodeParts() != null) {
    for (NodeBuildingPart bp : buildingModel.getNodeParts()) {
      partsOut.add(buildNodePart(bp, buildingModel, mf, tm));
    }
  }
  BuildingOutput out = new BuildingOutput();
  out.setModel(mf.toModel());
  out.setBuildingPartOutput(partsOut);
  return out;
}
origin: kendzi/kendzi3d

  List<BuildingPart> parts = bm.getParts();
  if (parts != null) {
    for (final BuildingPart bp : parts) {
List<BuildingPart> parts = bm.getParts();
if (parts != null) {
  for (BuildingPart bp : parts) {
origin: kendzi/kendzi3d

public static TextureData takeFacadeTextureData(BuildingModel buildingModel, NodeBuildingPart bp,
    BuildingElementsTextureManager tm, boolean colorable) {
  String mt = null;
  if (bp.getFacadeMaterialType() != null) {
    mt = bp.getFacadeMaterialType();
  } else if (buildingModel.getFacadeMaterialType() != null) {
    mt = buildingModel.getFacadeMaterialType();
  }
  TextureData td = tm.findTexture(new TextureFindCriteria(Type.FACADE, mt, null, null, null, colorable));
  if (td == null) {
    td = new TextureData(null, 1, 1);
  }
  return td;
}
origin: kendzi/kendzi3d

public static TextureData takeFloorTextureData(BuildingModel buildingModel, BuildingPart bp,
    BuildingElementsTextureManager tm, boolean colorable) {
  String mt = null;
  if (bp.getFloorMaterialType() != null) {
    mt = bp.getFloorMaterialType();
  } else if (buildingModel.getFloorMaterialType() != null) {
    mt = buildingModel.getFloorMaterialType();
  }
  TextureData td = tm.findTexture(new TextureFindCriteria(Type.FLOOR, mt, null, null, null, colorable));
  if (td == null) {
    td = new TextureData(null, 1, 1);
  }
  return td;
}
origin: kendzi/kendzi3d

private static Color takeRoofColor(BuildingModel buildingModel, BuildingPart bp, Wall w, WallPart wp,
    BuildingElementsTextureManager tm) {
  Color c = null;
  if (wp != null && wp.getRoofColor() != null) {
    c = wp.getRoofColor();
  } else if (w.getRoofColor() != null) {
    c = w.getRoofColor();
  } else if (bp.getRoofColor() != null) {
    c = bp.getRoofColor();
  } else if (buildingModel.getRoofColor() != null) {
    c = buildingModel.getRoofColor();
  }
  return c;
}
origin: kendzi/kendzi3d

private static TextureData takeRoofTextureData(BuildingModel buildingModel, BuildingPart bp, Wall w,
    BuildingElementsTextureManager tm, boolean colorable) {
  String mt = null;
  if (w.getRoofMaterialType() != null) {
    mt = w.getRoofMaterialType();
  } else if (bp.getRoofMaterialType() != null) {
    mt = bp.getRoofMaterialType();
  } else if (buildingModel.getRoofMaterialType() != null) {
    mt = buildingModel.getRoofMaterialType();
  }
  TextureData td = tm.findTexture(new TextureFindCriteria(Type.ROOF, mt, null, null, null, colorable));
  if (td == null) {
    td = new TextureData(null, 1, 1);
  }
  return td;
}
origin: kendzi/kendzi3d

public static TextureData takeFacadeTextureData(BuildingModel buildingModel, BuildingPart bp, Wall w, WallPart wp,
    BuildingElementsTextureManager tm, boolean colorable) {
  String mt = null;
  if (wp != null && wp.getFacadeMaterialType() != null) {
    mt = wp.getFacadeMaterialType();
  } else if (w.getFacadeMaterialType() != null) {
    mt = w.getFacadeMaterialType();
  } else if (bp.getFacadeMaterialType() != null) {
    mt = bp.getFacadeMaterialType();
  } else if (buildingModel.getFacadeMaterialType() != null) {
    mt = buildingModel.getFacadeMaterialType();
  }
  TextureData td = tm.findTexture(new TextureFindCriteria(Type.FACADE, mt, null, null, null, colorable));
  if (td == null) {
    td = new TextureData(null, 1, 1);
  }
  return td;
}
origin: kendzi/kendzi3d

/**
 * Parse building model from multipolygon.
 *
 * @param pRelation
 * @param pers
 * @return
 */
public static BuildingModel parseBuildingMultiPolygon(Relation pRelation, Perspective pers) {
  if (!pRelation.isMultipolygon()) {
    throw new IllegalArgumentException("for multipolygon relations!");
  }
  BuildingModel bm = new BuildingModel();
  List<BuildingPart> bps = new ArrayList<BuildingPart>();
  bm.setParts(bps);
  List<BuildingPart> bp = parseBuildingMultiPolygonPart(pRelation, pers);
  if (bp != null) {
    bps.addAll(bp);
  }
  return bm;
}
origin: kendzi/kendzi3d

private static Color takeFacadeColor(BuildingModel buildingModel, BuildingPart bp, Wall w, WallPart wp,
    BuildingElementsTextureManager tm) {
  Color c = null;
  if (wp != null && wp.getFacadeColor() != null) {
    c = wp.getFacadeColor();
  } else if (w.getFacadeColor() != null) {
    c = w.getFacadeColor();
  } else if (bp.getFacadeColor() != null) {
    c = bp.getFacadeColor();
  } else if (buildingModel.getFacadeColor() != null) {
    c = buildingModel.getFacadeColor();
  }
  return c;
}
origin: kendzi/kendzi3d

BuildingModel buildingModel = new BuildingModel();
buildingModel.setParts(Arrays.asList(bp));
kendzi.kendzi3d.buildings.modelBuildingModel

Most used methods

  • <init>
  • getParts
  • setParts
  • getFacadeColor
  • getFacadeMaterialType
  • getFloorColor
  • getFloorMaterialType
  • getNodeParts
  • getRoofColor
  • getRoofMaterialType
  • setNodeParts
  • setNodeParts

Popular in Java

  • Making http requests using okhttp
  • onRequestPermissionsResult (Fragment)
  • putExtra (Intent)
  • compareTo (BigDecimal)
  • ObjectMapper (com.fasterxml.jackson.databind)
    ObjectMapper provides functionality for reading and writing JSON, either to and from basic POJOs (Pl
  • Container (java.awt)
    A generic Abstract Window Toolkit(AWT) container object is a component that can contain other AWT co
  • SimpleDateFormat (java.text)
    Formats and parses dates in a locale-sensitive manner. Formatting turns a Date into a String, and pa
  • Random (java.util)
    This class provides methods that return pseudo-random values.It is dangerous to seed Random with the
  • SortedMap (java.util)
    A map that has its keys ordered. The sorting is according to either the natural ordering of its keys
  • DateTimeFormat (org.joda.time.format)
    Factory that creates instances of DateTimeFormatter from patterns and styles. Datetime formatting i
  • Top plugins for Android Studio
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now