IKsControl::KsProperty method (ksproxy.h)

The KsProperty method sets a property or retrieves property information, along with any other defined support operations available on a property set.

Syntax

HRESULT KsProperty(
  [in]      PKSPROPERTY Property,
  [in]      ULONG       PropertyLength,
  [in, out] LPVOID      PropertyData,
  [in]      ULONG       DataLength,
  [in, out] ULONG       *BytesReturned
);

Parameters

[in] Property

Pointer to a structure that describes a property and the request type of the property request. This structure must be either a KSPROPERTY or a structure that contains a KSPROPERTY structure as its first member. An example of a structure that can be pointed to by this member is the KSPROPERTY_VIDEOPROCAMP_S structure.

[in] PropertyLength

Size, in bytes, of the buffer at Property.

[in, out] PropertyData

Pointer to a buffer that contains data for a KSPROPERTY_TYPE_SET, KSPROPERTY_TYPE_UNSERIALIZESET, or KSPROPERTY_TYPE_UNSERIALIZERAW operation, or buffer space that receives data for all other operations.

[in] DataLength

Size, in bytes, of the buffer at PropertyData.

[in, out] BytesReturned

Pointer to a variable that receives the size, in bytes, of the data that KsProperty stores in the buffer at PropertyData. If no data is stored, the size is zero.

Return value

Returns NOERROR if successful; otherwise, returns an error code.

Remarks

To determine the buffer size that is required for a specific property request, you can call this method with PropertyData set to NULL and DataLength equal to zero. The method returns HRESULT_FROM_WIN32(ERROR_MORE_DATA), and BytesReturned contains the size of the required buffer.

Requirements

Requirement Value
Target Platform DesktopMobile
Header ksproxy.h (include Ksproxy.h)

See also

KSPROPERTY

KSPROPERTY_VIDEOPROCAMP_S