convert from Equidistant Cylindrical to Eckert I

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
9 messages Options
Reply | Threaded
Open this post in threaded view
|

convert from Equidistant Cylindrical to Eckert I

Wang Leslie

Dear all,


I'm new to this tool, and hope to get some advise here.

I'm thinking to use your tool to convert a map picture which is based on Equidistant Cylindrical, to another picture based on Eckert I. Since both of them are 2 dimension only (x,y), what I'm gonna to do is:
 - Use proj command to calculate the new mapped coordinate (x1, y1)
 - Set new pixel value at (x1, y1) using original pixel value (x,y)
 - loop for all pixel at original Equidistant Cylindrical picture

So can you please help me confirm if one idea can work or not? If yes, what should command line look like? Thanks.

Best Regards
Leslie Qi Wang

_______________________________________________
Proj mailing list
[hidden email]
http://lists.maptools.org/mailman/listinfo/proj
Reply | Threaded
Open this post in threaded view
|

Re: convert from Equidistant Cylindrical to Eckert I

strebe
Hello Leslie.

Your procedure will work. The results will be heavily aliased, which will look like speckling. Some values of (x₁, y
) will be empty unless the destination map is considerably smaller than the source image.

Regards,
— daan Strebe



-----Original Message-----
From: Wang Leslie <[hidden email]>
To: proj <[hidden email]>
Sent: Mon, May 23, 2016 7:37 am
Subject: [Proj] convert from Equidistant Cylindrical to Eckert I

Dear all,

I'm new to this tool, and hope to get some advise here.

I'm thinking to use your tool to convert a map picture which is based on Equidistant Cylindrical, to another picture based on Eckert I. Since both of them are 2 dimension only (x,y), what I'm gonna to do is:
 - Use proj command to calculate the new mapped coordinate (x1, y1)
 - Set new pixel value at (x1, y1) using original pixel value (x,y)
 - loop for all pixel at original Equidistant Cylindrical picture

So can you please help me confirm if one idea can work or not? If yes, what should command line look like? Thanks.

Best Regards
Leslie Qi Wang
_______________________________________________
Proj mailing list
[hidden email]
http://lists.maptools.org/mailman/listinfo/proj

_______________________________________________
Proj mailing list
[hidden email]
http://lists.maptools.org/mailman/listinfo/proj
Reply | Threaded
Open this post in threaded view
|

Re: convert from Equidistant Cylindrical to Eckert I

Norman Vine
Hello Leslie

I suggest using http://www.gdal.org/gdalwarp.html todo this

To avoid the speckling that Daan mentions you want to loop over the new image
pixels and do the inverse projection to find the pixel value in the original image

gdalwarp takes care of this for you and is built on top of the proj library

Norman

> On May 24, 2016, at 3:05 AM, [hidden email] wrote:
>
> Hello Leslie.
>
> Your procedure will work. The results will be heavily aliased, which will look like speckling. Some values of (x₁, y₁) will be empty unless the destination map is considerably smaller than the source image.
>
> Regards,
> — daan Strebe
>
>
>
> -----Original Message-----
> From: Wang Leslie <[hidden email]>
> To: proj <[hidden email]>
> Sent: Mon, May 23, 2016 7:37 am
> Subject: [Proj] convert from Equidistant Cylindrical to Eckert I
>
> Dear all,
>
> I'm new to this tool, and hope to get some advise here.
>
> I'm thinking to use your tool to convert a map picture which is based on Equidistant Cylindrical, to another picture based on Eckert I. Since both of them are 2 dimension only (x,y), what I'm gonna to do is:
>  - Use proj command to calculate the new mapped coordinate (x1, y1)
>  - Set new pixel value at (x1, y1) using original pixel value (x,y)
>  - loop for all pixel at original Equidistant Cylindrical picture
>
> So can you please help me confirm if one idea can work or not? If yes, what should command line look like? Thanks.
>
> Best Regards
> Leslie Qi Wang
> _______________________________________________
> Proj mailing list
> [hidden email]
> http://lists.maptools.org/mailman/listinfo/proj
> _______________________________________________
> Proj mailing list
> [hidden email]
> http://lists.maptools.org/mailman/listinfo/proj

_______________________________________________
Proj mailing list
[hidden email]
http://lists.maptools.org/mailman/listinfo/proj
Reply | Threaded
Open this post in threaded view
|

Re: convert from Equidistant Cylindrical to Eckert I

Wang Leslie
Hi Norman, Dann,

Thanks for quick reply. It would be highly appreciated for one sample command on these tools to achieve my goal.

