The PWImageRenderer
class is an implementation of PWViewRenderer that loads and renders images in JPEG and PNG formats.
Constructors | |
(id) | - initWithView: |
Public Functions | |
(void) | - activate |
(void) | - clear |
(void) | - deactivate |
(CGPoint) | - localToNormalized: |
(CGPoint) | - localToSource: |
(CGPoint) | - normalizedToLocal: |
(PWXmlElement *) | - profilerInfo |
(void) | - renderBytes:bytes:encodingParameters: |
(CGPoint) | - sourceToLocal: |
Public Static Functions | |
(PWImageRenderer *) | + rendererWithView: |
Properties | |
PWEventPublisher * | activated |
PWEventPublisher * | deactivated |
PWEventTimerProfiler * | decodingTimer |
PWMatrix * | localToNormalizedTransform |
PWMatrix * | localToSourceTransform |
PWMatrix * | normalizedToLocalTransform |
PWEventTimerProfiler * | renderingTimer |
PWRectangle * | sourceSize |
PWEventPublisher * | sourceSizeChanged |
PWMatrix * | sourceToLocalTransform |
CALayer * | target |
PWEventPublisher * | transformsChanged |
PWRectangle * | viewSize |
PWEventPublisher * | viewSizeChanged |
PWEventPublisher * | viewUpdated |
- (void) activate |
Called when a ViewRenderer
is being used by a view. The intention is that ViewRenderer
implementation will add subComponents to its target for display when activated. It is best to use the ViewRendererEvent.ACTIVATED
event in ViewRenderer
implementations rather than overriding this method. If you override this method, you MUST call the base method first.
- (void) clear |
Clears the view image data. It is HIGHLY recommended that your implementation override this method in order to properly clear the display.
- (void) deactivate |
Called when a ViewRenderer
will stop being used by the view. The intention is that ViewRenderer
implementation will remove subComponents from the target. It is best to use the ViewRendererEvent.DEACTIVATED
event in ViewRenderer
implementations rather than overring this method. If you override this method, you MUST call the base method last.
- (id) initWithView: | (CALayer *) | target |
Creates a new ViewRenderer
and attaches it to the specified target view.
- (CGPoint) localToNormalized: | (CGPoint) | local |
Converts a point from local coordinates to normalized coordinates.
- (CGPoint) localToSource: | (CGPoint) | local |
Converts a point from local coordinates to coordinates of the back buffer image (source coordinates).
- (CGPoint) normalizedToLocal: | (CGPoint) | normalized |
Converts a point from normalized coordinates to local coordinates.
- (PWXmlElement *) profilerInfo |
This profiler information will be attached to the view profiler information when the view is attached.
Reimplemented from <PWProfilerDelegate>.
- (void) renderBytes: | (NSString *) | mimeType | |
bytes: | (NSData *) | bytes | |
encodingParameters: | (NSDictionary *) | encodingParameters | |
Called when bytes are received and should be renderered. It is HIGHLY recommended to override this method in your implementation to render display data.
mimeType | The mime type defined when this ViewRenderer was registered. |
bytes | The data to be renderered. |
encodingParameters | A dictionary of parameters set by the service for this encoded data. |
+ (PWImageRenderer *) rendererWithView: | (CALayer *) | view |
Renders the specified view, other than the default view.
- (CGPoint) sourceToLocal: | (CGPoint) | source |
Converts a point from image (source) coordinates to local coordinates.
|
readwritenonatomicstronginherited |
The event that will get dispatched when this renderer is added to a view.
|
readwritenonatomicstronginherited |
The event that will get dispatched when this renderer is removed from a view.
|
readwritenonatomicstrong |
A profiler that measures how long it takes to decode an image.
|
readnonatomicstronginherited |
The matrix used for localToNormalized
transforms. (Useful for render operations.)
|
readnonatomicstronginherited |
The matrix used for localToSource
transforms. (Useful for render operations.)
|
readnonatomicstronginherited |
The matrix used for normalizedToLocal
transforms. (Useful for render operations.)
|
readwritenonatomicstrong |
A profiler that measures how long it takes to render an image.
|
readwritenonatomicstronginherited |
The size of the corresponding view on the service. This is related to the ClientSize property
on the service view.
|
readwritenonatomicstronginherited |
The event that will get dispatched when imageSize
is set.
|
readnonatomicstronginherited |
The matrix used for sourceToLocal
transforms. (Useful for render operations.)
|
readnonatomicstronginherited |
The PWView that is the target of the rendering.
|
readwritenonatomicstronginherited |
The event that will get dispatched when viewToSource
or viewToNormalized
transforms change.
|
readnonatomicstronginherited |
The size of the target area for this view. Your implementation should render to this size.
|
readwritenonatomicstronginherited |
The event that will get dispatched when the target view of this renderer resizes.
|
readwritenonatomicstronginherited |
The event that will get dispatched when the view display is updated to inform the view.
© 2010 - 2018 Calgary Scientific Inc. All rights reserved. This documentation shall not wholly or in part, in any form or by any means, electronic, mechanical, including photocopying, be reproduced or transmitted without the authorized, written consent of Calgary Scientific.
Generated on Tue Jan 16 2018 10:44:16 for PureWeb Objective-C API by
1.8.6