Subscribe: quartz-dev Mailing List
http://rss.lists.apple.com/quartz-dev.rss
Preview: quartz-dev Mailing List

quartz-dev Mailing List



quartz-dev Mailing List



Published: 2016-05-31T23:35:03-08:00

 



Re: CIColorMap filter problem.
From: email@hidden
Reply to list
Hi George,

Thanks for the comments. I've submitted a report: rdar://26335273

Cheers,
Demitri

 



Re: CIColorMap filter problem.
From: George Toledo
Reply to list

On Tue, May 17, 2016 at 2:14 PM,  <email@hidden> wrote: > quoted text
    Perhaps, or a modified version, if you need the UV offsets. You should be able to add or subtract a vec2 to "coord" to offset on the x or y axis.     I don't know whether this really should be necessary or not. [...]



Re: CIColorMap filter problem.
From: email@hidden
Reply to list

Hi George,

On May 17, 2016, at 1:40 PM, George Toledo <email@hidden> wrote:

[...]

It took me a few reads of the code to get this - are you suggesting that this kernel could replace both CIPixellate and the affine transform? Is it worth the trouble to do so?

[...] [...]



Re: CIColorMap filter problem.
From: George Toledo
Reply to list

In old examples for QC and Core Image, a function like this was used to achieve enlargement of an image, to create a non interpolated enlargement:     kernel vec4 nearestNeighbor(sampler image, float xFactor, float yFactor)  {          vec2 coord = samplerCoord(image); [...]



CIColorMap filter problem.
From: email@hidden
Reply to list
Hi,

I am having a problem that I first encountered on 10.11.4 (and persists in 10.11.5). My application uses Core Image to process an image with a number of filters. I've been able to narrow down the problem so I'll skip the details of the application, but what I want to do is this: pixellate an image, apply a color map, and scale. I want *no* interpolation - increasing magnification should make the pixels flat and large. (I am using an CIAffineTransform+NSAffineTransform to do the scaling, not CILanczosScaleTransform.)
I've created a simple application to demonstrate this:

https://github.com/demitri/CoreImageDemo

The problem I am seeing is that the order of these operations affects the outcome. I am testing this on two configurations:

Mid-2011 iMac, 10.11.3
Mid-2013 MacBook Air, 10.11.5

CIPixellate
CIColorMap
CIAffineTransform

[...]

It seems to me that as long as the scaling happens after the pixellate filter (the constraint I applied above), the output should be the same. Am I missing something or should I file a bug report?

If you're curious and try the application, the button to click is the misleading "two filters", and the method called is "twoFiltersAction". (And yes, the app is inefficient; it's just a sandbox.)

Cheers,
Demitri