Click here to Skip to main content
15,914,905 members
Home / Discussions / C#
   

C#

 
GeneralRe: C# Image hot spots? Pin
Jacob Dixon26-May-10 6:52
Jacob Dixon26-May-10 6:52 
GeneralRe: C# Image hot spots? Pin
Luc Pattyn26-May-10 7:39
sitebuilderLuc Pattyn26-May-10 7:39 
GeneralRe: C# Image hot spots? Pin
DaveyM6926-May-10 7:49
professionalDaveyM6926-May-10 7:49 
GeneralRe: C# Image hot spots? [modified] Pin
Luc Pattyn26-May-10 7:58
sitebuilderLuc Pattyn26-May-10 7:58 
GeneralRe: C# Image hot spots? Pin
DaveyM6926-May-10 13:07
professionalDaveyM6926-May-10 13:07 
GeneralRe: C# Image hot spots? Pin
Luc Pattyn26-May-10 13:33
sitebuilderLuc Pattyn26-May-10 13:33 
GeneralRe: C# Image hot spots? Pin
Jacob Dixon26-May-10 8:02
Jacob Dixon26-May-10 8:02 
GeneralRe: C# Image hot spots? Pin
Luc Pattyn26-May-10 8:17
sitebuilderLuc Pattyn26-May-10 8:17 
Yes, you have a real and a shadow image; you show the real one, but virtually you walk the shadow one so you get room identification almost automatically.

To highlight a room, you could do one of several things:

- replace the entire picture by a new one which you created manually (so N rooms takes N+1 pictures plus a shadow image); conceptually simple, lots of unrewarding work.

- replace the entire picture by a new one which you calculate on the spot. It could consist of the original pixels unmodified except for the ones that are inside the room, you could change their visible color and/or brightness; for a black-and-white floor plan, you might want to highlight the "current" room using a yellowish local background. It probably takes a couple of tricks to get that to work swiftly; you can't do a full 600*800 GetPixel/SetPixel loop fast enough, but you could do a two-image flood fill (scan the shadow, modify the visible image). Alternatively, you could extract each room once, from the shadow image; so you get separate room images, which tell you where the highlight should happen. If you make all room images the same highlight color, all you need is painting two images on top of each other: the real one, and the current room.

Smile | :)
Luc Pattyn [Forum Guidelines] [Why QA sucks] [My Articles]

I only read formatted code with indentation, so please use PRE tags for code snippets.

I'm not participating in frackin' Q&A, so if you want my opinion, ask away in a real forum (or on my profile page).

GeneralRe: C# Image hot spots? Pin
Jacob Dixon26-May-10 8:27
Jacob Dixon26-May-10 8:27 
GeneralRe: C# Image hot spots? Pin
Luc Pattyn26-May-10 8:38
sitebuilderLuc Pattyn26-May-10 8:38 
GeneralRe: C# Image hot spots? Pin
Jacob Dixon26-May-10 10:41
Jacob Dixon26-May-10 10:41 
GeneralRe: C# Image hot spots? Pin
Luc Pattyn26-May-10 10:51
sitebuilderLuc Pattyn26-May-10 10:51 
GeneralRe: C# Image hot spots? Pin
Jacob Dixon26-May-10 11:11
Jacob Dixon26-May-10 11:11 
GeneralRe: C# Image hot spots? Pin
Luc Pattyn26-May-10 11:51
sitebuilderLuc Pattyn26-May-10 11:51 
Questionread from serial port Pin
genieabdo26-May-10 3:41
genieabdo26-May-10 3:41 
AnswerRe: read from serial port Pin
Alaric_26-May-10 4:09
professionalAlaric_26-May-10 4:09 
GeneralRe: read from serial port Pin
genieabdo27-May-10 22:13
genieabdo27-May-10 22:13 
QuestionStreaming images using TCP help Pin
TimSWatson26-May-10 3:32
TimSWatson26-May-10 3:32 
AnswerRe: Streaming images using TCP help Pin
Luc Pattyn26-May-10 10:47
sitebuilderLuc Pattyn26-May-10 10:47 
GeneralRe: Streaming images using TCP help Pin
TimSWatson26-May-10 21:29
TimSWatson26-May-10 21:29 
GeneralRe: Streaming images using TCP help Pin
Luc Pattyn27-May-10 2:59
sitebuilderLuc Pattyn27-May-10 2:59 
QuestionNew Bluetooth Profile Pin
ika226-May-10 3:03
ika226-May-10 3:03 
QuestionWorking with list(Please help) [modified] Pin
future383926-May-10 2:36
future383926-May-10 2:36 
AnswerRe: Working with list(Please help) Pin
Henry Minute26-May-10 2:40
Henry Minute26-May-10 2:40 
GeneralMessage Removed Pin
26-May-10 2:46
future383926-May-10 2:46 

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.