Best Regards
Leslie

________________________________________
From: [hidden email] <[hidden email]> on behalf of Norman Vine <[hidden email]>
Sent: Tuesday, May 24, 2016 7:20 AM
To: PROJ.4 and general Projections Discussions
Subject: Re: [Proj] convert from Equidistant Cylindrical to Eckert I

Hello Leslie

I suggest using http://www.gdal.org/gdalwarp.html todo this

To avoid the speckling that Daan mentions you want to loop over the new image
pixels and do the inverse projection to find the pixel value in the original image

gdalwarp takes care of this for you and is built on top of the proj library

Norman

> On May 24, 2016, at 3:05 AM, [hidden email] wrote:
>
> Hello Leslie.
>
> Your procedure will work. The results will be heavily aliased, which will look like speckling. Some values of (x₁, y₁) will be empty unless the destination map is considerably smaller than the source image.
>
> Regards,
> — daan Strebe
>
>
>
> -----Original Message-----
> From: Wang Leslie <[hidden email]>
> To: proj <[hidden email]>
> Sent: Mon, May 23, 2016 7:37 am
> Subject: [Proj] convert from Equidistant Cylindrical to Eckert I
>
> Dear all,
>
> I'm new to this tool, and hope to get some advise here.
>
> I'm thinking to use your tool to convert a map picture which is based on Equidistant Cylindrical, to another picture based on Eckert I. Since both of them are 2 dimension only (x,y), what I'm gonna to do is:
>  - Use proj command to calculate the new mapped coordinate (x1, y1)
>  - Set new pixel value at (x1, y1) using original pixel value (x,y)
>  - loop for all pixel at original Equidistant Cylindrical picture
>
> So can you please help me confirm if one idea can work or not? If yes, what should command line look like? Thanks.
>
> Best Regards
> Leslie Qi Wang
> _______________________________________________
> Proj mailing list
> [hidden email]
> http://lists.maptools.org/mailman/listinfo/proj
> _______________________________________________
> Proj mailing list
> [hidden email]
> http://lists.maptools.org/mailman/listinfo/proj

_______________________________________________
Proj mailing list
[hidden email]
http://lists.maptools.org/mailman/listinfo/proj
_______________________________________________
Proj mailing list
[hidden email]
http://lists.maptools.org/mailman/listinfo/proj
Reply | Threaded
Open this post in threaded view
|

Re: convert from Equidistant Cylindrical to Eckert I

José Alberto Gonçalves
Hi
You can transform your image with the following command line:

gdalwarp -s_srs "+ellps=WGS84 +proj=eqd" -t_srs "+ellps=WGS84 +proj=eck1" in.tif out.tif

The input image must be georeferenced in the equidistant cylindrical projection, with units in meters. See page http://www.gdal.org/gdalwarp.html. Other important options are -r, -te and -tr.
Regards
José Gonçalves


2016-05-24 23:16 GMT+01:00 Wang Leslie <[hidden email]>:
Hi Norman, Dann,

Thanks for quick reply. It would be highly appreciated for one sample command on these tools to achieve my goal.

Best Regards
Leslie

________________________________________
From: [hidden email] <[hidden email]> on behalf of Norman Vine <[hidden email]>
Sent: Tuesday, May 24, 2016 7:20 AM
To: PROJ.4 and general Projections Discussions
Subject: Re: [Proj] convert from Equidistant Cylindrical to Eckert I

Hello Leslie

I suggest using http://www.gdal.org/gdalwarp.html todo this

To avoid the speckling that Daan mentions you want to loop over the new image
pixels and do the inverse projection to find the pixel value in the original image

gdalwarp takes care of this for you and is built on top of the proj library

Norman

> On May 24, 2016, at 3:05 AM, [hidden email] wrote:
>
> Hello Leslie.
>
> Your procedure will work. The results will be heavily aliased, which will look like speckling. Some values of (x₁, y₁) will be empty unless the destination map is considerably smaller than the source image.
>
> Regards,
> — daan Strebe
>
>
>
> -----Original Message-----
> From: Wang Leslie <[hidden email]>
> To: proj <[hidden email]>
> Sent: Mon, May 23, 2016 7:37 am
> Subject: [Proj] convert from Equidistant Cylindrical to Eckert I
>
> Dear all,
>
> I'm new to this tool, and hope to get some advise here.
>
> I'm thinking to use your tool to convert a map picture which is based on Equidistant Cylindrical, to another picture based on Eckert I. Since both of them are 2 dimension only (x,y), what I'm gonna to do is:
>  - Use proj command to calculate the new mapped coordinate (x1, y1)
>  - Set new pixel value at (x1, y1) using original pixel value (x,y)
>  - loop for all pixel at original Equidistant Cylindrical picture
>
> So can you please help me confirm if one idea can work or not? If yes, what should command line look like? Thanks.
>
> Best Regards
> Leslie Qi Wang
> _______________________________________________
> Proj mailing list
> [hidden email]
> http://lists.maptools.org/mailman/listinfo/proj
> _______________________________________________
> Proj mailing list
> [hidden email]
> http://lists.maptools.org/mailman/listinfo/proj

