Source Code Cross Referenced for TiePoint.java in  » GIS » GeoTools-2.4.1 » org » geotools » gce » geotiff » IIOMetadataAdpaters » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » GIS » GeoTools 2.4.1 » org.geotools.gce.geotiff.IIOMetadataAdpaters 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /*
002:         *    Geotools2 - OpenSource mapping toolkit
003:         *    http://geotools.org
004:         *    (C) 2006, Geotools Project Managment Committee (PMC)
005:         *
006:         *    This library is free software; you can redistribute it and/or
007:         *    modify it under the terms of the GNU Lesser General Public
008:         *    License as published by the Free Software Foundation;
009:         *    version 2.1 of the License.
010:         *
011:         *    This library is distributed in the hope that it will be useful,
012:         *    but WITHOUT ANY WARRANTY; without even the implied warranty of
013:         *    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
014:         *    Lesser General Public License for more details.
015:         *
016:         */
017:        package org.geotools.gce.geotiff.IIOMetadataAdpaters;
018:
019:        /**
020:         * Quoting the geotiff spec:
021:         * 
022:         * <pre>
023:         *      ModelTiepointTag:
024:         *      Tag = 33922 (8482.H) 
025:         *      Type = DOUBLE (IEEE Double precision)
026:         *      N = 6*K,  K = number of tiepoints
027:         *      Alias: GeoreferenceTag
028:         *      Owner: Intergraph
029:         * </pre>
030:         * 
031:         * This tag stores raster->model tiepoint pairs in the order
032:         * 
033:         * 
034:         * <pre>
035:         *   ModelTiepointTag = (...,I,J,K, X,Y,Z...),
036:         * </pre>
037:         * 
038:         * where (I,J,K) is the point at location (I,J) in raster space with pixel-value
039:         * K, and (X,Y,Z) is a vector in model space. In most cases the model space is
040:         * only two-dimensional, in which case both K and Z should be set to zero; this
041:         * third dimension is provided in anticipation of future support for 3D digital
042:         * elevation models and vertical coordinate systems.
043:         * 
044:         * <p>
045:         * A raster image may be georeferenced simply by specifying its location, size
046:         * and orientation in the model coordinate space M. This may be done by
047:         * specifying the location of three of the four bounding corner points. However,
048:         * tiepoints are only to be considered exact at the points specified; thus
049:         * defining such a set of bounding tiepoints does not imply that the model space
050:         * locations of the interior of the image may be exactly computed by a linear
051:         * interpolation of these tiepoints.
052:         * 
053:         * <p>
054:         * However, since the relationship between the Raster space and the model space
055:         * will often be an exact, affine transformation, this relationship can be
056:         * defined using one set of tiepoints and the "ModelPixelScaleTag", described
057:         * below, which gives the vertical and horizontal raster grid cell size,
058:         * specified in model units.
059:         * 
060:         * <p>
061:         * If possible, the first tiepoint placed in this tag shall be the one
062:         * establishing the location of the point (0,0) in raster space. However, if
063:         * this is not possible (for example, if (0,0) is goes to a part of model space
064:         * in which the projection is ill-defined), then there is no particular order in
065:         * which the tiepoints need be listed.
066:         * 
067:         * <p>
068:         * For orthorectification or mosaicking applications a large number of tiepoints
069:         * may be specified on a mesh over the raster image. However, the definition of
070:         * associated grid interpolation methods is not in the scope of the current
071:         * GeoTIFF spec.
072:         * 
073:         * 
074:         * @author Simone Giannecchini
075:         * @since 2.3
076:         */
077:        public final class TiePoint {
078:            private double[] values = null;
079:
080:            public TiePoint(double i, double j, double k, double x, double y,
081:                    double z) {
082:                values = new double[6];
083:                set(i, j, k, x, y, z);
084:            }
085:
086:            public void set(double i, double j, double k, double x, double y,
087:                    double z) {
088:                values[0] = i;
089:                values[1] = j;
090:                values[2] = k;
091:                values[3] = x;
092:                values[4] = y;
093:                values[5] = z;
094:            }
095:
096:            public double getValueAt(int index) {
097:                if (index < 0 || index > 5)
098:                    throw new IllegalArgumentException(
099:                            "Provided index should be between 0 and 5");
100:                return values[index];
101:            }
102:
103:            public double[] getData() {
104:                return values;
105:            }
106:
107:            public boolean isSet() {
108:                return values != null;
109:            }
110:
111:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.