# Create a custom layer

**URL:** <https://community.thinkgeo.com/t/create-a-custom-layer/4315>\
**Category:** MVC\
**Created:** [July 14, 2015, 9:20am UTC](https://community.thinkgeo.com/t/create-a-custom-layer/4315 "2015-07-14T09:20:52Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![john12](https://community.thinkgeo.com/letter_avatar_proxy/v4/letter/j/f9ae1b/32.png) [@john12](https://community.thinkgeo.com/u/john12)\
**Post date:** [July 14, 2015, 9:20am UTC](https://community.thinkgeo.com/t/create-a-custom-layer/4315/1 "2015-07-14T09:20:52Z")

</div>

I&nbsp;have&nbsp;an&nbsp;MVC&nbsp;application&nbsp;that&nbsp;is&nbsp;using&nbsp;Bing&nbsp;maps&nbsp;with&nbsp;features&nbsp;over&nbsp;our&nbsp;buildings.&nbsp;The&nbsp;issue&nbsp;is&nbsp;Bing&nbsp;maps&nbsp;are&nbsp;out&nbsp;of&nbsp;date.&nbsp;We&nbsp;have&nbsp;flyovers&nbsp;imagery&nbsp;we&nbsp;have&nbsp;taken.&nbsp;I&nbsp;would&nbsp;like&nbsp;to&nbsp;add&nbsp;these&nbsp;images&nbsp;overtop&nbsp;of&nbsp;the&nbsp;Bing&nbsp;maps.What&nbsp;is&nbsp;the&nbsp;best&nbsp;way&nbsp;to&nbsp;do&nbsp;this?  
  
  
  
Also&nbsp;we&nbsp;take&nbsp;new&nbsp;flyover&nbsp;images&nbsp;quarterly.&nbsp;Is&nbsp;there&nbsp;a&nbsp;way&nbsp;to&nbsp;automate&nbsp;the&nbsp;process&nbsp;for&nbsp;updating&nbsp;these&nbsp;maps?

---

<div class="post-metadata">

**Author:** ![Ethan](https://community.thinkgeo.com/user_avatar/community.thinkgeo.com/ethan/32/19964_2.png) [@Ethan](https://community.thinkgeo.com/u/Ethan)\
**Post date:** [July 14, 2015, 10:40pm UTC](https://community.thinkgeo.com/t/create-a-custom-layer/4315/2 "2015-07-14T22:40:25Z")

</div>

Hi&nbsp;John,&nbsp;  
&nbsp;&nbsp;  
&nbsp;Do&nbsp;you&nbsp;meant&nbsp;you&nbsp;have&nbsp;some&nbsp;special&nbsp;image&nbsp;need&nbsp;be&nbsp;render&nbsp;above&nbsp;Bing&nbsp;map?&nbsp;  
&nbsp;&nbsp;  
&nbsp;Do&nbsp;you&nbsp;have&nbsp;the&nbsp;images&nbsp;data&nbsp;local&nbsp;or&nbsp;it’s&nbsp;a&nbsp;web&nbsp;service&nbsp;which&nbsp;just&nbsp;like&nbsp;Bing&nbsp;tile&nbsp;maps?&nbsp;  
&nbsp;&nbsp;  
&nbsp;If&nbsp;you&nbsp;have&nbsp;the&nbsp;data&nbsp;local,&nbsp;you&nbsp;can&nbsp;just&nbsp;add&nbsp;them&nbsp;to&nbsp;a&nbsp;layer,&nbsp;then&nbsp;put&nbsp;the&nbsp;layer&nbsp;above&nbsp;Bing&nbsp;map.&nbsp;If&nbsp;it’s&nbsp;a&nbsp;web&nbsp;service&nbsp;and&nbsp;you&nbsp;can&nbsp;access&nbsp;that&nbsp;by&nbsp;WMS,&nbsp;we&nbsp;have&nbsp;speical&nbsp;layer&nbsp;for&nbsp;it.&nbsp;&nbsp;  
&nbsp;&nbsp;  
&nbsp;If&nbsp;it&nbsp;cannot&nbsp;be&nbsp;access&nbsp;via&nbsp;standard&nbsp;WMS,&nbsp;you&nbsp;can&nbsp;contact&nbsp;our&nbsp;sales&nbsp;for&nbsp;get&nbsp;professional&nbsp;service.&nbsp;  
&nbsp;&nbsp;  
&nbsp;Regards,&nbsp;  
&nbsp;&nbsp;  
&nbsp;Don

---

<div class="post-metadata">

**Author:** ![john12](https://community.thinkgeo.com/letter_avatar_proxy/v4/letter/j/f9ae1b/32.png) [@john12](https://community.thinkgeo.com/u/john12)\
**Post date:** [July 15, 2015, 12:27pm UTC](https://community.thinkgeo.com/t/create-a-custom-layer/4315/3 "2015-07-15T12:27:55Z")

</div>

Do&nbsp;you&nbsp;meant&nbsp;you&nbsp;have&nbsp;some&nbsp;special&nbsp;image&nbsp;need&nbsp;be&nbsp;render&nbsp;above&nbsp;Bing&nbsp;map?&nbsp;  
  
&nbsp;&nbsp;&nbsp;&nbsp;Yes,&nbsp;I&nbsp;have&nbsp;images&nbsp;I&nbsp;need&nbsp;to&nbsp;render&nbsp;above&nbsp;the&nbsp;Bing&nbsp;map.  
  
  
  
Do&nbsp;you&nbsp;have&nbsp;the&nbsp;images&nbsp;data&nbsp;local&nbsp;or&nbsp;it’s&nbsp;a&nbsp;web&nbsp;service&nbsp;which&nbsp;just&nbsp;like&nbsp;Bing&nbsp;tile&nbsp;maps?&nbsp;  
  
&nbsp;&nbsp;&nbsp;&nbsp;The&nbsp;images&nbsp;are&nbsp;on&nbsp;a&nbsp;network&nbsp;share&nbsp;folder  
  
&nbsp;  
  
If&nbsp;you&nbsp;have&nbsp;the&nbsp;data&nbsp;local,&nbsp;you&nbsp;can&nbsp;just&nbsp;add&nbsp;them&nbsp;to&nbsp;a&nbsp;layer,&nbsp;then&nbsp;put&nbsp;the&nbsp;layer&nbsp;above&nbsp;Bing&nbsp;map.&nbsp;If&nbsp;it’s&nbsp;a&nbsp;web&nbsp;service&nbsp;and&nbsp;you&nbsp;can&nbsp;access&nbsp;that&nbsp;by&nbsp;WMS,&nbsp;we&nbsp;have&nbsp;speical&nbsp;layer&nbsp;for&nbsp;it.&nbsp;&nbsp;  
  
&nbsp;&nbsp;&nbsp;&nbsp;What&nbsp;type&nbsp;of&nbsp;layer&nbsp;do&nbsp;I&nbsp;use&nbsp;to&nbsp;load&nbsp;jpg?  
  
&nbsp;&nbsp;&nbsp;&nbsp;Do&nbsp;you&nbsp;have&nbsp;a&nbsp;code&nbsp;snippet&nbsp;or&nbsp;link&nbsp;to&nbsp;the&nbsp;proper&nbsp;way&nbsp;to&nbsp;do&nbsp;this?

---

<div class="post-metadata">

**Author:** ![Ethan](https://community.thinkgeo.com/user_avatar/community.thinkgeo.com/ethan/32/19964_2.png) [@Ethan](https://community.thinkgeo.com/u/Ethan)\
**Post date:** [July 15, 2015, 10:30pm UTC](https://community.thinkgeo.com/t/create-a-custom-layer/4315/4 "2015-07-15T22:30:08Z")

</div>

Hi&nbsp;John,&nbsp;  
&nbsp;&nbsp;  
&nbsp;You&nbsp;need&nbsp;a&nbsp;world&nbsp;file&nbsp;for&nbsp;each&nbsp;JPG&nbsp;file(or&nbsp;you&nbsp;specified&nbsp;the&nbsp;image&nbsp;in&nbsp;map&nbsp;one&nbsp;by&nbsp;one),&nbsp;then&nbsp;you&nbsp;can&nbsp;easily&nbsp;render&nbsp;it&nbsp;by&nbsp;GDIPlusRasterLayer.&nbsp;  
&nbsp;&nbsp;  
&nbsp;This&nbsp;sample&nbsp;render&nbsp;GIF&nbsp;format&nbsp;radar&nbsp;image,&nbsp;I&nbsp;think&nbsp;it&nbsp;can&nbsp;show&nbsp;you&nbsp;how&nbsp;to&nbsp;render&nbsp;an&nbsp;image.&nbsp;It’s&nbsp;based&nbsp;on&nbsp;ServiceEdition,&nbsp;but&nbsp;it’s&nbsp;the&nbsp;same&nbsp;to&nbsp;use&nbsp;GDIPlusRasterLayer.&nbsp;  
&nbsp;&nbsp;  
&nbsp;[wiki.thinkgeo.com/wiki/Map\_Suite\_Services\_Edition\_All\_Samples#Filter\_Radar\_Image](http://wiki.thinkgeo.com/wiki/Map_Suite_Services_Edition_All_Samples#Filter_Radar_Image)&nbsp;  
&nbsp;&nbsp;  
&nbsp;Regards,&nbsp;  
&nbsp;&nbsp;  
&nbsp;Don

---

<div class="post-metadata">

**Author:** ![john12](https://community.thinkgeo.com/letter_avatar_proxy/v4/letter/j/f9ae1b/32.png) [@john12](https://community.thinkgeo.com/u/john12)\
**Post date:** [August 4, 2015, 10:45am UTC](https://community.thinkgeo.com/t/create-a-custom-layer/4315/5 "2015-08-04T10:45:52Z")

</div>

The&nbsp;images&nbsp;I&nbsp;have&nbsp;need&nbsp;to&nbsp;be&nbsp;rotated&nbsp;to&nbsp;match&nbsp;up&nbsp;with&nbsp;the&nbsp;map.&nbsp;From&nbsp;what&nbsp;I&nbsp;have&nbsp;found&nbsp;the&nbsp;rotate&nbsp;is&nbsp;not&nbsp;implemented&nbsp;in&nbsp;the&nbsp;raster&nbsp;implementation.&nbsp;Is&nbsp;there&nbsp;another&nbsp;option&nbsp;to&nbsp;add&nbsp;in&nbsp;these&nbsp;images?

---

<div class="post-metadata">

**Author:** ![Ethan](https://community.thinkgeo.com/user_avatar/community.thinkgeo.com/ethan/32/19964_2.png) [@Ethan](https://community.thinkgeo.com/u/Ethan)\
**Post date:** [August 5, 2015, 12:27am UTC](https://community.thinkgeo.com/t/create-a-custom-layer/4315/6 "2015-08-05T00:27:32Z")

</div>

Hi&nbsp;John,&nbsp;  
&nbsp;&nbsp;  
&nbsp;I&nbsp;am&nbsp;sorry&nbsp;we&nbsp;don’t&nbsp;support&nbsp;rotate&nbsp;for&nbsp;GdiPlusRasterLayer&nbsp;for&nbsp;now.&nbsp;&nbsp;  
&nbsp;&nbsp;  
&nbsp;But&nbsp;our&nbsp;developer&nbsp;is&nbsp;working&nbsp;for&nbsp;try&nbsp;to&nbsp;make&nbsp;all&nbsp;raster&nbsp;layer&nbsp;support&nbsp;rotating,&nbsp;I&nbsp;think&nbsp;that&nbsp;will&nbsp;be&nbsp;enable&nbsp;in&nbsp;future.&nbsp;  
&nbsp;&nbsp;  
&nbsp;Regards,&nbsp;  
&nbsp;&nbsp;  
&nbsp;Don

---

<div class="post-metadata">

**Author:** ![john12](https://community.thinkgeo.com/letter_avatar_proxy/v4/letter/j/f9ae1b/32.png) [@john12](https://community.thinkgeo.com/u/john12)\
**Post date:** [August 5, 2015, 9:25am UTC](https://community.thinkgeo.com/t/create-a-custom-layer/4315/7 "2015-08-05T09:25:54Z")

</div>

What&nbsp;should&nbsp;I&nbsp;use&nbsp;instead&nbsp;for&nbsp;GDIPlusRasterLayer&nbsp;for&nbsp;the&nbsp;images&nbsp;I&nbsp;need&nbsp;to&nbsp;import?&nbsp;Do&nbsp;you&nbsp;have&nbsp;an&nbsp;example&nbsp;of&nbsp;how&nbsp;to&nbsp;do&nbsp;this?  
  
  
  
I&nbsp;need&nbsp;to&nbsp;be&nbsp;able&nbsp;load&nbsp;a&nbsp;group&nbsp;of&nbsp;JPG,&nbsp;rotate&nbsp;the&nbsp;image&nbsp;to&nbsp;line&nbsp;up&nbsp;with&nbsp;Bing&nbsp;maps,&nbsp;and&nbsp;put&nbsp;two&nbsp;more&nbsp;layer&nbsp;on&nbsp;top&nbsp;of&nbsp;these.&nbsp;One&nbsp;of&nbsp;these&nbsp;layers&nbsp;will&nbsp;have&nbsp;shape&nbsp;the&nbsp;other&nbsp;will&nbsp;have&nbsp;labels&nbsp;for&nbsp;these&nbsp;shapes.

---

<div class="post-metadata">

**Author:** ![Ethan](https://community.thinkgeo.com/user_avatar/community.thinkgeo.com/ethan/32/19964_2.png) [@Ethan](https://community.thinkgeo.com/u/Ethan)\
**Post date:** [August 5, 2015, 10:18pm UTC](https://community.thinkgeo.com/t/create-a-custom-layer/4315/8 "2015-08-05T22:18:01Z")

</div>

Hi&nbsp;John,&nbsp;  
&nbsp;&nbsp;  
&nbsp;I&nbsp;am&nbsp;sorry,&nbsp;we&nbsp;have&nbsp;to&nbsp;use&nbsp;GDIPlusRasterLayer&nbsp;to&nbsp;render&nbsp;JPG&nbsp;image&nbsp;for&nbsp;now,&nbsp;and&nbsp;it&nbsp;still&nbsp;don’t&nbsp;support&nbsp;rotate.&nbsp;  
&nbsp;&nbsp;  
&nbsp;Regards,&nbsp;  
&nbsp;&nbsp;  
&nbsp;Don&nbsp;  
&nbsp;&nbsp;  
&nbsp;&nbsp;

---

<div class="post-metadata">

**Author:** ![Johnny](https://community.thinkgeo.com/user_avatar/community.thinkgeo.com/johnny/32/19044_2.png) [@Johnny](https://community.thinkgeo.com/u/Johnny)\
**Post date:** [August 7, 2015, 5:43am UTC](https://community.thinkgeo.com/t/create-a-custom-layer/4315/9 "2015-08-07T05:43:37Z")

</div>

Hi&nbsp;John,&nbsp;  
  
  
  
Please&nbsp;download&nbsp;the&nbsp;latest&nbsp;development&nbsp;version&nbsp;9.0.45.0&nbsp;from&nbsp;Product&nbsp;Center&nbsp;to&nbsp;have&nbsp;a&nbsp;try.&nbsp;Now&nbsp;it&nbsp;should&nbsp;support&nbsp;the&nbsp;rotation&nbsp;of&nbsp;GdiPlusRasterLayer,&nbsp;but&nbsp;we&nbsp;are&nbsp;still&nbsp;improving&nbsp;the&nbsp;performance,&nbsp;once&nbsp;everything&nbsp;goes&nbsp;well,&nbsp;we&nbsp;will&nbsp;synchronize&nbsp;it&nbsp;to&nbsp;Production&nbsp;branch.&nbsp;&nbsp;Here&nbsp;is&nbsp;the&nbsp;demo&nbsp;code:

> `RotationProjection projection = ``new`&nbsp;`RotationProjection(60.0);`  
> `GdiPlusRasterLayer gdiPlusRasterLayer = ``new`&nbsp;`GdiPlusRasterLayer(@``"....\App_Data\PNG\World.png"``, ``new`&nbsp;`RectangleShape(-20037508.352, 20037508.352, 20037508.352, -20037508.352));`  
> `gdiPlusRasterLayer.ImageSource.Projection = projection;`

  
  
  
  
  
BTW,&nbsp;the&nbsp;specified&nbsp;version&nbsp;is&nbsp;still&nbsp;in&nbsp;building&nbsp;now,&nbsp;maybe&nbsp;you&nbsp;need&nbsp;to&nbsp;wait&nbsp;several&nbsp;hours.  
  
  
  
Thanks,&nbsp;  
  
Johnny
