Click here to Skip to main content
15,892,059 members
Home / Discussions / Graphics
   

Graphics

 
GeneralRe: Edit background on animated GIF Pin
Drew Stainton4-Mar-09 8:18
Drew Stainton4-Mar-09 8:18 
GeneralRe: Edit background on animated GIF Pin
Hans Dietrich4-Mar-09 8:25
mentorHans Dietrich4-Mar-09 8:25 
GeneralRe: Edit background on animated GIF Pin
mariahayek23-Apr-09 1:00
mariahayek23-Apr-09 1:00 
Questiondraw polygon using only two vertices Pin
Member 33753344-Mar-09 3:13
Member 33753344-Mar-09 3:13 
QuestionMap Wrapping Pin
Jim Warburton1-Mar-09 9:28
Jim Warburton1-Mar-09 9:28 
AnswerRe: Map Wrapping Pin
Pete O'Hanlon1-Mar-09 9:36
mvePete O'Hanlon1-Mar-09 9:36 
GeneralRe: Map Wrapping Pin
Jim Warburton1-Mar-09 10:54
Jim Warburton1-Mar-09 10:54 
GeneralRe: Map Wrapping Pin
Luc Pattyn1-Mar-09 11:23
sitebuilderLuc Pattyn1-Mar-09 11:23 
Hi,

I don't see where the problem could be (unless you hope to solve this with a PictureBox Big Grin | :-D ). Here are some thoughts, they may not be optimal, just intended to show a possible way:

1.
if you have an image of the world (say from longitude 0 to long 360), then you need to paint it in two steps, first from your starting longitude x0 upto 360, then from 0 to the right border (x0 again). So calling some overload of Graphics.DrawImage twice should do it.

An altenative is to construct a double-sized image once (that is from 0 to 360 and again from 0 to 360)
and then paint the right part of it.

2.
if you are drawing the world yourself, you can draw it in the regular way, you only need to adjust the x coordinate and again tranform the longitudes [0,360) to [x0...360, 0...x0).

This by itself could be handled by modifying all x coordinates; or more easily by having your paint code execute twice, once with a translation that takes care of the left part so [0, x0) gets clipped of at the left, and once with a translation that takes care of the right part so [x0, 360) gets clipped of at the right.


Smile | :)

Luc Pattyn [Forum Guidelines] [My Articles]

- before you ask a question here, search CodeProject, then Google
- the quality and detail of your question reflects on the effectiveness of the help you are likely to get
- use the code block button (PRE tags) to preserve formatting when showing multi-line code snippets


GeneralRe: Map Wrapping Pin
Jim Warburton1-Mar-09 12:28
Jim Warburton1-Mar-09 12:28 
GeneralRe: Map Wrapping Pin
Luc Pattyn1-Mar-09 12:31
sitebuilderLuc Pattyn1-Mar-09 12:31 
QuestionA Question about programming with DirectX 9 Pin
Kast Bloodrider28-Feb-09 6:43
Kast Bloodrider28-Feb-09 6:43 
AnswerRe: A Question about programming with DirectX 9 Pin
Pete O'Hanlon1-Mar-09 9:59
mvePete O'Hanlon1-Mar-09 9:59 
Questiondraw a line inside a circle Pin
Deresen25-Feb-09 6:11
Deresen25-Feb-09 6:11 
GeneralRe: draw a line inside a circle Pin
Luc Pattyn25-Feb-09 8:39
sitebuilderLuc Pattyn25-Feb-09 8:39 
GeneralRe: draw a line inside a circle Pin
Deresen25-Feb-09 9:08
Deresen25-Feb-09 9:08 
GeneralRe: draw a line inside a circle Pin
Luc Pattyn25-Feb-09 9:20
sitebuilderLuc Pattyn25-Feb-09 9:20 
GeneralRe: draw a line inside a circle Pin
Deresen25-Feb-09 11:34
Deresen25-Feb-09 11:34 
GeneralRe: draw a line inside a circle Pin
Luc Pattyn25-Feb-09 12:00
sitebuilderLuc Pattyn25-Feb-09 12:00 
GeneralRe: draw a line inside a circle Pin
Deresen25-Feb-09 20:52
Deresen25-Feb-09 20:52 
AnswerRe: draw a line inside a circle Pin
mohini19893-Mar-09 20:37
mohini19893-Mar-09 20:37 
NewsRe: draw a line inside a circle Pin
akirilov24-Apr-09 3:07
akirilov24-Apr-09 3:07 
GeneralRe: draw a line inside a circle Pin
akirilov24-Apr-09 3:17
akirilov24-Apr-09 3:17 
QuestionBITMAPINFO + Colour video Pin
jossion23-Feb-09 22:14
jossion23-Feb-09 22:14 
QuestionRe: BITMAPINFO + Colour video Pin
Mark Salsbery24-Feb-09 5:41
Mark Salsbery24-Feb-09 5:41 
AnswerRe: BITMAPINFO + Colour video Pin
jossion24-Feb-09 16:52
jossion24-Feb-09 16:52 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.