亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? roboproto.java

?? 一個由c轉成java的3D robot 仿真平臺
?? JAVA
?? 第 1 頁 / 共 5 頁
字號:
/************************************************************************//* File: ~/sopra/RoboPackII/RoboProto.java                              *//* This file consists of the main class which includes the user 	*//* interface and holds the specific values of the robot.		*//* The most important methods are also part of this file.		*//************************************************************************/package RoboPackII;import java.awt.*;import java.io.RandomAccessFile;import java.io.IOException;import java.applet.Applet;import java.net.MalformedURLException;import java.net.URL;public class RoboProto extends Applet{            // Constants:	private final double[][] realRobRestr =   // realRobotRestrictions	  { {  -0.88, 0.9  },     //angle1	    {  -2.38, -0.82},     //angle2	    { -0.686, 0.406},	  //angle3      	    {      0, 0    },     // useful dummy	    { -0.698, 0.698} };	  //angle4      	// Declaration of the graphics constants:	public final static int numberOfPoints = 154;	public final static int numberOfEdges = 211;	public final static int numberOfAreas = 100;			//Declaration of the variables specifying the robot:	public AreasPointsList[] apl = new AreasPointsList[numberOfAreas];	public Points light = null;	public long[][] colorTable = new long[7][31];	public double[] linkLengths = new double[4];	public int[] angleWeights = new int[6]; 	public int[] power = new int[6];	public AngleDates[] angles = new AngleDates[6];	public Points[] line = new Points[2];	public Edges gkl = null;	public int[] rpl = new int[14];	public Points[] coorpl = new Points[4];	public Edges coorc[] = new Edges[3];	public Points[] pl = new Points[numberOfPoints];	public Points[] PL = new Points[numberOfPoints];//vertices of the robot	public Edges[] el = new Edges[numberOfEdges];   //edges of the robot	public Areas[] al = new Areas[numberOfAreas];	private boolean robotIsReal = false; // signifies whether the existing					     // robot is simulated	public double[] target = { 0, 0, 0 };// for the auto control	// Some strange, but nevertheless needed variables:	private int errorcode, reminder, steps, stepNumber;	private double angleX, angleY, d, x, y, z, s_wx, h;	private double[] input = new double[9];	private double[] location = new double[3];	private double[] pos = new double[3];	private double[] angleNew = new double[6], angleOld = new double[6];	private double[] hw = new double[6];	private double[] wB = new double[6];	private double[] wE = new double[6];	private int n;	private int indx = -1;        public boolean crashIsActive = false;	private double[] locationNew = new double[3];	public Points[] BListe = new Points[361];	public short f_Z_B = 0;    	public short  f_Z_R = 0;	public int akt = 0;	public int errvariable = 0;	public short fFile = 0;	private double[][] T = new double[3][4];	private Points p1 = new Points(), p2 = new Points();	private int fAutoLine = 0;	private double m, mdiff, distance;	private boolean[] anglesLeftExtreme = { false, false, false, false,					        false, false };		// signifies whether the minimum of an angle had been reached	// Variables for the saving and loading of positions:	public double[][] savedAngles = new double[4][7];	private Button[] storeButtons = { new Button("Def.Init "),					  new Button("Def.Pos.1"),					  new Button("Def.Pos.2"), 					  new Button("Def.Pos.3") };	private Button[] loadButtons = { new Button("Go Init"),					 new Button("Go Pos.1"),					 new Button("Go Pos.2"),					 new Button("Go Pos.3") }; 		// Declaration of the user interface variables:		private Font headerFont = new Font("TimesRoman", Font.BOLD, 14);	public Canvas roboCanvas = new Canvas();	public final int canvasSize = 500; // as in the original program	public ThreeD animation = new ThreeD(roboCanvas, this);	  // the animation has to be started after the roboCanvas gets resized		public int xControl = 25; //controls the speed	private Scrollbar speedScroll = new Scrollbar(Scrollbar.HORIZONTAL, 					 		xControl, 10, 1, 82); 	   // 'speedScroll' represents 1 to 82	public boolean megaSpeed = true;// if 'megaSpeed' is true, the double					 // buffering is omitted        public  float zoomValue = 1.5f; // should be between 0.1 and 3.5	private final int zoomScrollScale = 100;	private Scrollbar zoomScroll = new Scrollbar(Scrollbar.HORIZONTAL, 			       (int)(zoomScrollScale * zoomValue), 10, 0, 350);	  // 'zoomScrollScale' times the representing value           	private Panel belowP = new Panel();	private Panel leftP = new Panel();	private Panel rightP = new Panel();	private Panel upP = new Panel();	private Button exampleButton = new Button("Example");	private Scrollbar[] manualScrolls = new Scrollbar[6]; 	private Label[] manualLabels = new Label[6];	private final int manualScrollScale = 30;		// ... * 30, so that the control is more sensitive	private Scrollbar[] linkScrolls = new Scrollbar[3];	private Label[] linkLabels = new Label[3];	private Label linkHeader = new Label("Linklengths:");	private Button linkExec = new Button("e x e c u t e");	private final double[] linkMax = { 15.0, 15.0, 15.0 };	private final double[] linkMin = { 4.5, 2.5, 2.5 };	private final int linkScrollScale = 30; 		private Scrollbar[] autoScrolls = new Scrollbar[3];	private Label[] autoLabels = new Label[3];	private final int autoScrollScale = 20;	private final int autoScrollRange = 50;        private Label autoHeader = new Label("Inverse Kinematics:");	private final String onLine = new String("Move on a straight line");	private final String notOnLine = new String("Move on arbitrary way");	private Choice lineButton = new Choice();	private Button autoExecButton = new Button("e x e c u t e");	private static ErrorWindow errWin = null;//the object instanciated in 					  // 'writeError'	private static Win helpWin = null; // the help / about text are shown	private static Win aboutWin = null;// in these windows		private Choice hand = new Choice();	private Label handLabel = new Label("Hand");	private Scrollbar handScroll = new Scrollbar(Scrollbar.HORIZONTAL, 			                 0, 10, 0, 50);//represents 0 to 1	private final int handScrollScale = 100;	private double handValue = 0.0;// must be between 0.0 and 0.5				// 0.5 is fully closed and 0.0 open	private boolean showTheMove = true; // necessary for the "hand move"	private CheckboxGroup whichRobotGroup = new CheckboxGroup();	private Checkbox realRobot = new Checkbox("Real Robot", 					whichRobotGroup, false);	private Checkbox virtualRobot = new Checkbox("Virtual Robot", 					whichRobotGroup, true);	private Button fileButton = new Button("Open File");	private final String teachStr = new String("Teach");	private final String enterStr = new String("Enter");	private Button teachButton = new Button(teachStr);	private Button stopButton = new Button("Stop");	private RandomAccessFile saveFile = null;	private TextField[] weightsText = new TextField[6];	private Button weightsExec = new Button("e x e c u t e");	private Button helpButton = new Button("Help");	private Button aboutButton = new Button("About");        private String netscape = new String("netscape");	 			public void init()    	{	   for (int i = 0; i < 6; i++)	     manualLabels[i] = new Label("  ");	   for (int i = 0; i < 3; i++)	     {	       linkLabels[i] = new Label("  ");	       autoLabels[i] = new Label("  ");	     }  // instanciation of the label-arrays	   Label manualHeader = new Label("Forward Kinematics:");	   manualHeader.setFont(headerFont);	   linkHeader.setFont(headerFont);	   autoHeader.setFont(headerFont);		   RobotInit.now(this); // the robot specific variables get its values	   setLayout(new BorderLayout());	   // Definition of the 'roboCanvas':	   roboCanvas.resize(canvasSize, canvasSize);	   roboCanvas.setBackground(new Color(200, 200, 200));// a nice gray 	   add("Center", roboCanvas);	   // Defintion of the 'upP'anel:	   	   upP.setLayout(new FlowLayout()); 	   upP.add(helpButton);	   Label title = new Label("RoboSim - A Robot Manipulator Simulator");	   Font titleFont = new Font("TimesRoman", Font.ITALIC, 30);	   title.setFont(titleFont);	   upP.add(title);	   upP.add(aboutButton);	   add("North", upP);	   	   	   // Definition of the 'leftP'anel:	   leftP.setLayout(new GridLayout(33, 1, 10, 1));	   leftP.add(manualHeader);	   for (int i = 0; i < 6; i++)	     {		manualScrolls[i] = new Scrollbar(Scrollbar.HORIZONTAL, 			   (int)(manualScrollScale  * angles[i].act),			   10 /* width */, 			   (int)(manualScrollScale * angles[i].min), 			   (int)(manualScrollScale * angles[i].max));		manualScrolls[i].resize(100, 10);		updateManualLabel(i);		leftP.add(manualLabels[i]);		leftP.add(manualScrolls[i]);	   	leftP.add(new Label(""));	     }	   leftP.add(new Label(" ")); // Distance to the next entries	   leftP.add(new Label(" ")); 	   Label speedHeader = new Label("Speed:");	   speedHeader.setFont(headerFont);	   leftP.add(speedHeader);	   leftP.add(new Label("slow           -->                fast"));	   leftP.add(speedScroll); 	   leftP.add(new Label(" ")); // Distance to the next entries	   Label zoomHeader = new Label("Zoom:");	   zoomHeader.setFont(headerFont);	   leftP.add(zoomHeader);	   leftP.add(new Label("out            -->                   in"));	   leftP.add(zoomScroll);  	   leftP.add(new Label(" "));	   handLabel.setFont(headerFont);	   leftP.add(handLabel);	   leftP.add(new Label("open          -->                closed"));	   leftP.add(handScroll);	   add("West", leftP);  	   // Definition of the 'rightP'anel:	   rightP.setLayout(new GridLayout(27, 1, 10, 1));		   rightP.add(autoHeader);  	 	   for (int i = 0; i < 3; i++)	     {		autoScrolls[i] = new Scrollbar(Scrollbar.HORIZONTAL, 			   autoScrollScale * (int)target[i], 10 /* width */,  		           autoScrollScale * (-autoScrollRange), 			   autoScrollScale * autoScrollRange);		autoScrolls[i].resize(100, 10);		updateAutoLabel(i);						rightP.add(autoLabels[i]);		rightP.add(autoScrolls[i]);		if (i != 2) 		  rightP.add(new Label(""));	     }	   actualizeAutoPanel(); // to initialize the default values	   lineButton.addItem(notOnLine);	   lineButton.addItem(onLine);	   rightP.add(lineButton);	   rightP.add(autoExecButton);	   rightP.add(new Label("")); 	   rightP.add(linkHeader); 	   for (int i = 0; i < 3; i++)	     {		linkScrolls[i] = new Scrollbar(Scrollbar.HORIZONTAL, 			   (int)(linkScrollScale * linkLengths[i]), 			   10 /* width */, 			   (int)(linkScrollScale * linkMin[i]), 			   (int)(linkScrollScale * linkMax[i]));		linkScrolls[i].resize(100, 10);		updateLinkLabel(i);						rightP.add(linkLabels[i]);		rightP.add(linkScrolls[i]);	        if (i != 2)		  rightP.add(new Label(""));	     }	   rightP.add(linkExec);	   rightP.add(new Label(" "));	   rightP.add(fileButton); 	   rightP.add(new Label(" "));	   rightP.add(virtualRobot);	   rightP.add(realRobot);  	  	 	  	 	   add("East", rightP);		   // Definition of the 'belowP'anel:	   belowP.setLayout(new GridLayout(2, 12));	   Label weightHeader = new Label("Weights of:");	   weightHeader.setFont(headerFont);	   belowP.add(weightHeader); 	   for (int i = 0; i < 6; i++)	     belowP.add(new Label("Angle " + String.valueOf(i + 1)));	   belowP.add(exampleButton);	   for (int i = 1; i < 4; i++) // storeButton[0] should be irreversible	     belowP.add(storeButtons[i]);		   belowP.add(teachButton);	   belowP.add(weightsExec);	   for (int i = 0; i < 6; i++)	     {	       weightsText[i] = new TextField(String.valueOf(angleWeights[i]));	       belowP.add(weightsText[i]);	     }	   for (int i = 0; i < 4; i++)	     belowP.add(loadButtons[i]);	   stopButton.disable();	   belowP.add(stopButton);	   add("South", belowP);	   // First robot calculations and first painting of the robot:	   AllAboutMoving.copyPointList(PL, pl, this);	   RefDouble refAngleX = new RefDouble(angleX);// reference paramaters	   RefDouble refAngleY = new RefDouble(angleY);// are needed	   RefDouble refD = new RefDouble(d);	   AllAboutMoving.angleCalculation(0.0, 10.0, 26.0, refAngleY, 				refAngleX, refD);	   angleX = refAngleX.in; // the real variables get the new values	   angleY = refAngleY.in;	   d = refD.in;	   location[0] = 0.0; // I don't know, why these initialisations are	   location[1] = 10.0;// not in the init part of this program	   location[2] = 26.0;	   AllAboutMoving.Nvector(pl, al, apl, 0, this); 	   animation.setScale(zoomValue);	   animation.start(); // now the animation can be started, a new thread			      // begins to work	   CinematicCalculations.calculatePos(angles, pos, this);	 	   repaint();	}	public void start()	{ 	   menuEnable();	   repaint();		   repaint();	   repaint();// if java doesn't want to paint the robot	   repaint();	   repaint();	} 	public void stop()	{	  if (errWin != null)	    errWin.dispose(); // tidies up the only window which can be open	}		public void repaint()	{	   animation.repaint();	}	public void menuEnable()	{	   // If another window, which has the panels disabled,is destroyed, 	   // the panels should be enabled by using this method	   if (!leftP.isEnabled()) 	     leftP.enable(); 	   if (!rightP.isEnabled()) 	     rightP.enable();	   if (!belowP.isEnabled()) 	     belowP.enable();	   if (!upP.isEnabled()) 	     upP.enable();	   repaint();	}	public void menuDisable()	{	   upP.disable();	   leftP.disable();	   rightP.disable(); 	   belowP.disable();	}	private double roundTo2(double arg)	{	   return Math.floor(arg * 100) / 100;	}	private String formatTo5(double number)	{

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
性感美女久久精品| 91在线精品一区二区三区| 亚洲香蕉伊在人在线观| 国产丝袜美腿一区二区三区| 91精品国产综合久久福利| 波多野结衣在线aⅴ中文字幕不卡| 日韩成人免费在线| 夜色激情一区二区| 国产精品欧美一区喷水| 91官网在线观看| 成人av片在线观看| 国产乱理伦片在线观看夜一区| 午夜精品一区二区三区免费视频 | 日韩理论片在线| 亚洲国产精品黑人久久久 | 成人av电影在线| 不卡欧美aaaaa| 北条麻妃国产九九精品视频| 成人免费看片app下载| 国产精品91xxx| 成人一区二区三区中文字幕| 国产成人自拍网| 国产成人在线观看免费网站| 大胆亚洲人体视频| 成人精品一区二区三区四区 | 日本不卡高清视频| 日本不卡中文字幕| 另类小说综合欧美亚洲| 免费看日韩精品| 国内精品国产三级国产a久久| 极品少妇一区二区| 成人午夜在线免费| 色婷婷综合激情| 欧美精品乱码久久久久久按摩 | 国产精品1区2区| 波多野结衣欧美| 3atv在线一区二区三区| 精品1区2区在线观看| 久久久久久影视| 亚洲美女在线国产| 天堂久久久久va久久久久| 精品系列免费在线观看| 99精品热视频| 日韩视频中午一区| 中文字幕+乱码+中文字幕一区| 亚洲欧美日韩一区二区三区在线观看| 亚洲国产精品久久一线不卡| 欧美大片一区二区| 欧美高清在线精品一区| 亚洲成人午夜电影| 福利电影一区二区| 欧美三级电影网站| 国产精品久久久久aaaa樱花| 天天av天天翘天天综合网| 激情久久久久久久久久久久久久久久| 色综合一区二区| 久久免费偷拍视频| 精品视频资源站| 国产精品免费视频观看| 久久99精品久久久久久| 欧美视频一区二| ...中文天堂在线一区| 韩国三级在线一区| 欧美精品乱人伦久久久久久| 一区二区三国产精华液| 国产91精品一区二区麻豆亚洲| 欧美日韩高清一区| 亚洲精品久久久蜜桃| 韩国视频一区二区| 欧美一区二区三区啪啪| 亚洲成精国产精品女| 91丨九色丨尤物| 中文字幕在线观看不卡视频| 国产精品一区二区久久精品爱涩| 欧美精品乱码久久久久久| 亚洲激情图片qvod| 欧美亚洲一区三区| 一区二区欧美国产| 在线日韩国产精品| 亚洲精品欧美在线| 欧美视频日韩视频| 亚洲成人综合视频| 91麻豆精品国产91久久久久久久久 | 精品日韩欧美在线| 精品一区二区av| 国产亚洲成年网址在线观看| 国内成人自拍视频| 国产日韩高清在线| 99精品国产99久久久久久白柏 | 久久久久久久久久久久电影| 韩国在线一区二区| 日本一区二区成人| 91视频在线观看免费| 亚洲自拍另类综合| 欧美一区二区三区成人| 国产一区二区三区av电影| 国产欧美日韩综合精品一区二区| 成人久久18免费网站麻豆| 亚洲人成人一区二区在线观看| 91国模大尺度私拍在线视频| 蜜桃一区二区三区在线| 国产午夜亚洲精品羞羞网站| 色综合久久99| 日本在线观看不卡视频| 国产亚洲一区二区三区四区| www.成人网.com| 亚洲 欧美综合在线网络| 久久久久久久性| 欧美日韩国产一区二区三区地区| 蜜桃精品视频在线观看| 国产精品国产三级国产普通话三级 | 成人午夜视频网站| 色伊人久久综合中文字幕| 午夜影院在线观看欧美| 欧美一卡二卡三卡| a4yy欧美一区二区三区| 另类专区欧美蜜桃臀第一页| 亚洲欧美国产高清| 久久99久久精品| 亚洲成a天堂v人片| 亚洲欧洲日本在线| 久久久美女毛片| 欧美一级国产精品| 欧美日韩精品欧美日韩精品| 国产高清不卡一区| 久久精品国产亚洲aⅴ | 日韩免费看网站| 欧美色综合网站| 色综合久久久久久久久久久| 国产精品一二三| 久久99久久精品| 蜜臀久久99精品久久久久宅男| 夜夜亚洲天天久久| 亚洲精品免费播放| 成人av电影在线网| 盗摄精品av一区二区三区| 韩国av一区二区三区四区| 日本在线不卡视频| 免费精品视频最新在线| 亚洲超丰满肉感bbw| 亚洲成av人片在线观看| 亚洲成人精品一区| 亚洲h在线观看| 亚洲小少妇裸体bbw| 亚洲一区二区av在线| 亚洲一区二区av电影| 亚洲精品免费在线播放| 亚洲精品国产无套在线观| 亚洲人精品午夜| 亚洲精品国产视频| 亚洲成人精品影院| 日韩精品一二三四| 美腿丝袜在线亚洲一区| 国产精品一二一区| 成人亚洲一区二区一| 91欧美激情一区二区三区成人| 成人免费毛片片v| 91免费在线看| 在线不卡中文字幕播放| 欧美va亚洲va在线观看蝴蝶网| 久久久一区二区| 亚洲视频在线一区| 午夜视频在线观看一区| 美国毛片一区二区三区| 国产99久久久国产精品免费看 | 国产精品午夜久久| 一区二区三区在线观看视频 | 亚洲精品videosex极品| 蜜臀va亚洲va欧美va天堂| 懂色一区二区三区免费观看| 欧美性猛交xxxx乱大交退制版| 日韩精品中午字幕| 亚洲伦理在线精品| 看片的网站亚洲| 色先锋久久av资源部| 日韩欧美精品三级| 亚洲视频在线观看一区| 久久精品99国产国产精| 色综合久久综合网97色综合| 日韩免费观看高清完整版 | 成人免费三级在线| 日韩欧美国产系列| 亚洲视频一二区| 国产精品系列在线观看| 欧美探花视频资源| 中文字幕一区二区三区在线不卡| 偷窥少妇高潮呻吟av久久免费| 国产成人免费在线观看| 日韩欧美中文一区二区| 一区二区三区四区亚洲| 国产精品中文字幕日韩精品 | 久久夜色精品国产欧美乱极品| 亚洲欧美偷拍卡通变态| 成人精品免费视频| 欧美sm极限捆绑bd| 日本网站在线观看一区二区三区| 色婷婷久久久亚洲一区二区三区| 亚洲国产精品黑人久久久| 极品少妇一区二区三区精品视频 | 国产亚洲欧洲一区高清在线观看|