當前位置: 首頁>>代碼示例>>Java>>正文


Java Vector3D.getZ方法代碼示例

本文整理匯總了Java中math.geom3d.Vector3D.getZ方法的典型用法代碼示例。如果您正苦於以下問題:Java Vector3D.getZ方法的具體用法?Java Vector3D.getZ怎麽用?Java Vector3D.getZ使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在math.geom3d.Vector3D的用法示例。


在下文中一共展示了Vector3D.getZ方法的9個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: project

import math.geom3d.Vector3D; //導入方法依賴的package包/類
/** Project a point onto plane
 * 
 * @param point point to project
 * @return point within plane that lies in direction of normal vector from input point
 */
public Point3D project(Point3D point) {
    Vector3D planeNormal = getNormalVector();
    
    // the difference between origin of plane and the point
    Vector3D dp = new Vector3D( point, getOrigin() );
    
    // compute ratio of dot products,
    double t = Vector3D.dotProduct(planeNormal, dp);
    return new Point3D(
    		point.getX()+t*planeNormal.getX(),
    		point.getY()+t*planeNormal.getY(),
    		point.getZ()+t*planeNormal.getZ()
    );
}
 
開發者ID:kefik,項目名稱:Pogamut3,代碼行數:20,代碼來源:Plane3D.java

示例2: plus

import math.geom3d.Vector3D; //導入方法依賴的package包/類
@Override
public Point6D plus(Vector3D v){
	return new Point6D(this.getX() + v.getX(),
					   this.getY()+ v.getY(),
					   this.getZ() + v.getZ(),
					   this.normal);
				
}
 
開發者ID:nick-parker,項目名稱:Bread,代碼行數:9,代碼來源:Point6D.java

示例3: StraightLine3D

import math.geom3d.Vector3D; //導入方法依賴的package包/類
public StraightLine3D(Point3D origin, Vector3D direction) {
    this.x0 = origin.getX();
    this.y0 = origin.getY();
    this.z0 = origin.getZ();
    this.dx = direction.getX();
    this.dy = direction.getY();
    this.dz = direction.getZ();
}
 
開發者ID:pokowaka,項目名稱:android-geom,代碼行數:9,代碼來源:StraightLine3D.java

示例4: Plane3D

import math.geom3d.Vector3D; //導入方法依賴的package包/類
public Plane3D(Point3D point, Vector3D vector1, Vector3D vector2) {
    this.x0 = point.getX();
    this.y0 = point.getY();
    this.z0 = point.getZ();
    this.dx1 = vector1.getX();
    this.dy1 = vector1.getY();
    this.dz1 = vector1.getZ();
    this.dx2 = vector2.getX();
    this.dy2 = vector2.getY();
    this.dz2 = vector2.getZ();
}
 
開發者ID:pokowaka,項目名稱:android-geom,代碼行數:12,代碼來源:Plane3D.java

示例5: Velocity

import math.geom3d.Vector3D; //導入方法依賴的package包/類
public Velocity( Vector3D vector ) {
	this(vector.getX(), vector.getY(), vector.getZ());
}
 
開發者ID:kefik,項目名稱:Pogamut3,代碼行數:4,代碼來源:Velocity.java

示例6: setBedMin

import math.geom3d.Vector3D; //導入方法依賴的package包/類
public void setBedMin(Vector3D vec){
    this.xMin = vec.getX();
    this.yMin = vec.getY();
    this.zMin =vec.getZ();
    this.bedMin = vec;
}
 
開發者ID:nick-parker,項目名稱:Bread,代碼行數:7,代碼來源:Slicer.java

示例7: setBedMax

import math.geom3d.Vector3D; //導入方法依賴的package包/類
public void setBedMax(Vector3D vec){
    this.xMax = vec.getX();
    this.yMax = vec.getY();
    this.zMax =vec.getZ();
    this.bedMax = vec;
}
 
開發者ID:nick-parker,項目名稱:Bread,代碼行數:7,代碼來源:Slicer.java

示例8: VectorToStr

import math.geom3d.Vector3D; //導入方法依賴的package包/類
public static String VectorToStr(Vector3D v){
	return "{"+ v.getX() + " " + v.getY() + " " +v.getZ() +"}";
}
 
開發者ID:nick-parker,項目名稱:Bread,代碼行數:4,代碼來源:Utils3D.java

示例9: projectVector

import math.geom3d.Vector3D; //導入方法依賴的package包/類
public Vector3D projectVector(Vector3D vect) {
    Point3D point = new Point3D(x0+vect.getX(), y0+vect.getY(), z0
            +vect.getZ());
    point = this.projectPoint(point);
    return new Vector3D(point.getX()-x0, point.getY()-y0, point.getZ()-z0);
}
 
開發者ID:pokowaka,項目名稱:android-geom,代碼行數:7,代碼來源:Plane3D.java


注:本文中的math.geom3d.Vector3D.getZ方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。