IMcRegionAccessFastAccess Property
|
|
A flag that specifies the client is willing and capable
of direct access to the image pixel.
Namespace:
MediaCy.IQL.Engine
Assembly:
MediaCy.IQL.Engine (in MediaCy.IQL.Engine.dll) Version: 10.0.6912.0
SyntaxProperty FastAccess As Boolean
Get
Set
Property Value
Type:
Boolean
RemarksWith FastAccess turned on (Ttrue), the pixel access functions GetLine
and GetArea may return SAFEARRAYs that actually point to the image buffer. If
FastAccess is False (its default state), the buffers returned by these functions
contain copies of image data.
FastAccess will honor a True assignment only when the client and the
McRegionAccess object reside in the same address space (i.e., are running in the
same process). In the case of GetArea, another requirement is that the accessed
area be stored in one contiguous memory block.
If the image is not stored in one contiguous buffer, and if GetLine
succeeds in returning a pointer to image memory, this pointer is valid
only until the next call to GetLine (since that line may be swapped
out on the next call).
Whether or not GetLine and GetArea use FastAccess mode, they always
return the same type of SAFEARRAY. Therefore, clients need not
handle these SAFEARRAY differently. The exception to this rule is when
region masking is required. Since, with FastAccess on, GetLine and GetArea
may return pointers to the actual image data, clients should be careful
not to modify the value of pixels lying outside the mask.
PutLine and PutArea check the pixel buffers that are passed to them. If
these buffers represent actual image memory, they return immediately (any
modified value would already have affected the image).
Setting FastAccess to True does not force the RegionMask property
to Nothing. However, masking is not performed on PutLine or PutArea if
the source came from GetLine or GetArea in FastAccess mode.
Under some circumstances where GetArea or GetLine is called indirectly from an
out-of-process client, it may be safe to set FastAccess True because it is known
that the Variant returned from GetArea/Line will only be used in the same
process as the call to those methods. In this situation, you may force
FastAccess to True by assigning to it the value mcpixbuf_cvbForceFastAccess.
See Also