I have the following:
- A PNG or JPG of a random width and height, in pixels, that represents a partial map of the world (i.e. a rectangle of the United States).
- The four corners of this image are represented by real latitude and longitude values that if plotted, would represent 4 corner points of the United States (LatTop, LatBottom, LongLeft, LongRight).
- A coordinate that, if plotted, would represent a point somewhere inside of this "rectangle" (Latitude, Longitude).
My question is, what type of projection or formula would I use to calculate the X and Y coordinates (in pixels based off of the original PNG/JPG image) of the coordinate provided in #3 above?
Some example values would be:
- ImageWidth = 1312
- ImageHeight = 576
- LatTop = 30.244381
- LatBottom = 29.529928
- LongLeft = -96.764958
- LongRight = -94.404619
- Coordinate Latitude = 30.100000
- Coordinate Longitude = 95.100000
I found some information regarding Plate Carrée projections but I could not successfully apply it to this problem. Perhaps I am missing something.