Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[udig-devel] net.refractions.udig.libs / geotools 2.6 issue

I am cross-posting to geotools and udig, because i think both are concerned.

So in a nutschell, i try to use geotools Warp2DTransform to perform warping from pixels coordinate to geographic coordinate. I have been using geotools for a while, but now i need to move geotools library to osgi bundle (here comes udig).

So i used net.refractions.udig.libs that have already done the work. I am checking out the trunk, ie using geotools-2.6-SNAPSHOT version.

Using directly the geotools 2.6 with my classes, Warp2DTransform Works ok. I input a set of GCPs and get a correct transformation, of degree 3.
Using the same class in the udig bundles, the results is totally wrong, ie the coefficients are very low. See the difference below. The funny thing is that is that when i divide the outputs with prescales factors, i got results of the right order (ie coordinates around (43,12) instead of(0.006,0,001), but there are still wrong in the sense that coordinates are very close to each others (order of 0.0001 degrees instead of degrees).

any hints?

geotools 2.6-SNAPSHOT/udig eclipse bundle (Wrong coeffs)

PARAM_MT["WarpPolynomial",
 PARAMETER["degree", 3],
 PARAMETER["xCoeffs", {0.006612524390220642, 0.00000001603510035864, -0.00000000411600664663, -0.00000000000000079568, -0.00000000000000710382, -0.00000000000000444428, -0.00000000000000000005, -0.00000000000000000003, 0.00000000000000000026, 0.00000000000000000104}],
 PARAMETER["yCoeffs", {-0.0015807533636689186, 0.00000000305463854211, 0.00000001448123754244, 0.00000000000000241329, -0.00000000000000179796, 0.00000000000000177312, 0.00000000000000000001, -0.00000000000000000001, -0.00000000000000000005, -0.00000000000000000025}],
 PARAMETER["preScaleX", 0.0001521606754977256],
 PARAMETER["preScaleY", 0.00012525050260592252],
 PARAMETER["postScaleX", 0.9410438537597656],
 PARAMETER["postScaleY", 1.0499610900878906]]


geotools 2.6 (right Coeffs)

PARAM_MT["WarpPolynomial",
PARAMETER["degree", 3],
   PARAMETER["xCoeffs", {46.180110931396484, 0.7821832299232483, -0.21910369396209717, -0.0004944244283251464, -0.0024764996487647295, 0.00076442607678473, -0.00001066674121830147, 0.0000213175590033643, 0.0001045847893692553, 0.00009047376806847751}],
  PARAMETER["yCoeffs", {-12.020193099975586, 0.16218608617782593, 0.8374767303466797, 0.0009584086365066469, -0.0007706039468757808, 0.0001044207310769707, -0.0000068093295340077, -0.00006432097870856524, 0.00001632759085623547, -0.00000976871160673909}],
  PARAMETER["preScaleX", 0.0001521606754977256],
  PARAMETER["preScaleY", 0.00012525050260592252],
  PARAMETER["postScaleX", 0.9410438537597656],
  PARAMETER["postScaleY", 1.0499610900878906]]



Back to the top