Le 22 janv. 2010 à 19:41, David Duncan a écrit :
> This will set layer1 and layer2 to use the same contents, and have them use
> different parts of that bitmap.
>
> However your contentsRect is being set incorrectly. The contentsRect is a
> rectangle in a unit coordinate system, which means tha
On Jan 22, 2010, at 10:18 AM, vincent habchi wrote:
> Thanks for that answer. I would dare a further request for enlightenment ;)
> Does it mean that:
>
> 1. by defining a suitable ContentsRect, I can get a clipped area of a CALayer
> just by accessing layer.contents?
> 2. that I can copy this
David,
> Yes it is. The contents property is generally used to represent bitmapped
> content of a layer, which in the case of a plain CALayer means that anything
> drawn via -drawInContext: or -drawLayer:inContext: will be accessible via the
> contents property.
Thanks for that answer. I would
On Jan 21, 2010, at 11:53 PM, vincent habchi wrote:
> Does that mean that the content property is altered not only when you set it
> explicitly, but also when you draw on the layer via [DrawLayer: inContext:]?
Yes it is. The contents property is generally used to represent bitmapped
content of
Douglas,
> Have you checked the values of dx and dy in the debugger? Shouldn't those
> variables be declared as CGFloats as opposed to int?
That's correct, but it does not matter since the int is automatically converted
to float/double. Actually this part of code works like a charm. You click,
Vincent,
Have you checked the values of dx and dy in the debugger? Shouldn't those
variables be declared as CGFloats as opposed to int?
In regards to resizing the layer when the enclosing view resizes, what values
have you set for the layer's autorezingMask property?
regards,
douglas
On Jan
Hi Scott,
> this specific example of course assumes that you’re using the iphone. But,
> the technique should be sound for what you’re trying to do.
>
> The technique is applicable to use a pool of multiple views to contain
> smaller amounts of the content. the advantage is that you can render
this specific example of course assumes that you’re using the iphone. But, the
technique should be sound for what you’re trying to do.
The technique is applicable to use a pool of multiple views to contain smaller
amounts of the content. the advantage is that you can render or fetch the
content
look at the ScrollViewSuite example.. specifically the tiling one. techniques
illustrated.
On Jan 21, 2010, at 12:39 PM, vincent habchi wrote:
> Hi to all,
>
> I'm trying to write a (at that time) simple GIS-like application based on
> Cocoa. For each cartographic layer, I use a CALayer objec
Vincent,
Do you have some code that you can show us? Otherwise, diagnosing your problem
will be pure guesswork.
regards,
douglas
> However, I'm facing a challenge: when the user move the mouse, the drawing
> must move accordingly, feeling in white spaces that appear when updating the
> posi
Hi to all,
I'm trying to write a (at that time) simple GIS-like application based on
Cocoa. For each cartographic layer, I use a CALayer object, which is nice to
control things like opacity in real-time.
However, I'm facing a challenge: when the user move the mouse, the drawing must
move accor
11 matches
Mail list logo