MATLAB IMAGE ACQUISITION TOOLBOX - RELEASE NOTES Podręcznik Użytkownika Strona 110

  • Pobierz
  • Dodaj do moich podręczników
  • Drukuj
  • Strona
    / 172
  • Spis treści
  • BOOKMARKI
  • Oceniono. / 5. Na podstawie oceny klientów
Przeglądanie stron 109
5 Acquiring Image Data
5-32
done. Insert this code just before the acquisition thread function breaks out of the
frame acquisition loop — see “Implementing the Acquisition Thread Function” on
page 5-18.
You can use the IAutoCriticaSection::leave() function but this is not
necessary. The IAutoCriticalSection leaves the critical section automatically
when the code section goes out of scope. You might want to include explicit calls
to the leave() function in your code to help document the extent of your critical
section.
bool MyDeviceAdaptor::stopCapture(){
// If the device is not acquiring data, return.
if (!isAcquiring())
return true;
// Get the critical section and enter it.
std::auto_ptr<imaqkit::IAutoCriticalSection>
GrabSection(imaqkit::createAutoCriticalSection(_grabSection,
true));
//**********************************************************
// Insert calls to your device's SDK to stop the device, if
// necessary.
//**********************************************************
// Leave the critical section.
GrabSection->leave();
return true;
}
Przeglądanie stron 109
1 2 ... 105 106 107 108 109 110 111 112 113 114 115 ... 171 172

Komentarze do niniejszej Instrukcji

Brak uwag