Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / IR tracking

Author
Message
Iconik
15
Years of Service
User Offline
Joined: 11th Dec 2008
Location:
Posted: 11th Dec 2008 10:18
Ive made an IR camera out of a webcam and i would like it to be able to track IRLED's but unfortunatly my kwnologe of Dark GDK and C++ isn't exactly up to scratch so i was wandering if someone could please help me.
APEXnow
Retired Moderator
21
Years of Service
User Offline
Joined: 15th Apr 2003
Location: On a park bench
Posted: 11th Dec 2008 12:14
Although this isn't specifically related to GDK or it's functions, I'll let this one through as it might prove an interesting challenge.

Paul.

Iconik
15
Years of Service
User Offline
Joined: 11th Dec 2008
Location:
Posted: 11th Dec 2008 16:37
Im hoping to use the GDK librarys to make a oldschool rail game like house of the dead using headtracking and some form of light gun. The majority of this i could do myself but im having some serious problems with the IR tracking.
Lilith
16
Years of Service
User Offline
Joined: 12th Feb 2008
Location: Dallas, TX
Posted: 11th Dec 2008 17:53
Not being familiar with the subject, what can you tell us about how the information from the webcam is delivered to you.

Lilith, Night Butterfly
I'm not a programmer but I play one in the office
Iconik
15
Years of Service
User Offline
Joined: 11th Dec 2008
Location:
Posted: 12th Dec 2008 01:13
The web cam is basicly a digital camera with an IR filter that only lets in waveleanghts from the IR part of the light spectrum. IRLED's appear as white dots similar to the wiimote sensitivity config. Im guessing the best way to track them is to seperate the white dots from the rest of the black image.
Lilith
16
Years of Service
User Offline
Joined: 12th Feb 2008
Location: Dallas, TX
Posted: 12th Dec 2008 05:11 Edited at: 12th Dec 2008 05:14
Does the camera API feed you the image and do you have access to the image.

If I had the image to work with I would have to assume that the pixels are neither totally black or totally white. I couldn't even assume that any of them were absolutely grey unless the webcam API guarantee it.

I'd have to consider a certain sensitivity and require that for a spot to be considered white that it had a pixel value above a certain intensity. Then, assuming I had to scan the entire image to find a spot, I'd scan each line successively until I found a pixel that was at or above my sensitivity setting. I'd then start scanning down from that point until the pixels were under my sensitivity level and find the mid point of the line joining the top and bottom and scan left and right to find where the pixels were under my sensitivity range and let my findings define a rectangle that encompassed the dot and use that information to find a center.

If continual tracking was required from one image to the next I might constrain my scans to the neighborhood of the last spot found unless there was a chance that it would be fast moving.

But if the need to locate the dot didn't occur until something triggered the need.

You might find some information on the process by looking at what Johnny Lee did with Wii tracking. Have a look at this link

http://www.cs.cmu.edu/~johnny/projects/wii/

You might find more information by googling some of the topics you find there. In fact, this link may be even better

http://www.wiimoteproject.com/

Lilith, Night Butterfly
I'm not a programmer but I play one in the office
Iconik
15
Years of Service
User Offline
Joined: 11th Dec 2008
Location:
Posted: 12th Dec 2008 05:56
Ive looked into Jonny Chung Lee's wiimote projects and im quite impressed, Because of that ive decided to try out Brian Peeks wiimote librarys. Im also intrested in implamenting the wiiboard as duck/cover pedal like in the time crisis series. I will experement with it somemore tomorrow morning and give any nesecery feadback.

(p.S.)

thank you Lilith

Login to post a reply

Server time is: 2024-09-30 13:12:12
Your offset time is: 2024-09-30 13:12:12