View Single Post
  #7   Spotlight this post!  
Unread 23-01-2012, 15:25
Bongle's Avatar
Bongle Bongle is offline
Registered User
FRC #2702 (REBotics)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2002
Location: Waterloo
Posts: 1,069
Bongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond repute
Send a message via MSN to Bongle
Re: Saving Image from Axis Camera to cRIO

We have been using ColorImage::Write.

Something along these lines
Code:
ColorImage img;
camera.getImage(&img);

if(savingInAComplicatedWay)
{
  static int cImages = 0;
  char szSavePoint[200];
  sprintf(szSavePoint, "image%d.jpg",cImages++);
  img.Write(szSavePoint);
}
else
{
  img.write("img.jpg");
}
It ends up as a JPG in the root of the cRio. Then we just use windows explorer and go to ftp://10.te.am.2 to access the saved images and copy them to our PC for more analysis.

My standard disclaimer of "This code is from memory and probably won't compile" applies.
Reply With Quote