CIFilter的中心向量 [英] Center vector of CIFilter

查看:105
本文介绍了CIFilter的中心向量的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我很难理解许多不同的CIFilter使用的中心向量的含义。

I'm having a hard time understanding the meaning of the center vector used by many different CIFilters.

让我们来看一下 CIRadialGradient ,例如, inputCenter 是什么意思?它的值范围是多少?

Let's take CIRadialGradient for example, what does the inputCenter mean? What's its values range? How does its coordinate system behave etc.

推荐答案

正如Brian所说,它只是一种编码效果居中位置的类型。但是,CoreImage坐标从您在iOS上惯用的Y轴上反转了:0,0点是左下角,并且y值随着您向屏幕顶部移动而增大。

As Brian said, it's just a type that encodes a position where the effect is centered. HOWEVER, CoreImage coordinates are inverted on the Y-axis from what you're used to using on iOS: The 0,0 point is the lower-left corner and the y value increases as you move toward the top of the screen.

这篇关于CIFilter的中心向量的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