We create printed maps from a GeoTIFF file projected in LCC, which is a common projection for aviation maps. Part of our process includes customization of the raster image by selecting a region and adding other design elements. The final part of the process allows for the customer to select desired airports on the map via a custom leaflet application showing all the airports via a GeoJSON file.
We would like to have the tiles map image the customer sees in the Leaflet application be similar to the way the printed map will appear to the customer. This means they will stay in LCC and we crop and raster tile the actual artwork for use in leaflet. We have this all worked out just fine with tiling the resulting image and using leaflet and proj4leaflet. The issue we have is sometimes would like to rotate the crop so that the raster image does not end up aligning with the LCC projection.
Shown here is a copy of my main image where you can see the inside image which will make up our final printed artwork. The inlayed image aligns with the original image, but the cropped area is rotated about 13 degrees.
I would like to output inset cropped image, rotated so that it appears as it would appear hanging on the wall. This would involve rotating the image about 13 degrees.
If it were not rotated, we easily calculate a new TFW and include the northing and easting components by calculating the pixel size and the amount of the crop. This all works out perfectly.
However, with it being rotated, we need to add the rotation components to the TFW file and I have been unsuccessful in trying to figure that out.
The end results should be a map which appears to be a cropped version of the main map, projected in LCC, but rotated 13 degrees so that it appears online as it would appear hanging on the wall.
Things I've Tried
I've studied the page here: https://en.wikipedia.org/wiki/World_file and worked out that I need to do some trig on the pixel values.
The other completely unknown is if Leaflet and proj4leaflet can even handle these translations? Answer -- YES, I think I can use the Leaflet.Transformation function for this once I figure out the transformation to use for the rotation.
Update
Here is a concrete example of what I am trying to do along with the files.
The projection of these are
'+proj=lcc +lat_0=38 +lon_0=-100 +lat_1=45 +lat_2=33 +x_0=0 +y_0=0 +datum=WGS84 +units=m +no_defs'
Here is a portion of the the map I'm working with along with the accompanying pgw file.
Here is that same image rotated 45 degrees (around the center of the image)
What should the corresponding world file be for the rotated 45 image and how do you calculate each field in that file.