_______________________________________________
Proj mailing list
[hidden email]
http://lists.maptools.org/mailman/listinfo/proj
_______________________________________________
Proj mailing list
[hidden email]
http://lists.maptools.org/mailman/listinfo/proj


_______________________________________________
Proj mailing list
[hidden email]
http://lists.maptools.org/mailman/listinfo/proj
Reply | Threaded
Open this post in threaded view
|

Re: convert from Equidistant Cylindrical to Eckert I

Wang Leslie

Hi Jose,


Thanks for the quick reply.


What do you mean "be geo-referenced"? What I'm thinking is to use these tools to convert a 360 panorama picture, such as https://upload.wikimedia.org/wikipedia/commons/3/35/Space_Needle_360_Panorama.jpg, which is an equidistant cylindrical projection, to other type of projection, which keeps same quality but with smaller size. Thus I can save some storage spaces. In this case, these 360 picture doesn't have any geo-referenced data. Can I still use these tools? 





From: [hidden email] <[hidden email]> on behalf of Jose Gonçalves <[hidden email]>
Sent: Tuesday, May 24, 2016 11:03 PM
To: PROJ.4 and general Projections Discussions
Subject: Re: [Proj] convert from Equidistant Cylindrical to Eckert I
 
Hi
You can transform your image with the following command line:

gdalwarp -s_srs "+ellps=WGS84 +proj=eqd" -t_srs "+ellps=WGS84 +proj=eck1" in.tif out.tif

