Szerkesztés

Megosztás a következőn keresztül:


KSPROPERTY_CAMERACONTROL_EXTENDED_FLASHMODE (normal and sequence)

The flash property control sets flash mode operation for both normal and sequence photo mode of the camera.

Usage summary table

Get Set Target Property descriptor type Property value type
Yes Yes Filter KSPROPERTY KSCAMERA_EXTENDEDPROP_HEADER

The property value (operation data) contains a KSCAMERA_EXTENDEDPROP_HEADER structure and a KSCAMERA_EXTENDEDPROP_VALUE structure.

The total property data size is sizeof(KSCAMERA_EXTENDEDPROP_HEADER) + sizeof(KSCAMERA_EXTENDEDPROP_VALUE). The Size member of KSCAMERA_EXTENDEDPROP_HEADER is set to this total property data size.

The Capability member of KSCAMERA_EXTENDEDPROP_HEADER contains a bitwise OR combination of one or more of the following flash modes that are supported by the driver.

Flash mode Description
KSCAMERA_EXTENDEDPROP_FLASH_OFF Flash is off.
KSCAMERA_EXTENDEDPROP_FLASH_ON Flash is on at the default intensity level.
KSCAMERA_EXTENDEDPROP_FLASH_ON_ADJUSTABLEPOWER Flash is on at a specific power level.
KSCAMERA_EXTENDEDPROP_FLASH_AUTO Flash is automatic based on lighting conditions.
KSCAMERA_EXTENDEDPROP_FLASH_AUTO_ADJUSTABLEPOWER Flash is automatic based on lighting conditions at a specific power level.

The following feature flags can be combined with the previous flash settings except for KSCAMERA_EXTENDEDPROP_FLASH_OFF.

Flash feature Description
KSCAMERA_EXTENDEDPROP_FLASH_REDEYEREDUCTION Enable redeye reduction feature. This flag can be combined with any other setting.
KSCAMERA_EXTENDEDPROP_FLASH_SINGLEFLASH Set flash for only one trigger. This feature is ignored when the camera is not in photo sequence mode.
KSCAMERA_EXTENDEDPROP_FLASH_MULTIFLASHSUPPORTED Set flash to trigger on every sequence frame. This feature is ignored when the camera is not in photo sequence mode.

The Flags member of KSCAMERA_EXTENDEDPROP_HEADER contains the flash mode currently set for the camera.

The default flash mode for a camera is KSCAMERA_EXTENDEDPROP_FLASH_OFF. If the camera supports flash, KSCAMERA_EXTENDEDPROP_FLASH_OFF, KSCAMERA_EXTENDEDPROP_FLASH_ON, and KSCAMERA_EXTENDEDPROP_FLASH_AUTO are required modes. The KSCAMERA_EXTENDEDPROP_FLASH_AUTO_ADJUSTABLEPOWER and KSCAMERA_EXTENDEDPROP_FLASH_AUTO_ADJUSTABLEPOWER modes are optional.

If photo sequence mode is supported by the camera, the flash control property is required with support for KSCAMERA_EXTENDEDPROP_FLASH_SINGLEFLASH.

This property control is synchronous and not cancelable.

Remarks

Getting the property

When responding to a KSPROPERTY_TYPE_GET request, the driver sets the members of the KSCAMERA_EXTENDEDPROP_HEADER to the following.

Member Value
Version 1
PinId KSCAMERA_EXTENDEDPROP_FILTERSCOPE (0xFFFFFFFF)
Size sizeof(KSCAMERA_EXTENDEDPROP_HEADER) + sizeof(KSCAMERA_EXTENDEDPROP_VALUE)
Result 0
Capability Flash mode values supported
Flags (The current flash mode value setting) | (flash feature flags)

When the torch mode is KSCAMERA_EXTENDEDPROP_FLASH_ON_ADJUSTABLEPOWER or KSCAMERA_EXTENDEDPROP_FLASH_ON_ADJUSTABLEPOWER, the Value.ull member of KSCAMERA_EXTENDEDPROP_VALUE contains an intensity level value between 0 - 100. An intensity of 0 indicates a minimum level and an intensity of 100 indicates a maximum intensity level. When the adjustable power flags are not set, the value for the normalized intensity setting is returned in Value.ull.

If no flash mode was previously set, then Flags is set to KSCAMERA_EXTENDEDPROP_FLASH_OFF (default).

Setting the property

When the property is set, a KSPROPERTY_TYPE_SET request, the Flags member of KSCAMERA_EXTENDEDPROP_HEADER will contain the torch mode to set. The Value.ull member of KSCAMERA_EXTENDEDPROP_VALUE will contain the intensity level to set if Flags is KSCAMERA_EXTENDEDPROP_FLASH_ON_ADJUSTABLEPOWER or KSCAMERA_EXTENDEDPROP_FLASH_AUTO_ADJUSTABLEPOWER.

Requirements

Version: Available starting with Windows 8.1

Header: Ksmedia.h (include Ksmedia.h)

See also

KSCAMERA_EXTENDEDPROP_HEADER

KSCAMERA_EXTENDEDPROP_VALUE