JUCE  v5.4.1-191-g0ab5e696f
JUCE API
Looking for a senior C++ dev?
I'm looking for work. Hire me!
CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker Class Reference
Inheritance diagram for CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker:
Collaboration diagram for CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker:

Public Member Functions

 StillPictureTaker (GlobalRef &captureSessionToUse, GlobalRef &captureRequestBuilderToUse, GlobalRef &previewCaptureRequestToUse, GlobalRef &handlerToUse, int autoFocusModeToUse)
 
void takePicture (const LocalRef< jobject > &stillPictureCaptureRequestToUse)
 

Private Types

enum  State {
  State::idle = 0,
  State::pendingFocusLock,
  State::pendingExposurePrecapture,
  State::pendingExposurePostPrecapture,
  State::pictureTaken
}
 

Private Member Functions

void cameraCaptureSessionCaptureCompleted (bool isPreview, jobject session, jobject request, jobject result)
 
void cameraCaptureSessionCaptureFailed (bool isPreview, jobject session, jobject request, jobject failure)
 
void cameraCaptureSessionCaptureProgressed (bool isPreview, jobject session, jobject request, jobject partialResult)
 
void cameraCaptureSessionCaptureSequenceAborted (bool isPreview, jobject session, int sequenceId)
 
void cameraCaptureSessionCaptureSequenceCompleted (bool isPreview, jobject session, int sequenceId, int64 frameNumber)
 
void cameraCaptureSessionCaptureStarted (bool isPreview, jobject session, jobject request, int64 timestamp, int64 frameNumber)
 
void captureStillPicture ()
 
void captureStillPictureDelayed ()
 
LocalRef< jobject > createCaptureSessionCallback (bool createPreviewSession)
 
void lockFocus ()
 
void run () override
 
void runPrecaptureSequence ()
 
void unlockFocus ()
 
void updateState (jobject captureResult)
 

Static Private Member Functions

static bool autoFocusHasFinished (const LocalRef< jobject > &controlAfStateValue)
 
static void cameraCaptureSessionCaptureCompletedCallback (JNIEnv *, jobject, jlong host, jboolean isPreview, jobject rawSession, jobject rawRequest, jobject rawResult)
 
static void cameraCaptureSessionCaptureFailedCallback (JNIEnv *, jobject, jlong host, jboolean isPreview, jobject rawSession, jobject rawRequest, jobject rawResult)
 
static void cameraCaptureSessionCaptureProgressedCallback (JNIEnv *, jobject, jlong host, jboolean isPreview, jobject rawSession, jobject rawRequest, jobject rawResult)
 
static void cameraCaptureSessionCaptureSequenceAbortedCallback (JNIEnv *, jobject, jlong host, jboolean isPreview, jobject rawSession, jint sequenceId)
 
static void cameraCaptureSessionCaptureSequenceCompletedCallback (JNIEnv *, jobject, jlong host, jboolean isPreview, jobject rawSession, jint sequenceId, jlong frameNumber)
 
static void cameraCaptureSessionCaptureStartedCallback (JNIEnv *, jobject, jlong host, jboolean isPreview, jobject rawSession, jobject rawRequest, jlong timestamp, jlong frameNumber)
 
static LocalRef< jobject > getCaptureResultIntegerKeyValue (jfieldID key, jobject captureResult)
 
static int getControlAEState (jobject captureResult)
 

Private Attributes

int autoFocusMode
 
GlobalRef & captureRequestBuilder
 
GlobalRef & captureSession
 
GlobalRef captureSessionPreviewCaptureCallback
 
GlobalRef captureSessionStillPictureCaptureCallback
 
State currentState = State::idle
 
GlobalRef delayedCaptureRunnable
 
GlobalRef & handler
 
GlobalRef & previewCaptureRequest
 
AndroidRunnable runnable
 
GlobalRef stillPictureCaptureRequest
 

Member Enumeration Documentation

◆ State

Enumerator
idle 
pendingFocusLock 
pendingExposurePrecapture 
pendingExposurePostPrecapture 
pictureTaken 

Constructor & Destructor Documentation

◆ StillPictureTaker()

CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::StillPictureTaker ( GlobalRef &  captureSessionToUse,
GlobalRef &  captureRequestBuilderToUse,
GlobalRef &  previewCaptureRequestToUse,
GlobalRef &  handlerToUse,
int  autoFocusModeToUse 
)
inline

Member Function Documentation

◆ autoFocusHasFinished()

static bool CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::autoFocusHasFinished ( const LocalRef< jobject > &  controlAfStateValue)
inlinestaticprivate

References juce::getEnv().

◆ cameraCaptureSessionCaptureCompleted()

void CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::cameraCaptureSessionCaptureCompleted ( bool  isPreview,
jobject  session,
jobject  request,
jobject  result 
)
inlineprivate

◆ cameraCaptureSessionCaptureCompletedCallback()

static void CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::cameraCaptureSessionCaptureCompletedCallback ( JNIEnv *  ,
jobject  ,
jlong  host,
jboolean  isPreview,
jobject  rawSession,
jobject  rawRequest,
jobject  rawResult 
)
inlinestaticprivate

References juce::getEnv().

◆ cameraCaptureSessionCaptureFailed()

void CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::cameraCaptureSessionCaptureFailed ( bool  isPreview,
jobject  session,
jobject  request,
jobject  failure 
)
inlineprivate

◆ cameraCaptureSessionCaptureFailedCallback()

static void CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::cameraCaptureSessionCaptureFailedCallback ( JNIEnv *  ,
jobject  ,
jlong  host,
jboolean  isPreview,
jobject  rawSession,
jobject  rawRequest,
jobject  rawResult 
)
inlinestaticprivate

References juce::getEnv().

◆ cameraCaptureSessionCaptureProgressed()

void CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::cameraCaptureSessionCaptureProgressed ( bool  isPreview,
jobject  session,
jobject  request,
jobject  partialResult 
)
inlineprivate

◆ cameraCaptureSessionCaptureProgressedCallback()

static void CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::cameraCaptureSessionCaptureProgressedCallback ( JNIEnv *  ,
jobject  ,
jlong  host,
jboolean  isPreview,
jobject  rawSession,
jobject  rawRequest,
jobject  rawResult 
)
inlinestaticprivate

References juce::getEnv().

◆ cameraCaptureSessionCaptureSequenceAborted()

void CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::cameraCaptureSessionCaptureSequenceAborted ( bool  isPreview,
jobject  session,
int  sequenceId 
)
inlineprivate

◆ cameraCaptureSessionCaptureSequenceAbortedCallback()

static void CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::cameraCaptureSessionCaptureSequenceAbortedCallback ( JNIEnv *  ,
jobject  ,
jlong  host,
jboolean  isPreview,
jobject  rawSession,
jint  sequenceId 
)
inlinestaticprivate

References juce::getEnv().

◆ cameraCaptureSessionCaptureSequenceCompleted()

void CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::cameraCaptureSessionCaptureSequenceCompleted ( bool  isPreview,
jobject  session,
int  sequenceId,
int64  frameNumber 
)
inlineprivate

◆ cameraCaptureSessionCaptureSequenceCompletedCallback()

static void CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::cameraCaptureSessionCaptureSequenceCompletedCallback ( JNIEnv *  ,
jobject  ,
jlong  host,
jboolean  isPreview,
jobject  rawSession,
jint  sequenceId,
jlong  frameNumber 
)
inlinestaticprivate

References juce::getEnv().

◆ cameraCaptureSessionCaptureStarted()

void CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::cameraCaptureSessionCaptureStarted ( bool  isPreview,
jobject  session,
jobject  request,
int64  timestamp,
int64  frameNumber 
)
inlineprivate

◆ cameraCaptureSessionCaptureStartedCallback()

static void CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::cameraCaptureSessionCaptureStartedCallback ( JNIEnv *  ,
jobject  ,
jlong  host,
jboolean  isPreview,
jobject  rawSession,
jobject  rawRequest,
jlong  timestamp,
jlong  frameNumber 
)
inlinestaticprivate

References juce::getEnv().

◆ captureStillPicture()

void CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::captureStillPicture ( )
inlineprivate

References juce::getEnv().

◆ captureStillPictureDelayed()

void CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::captureStillPictureDelayed ( )
inlineprivate

◆ createCaptureSessionCallback()

LocalRef<jobject> CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::createCaptureSessionCallback ( bool  createPreviewSession)
inlineprivate

References juce::getEnv().

◆ getCaptureResultIntegerKeyValue()

static LocalRef<jobject> CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::getCaptureResultIntegerKeyValue ( jfieldID  key,
jobject  captureResult 
)
inlinestaticprivate

References juce::getEnv().

◆ getControlAEState()

static int CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::getControlAEState ( jobject  captureResult)
inlinestaticprivate

References juce::getEnv().

◆ lockFocus()

void CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::lockFocus ( )
inlineprivate

◆ run()

void CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::run ( )
inlineoverrideprivatevirtual

◆ runPrecaptureSequence()

void CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::runPrecaptureSequence ( )
inlineprivate

◆ takePicture()

void CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::takePicture ( const LocalRef< jobject > &  stillPictureCaptureRequestToUse)
inline

References JUCE_CAMERA_LOG.

◆ unlockFocus()

void CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::unlockFocus ( )
inlineprivate

◆ updateState()

void CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::updateState ( jobject  captureResult)
inlineprivate

Member Data Documentation

◆ autoFocusMode

int CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::autoFocusMode
private

◆ captureRequestBuilder

GlobalRef& CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::captureRequestBuilder
private

◆ captureSession

GlobalRef& CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::captureSession
private

◆ captureSessionPreviewCaptureCallback

GlobalRef CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::captureSessionPreviewCaptureCallback
private

◆ captureSessionStillPictureCaptureCallback

GlobalRef CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::captureSessionStillPictureCaptureCallback
private

◆ currentState

State CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::currentState = State::idle
private

◆ delayedCaptureRunnable

GlobalRef CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::delayedCaptureRunnable
private

◆ handler

GlobalRef& CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::handler
private

◆ previewCaptureRequest

GlobalRef& CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::previewCaptureRequest
private

◆ runnable

AndroidRunnable CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::runnable
private

◆ stillPictureCaptureRequest

GlobalRef CameraDevice::Pimpl::ScopedCameraDevice::CaptureSession::StillPictureTaker::stillPictureCaptureRequest
private

The documentation for this class was generated from the following file: