View Single Post
  #2   Spotlight this post!  
Unread 09-12-2010, 03:16
Greg McKaskle Greg McKaskle is offline
Registered User
FRC #2468 (Team NI & Appreciate)
 
Join Date: Apr 2008
Rookie Year: 2008
Location: Austin, TX
Posts: 4,750
Greg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond repute
Re: Error: within this context

You've added a data member called camera, of type AxisCamera, no problem there. But the code you've included has a constructor with an initialization list, and you haven't added a value for camera field.

Not being that familiar with the C++ WPI code, the issue is likely that the AxisCamera doesn't have a default constructor or for some other reason, the compiler wants camera to be assigned using the initialization list.

Try putting

camera(???)

after the controller(1) line and before the {. Replace ??? with the parameters required for an AxisCamera object to be initialized.

Gotta love compiler error messages sometimes.

Greg McKaskle
Reply With Quote