The input image must be georeferenced in the equidistant cylindrical projection, with units in meters. See page http://www.gdal.org/gdalwarp.html. Other important options are -r, -te and -tr.
www.gdal.org
image reprojection and warping utility. SYNOPSIS. Usage: gdalwarp [--help-general] [--formats] [-s_srs srs_def] [-t_srs srs_def] [-to "NAME=VALUE"] [-order n | -tps ...


Regards
José Gonçalves


2016-05-24 23:16 GMT+01:00 Wang Leslie <[hidden email]>:
Hi Norman, Dann,

Thanks for quick reply. It would be highly appreciated for one sample command on these tools to achieve my goal.

Best Regards
Leslie

________________________________________
From: [hidden email] <[hidden email]> on behalf of Norman Vine <[hidden email]>
Sent: Tuesday, May 24, 2016 7:20 AM
To: PROJ.4 and general Projections Discussions
Subject: Re: [Proj] convert from Equidistant Cylindrical to Eckert I

Hello Leslie

I suggest using http://www.gdal.org/gdalwarp.html todo this

To avoid the speckling that Daan mentions you want to loop over the new image
pixels and do the inverse projection to find the pixel value in the original image

gdalwarp takes care of this for you and is built on top of the proj library

Norman

> On May 24, 2016, at 3:05 AM, [hidden email] wrote:
>
> Hello Leslie.
>
> Your procedure will work. The results will be heavily aliased, which will look like speckling. Some values of (x₁, y₁) will be empty unless the destination map is considerably smaller than the source image.
>
> Regards,
> — daan Strebe
>
>
>
> -----Original Message-----
> From: Wang Leslie <[hidden email]>
> To: proj <[hidden email]>
> Sent: Mon, May 23, 2016 7:37 am
> Subject: [Proj] convert from Equidistant Cylindrical to Eckert I
>
> Dear all,
>
> I'm new to this tool, and hope to get some advise here.
>
> I'm thinking to use your tool to convert a map picture which is based on Equidistant Cylindrical, to another picture based on Eckert I. Since both of them are 2 dimension only (x,y), what I'm gonna to do is:
>  - Use proj command to calculate the new mapped coordinate (x1, y1)
>  - Set new pixel value at (x1, y1) using original pixel value (x,y)
>  - loop for all pixel at original Equidistant Cylindrical picture
>
> So can you please help me confirm if one idea can work or not? If yes, what should command line look like? Thanks.
>
> Best Regards
> Leslie Qi Wang
> _______________________________________________
> Proj mailing list
> [hidden email]
> http://lists.maptools.org/mailman/listinfo/proj
> _______________________________________________
> Proj mailing list
> [hidden email]
> http://lists.maptools.org/mailman/listinfo/proj

_______________________________________________
Proj mailing list
[hidden email]
http://lists.maptools.org/mailman/listinfo/proj
_______________________________________________
Proj mailing list
[hidden email]
http://lists.maptools.org/mailman/listinfo/proj


_______________________________________________
Proj mailing list
[hidden email]
http://lists.maptools.org/mailman/listinfo/proj
Reply | Threaded
Open this post in threaded view
|

Re: convert from Equidistant Cylindrical to Eckert I

strebe
Hello Leslie.

You cannot magically preserve information by reprojecting it. That can only lose information. You would get much better results just using standard image editing applications to scale the image down.

Regards,
— daan Strebe

On May 24, 2016, at 16:34, Wang Leslie <[hidden email]> wrote:

Hi Jose,


Thanks for the quick reply.


What do you mean "be geo-referenced"? What I'm thinking is to use these tools to convert a 360 panorama picture, such as https://upload.wikimedia.org/wikipedia/commons/3/35/Space_Needle_360_Panorama.jpg, which is an equidistant cylindrical projection, to other type of projection, which keeps same quality but with smaller size. Thus I can save some storage spaces. In this case, these 360 picture doesn't have any geo-referenced data. Can I still use these tools? 




_______________________________________________
Proj mailing list
[hidden email]
http://lists.maptools.org/mailman/listinfo/proj
Reply | Threaded
Open this post in threaded view
|

Re: convert from Equidistant Cylindrical to Eckert I

José Alberto Gonçalves
In reply to this post by Wang Leslie
An image is georeferenced if there is some form of associating pixel positions (row, column) to geolocation, in geographic or cartographic coordinates.
Proj, or any other program that uses proj, needs that to apply map projection formulas
In your case you must simulate that your image is georeferenced, giving it an extent of 360 degrees in longitude (row) and some proportional extent in latitude (column).
Regards

Jose


2016-05-25 0:34 GMT+01:00 Wang Leslie <[hidden email]>:

Hi Jose,


Thanks for the quick reply.


What do you mean "be geo-referenced"? What I'm thinking is to use these tools to convert a 360 panorama picture, such as https://upload.wikimedia.org/wikipedia/commons/3/35/Space_Needle_360_Panorama.jpg, which is an equidistant cylindrical projection, to other type of projection, which keeps same quality but with smaller size. Thus I can save some storage spaces. In this case, these 360 picture doesn't have any geo-referenced data. Can I still use these tools? 




_______________________________________________
Proj mailing list
[hidden email]
http://lists.maptools.org/mailman/listinfo/proj
Reply | Threaded
Open this post in threaded view
|

Re: convert from Equidistant Cylindrical to Eckert I

Wang Leslie

I thought this association is standard. In other words, given the size of one image and type of cylindrical projection, each pixel should be associated to correct (longitude, latitude) at sphere. My assumption is the image is assumed to unwrap the complete sphere. 


Best Regards

Leslie




From: [hidden email] <[hidden email]> on behalf of Jose Gonçalves <[hidden email]>
Sent: Wednesday, May 25, 2016 11:51 AM
To: PROJ.4 and general Projections Discussions
Subject: Re: [Proj] convert from Equidistant Cylindrical to Eckert I
 
An image is georeferenced if there is some form of associating pixel positions (row, column) to geolocation, in geographic or cartographic coordinates.
Proj, or any other program that uses proj, needs that to apply map projection formulas
In your case you must simulate that your image is georeferenced, giving it an extent of 360 degrees in longitude (row) and some proportional extent in latitude (column).
Regards

Jose


2016-05-25 0:34 GMT+01:00 Wang Leslie <[hidden email]>:

Hi Jose,


Thanks for the quick reply.


What do you mean "be geo-referenced"? What I'm thinking is to use these tools to convert a 360 panorama picture, such as https://upload.wikimedia.org/wikipedia/commons/3/35/Space_Needle_360_Panorama.jpg, which is an equidistant cylindrical projection, to other type of projection, which keeps same quality but with smaller size. Thus I can save some storage spaces. In this case, these 360 picture doesn't have any geo-referenced data. Can I still use these tools? 




_______________________________________________
Proj mailing list
[hidden email]
http://lists.maptools.org/mailman/listinfo/proj