forked from octocat/Spoon-Knife
-
Notifications
You must be signed in to change notification settings - Fork 0
/
GradientIssue.rtf
63 lines (57 loc) · 3.24 KB
/
GradientIssue.rtf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
{\rtf1\ansi\ansicpg1252\cocoartf1347\cocoasubrtf570
{\fonttbl\f0\fnil\fcharset0 Menlo-Regular;\f1\froman\fcharset0 Times-Roman;\f2\fswiss\fcharset0 ArialMT;
}
{\colortbl;\red255\green255\blue255;\red170\green13\blue145;\red63\green110\blue116;\red0\green0\blue0;
\red92\green38\blue153;\red46\green13\blue110;\red28\green0\blue207;\red0\green116\blue0;\red38\green71\blue75;
\red26\green26\blue26;\red255\green255\blue255;}
\paperw11900\paperh16840\margl1440\margr1440\vieww18000\viewh13000\viewkind0
\deftab264
\pard\tx264\pardeftab264\pardirnatural
\f0\fs22 \cf2 \CocoaLigature0 let\cf0 filterGroup = \cf3 GPUImageFilterGroup\cf0 ()\
\f1\fs24 \cf4 \expnd0\expndtw0\kerning0
\CocoaLigature1 \outl0\strokewidth0 \strokec4 \
\f0\fs22 \cf0 \kerning1\expnd0\expndtw0 \CocoaLigature0 \outl0\strokewidth0 \cf2 let\cf0 curveFilter = \cf3 GPUImageToneCurveFilter\cf0 ()\
curveFilter.\cf3 rgbCompositeControlPoints\cf0 = ([\cf5 NSValue\cf0 (CGPoint:\cf6 CGPointMake\cf0 (\cf7 75\cf0 /\cf7 255\cf0 , \cf7 0.0\cf0 )), \cf5 NSValue\cf0 (CGPoint:\cf6 CGPointMake\cf0 (\cf7 137\cf0 /\cf7 255\cf0 , \cf7 64\cf0 /\cf7 255\cf0 )), \cf5 NSValue\cf0 (CGPoint:\cf6 CGPointMake\cf0 (\cf7 219\cf0 /\cf7 255\cf0 , \cf7 227\cf0 /\cf7 255\cf0 )), \cf5 NSValue\cf0 (CGPoint:\cf6 CGPointMake\cf0 (\cf7 232\cf0 /\cf7 255\cf0 , \cf7 1.0\cf0 ))])\cf8 \
\cf0 curveFilter.\cf9 useNextFrameForImageCapture\cf0 ()\
filterGroup.\cf9 addFilter\cf0 (curveFilter)
\f1\fs24 \cf4 \expnd0\expndtw0\kerning0
\CocoaLigature1 \outl0\strokewidth0 \strokec4 \
\pard\pardeftab720
\cf4 \expnd0\expndtw0\kerning0
\outl0\strokewidth0 \
\pard\tx264\pardeftab264\pardirnatural
\f0\fs22 \cf0 \kerning1\expnd0\expndtw0 \CocoaLigature0 \outl0\strokewidth0 \cf2 let\cf0 falseColorFilter = GPUImageFalseColorFilter()\
falseColorFilter.firstColor = GPUVector4(one: \cf7 0.0\cf0 , two: \cf7 0.0\cf0 , three: \cf7 0.0\cf0 , four: \cf7 1.0\cf0 )\
falseColorFilter.secondColor = GPUVector4(one: \cf7 1.0\cf0 , two: \cf7 1.0\cf0 , three: \cf7 1.0\cf0 , four: \cf7 1.0\cf0 )\
sourcePicture?.addTarget(falseColorFilter)\
\
\cf2 let\cf0 blendFilter = GPUImageMultiplyBlendFilter()\
sourcePicture?.addTarget(blendFilter)\
falseColorFilter.addTarget(blendFilter)\
blendFilter.addTarget(imageView)\
falseColorFilter.useNextFrameForImageCapture()\
filterGroup.addFilter(blendFilter)\
lookupFilter.addTarget(blendFilter)\
\pard\pardeftab720\sa200
\f2 \cf10 \cb11 \expnd0\expndtw0\kerning0
\CocoaLigature1 \outl0\strokewidth0 \strokec10 \
\pard\pardeftab720\sa200
\cf10 \cb1 \expnd0\expndtw0\kerning0
\outl0\strokewidth0 \uc0\u8232 \cb11 \expnd0\expndtw0\kerning0
\outl0\strokewidth0 \
\pard\tx264\pardeftab264\pardirnatural
\f0 \cf0 \cb1 \kerning1\expnd0\expndtw0 \CocoaLigature0 \outl0\strokewidth0 filterGroup.\cf3 initialFilters\cf0 = [curveFilter]\
filterGroup.\cf3 terminalFilter\cf0 = blendFilter\
\
filterGroup.\cf9 forceProcessingAtSize\cf0 (\cf3 imageView\cf0 .\cf3 sizeInPixels\cf0 )\
filterGroup.\cf9 useNextFrameForImageCapture\cf0 ()\
\cf3 sourcePicture\cf0 ?.\cf9 addTarget\cf0 (filterGroup)\
filterGroup.\cf9 addTarget\cf0 (\cf3 imageView\cf0 )\
\cf3 sourcePicture\cf0 ?.\cf9 processImage\cf0 ()\
\
\
\
\
\
\
}