2
votes

I'm using a Core Plot Scatter Plot to chart data. While I want the background to be white, I'd like to mask the plot symbols and data lines to an image sitting beneath the graph. This way, the only parts of the image visible would be the "fill" of the scatter plot lines and plot symbols.

How can I mask lines and symbols to an image while still keeping the background white?

Here's a Photoshop Mockup of what I'd like to do:

Photoshop Mockup

Thanks!

1
Cheers for adding in the pic Eric. Add an answer too? :P - jclay
Do you want a white fill in the graph, but have the image show through the symbols and plot line? Is the image a tiled texture or a photo that covers the whole graph? - Eric Skroch
@EricSkroch, yeah the graph should have a white background but make the graph lines and symbols the color of the image below the graph at that location in the photo. Here's an example of a photo I'm using: link. Notice how the graph lines and symbols simply take the color of the image below it. - jclay

1 Answers

0
votes

I'm not sure it's possible. The final result will depend on the image you're trying to use. The plot is drawn on top of the plot area and graph fills. You might be able to use image fills for the line and plot symbols. Experiment with the tiled and tileAnchoredToContext properties of CPTImage to see if you can position the fill images in a way that mimics the effect you're looking for.