1 / 5

Μετατροπή συνεχούς διαστήματος σε διακριτό

0. 1. 2. 3. 4. 5. 6. 7. 8. 9. Μετατροπή συνεχούς διαστήματος σε διακριτό. n = 10 Pixels:. 10 Λογικές Μονάδες (rWidth). 0  x  rWidth maxX = n-1; pixelWidth = rWidth / maxX; // κλίμακα Συντεταγμένες συσκευής (pixels): int iX(float x) {return Math.round(x/ pixelWidth)}.

quilla
Download Presentation

Μετατροπή συνεχούς διαστήματος σε διακριτό

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. 0 1 2 3 4 5 6 7 8 9 Μετατροπή συνεχούς διαστήματος σε διακριτό n = 10 Pixels: 10 Λογικές Μονάδες (rWidth) 0 x  rWidth maxX = n-1; pixelWidth = rWidth / maxX; // κλίμακα Συντεταγμένες συσκευής (pixels): int iX(float x) {return Math.round(x/ pixelWidth)}

  2. 1η Άσκηση Γραφικής Anisotropic mapping mode Y = 10 Χ / Υ = 2 0,0 Χ = 10 Ανισοτροπικό σύστημα συντεταγμένων Είναι το σύστημα στο οποίο η αναλογία κλίμακας τωνxκαι yσυντεταγμένων ,δεν είναι ίση με 1. Μήκος μονάδας x διαφορετικό από μήκος μονάδας y.

  3. 1η Άσκηση Γραφικής Anisotropic mapping mode rWidth = 10.0; rHeight = 7.0; Dimension d = getSize(); maxX = d.width - 1; maxY = d.height - 1; //pixels number -1 pixelWidth = rWidth/maxX; // κλίμακα x pixelHeight = rHeight/maxY; // κλίμακα y Συντεταγμένες συσκευής: int iX(float x){return Math.round(x/pixelWidth);} int iY(float y){return maxY - Math.round(y/pixelHeight);} Λογικές συντεταγμένες: float fx(int X){return X * pixelWidth;} float fy(int Y){return (maxY - Y) * pixelHeight;} 0  y  7

  4. 2η Άσκηση Γραφικής Isotropic mapping mode Y = 10 Χ / Υ = 1 0,0 Χ = 10 Iσοτροπικό σύστημα συντεταγμένων Είναι το σύστημα στο οποίο η αναλογία κλίμακας τωνxκαι yσυντεταγμένων , είναι ίση με 1. Μήκος μονάδας x ίσο με μήκος μονάδας y.

  5. 2η Άσκηση Γραφικής Isotropic mapping mode rWidth = 10.0; rHeight = 10.0; Dimension d = getSize(); maxX = d.width - 1; maxY = d.height - 1; //pixels number -1 pixelSize = Math.max(rWidth/maxX, rHeight/maxY); //scale centerX = maxX/2; centerY = maxY/2; // λογικό (0,0) // κέντρο frame Συντεταγμένες συσκευής: int iX(float x){return Math.round(centerX + x/pixelSize);} int iY(float y){return Math.round(centerY - y/pixelSize);} Λογικές συντεταγμένες: float fx(int X){return (X - centerX) * pixelSize;} float fy(int Y){return (centerY - Y) * pixelSize;} 0  y  10

More Related