Problem with Soccer Simulation.... :s

Hello everybody

I have a little problem with the soccer simulation, the problem is when i try to get the frame of the simulated webcam, the frame isn't correct, i mean, the size isn't correct. How do i solve this?

Code Snippet

delegate(webcam.QueryFrameResponse rsp)

{

_lastFrame = rsp.Frame;<-- HERE, rsp.Frame is an array of 230400 and it should be of 76,800

// tell our webcam to update its frame

_robotCam.Post(new webcam.UpdateFrame());

thanks for your help

-Iván-

[1093 byte] By [Jivfu] at [2008-2-24]
# 1

I haven't used the simulated webcam, but do you think it's returning RGB values? 230,400/76,800 = 3, so it could be returning R,G,B pixel values.

Stanlo at 2007-9-25 > top of Msdn Tech,Microsoft Robotics Studio,Microsoft Robotics - Simulation...
# 2

hi, the sim web cam and real web cam service act the same, but the default format of the sim web cam, is 24 bit RGB, but in the order of b,g ,r.

TO see exactly how we read the bytes, for the default format QueryFrame, look in the visionprocessing.cs file, in the Simple SoccerPlayer service, which is part of the sim soccer package

GeorgeChrysanthakopoulos at 2007-9-25 > top of Msdn Tech,Microsoft Robotics Studio,Microsoft Robotics - Simulation...

Microsoft Robotics Studio

Site Classified