Create the package.

master
LH 6 years ago
parent cc4f60b01a
commit df32609c70
  1. 8
      Asset.meta
  2. 8
      Asset/Texture.meta
  3. 7
      README.md.meta
  4. 8
      Resources.meta
  5. 9
      Resources/flockaroo_ColoredPencils.meta
  6. 403
      Resources/flockaroo_ColoredPencils/coloredpencil.cginc
  7. 9
      Resources/flockaroo_ColoredPencils/coloredpencil.cginc.meta
  8. 72
      Resources/flockaroo_ColoredPencils/glsl2Cg.cginc
  9. 9
      Resources/flockaroo_ColoredPencils/glsl2Cg.cginc.meta
  10. 100
      Resources/flockaroo_ColoredPencils/imageEffShader.shader
  11. 9
      Resources/flockaroo_ColoredPencils/imageEffShader.shader.meta
  12. 101
      Resources/flockaroo_ColoredPencils/imageEffShader1.shader
  13. 9
      Resources/flockaroo_ColoredPencils/imageEffShader1.shader.meta
  14. 5
      Resources/flockaroo_ColoredPencils/shaderoo.cginc
  15. 9
      Resources/flockaroo_ColoredPencils/shaderoo.cginc.meta
  16. 8
      Resources/flockaroo_OilPainting.meta
  17. 87
      Resources/flockaroo_OilPainting/Buff_A.cginc
  18. 9
      Resources/flockaroo_OilPainting/Buff_A.cginc.meta
  19. 119
      Resources/flockaroo_OilPainting/Buff_A.shader
  20. 9
      Resources/flockaroo_OilPainting/Buff_A.shader.meta
  21. 346
      Resources/flockaroo_OilPainting/Geom_A.cginc
  22. 9
      Resources/flockaroo_OilPainting/Geom_A.cginc.meta
  23. 314
      Resources/flockaroo_OilPainting/Geom_A.cginc.new
  24. 8
      Resources/flockaroo_OilPainting/Geom_A.cginc.new.meta
  25. 314
      Resources/flockaroo_OilPainting/Geom_A.cginc.orig
  26. 8
      Resources/flockaroo_OilPainting/Geom_A.cginc.orig.meta
  27. 124
      Resources/flockaroo_OilPainting/Geom_A.shader
  28. 9
      Resources/flockaroo_OilPainting/Geom_A.shader.meta
  29. 45
      Resources/flockaroo_OilPainting/Image.cginc
  30. 9
      Resources/flockaroo_OilPainting/Image.cginc.meta
  31. 119
      Resources/flockaroo_OilPainting/Image.shader
  32. 9
      Resources/flockaroo_OilPainting/Image.shader.meta
  33. 164
      Resources/flockaroo_OilPainting/glsl2Cg.cginc
  34. 9
      Resources/flockaroo_OilPainting/glsl2Cg.cginc.meta
  35. 22
      Resources/flockaroo_OilPainting/shaderoo.cginc
  36. 9
      Resources/flockaroo_OilPainting/shaderoo.cginc.meta
  37. 8
      Runtime.meta
  38. 8
      Runtime/ColoredPencils.meta
  39. 305
      Runtime/ColoredPencils/ColoredPencilsEffect.cs
  40. 12
      Runtime/ColoredPencils/ColoredPencilsEffect.cs.meta
  41. BIN
      Runtime/ColoredPencils/Readme.pdf
  42. 8
      Runtime/ColoredPencils/Readme.pdf.meta
  43. 70
      Runtime/ColoredPencils/Readme.txt
  44. 8
      Runtime/ColoredPencils/Readme.txt.meta
  45. BIN
      Runtime/ColoredPencils/howto.png
  46. 55
      Runtime/ColoredPencils/howto.png.meta
  47. 8
      Runtime/OilPainting.meta
  48. 421
      Runtime/OilPainting/OilPaintingEffect.cs
  49. 11
      Runtime/OilPainting/OilPaintingEffect.cs.meta
  50. 97
      Runtime/OilPainting/Readme.md
  51. 7
      Runtime/OilPainting/Readme.md.meta
  52. BIN
      Runtime/OilPainting/Readme.pdf
  53. 7
      Runtime/OilPainting/Readme.pdf.meta
  54. BIN
      Runtime/OilPainting/howto.png
  55. 88
      Runtime/OilPainting/howto.png.meta
  56. 12
      Runtime/UltraCombos.Flockaroo.asmdef
  57. 7
      Runtime/UltraCombos.Flockaroo.asmdef.meta
  58. 8
      Tests.meta
  59. 8
      Tests/ColoredPencils.meta
  60. 9
      Tests/ColoredPencils/DemoScene.meta
  61. 607
      Tests/ColoredPencils/DemoScene/DemoScene.unity
  62. 8
      Tests/ColoredPencils/DemoScene/DemoScene.unity.meta
  63. 146
      Tests/ColoredPencils/DemoScene/New Material 1.mat
  64. 8
      Tests/ColoredPencils/DemoScene/New Material 1.mat.meta
  65. 146
      Tests/ColoredPencils/DemoScene/New Material 2.mat
  66. 8
      Tests/ColoredPencils/DemoScene/New Material 2.mat.meta
  67. 146
      Tests/ColoredPencils/DemoScene/New Material 3.mat
  68. 8
      Tests/ColoredPencils/DemoScene/New Material 3.mat.meta
  69. 146
      Tests/ColoredPencils/DemoScene/New Material.mat
  70. 8
      Tests/ColoredPencils/DemoScene/New Material.mat.meta
  71. 16
      Tests/ColoredPencils/DemoScene/youSpinMeRiseRound_ColoredPencils.cs
  72. 12
      Tests/ColoredPencils/DemoScene/youSpinMeRiseRound_ColoredPencils.cs.meta
  73. 8
      Tests/OilPainting.meta
  74. 8
      Tests/OilPainting/DemoScene.meta
  75. 607
      Tests/OilPainting/DemoScene/DemoScene.unity
  76. 8
      Tests/OilPainting/DemoScene/DemoScene.unity.meta
  77. 146
      Tests/OilPainting/DemoScene/New Material 1.mat
  78. 8
      Tests/OilPainting/DemoScene/New Material 1.mat.meta
  79. 146
      Tests/OilPainting/DemoScene/New Material 2.mat
  80. 8
      Tests/OilPainting/DemoScene/New Material 2.mat.meta
  81. 146
      Tests/OilPainting/DemoScene/New Material 3.mat
  82. 8
      Tests/OilPainting/DemoScene/New Material 3.mat.meta
  83. 146
      Tests/OilPainting/DemoScene/New Material.mat
  84. 8
      Tests/OilPainting/DemoScene/New Material.mat.meta
  85. 16
      Tests/OilPainting/DemoScene/youSpinMeRiseRound_OilPainting.cs
  86. 11
      Tests/OilPainting/DemoScene/youSpinMeRiseRound_OilPainting.cs.meta
  87. 8
      package.json
  88. 7
      package.json.meta

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 7743f8c52008a9d4aa780f0edf39984e
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 88828489e3254af4a8041c7529154569
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 9a167bada92a0244ebe7b5e9f05311ba
TextScriptImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 495627c0ae63b5741ade9ce06b724256
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,9 @@
fileFormatVersion: 2
guid: 942be931e8ebda149a13d3d1523b4102
folderAsset: yes
timeCreated: 1529632860
licenseType: Store
DefaultImporter:
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,403 @@
// created by florian berger (flockaroo) - 2018
// color crosshatch effect
// uncomment this if you have performance problems
//#define NEW_METHOD
//#define FASTER
// try uncommenting this if the effect doesnt work (some platforms dont support many nested loops)
//#define LESS_LOOPS
//#define __UNITY_3D__
#define Res iResolution.xy
#define Res0 vec2(textureSize(iChannel0,0))
#define Res1 vec2(textureSize(iChannel1,0))
#define Res2 vec2(textureSize(iChannel2,0))
#define Res3 vec2(textureSize(iChannel3,0))
#define PI2 6.28318530718
#define sc (iResolution.x/600.)
#ifndef __UNITY_3D__
#define mul(a,b) (b*a)
#define vec2i vec2
#define vec3i vec3
#define vec4i vec4
#endif
#ifdef __UNITY3D__
sampler2D _PaperTex;
float4 _PaperTex_TexelSize;
#endif
vec2 roffs;
float ramp;
float rsc;
vec2 uvSmooth(vec2 uv,vec2 res)
{
return uv+.6*sin(uv*res*PI2)/PI2/res;
}
vec4 getRand(vec2 pos)
{
vec2 tres=vec2(textureSize(iChannel1,0));
//vec2 fr=fract(pos-.5);
//vec2 uv=(pos-.7*sin(fr*PI2)/PI2)/tres.xy;
vec2 uv=pos/tres.xy;
//uv=uvSmooth(uv,tres);
return textureLod(iChannel1,uv,0.);
}
#ifdef SHADEROO
uniform float flicker;
uniform float flickerFreq;
uniform float brightness;
uniform float contrast;
uniform float contentWhiteVign;
uniform float hatchLen;
#else
float flicker=0.;
#endif
//int flickerTime = 5;
//#define flickerParam (float(iFrame/5)/60.*flicker)
float flickerParam;
vec4 getCol2(vec2 pos)
{
vec2 res = vec2(textureSize(iChannel2,0));
vec2 uv=(pos-iResolution.xy*.5)*vec2(res.y,res.x)/mix(iResolution.x*res.y,iResolution.y*res.x,.5);
vec4 c = texture(iChannel2,uv+.5);
return c;
}
vec4 getCol(vec2 pos, float lod)
{
vec4 r1 = (getRand((pos+roffs)*.05*rsc/sc+131.*flickerParam+13.)-.5)*10.*ramp;
vec2 res0=vec2(textureSize(iChannel0,0));
vec2 uv=(pos+r1.xy*sc)/iResolution.xy;
//uv=uvSmooth(uv,res0);
vec4 c = textureLod(iChannel0,uv,lod);
c = clamp(((c-.5)*contrast+.5)*brightness,0.,100.);
vec4 bg= vec4i(vec3i(clamp(.3+pow(length(uv-.5),2.),0.,1.)),1);
bg=vec4i(1);
//c*=vec4(1.2,1,.8,1);
//c = mix(c,bg,clamp(dot(c.xyz,vec3(-1,1.8,-1)*1.5),0.,1.));
float vign=pow(clamp(-.5+length(uv-.5)*contentWhiteVign*3.,0.,1.),3.);
c = mix(c,bg,vign);
//c=(c*1.3-.5)*.7+.5;
return c;
}
vec4 getCol(vec2 pos)
{
return getCol(pos,0.);
}
vec3 quant(vec3 c, ivec3 num)
{
vec3 fnum=vec3(num);
return floor(c*(fnum-.0001))/(fnum-1.);
}
float quant(float c, int num)
{
float fnum=float(num);
return floor(c*(fnum-.0001))/(fnum-1.);
}
float squant(float c, int num, float w)
{
float fnum=float(num);
float s=sin(c*fnum*PI2);
c*=fnum;
c=mix(floor(c),ceil(c),smoothstep(-w*.5,w*.5,c-floor(c)-.5));
return c/fnum;
}
float getVal(vec2 pos)
{
return clamp(dot(getCol(pos).xyz,vec3i(.333)),0.,1.);
}
float getVal(vec2 pos,float lod)
{
return clamp(dot(getCol(pos,lod).xyz,vec3i(.333)),0.,1.);
}
float compAbsMax(vec3 v) { vec3 a=abs(v); return (a.x>a.y) ? (a.x>a.z)?v.x:v.z : (a.y>a.z)?v.y:v.z; }
vec2 getMaxGrad(vec2 pos, float eps, float lod)
{
vec2 d=vec2(eps,0);
vec3 c0=getCol(pos,lod).xyz;
return vec2(
compAbsMax(getCol(pos+d.xy,lod).xyz-c0),
compAbsMax(getCol(pos+d.yx,lod).xyz-c0)
)/eps;
}
vec2 getMaxGrad(vec2 pos, float eps)
{
return getMaxGrad(pos, eps, 0.);
}
vec2 getGrad(vec2 pos, float eps, float lod)
{
vec2 d=vec2(eps,0);
float v0=getVal(pos,lod);
return vec2(
getVal(pos+d.xy,lod)-v0,
getVal(pos+d.yx,lod)-v0
)/eps;
}
vec2 getGrad(vec2 pos, float eps)
{
return getGrad(pos, eps, 0.);
}
float compProd(vec2 v)
{
return v.x*v.y;
}
#ifdef SHADEROO
uniform float fixedHatchDir;
uniform float outlines;
uniform float hatches;
uniform float vignetting;
uniform float hatchScale;
uniform vec3 paperTint;
uniform float paperRough;
uniform float paperTexFade;
uniform float colorStrength;
uniform float effectFade;
uniform float panFade;
uniform float mipLevel;
uniform float outlineRand;
#else
float brightness=1.;
float fixedHatchDir=0.;
float outlines=1.;
float vignetting=1.;
float hatchScale=1.;
vec3 paperTint = vec3(1,.97,.85);
#endif
void mainImage( out vec4 fragColor, in vec2 fragCoord )
{
flickerParam = ((iTime-mod(iTime,1.0/max(flickerFreq,1.)))*flicker);
float issc=1./sqrt(sc);
vec4 r = getRand(fragCoord*1.2*issc)-getRand(fragCoord*1.2*issc+vec2(1,-1)*1.5);
vec4 r2 = getRand(fragCoord*1.2*issc);
// outlines
float br=0.;
roffs = vec2i(0.);
ramp = .7*outlineRand;
rsc = .7;
#ifdef FASTER
int num=1;
#else
int num=3;
#endif
for(int i=0;i<num;i++)
{
float fi=float(i+1)/float(num);
float t=.03+.25*fi, w=t*2.;
ramp=.2*pow(1.3,fi*5.)*outlineRand; rsc=2.7*pow(1.2,-fi*5.);
br+=.6*(.5+fi)*smoothstep(t-w/2.,t+w/2.,length(getMaxGrad(fragCoord,.4*sc))*sc);
ramp=.3*pow(1.3,fi*5.)*outlineRand; rsc=10.7*pow(1.3,-fi*5.);
br+=.4*(.2+fi)*smoothstep(t-w/2.,t+w/2.,length(getMaxGrad(fragCoord,.4*sc))*sc);
//roffs += vec2(13.,37.);
}
#ifdef __UNITY3D__
vec3 paperCol = paperTint*mix(vec3i(1),texture(_PaperTex,fragCoord/iResolution.xy).xyz,paperTexFade);
#else
vec3 paperCol = paperTint*vec3i(1);
#endif
float contour = outlines*.4*br*(.75+.5*(r2.z-.5)*paperRough)*3./float(num);
//vec3 paperCol = paperTint*((paperTexFade<0.5)?vec3i(1):texture(_PaperTex,fragCoord/iResolution.xy).xyz);
//vec3 paperCol = paperTint;
//if(paperTexFade>0.5) paperCol *= texture(_PaperTex,fragCoord/iResolution.xy).xyz;
fragColor.xyz=paperCol-contour;
fragColor.xyz=clamp(fragColor.xyz,0.,1.);
// cross hatch
ramp=0.;
#ifdef FASTER
int hnum=2;
#else
int hnum=3;
#endif
#define N(v) (v.yx*vec2(-1,1))
#define CS(ang) cos(ang-vec2(0,1.6))
#ifdef NEW_METHOD
vec3 hatch = vec3i(0);
for(float i=0.;i<float(hnum)-.1;i+=1.0)
{
float hsc=.8/hatchScale*(1.+.2*i); // thickness of hatches
float cellSize = hatchLen/pow(1.7,i)*(sc);
float level=log2(cellSize)-log2(Res.x)+log2(Res0.x);
vec4 col = getCol(fragCoord+5.*sc*(getRand(fragCoord*.02+1120.*flickerParam).xy-.5)*clamp(flicker,-1.,1.),
level-2.);
float gr=dot(col.xyz,vec3i(.333));
col.xyz=((col.xyz-gr)*colorStrength+gr)*brightness;
for(float j=0.;j<3.99;j+=1.0) // 4 neasrest cell edges to get overlapping hatches from cell to cell
{
vec2 cellOffs = vec2(mod(j,2.),floor(j*.5));
vec2 cellPos = floor(fragCoord/cellSize+cellOffs)*cellSize;
// mix factor depending on close-ness to cell center
float cellMix = compProd(1.-abs((fragCoord-cellPos)/cellSize));
// gradient of cell edge
vec2 g = N(getGrad(cellPos,1.,0.6+level));
// angle of hatch
float ang = mix(-atan(g.y,g.x),-.5,fixedHatchDir);
if((abs(g.x)+abs(g.y))<1.0e-10) ang=-.5;
ang -= .08*i*i;
// taking cos/sin dirctly out of the gradient seems a lot slower
// maybe due to nan in normalize when grad=0
//vec2 cs=normalize(g)*vec2(1,-1);
vec2 cs=CS(-ang);
// rotated uv coordnates for random tex (quenched in x)
//...now rotated around cellPos, and then random offs added, gives less jitter
vec2 uvh = (mul(mat2(cs,N(cs)),(fragCoord-cellPos))+cellPos+getRand(cellPos*1.3).xy*37.)*issc*vec2(.05,1)*hsc;
//vec2 uvh = ( (mat2(cs,N(cs))*(fragCoord-cellPos))+cellPos+getRand(cellPos*1.3).xy*37.)*issc*vec2(.05,1)*hsc;
// noise pattern for halftoning
vec4 rh = getRand(uvh+1003.123*flickerParam +2.*vec2(sin(uvh.y),0));
//add some sin to noise (make it slightly blue noise in one direction)
rh.x = mix(rh.x,sin(3.*uvh.y*hsc)*.5+.5,.25);
//if(i==0.) //...to debug levels of hatches
hatch += (smoothstep(hatches-.4,hatches+.4,rh.x+col.xyz))*cellMix;
}
}
hatch=(hatch/float(hnum))+abs(r.z)*.25*paperRough;
fragColor.xyz=hatch*(1.-1.5*contour);
fragColor.xyz=.15+.85*fragColor.xyz;
fragColor.xyz*=paperCol;
#else
float hatch2 = 0.;
float hatch = 0.;
float sum=0.;
float cflick = clamp(flicker,-1.,1.);
for(int k=0;k<3;k++)
{
// hatches should be initialized for every color
// ...but for some reason looks a lot better when not ?!
// hatch2 = 0.; hatch = 0.; sum=0.;
// comp: k=0 -> 1,0,0 k=1 -> 0,1,0 k=2 -> 0,0,1
vec3 comp = 1.-clamp(vec3(ivec3(k,k+2,k+1)%3),0.,1.);
comp /= comp.x+comp.y+comp.z;
comp = mix(vec3i(.33),comp,colorStrength);
#ifdef LESS_LOOPS
for(int i2=0;i2<hnum*4;i2++)
{
int i=i2/4;
int j=i2%4;
#else
for(int i=0;i<hnum;i++)
{
#endif
float cellSize = hatchLen/pow(1.7,float(i))*(sc);
float level=log(.3*cellSize)/log(2.)*mipLevel;
float hsc=.8/hatchScale*(1.+.2*float(i)); // thickness of hatches
#ifndef LESS_LOOPS
for(int j=0;j<4;j++) // 4 neasrest cell edges to get overlapping hatches from cell to cell
{
#endif
vec2 cellOffs = vec2(j%2,j/2);
vec2 cellPos = floor(fragCoord/cellSize+cellOffs)*cellSize;
// mix factor depending on close-ness to cell center
float cellMix = compProd(1.-abs((fragCoord-cellPos)/cellSize));
vec4 cellCol = getCol(cellPos+5.*sc*(getRand(cellPos*.02+1120.*flickerParam).xy-.5)*cflick,level);
vec4 col = getCol(fragCoord+5.*sc*(getRand(fragCoord*.02+1120.*flickerParam).xy-.5)*cflick,level);
float br=dot(col.xyz,comp);
//br=squant(br,8,.3);
// gradient of cell edge
vec2 g = N(getGrad(cellPos,1.,log(1.5*cellSize)/log(2.)*clamp(mipLevel,0.,1.)));
// angle of hatch
float ang = mix(-atan(g.y,g.x),-.5,fixedHatchDir);
if((abs(g.x)+abs(g.y))<1.0e-10) ang=-.5;
ang -= .08*float(i)*float(i);
// taking cos/sin dirctly out of the gradient seems a lot slower
// maybe due to nan in normalize when grad=0
//vec2 cs=normalize(g)*vec2(1,-1);
vec2 cs=CS(-ang);
// rotated uv coordnates for random tex (quenched in x)
//vec2 uvh = mul(mat2(cs,N(cs)),fragCoord)/sqrt(sc)*vec2(.05,1)*hsc;
// ...now rotated around cellPos, and then random offs added, gives less jitter
vec2 uvh = (mul(mat2(cs,N(cs)),(fragCoord-cellPos))+cellPos+getRand(cellPos*1.3).xy*37.)*issc*vec2(.05,1)*hsc;
float colOffs = ((cellCol.x/cellCol.y)+(cellCol.y/cellCol.z))*102.423;
colOffs=0.;
// noise pattern for halftoning
vec4 rh = getRand(uvh+float(k)*121.12312+colOffs+1003.123*flickerParam +1.*vec2(sin(uvh.y),0));
//add some sin to noise (make it slightly blue noise in one direction)
rh.x = mix(rh.x,sin(3.*uvh.y*hsc)*.5+.5,.25);
//if(i==2) //...to debug levels of hatches
{
hatch += (1.-smoothstep(hatches-.4,hatches+.4,(rh.x)+br)-paperRough*.3*abs(r.z))*cellMix;
sum+=cellMix;
}
//this one is slightly darker
#ifndef FASTER
if(j==0) hatch2 = max(hatch2, (1.-smoothstep(hatches-.4,hatches+.4,(rh.x)+br)-.3*abs(r.z)));
#endif
}
#ifndef LESS_LOOPS
}
#endif
// mix some darker an brighter hatches
#ifdef FASTER
fragColor.xyz*=1.-clamp(mix(vec3i(.5),comp,colorStrength),0.,1.)*hatch/sum;
#else
fragColor.xyz*=1.-clamp(mix(vec3i(.5),comp,colorStrength),0.,1.)*clamp(mix(hatch/sum,hatch2,.3),0.,1.);
#endif
}
#endif
// not completely black because pencil has a gray tone
//fragColor.xyz=1.-((1.-fragColor.xyz)*.95);
// paper tex
fragColor.xyz *= 1.+(-.05+.06*r.xxx+.06*r.xyz)*paperRough;
fragColor.w = 1.;
if (fragCoord.x<iMouse.x) fragColor.xyz=getCol2(fragCoord).xyz;
fragColor.xyz=mix(fragColor.xyz,getCol2(fragCoord).xyz,effectFade);
#define PANFADE_W 0.025
fragColor.xyz=mix(fragColor.xyz,getCol2(fragCoord).xyz,smoothstep((1.-panFade)-PANFADE_W,(1.-panFade)+PANFADE_W,((1.-fragCoord.x/iResolution.x)-.5)/(1.+2.*PANFADE_W)+.5));
//if (fragCoord.x/iResolution.x<.5) fragColor.xyz=getCol(fragCoord,4.).xyz;
// vignetting
if(true)
{
vec2 scc=(fragCoord-.5*iResolution.xy)/iResolution.x;
float vign = 1.-.3*dot(scc,scc);
vign*=1.-.7*vignetting*exp(-sin(fragCoord.x/iResolution.x*3.1416)*40.);
vign*=1.-.7*vignetting*exp(-sin(fragCoord.y/iResolution.y*3.1416)*20.);
fragColor.xyz *= vign;
}
//fragColor.xyz=getRand(fragCoord*.02).xyz;
//if (fragCoord.x<iResolution.x*.5) fragColor.xyz=getCol(fragCoord,3.).xyz;
//fragColor.xyz= vec3(0)+squant(getVal(fragCoord),5);
}

@ -0,0 +1,9 @@
fileFormatVersion: 2
guid: d5ef4b1a4862a754691737b188c8e321
timeCreated: 1529632977
licenseType: Store
ShaderImporter:
defaultTextures: []
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,72 @@
// glsl -> Cg
// many things can be covered here, but...
// not possible by typedef or #define are:
// (at least not with the limited preprocess abilities of Cg)
//
// array initializers
// glsl: type arr[n] = type[](a,b,c,...);
// Cg: type arr[n] = {a,b,c,...}
//
// vec initializers with 1 arg:
// glsl: vec4(x)
// Cg: vec4i(x) (see helpers below - or float4(x,x,x,x))
//
// matrix multiplications
// glsl: m*v
// Cg: mul(m,v)
//
// matrix initializers (column first in glsl)
// glsl: mat4(a,b,c,...)
// Cg: transpose(mat4(a,b,c,...))
//
// in mainGeom(...) vertAttrib[] not initialized
// so either inout as argument, or actually init them in mainGeom()
//
float4 vec4i(float x) { return float4(x,x,x,x); }
float4 vec4i(float x, float3 v) { return float4(x,v.x,v.y,v.z); }
float4 vec4i(float3 v, float x) { return float4(v.x,v.y,v.z,x); }
float4 vec4i(float2 v1, float2 v2) { return float4(v1.x,v1.y,v2.x,v2.y); }
float3 vec3i(float x) { return float3(x,x,x); }
float3 vec3i(float2 v, float x) { return float3(v.x,v.y,x); }
float3 vec3i(float x, float2 v) { return float3(x,v.x,v.y); }
float2 vec2i(float x) { return float2(x,x); }
typedef float2 vec2;
typedef float3 vec3;
typedef float4 vec4;
typedef int4 ivec4;
typedef int3 ivec3;
typedef int2 ivec2;
typedef float4x4 mat4;
typedef float3x3 mat3;
typedef float2x2 mat2;
#define atan(a,b) atan2(a,b)
#define texture(a,b) tex2D(a,b)
//#define texture(a,b,c) tex2Dbias(a,float4(b,0,c))
#define textureLod(a,b,c) tex2Dlod(a,float4(b,0,c))
//#define textureLod(a,b,c) tex2D(a,b)
//#define texelFetch(a,b,c) tex2Dfetch(a,int4(b,0,c))
#define texelFetch(a,b,c) tex2Dlod(a,float4((float2(b)+.5)/float2(textureSize(a,0)),0,c))
//#define GET_VARARG_MACRO(_1,_2,_3,_4,NAME,...) NAME
//#define vec4(...) GET_VARARG_MACRO(__VA_ARGS__, vec4i, vec4i, vec4i, vec4i, vec4)(__VA_ARGS__)
//#define vec4 float4
//#define vec3 float3
//#define vec2 float2
//#define ivec4 int4
//#define ivec3 int3
//#define ivec2 int2
//#define mat4 float4x4
//#define mat3 float3x3
//#define mat2 float2x2
#define mix(a,b,c) lerp(a,b,c)
#define fract(a) frac(a)
#define mod(a,b) fmod(a,b)
#define textureSize(a,b) a##_TexelSize.zw
//#define smoothstep(a,b,c) step(.5*(a+b),c)

@ -0,0 +1,9 @@
fileFormatVersion: 2
guid: 9011d1d15b095d640bf2eb3c1a649cb5
timeCreated: 1529632977
licenseType: Store
ShaderImporter:
defaultTextures: []
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,100 @@
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Hidden/ColoredPencilsShader"
{
Properties
{
_MainTex ("Texture", 2D) = "white" {}
_MainTexMip ("Texture", 2D) = "white" {}
_RandTex("Texture", 2D) = "white" {}
}
SubShader
{
// No culling or depth
Cull Off ZWrite Off ZTest Always
//Blend One One
Pass
{
CGPROGRAM
#pragma vertex vert
#pragma fragment frag
#include "UnityCG.cginc"
sampler2D _MainTex;
sampler2D _RandTex;
float4 _RandTex_TexelSize;
float4 _MainTex_TexelSize;
int _FrameCount;
float flipY;
#define iChannel0 _MainTex
#define iChannel1 _RandTex
#define iChannel2 _MainTex
#include "glsl2Cg.cginc"
#include "shaderoo.cginc"
#define SHADEROO
#define __UNITY_3D__
#include "coloredpencil.cginc"
struct appdata
{
float4 vertex : POSITION;
float2 uv : TEXCOORD0;
};
struct v2f
{
float2 uv : TEXCOORD0;
float4 vertex : SV_POSITION;
//float4 vertex : TEXCOORD4;
#ifdef SHADEROO_GEOM
float4 vertAttr0: TEXCOORD1;
float4 vertAttr1: TEXCOORD2;
float4 vertAttr2: TEXCOORD3;
#endif
};
v2f vert (appdata v)
{
v2f o;
#ifdef SHADEROO_GEOM
float4 vertAttr[3] = { float4(0,0,0,0), float4(0,0,0,0), float4(0,0,0,0) };
/*vertAttr[0]=float4(0,0,0,0);
vertAttr[1]=float4(0,0,0,0);
vertAttr[2]=float4(0,0,0,0);*/
int vIdx=int(v.vertex.x+.1);
mainGeom(o.vertex,vertAttr,vIdx);
o.vertAttr0=vertAttr[0];
o.vertAttr1=vertAttr[1];
o.vertAttr2=vertAttr[2];
#else
//o.vertex = UnityObjectToClipPos(float4(v.vertex.xyz, 1.0));
o.vertex = v.vertex;
o.vertex.xy=o.vertex.xy*2.-1.;
o.uv = v.uv;
#endif
return o;
}
fixed4 frag (v2f i) : SV_Target
{
float4 c;
#ifdef SHADEROO_GEOM
float4 vertAttr[3];
vertAttr[0]=i.vertAttr0;
vertAttr[1]=i.vertAttr1;
vertAttr[2]=i.vertAttr2;
mainFragment(c,i.vertex+vec4(.5,.5,0,0),vertAttr);
//mainFragment(c,vec4((i.vertex.xy*.5+.5)*iResolution.xy,i.vertex.zw),vertAttr);
#else
if(flipY>.5) i.uv.y=1.-i.uv.y;
mainImage(c,i.uv*iResolution.xy);
#endif
return c;
}
ENDCG
}
}
}

@ -0,0 +1,9 @@
fileFormatVersion: 2
guid: 14e857cc01ec926439bfe9c1164b92c9
timeCreated: 1529632977
licenseType: Store
ShaderImporter:
defaultTextures: []
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,101 @@
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Hidden/ColoredPencilsShader"
{
Properties
{
_MainTex ("Texture", 2D) = "white" {}
_MainTexMip ("Texture", 2D) = "white" {}
_RandTex("Texture", 2D) = "white" {}
}
SubShader
{
// No culling or depth
Cull Off ZWrite Off ZTest Always
//Blend One One
Pass
{
CGPROGRAM
#pragma vertex vert
#pragma fragment frag
#include "UnityCG.cginc"
sampler2D _MainTex;
sampler2D _RandTex;
float4 _RandTex_TexelSize;
float4 _MainTex_TexelSize;
int _FrameCount;
float flipY;
#define iChannel0 _MainTex
#define iChannel1 _RandTex
#define iChannel2 _MainTex
#include "glsl2Cg.cginc"
#include "shaderoo.cginc"
#define SHADEROO
#define __UNITY_3D__
#define NEW_METHOD
#include "coloredpencil.cginc"
struct appdata
{
float4 vertex : POSITION;
float2 uv : TEXCOORD0;
};
struct v2f
{
float2 uv : TEXCOORD0;
float4 vertex : SV_POSITION;
//float4 vertex : TEXCOORD4;
#ifdef SHADEROO_GEOM
float4 vertAttr0: TEXCOORD1;
float4 vertAttr1: TEXCOORD2;
float4 vertAttr2: TEXCOORD3;
#endif
};
v2f vert (appdata v)
{
v2f o;
#ifdef SHADEROO_GEOM
float4 vertAttr[3] = { float4(0,0,0,0), float4(0,0,0,0), float4(0,0,0,0) };
/*vertAttr[0]=float4(0,0,0,0);
vertAttr[1]=float4(0,0,0,0);
vertAttr[2]=float4(0,0,0,0);*/
int vIdx=int(v.vertex.x+.1);
mainGeom(o.vertex,vertAttr,vIdx);
o.vertAttr0=vertAttr[0];
o.vertAttr1=vertAttr[1];
o.vertAttr2=vertAttr[2];
#else
//o.vertex = UnityObjectToClipPos(float4(v.vertex.xyz, 1.0));
o.vertex = v.vertex;
o.vertex.xy=o.vertex.xy*2.-1.;
o.uv = v.uv;
#endif
return o;
}
fixed4 frag (v2f i) : SV_Target
{
float4 c;
#ifdef SHADEROO_GEOM
float4 vertAttr[3];
vertAttr[0]=i.vertAttr0;
vertAttr[1]=i.vertAttr1;
vertAttr[2]=i.vertAttr2;
mainFragment(c,i.vertex+vec4(.5,.5,0,0),vertAttr);
//mainFragment(c,vec4((i.vertex.xy*.5+.5)*iResolution.xy,i.vertex.zw),vertAttr);
#else
if(flipY>.5) i.uv.y=1.-i.uv.y;
mainImage(c,i.uv*iResolution.xy);
#endif
return c;
}
ENDCG
}
}
}

@ -0,0 +1,9 @@
fileFormatVersion: 2
guid: 083e1e9d1258029439d28e0ee0c26252
timeCreated: 1546809258
licenseType: Store
ShaderImporter:
defaultTextures: []
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,5 @@
#define iTime (_Time.y)
#define iMouse float4(0,0,0,0)
#define iResolution float3(_ScreenParams.xy,0)
#define iFrame _FrameCount
#define iMouseData float4(0,0,0,0)

@ -0,0 +1,9 @@
fileFormatVersion: 2
guid: 9806aa3db21a1724189db8ba7edd10b3
timeCreated: 1529632977
licenseType: Store
ShaderImporter:
defaultTextures: []
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 72388c02446634bf5b1f88a67609fe9e
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,87 @@
// created by florian berger (flockaroo) - 2018
// License Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License.
// oil paint brush drawing
// generating stroke texture
#define MULTI_STROKE
#define Res (iResolution.xy)
#define Res0 vec2(textureSize(iChannel0,0))
#define Res1 vec2(textureSize(iChannel1,0))
#define Res2 vec2(textureSize(iChannel2,0))
#define PI 3.1415927
#define N(v) (v.yx*vec2(1,-1))
uniform float StrokeBend;
uniform float StrokeContour;
uniform float StrokeDir;
vec4 getRand(int idx)
{
ivec2 rres=textureSize(iChannel1,0);
idx=idx%(rres.x*rres.y);
return texelFetch(iChannel1,ivec2(idx%rres.x,idx/rres.x),0);
}
float getStroke(vec2 uv, int pidx)
{
vec4 rnd = getRand(pidx);
uv-=.5;
uv.x-=.035*StrokeBend*1.;
uv.x+=uv.y*uv.y*StrokeBend*1.;
//uv.x*=1.+.25*abs(StrokeBend);
uv.x*=1.2;
uv.y+=-StrokeBend*.1*(uv.x)+.05+.01*sin(uv.x*24.+float(pidx)*3.);
uv+=.5;
uv=clamp(uv,0.,1.);
float s=1.;
s*=uv.x*(1.-uv.x)*6.;
s*=uv.y*(1.-uv.y)*6.;
float s0=s;
s=(s-.5);
vec2 uv0=uv;
// move noise coord for each brush stroke
uv+=rnd.z*vec2(7,5)*303.72;
// brush hair noise
float psc=1.;
float pat = textureLod(iChannel1,psc*uv*1.5*sqrt(Res.x/600.)*vec2(.06,.006),.5).x
+textureLod(iChannel1,psc*uv*3.0*sqrt(Res.x/600.)*vec2(.06,.006),.5).x;
s0=s;
uv0.y=1.-uv0.y;
//s=(14.*(1.-uv0.y)*s0)*(exp(-s0*3.5))-uv0.y*.5;
s=(14.*(1.-uv0.y)*s0)*(exp(-s0*3.5/(StrokeContour+.01))-uv0.y*.5)-uv0.y*.5;
s=max(s,(pow(abs(s0),.2)*((s0>0.0)?1.:-1.)+(pat-1.4)-uv0.y*1.)*1.);
//s=mix((s0*1.+pat-1.)*1.,s,StrokeContour);
return s;
}
uniform int strokeSeed;
#ifdef MULTI_STROKE
uniform vec2 strokeNumXY;
#endif
void mainImage( out vec4 fragColor, vec2 fragCoord )
{
int seed=strokeSeed;
vec2 uv = fragCoord.xy / Res2;
#ifdef MULTI_STROKE
vec2 xynum=floor(max(vec2i(strokeNumXY),vec2i(1)));
vec2 uv2 = fract(uv*xynum);
vec2 xy = floor(uv*xynum);
uv=uv2;
seed+=7*int(xy.y*xynum.x+xy.x);
#endif
fragColor.xyz =vec3i(0) + getStroke(uv,seed);
fragColor.w = 1.;
}

@ -0,0 +1,9 @@
fileFormatVersion: 2
guid: d539d1b2b118948ae9062c680b7a72d9
ShaderImporter:
externalObjects: {}
defaultTextures: []
nonModifiableTextures: []
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,119 @@
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Hidden/Buff_AShader"
{
Properties
{
_MainTex ("Texture", 2D) = "white" {}
//_MainTexMip ("Texture", 2D) = "white" {}
//_RandTex("Texture", 2D) = "white" {}
//_FrameCount("framecount", Int) = 0;
//flipY("Flip Y", Float) = 0.;
//###ShaderUniforms
}
SubShader
{
// No culling or depth
Cull Off
//ZWrite Off
//ZTest Always
//Blend One One
//###RenderAttribs
Pass
{
CGPROGRAM
#pragma vertex vert
#pragma fragment frag
#include "UnityCG.cginc"
sampler2D _MainTex;
float4 _MainTex_TexelSize;
//sampler2D _RandTex;
//float4 _RandTex_TexelSize;
int _FrameCount;
float flipY;
//#define iChannel0 _MainTex
//#define iChannel1 _RandTex
//#define iChannel2 _MainTex
#include "glsl2Cg.cginc"
#include "shaderoo.cginc"
#define __UNITY3D__
#define SHADEROO
#define __SHADEROO_GEOM
// define this, so that frag only funcs are also compiled
#define SHADEROO_FRAGMENT_SHADER
#include "Buff_A.cginc"
#undef SHADEROO_FRAGMENT_SHADER
struct appdata
{
float4 vertex : POSITION;
float2 uv : TEXCOORD0;
};
struct v2f
{
float2 uv : TEXCOORD0;
float4 vertex : SV_POSITION;
//float4 vertex : TEXCOORD4;
#ifdef SHADEROO_GEOM
float4 vertAttr0: TEXCOORD1;
float4 vertAttr1: TEXCOORD2;
float4 vertAttr2: TEXCOORD3;
#endif
};
v2f vert (appdata v)
{
v2f o;
#ifdef SHADEROO_GEOM
float4 vertAttr[3] = { float4(0,0,0,0), float4(0,0,0,0), float4(0,0,0,0) };
/*vertAttr[0]=float4(0,0,0,0);
vertAttr[1]=float4(0,0,0,0);
vertAttr[2]=float4(0,0,0,0);*/
int vIdx=int(v.vertex.x+.1);
mainGeom(o.vertex,vertAttr,vIdx);
o.vertAttr0=vertAttr[0];
o.vertAttr1=vertAttr[1];
o.vertAttr2=vertAttr[2];
#else
//o.vertex = UnityObjectToClipPos(float4(v.vertex.xyz, 1.0));
o.vertex = v.vertex;
o.vertex.xy=o.vertex.xy*2.-1.;
o.uv = v.uv;
#endif
return o;
}
fixed4 frag (v2f i) : SV_Target
{
float4 c;
#ifdef SHADEROO_GEOM
float4 vertAttr[3];
vertAttr[0]=i.vertAttr0;
vertAttr[1]=i.vertAttr1;
vertAttr[2]=i.vertAttr2;
//FIXME: is +.5 really needed?
mainFragment(c,i.vertex/*+vec4(.5,.5,0,0)*/,vertAttr);
//mainFragment(c,vec4((i.vertex.xy*.5+.5)*iResolution.xy,i.vertex.zw),vertAttr);
#else
//FIXME: is +.5 really needed?
vec2 res=(i.vertex.xy/*+.5*/)/i.uv.xy;
if(flipY>.5) i.uv.y=1.-i.uv.y;
mainImage(c,i.uv*res.xy);
//mainImage(c,i.uv*512.0);
//if(flipY>.5) i.vertex.y=1.-i.vertex.y;
//mainImage(c,i.vertex.xy+vec2(.5,.5));
#endif
return c;
}
ENDCG
}
}
}

@ -0,0 +1,9 @@
fileFormatVersion: 2
guid: f31706c430832401a9e64ab6c5790804
ShaderImporter:
externalObjects: {}
defaultTextures: []
nonModifiableTextures: []
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,346 @@
// created by florian berger (flockaroo) - 2018
// License Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License.
// oil paint brush drawing
// calculating and drawing drawing the brush strokes
#define MULTI_STROKE
//#NumTriangles 0x10000
#ifndef __UNITY3D__
ivec2 ivec2i(int x) { return ivec2(x,x); }
ivec2 ivec2i(vec2 x) { return ivec2(x); }
vec2 vec2i(int x) { return vec2(x,x); }
vec2 vec2i(ivec2 x) { return vec2(x); }
vec2 vec2i(float x) { return vec2(x,x); }
vec3 vec3i(float x) { return vec3(x,x,x); }
vec3 vec3i(vec2 a, float b) { return vec3(a,b); }
vec3 vec3i(vec2 a, int b) { return vec3(a,b); }
vec4 vec4i(vec3 v,int x) { return vec4(v,x); }
#define mul(m,v) (v*m)
#endif
#ifdef __UNITY3D__
uniform int NumTriangles;
#else
#define NumTriangles 0x10000
#endif
#define Res (iResolution.xy)
#define Res0 vec2(textureSize(iChannel0,0))
#define Res1 vec2(textureSize(iChannel1,0))
#define PI 3.1415927
#define N(v) (v.yx*vec2(1,-1))
vec4 getRand(vec2 pos)
{
return textureLod(iChannel1,pos/Res1,0.);
}
vec4 getRand(int idx)
{
ivec2 rres=textureSize(iChannel1,0);
idx=idx%(rres.x*rres.y);
return texelFetch(iChannel1,ivec2(idx%rres.x,idx/rres.x),0);
}
uniform float SrcContrast;
uniform float SrcBright;
uniform float SrcColor;
uniform float SrcBlur;
vec4 getCol(vec2 pos, float lod)
{
// use max(...) for fitting full image or min(...) for fitting only one dir
vec2 uv = (pos-.5*Res)*min(Res0.y/Res.y,Res0.x/Res.x)/Res0+.5;
vec2 mask = step(vec2i(-.5),-abs(uv-.5));
vec4 c=textureLod(iChannel0,uv,lod+SrcBlur*(log2(Res.x)-1.));
float br=dot(c.xyz,vec3(.333,.333,.333));
c=(c-br)*SrcColor+br;
c=(c-.5)*SrcContrast+.5;
c*=SrcBright;
return clamp(c,0.,1.)*mask.x*mask.y;
//return clamp(((textureLod(iChannel0,uv,lod+SrcBlur*(log2(Res.x)-1.))-.5)*SrcContrast+.5*SrcBright),0.,1.)*mask.x*mask.y;
}
uniform float FlickerStrength;
uniform float FlickerFreq;
float flickerParam;
vec3 getValCol(vec2 pos, float lod)
{
return getCol(pos,1.5+log2(Res0.x/600.)+lod).xyz*.7+getCol(pos,3.5+log2(Res0.x/600.)+lod).xyz*.3+.003*getRand(pos*.1+flickerParam*10.).xyz;
//return getCol(pos,.5+lod).xyz*.7+getCol(pos,lod+2.5).xyz*0.3+.003*getRand(pos*.1+iTime*FlickerStrength*10.).xyz;
}
float compsignedmax(vec3 c)
{
vec3 s=sign(c);
vec3 a=abs(c);
if (a.x>a.y && a.x>a.z) return c.x;
if (a.y>a.x && a.y>a.z) return c.y;
return c.z;
}
vec2 getGradMax(vec2 pos, float eps)
{
vec2 d=vec2(eps,0);
float lod = log2(2.*eps*Res0.x/Res.x);
lod=0.;
return vec2(
compsignedmax(getValCol(pos+d.xy,lod)-getValCol(pos-d.xy,lod)),
compsignedmax(getValCol(pos+d.yx,lod)-getValCol(pos-d.yx,lod))
)/eps/2.;
}
vec2 quad(vec2 p1, vec2 p2, vec2 p3, vec2 p4, int idx)
{
#ifdef __UNITY3D__
vec2 p[6] = {p1,p2,p3,p2,p4,p3};
#else
vec2[6] p = vec2[6](p1,p2,p3,p2,p4,p3);
#endif
return p[idx%6];
}
uniform float BrushDetail;
uniform float StrokeBend;
int bitinv(int x, int bits)
{
int ret=0;
for(int i=0;i<bits;i++) ret |= ((x>>i)&1)<<(bits-1-i);
return ret;
}
int SCRAMBLE(int idx, int num)
{
return idx;
// sort of a generalized bit conversion - exchange half domains until smallest scale
int idx0=0;
for(int i=0;i<15;i++)
{
if(idx-idx0>=num-num/2) { idx=idx-(num-num/2); idx0+=0; num=num/2; }
else { idx=idx+num/2; idx0+=num/2; num=num-num/2; }
if (num<=0) break;
}
return idx;
}
uniform float BrushSize;
//uniform float StrokeThresh;
uniform float LayerScale;
uniform float StrokeAng;
uniform float ColorSpread;
#define CS(ang) cos(ang-vec2(0,PI/2.))
mat2 ROT2(float ang) { vec2 b=CS(ang); return mat2(b,b.yx*vec2(-1,1)); }
// HSV <-> RGB from http://lolengine.net/blog/2013/07/27/rgb-to-hsv-in-glsl
vec3 rgb2hsv(vec3 c)
{
vec4 K = vec4(0.0, -1.0 / 3.0, 2.0 / 3.0, -1.0);
vec4 p = mix(vec4(c.bg, K.wz), vec4(c.gb, K.xy), step(c.b, c.g));
vec4 q = mix(vec4(p.xyw, c.r), vec4(c.r, p.yzx), step(p.x, c.r));
float d = q.x - min(q.w, q.y);
float e = 1.0e-10;
return vec3(abs(q.z + (q.w - q.y) / (6.0 * d + e)), d / (q.x + e), q.x);
}
vec3 hsv2rgb(vec3 c)
{
vec4 K = vec4(1.0, 2.0 / 3.0, 1.0 / 3.0, 3.0);
vec3 p = abs(fract(c.xxx + K.xyz) * 6.0 - K.www);
return c.z * mix(K.xxx, clamp(p - K.xxx, 0.0, 1.0), c.y);
}
void mainGeom( out vec4 vertCoord, inout vec4 vertAttrib[3], int vertIndex )
{
flickerParam = ((iTime-mod(iTime,1.0/max(FlickerFreq,1.)))*FlickerStrength);
vertCoord=vec4(0,0,0,1);
int pidx = vertIndex/6;
float idxFact = float(pidx)/float(NumTriangles/2);
vec3 brushPos;
int layerScalePercent = int(floor(LayerScale*100.));
float ls = pow(float(layerScalePercent)/100.,2.);
//float pow(ls,
int NumGrid=int(float(NumTriangles/2)*(1.-ls));
float aspect=Res.x/Res.y;
int NumX = int(sqrt(float(NumGrid)*aspect));
int NumY = int(sqrt(float(NumGrid)/aspect));
//int pidx2 = NumX*NumY*4/3-pidx;
int pidx2 = NumTriangles/2-pidx;
int NumX2=NumX;
int NumY2=NumY;
int layer=0;
//int maxLayer=int(-log(float(NumY))/log(float(layerScalePercent)/100.));
for(int i=0; i<20; i++) { if(pidx2<NumX2*NumY2) { layer=i; break;} pidx2-=NumX2*NumY2; NumX2=NumX2*layerScalePercent/100; NumY2=NumY2*layerScalePercent/100; }
//NumX2=NumX*pow(layerScale,)
//layer=maxLayer-layer;
pidx2=NumX2*NumY2-pidx2;
brushPos.xy = (vec2(SCRAMBLE(pidx2%NumX2,NumX2),SCRAMBLE(pidx2/NumX2,NumY2))+.5)/vec2(NumX2,NumY2)*Res;
//brushPos.xy = vec2(SCRAMBLE(pidx2%NumX2,NumX2),SCRAMBLE(pidx2/NumX2,NumY2))/(vec2(NumX2,NumY2)-1.)*Res;
float gridW = Res.x/float(NumX2);
float gridW0 = Res.x/float(NumX);
// add some noise to grid pos
brushPos.xy += gridW*(getRand(brushPos.xy+flickerParam*30.).xy-.5);
// more trigonal grid by displacing every 2nd line
brushPos.x += gridW*.5*(float((pidx2/NumX2)%2)-.5);
vec2 g;
g = .5*getGradMax(brushPos.xy,gridW*1.)+.5*getGradMax(brushPos.xy,gridW*.12);
//g = getGradMax(brushPos.xy,gridW*.1);
float gl=length(g);
// add small error to gardient so big plain areas dont get too simple
g+=.007*(getRand(brushPos.xy*.5).xy-.5);
vec2 n = normalize(g);
vec2 t = N(n);
brushPos.z = .5;
//float wh = (gridW-gridW0+1.*min(Res.x/Res0.x,10.))*(.8+.4*getRand(pidx).z)/**pow(1.-idxFact,4.)*/;
//float lh = wh*1.5*exp(float(NumX2)/float(NumX)*.7)*(.8+.4*getRand(pidx).y);
// bigger scales covering at first, smaller scales not covering completely anymore
float wh = (gridW-.6*gridW0)*1.2;
float lh = wh;
float stretch=sqrt(1.5*pow(3.,1./float(layer+1)));
//stretch=1.5;
wh*=BrushSize*(.8+.4*getRand(pidx).y)/stretch;
lh*=BrushSize*(.8+.4*getRand(pidx).z)*stretch;
float wh0=wh;
//wh/=1.-.25*abs(StrokeBend);
wh*=1.25;
wh = (lh>max(Res.x,Res.y)*.1) ? 0. : wh;
//float StrokeThresh = iMouse.x/iResolution.x;
//wh = (layer!=int(StrokeThresh*20.)-1 && int(StrokeThresh*20.)>0) ? 0. : wh;
wh = (gl*BrushDetail<.003/wh0 && wh0<Res.x*.03) ? 0. : wh;
vec2 qc = quad( vec2(-1,-1), vec2(1,-1), vec2(-1,1), vec2(1,1), vertIndex );
// calc the vertCoord of actual line segment
//vertCoord.xy = quad( -wh*n-lh*t, +wh*n-lh*t, -wh*n+lh*t, +wh*n+lh*t, vertIndex);
vertCoord.xy = mul(qc,mat2(wh*n,lh*t));
vertCoord.xy = mul(vertCoord.xy,ROT2(StrokeAng));
vertCoord.xy += brushPos.xy;
//vertCoord.xy -= wh0*.25*StrokeBend*n;
vertCoord.xy = vertCoord.xy/Res*2.-1.;
// bg plane for drawing canvas
vertCoord.xy = (pidx==0) ? qc : vertCoord.xy;
vertCoord.z = brushPos.z*.01;
vertCoord.w = 1.;
vertAttrib[1].xy = qc*.5+.5;
vertAttrib[0]=getCol(brushPos.xy,1.);
vertAttrib[0].xyz=hsv2rgb(rgb2hsv(vertAttrib[0].xyz)+(getRand(brushPos.xy).xyz-.5)*vec3(.24,.4,.4)*ColorSpread);
vertAttrib[0].w=idxFact;
vertAttrib[1].w=wh0;
vertAttrib[1].z=float(layer);
vertAttrib[2].x=float(pidx);
//if(int(iMouseData.w)/1!=0)
// vertAttrib[1].w=1.;
}
uniform float Canvas;
uniform float StrokeSat;
uniform float StrokeContour;
uniform float StrokeDir;
uniform vec3 CanvasTint;
float getCanv(vec2 fragCoord)
{
float canv=0.;
canv=max(canv,(getRand(fragCoord.xy*vec2(.7,.03).xy)).x);
canv=max(canv,(getRand(fragCoord.xy*vec2(.7,.03).yx)).x);
canv-=.6;
return canv;
}
#ifdef MULTI_STROKE
uniform vec2 strokeNumXY;
#endif
float getStroke(vec2 uv, int pidx, vec2 fragCoord, float canv,vec2 d)
{
uv.y*=1.-step(0.1,StrokeDir)*2.;
vec4 rnd = getRand(pidx);
#ifdef SHADEROO_FRAGMENT_SHADER
uv+=dFdx(uv)*d.x;
uv+=dFdy(uv)*d.y;
#endif
uv+=.5;
#ifdef MULTI_STROKE
ivec2 xynum=ivec2i(max(vec2(strokeNumXY),vec2i(1)));
uv += vec2(pidx%xynum.x,(pidx/xynum.x)%xynum.y);
uv /= vec2i(xynum);
#endif
vec4 stroke = texture(iChannel2,uv);
float s = stroke.x;
float smask = stroke.y;
fragCoord+=d;
s+=clamp(1.-smask*5.,0.,1.)*getCanv(fragCoord)*Canvas*3.;
s+=clamp(1.-smask*5.,0.,1.)*(getRand(fragCoord.xy*.7).z-.5)*Canvas*1.5;
return s;
}
uniform float PaintShiny;
uniform float PaintSpec;
uniform float PaintDiff;
uniform float LightAng;
uniform float LightOffs;
uniform float halfFOV;
uniform float CanvasBg;
void mainFragment( out vec4 fragColor, vec4 fragCoord, vec4 vertAttrib[3] )
{
int pidx = int(vertAttrib[2].x);
int layer = int(vertAttrib[1].z);
float wh0 = vertAttrib[1].w;
float canv=getCanv(fragCoord.xy);
//float w=vertAttrib[0].w/iResolution.x;
// draw a line with smooth falloff
// triangular falloff
vec2 uv=vertAttrib[1].xy-.5;
vec3 n = vec3(0,0,1);
float s=getStroke(uv,pidx,fragCoord.xy,canv,vec2i(0));
float s0=s;
#ifdef SHADEROO_FRAGMENT_SHADER
float ws=fwidth(s);
// use this for non 0-clamped tex
s=smoothstep(-ws,ws,s);
// use this for 0-clamped tex:
//s=clamp(s*10.,0.,1.);
#endif
vec2 d=vec2(.7,0);
vec2 g = vec2(
getStroke(uv,pidx,fragCoord.xy,canv,d.xy)-s0,
getStroke(uv,pidx,fragCoord.xy,canv,d.yx)-s0
)/d.x;
n=normalize(vec3(-g,1.));
vec2 uvs=fragCoord.xy/Res;
vec2 cso=CS(LightOffs);
vec3 light = vec3i(CS(LightAng)*cso.y,cso.x);
float diff=clamp(dot(n,light),0.,1.0);
vec3 eyeDir = normalize(vec3i((-uvs*2.+1.)*tan(halfFOV)*vec2(1.0,Res.y/Res.x),1));
float spec=clamp(dot(reflect(-light,n),eyeDir),0.0,1.0);
spec=pow(spec,20.*PaintShiny+1.01)*(.5+PaintShiny);
fragColor.xyz = vertAttrib[0].xyz*mix(1.,diff,PaintDiff)+spec*PaintSpec;
fragColor.w=s;
vec4 canvCol=vec4i(vec3i(mix(1.,canv+.5,.14*CanvasBg))*CanvasTint,1);
fragColor = pidx==0 ? canvCol : fragColor;
}

@ -0,0 +1,9 @@
fileFormatVersion: 2
guid: 8d538ba86096c44e5ac06e3de2c84536
ShaderImporter:
externalObjects: {}
defaultTextures: []
nonModifiableTextures: []
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,314 @@
// created by florian berger (flockaroo) - 2018
// License Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License.
// oil paint brush drawing
// calculating and drawing drawing the brush strokes
#define MULTI_STROKE
////#NumTriangles 0x10000
#ifndef __UNITY3D__
vec2 vec2i(float x) { return vec2(x,x); }
vec3 vec3i(float x) { return vec3(x,x,x); }
vec4 vec4i(vec3 v,int x) { return vec4(v,x); }
#define mul(m,v) (v*m)
#endif
#ifdef __UNITY3D__
uniform int NumTriangles;
#else
#define NumTriangles 0x10000
#endif
#define Res (iResolution.xy)
#define Res0 vec2(textureSize(iChannel0,0))
#define Res1 vec2(textureSize(iChannel1,0))
#define PI 3.1415927
#define N(v) (v.yx*vec2(1,-1))
vec4 getRand(vec2 pos)
{
return textureLod(iChannel1,pos/Res1,0.);
}
vec4 getRand(int idx)
{
ivec2 rres=textureSize(iChannel1,0);
idx=idx%(rres.x*rres.y);
return texelFetch(iChannel1,ivec2(idx%rres.x,idx/rres.x),0);
}
uniform float SrcContrast;
uniform float SrcBright;
uniform float SrcBlur;
vec4 getCol(vec2 pos, float lod)
{
// use max(...) for fitting full image or min(...) for fitting only one dir
vec2 uv = (pos-.5*Res)*min(Res0.y/Res.y,Res0.x/Res.x)/Res0+.5;
vec2 mask = step(vec2i(-.5),-abs(uv-.5));
return clamp(((textureLod(iChannel0,uv,lod+SrcBlur*(log2(Res.x)-1.))-.5)*SrcContrast+.5*SrcBright),0.,1.)*mask.x*mask.y;
}
uniform float FlickerStrength;
vec3 getValCol(vec2 pos, float lod)
{
return getCol(pos,1.5+log2(Res0.x/600.)+lod).xyz*.7+getCol(pos,3.5+log2(Res0.x/600.)+lod).xyz*.3+.003*getRand(pos*.1+iTime*FlickerStrength*10.).xyz;
//return getCol(pos,.5+lod).xyz*.7+getCol(pos,lod+2.5).xyz*0.3+.003*getRand(pos*.1+iTime*FlickerStrength*10.).xyz;
}
float compsignedmax(vec3 c)
{
vec3 s=sign(c);
vec3 a=abs(c);
if (a.x>a.y && a.x>a.z) return c.x;
if (a.y>a.x && a.y>a.z) return c.y;
return c.z;
}
vec2 getGradMax(vec2 pos, float eps)
{
vec2 d=vec2(eps,0);
float lod = log2(2.*eps*Res0.x/Res.x);
lod=0.;
return vec2(
compsignedmax(getValCol(pos+d.xy,lod)-getValCol(pos-d.xy,lod)),
compsignedmax(getValCol(pos+d.yx,lod)-getValCol(pos-d.yx,lod))
)/eps/2.;
}
vec2 quad(vec2 p1, vec2 p2, vec2 p3, vec2 p4, int idx)
{
#ifdef __UNITY3D__
vec2 p[6] = {p1,p2,p3,p2,p4,p3};
#else
vec2[6] p = vec2[6](p1,p2,p3,p2,p4,p3);
#endif
return p[idx%6];
}
uniform float BrushDetail;
uniform float StrokeBend;
int bitinv(int x, int bits)
{
int ret=0;
for(int i=0;i<bits;i++) ret |= ((x>>i)&1)<<(bits-1-i);
return ret;
}
int SCRAMBLE(int idx, int num)
{
return idx;
// sort of a generalized bit conversion - exchange half domains until smallest scale
int idx0=0;
for(int i=0;i<15;i++)
{
if(idx-idx0>=num-num/2) { idx=idx-(num-num/2); idx0+=0; num=num/2; }
else { idx=idx+num/2; idx0+=num/2; num=num-num/2; }
if (num<=0) break;
}
return idx;
}
uniform float BrushSize;
//uniform float StrokeThresh;
uniform float LayerScale;
uniform float StrokeAng;
#define CS(ang) cos(ang-vec2(0,PI/2.))
mat2 ROT2(float ang) { vec2 b=CS(ang); return mat2(b,b.yx*vec2(-1,1)); }
void mainGeom( out vec4 vertCoord, inout vec4 vertAttrib[3], int vertIndex )
{
vertCoord=vec4(0,0,0,1);
int pidx = vertIndex/6;
float idxFact = float(pidx)/float(NumTriangles/2);
vec3 brushPos;
//int layerScalePercent = int(floor(LayerScale*100.));
float ls = pow(LayerScale,2.);
//float pow(ls,
int NumGrid=int(float(NumTriangles/2)*(1.-ls));
float aspect=Res.x/Res.y;
int NumX = int(sqrt(float(NumGrid)*aspect));
int NumY = int(sqrt(float(NumGrid)/aspect));
//int pidx2 = NumX*NumY*4/3-pidx;
int pidx2 = NumTriangles/2-pidx;
int NumX2=NumX;
int NumY2=NumY;
int layer=0;
//int maxLayer=int(-log2(float(NumY))/log2(layerScale));
int imax=8;
layer = imax;
for(int i=0; i<imax; i++) { if(pidx2<NumX2*NumY2) { layer=i; break;} pidx2-=NumX2*NumY2; NumX2=NumX2*int(LayerScale*100.)/100; NumY2=NumY2*int(LayerScale*100.)/100; }
//NumX2=NumX*pow(layerScale,)
//layer=maxLayer-layer;
pidx2=NumX2*NumY2-pidx2;
brushPos.xy = (vec2(SCRAMBLE(pidx2%NumX2,NumX2),SCRAMBLE(pidx2/NumX2,NumY2))+.5)/vec2(NumX2,NumY2)*Res;
//brushPos.xy = vec2(SCRAMBLE(pidx2%NumX2,NumX2),SCRAMBLE(pidx2/NumX2,NumY2))/(vec2(NumX2,NumY2)-1.)*Res;
float gridW = Res.x/float(NumX2);
float gridW0 = Res.x/float(NumX);
// add some noise to grid pos
brushPos.xy += gridW*(getRand(brushPos.xy+float(iFrame)*FlickerStrength).xy-.5);
// more trigonal grid by displacing every 2nd line
brushPos.x += gridW*.5*(float((pidx2/NumX2)%2)-.5);
vec2 g;
g = .5*getGradMax(brushPos.xy,gridW*1.)+.5*getGradMax(brushPos.xy,gridW*.12);
//g = getGradMax(brushPos.xy,gridW*.1);
float gl=length(g);
// add small error to gardient so big plain areas dont get too simple
g+=.007*(getRand(brushPos.xy*.5).xy-.5);
vec2 n = normalize(g);
vec2 t = N(n);
brushPos.z = .5;
//float wh = (gridW-gridW0+1.*min(Res.x/Res0.x,10.))*(.8+.4*getRand(pidx).z)/**pow(1.-idxFact,4.)*/;
//float lh = wh*1.5*exp(float(NumX2)/float(NumX)*.7)*(.8+.4*getRand(pidx).y);
// bigger scales covering at first, smaller scales not covering completely anymore
float wh = (gridW-.6*gridW0)*1.2;
float lh = wh;
float stretch=sqrt(1.5*pow(3.,1./float(layer+1)));
//stretch=1.5;
wh*=BrushSize*(.8+.4*getRand(pidx).y)/stretch;
lh*=BrushSize*(.8+.4*getRand(pidx).z)*stretch;
float wh0=wh;
//wh/=1.-.25*abs(StrokeBend);
wh*=1.25;
//if(imax!=0)
wh = (lh>max(Res.x,Res.y)*.1 && layer!=imax-1) ? 0. : wh;
//float StrokeThresh = iMouse.x/iResolution.x;
//wh = (layer!=int(StrokeThresh*20.)-1 && int(StrokeThresh*20.)>0) ? 0. : wh;
wh = (gl*BrushDetail<.003/wh0 && wh0<Res.x*.03 && layer!=imax-1) ? 0. : wh;
wh = (layer>=imax) ? 0. : wh;
vec2 qc = quad( vec2(-1,-1), vec2(1,-1), vec2(-1,1), vec2(1,1), vertIndex );
// calc the vertCoord of actual line segment
//vertCoord.xy = quad( -wh*n-lh*t, +wh*n-lh*t, -wh*n+lh*t, +wh*n+lh*t, vertIndex);
vertCoord.xy = mul(qc,mat2(wh*n,lh*t));
vertCoord.xy = mul(vertCoord.xy,ROT2(StrokeAng));
vertCoord.xy += brushPos.xy;
//vertCoord.xy -= wh0*.25*StrokeBend*n;
vertCoord.xy = vertCoord.xy/Res*2.-1.;
// bg plane for drawing canvas
vertCoord.xy = (pidx==0) ? qc : vertCoord.xy;
vertCoord.z = brushPos.z*.01;
vertCoord.w = 1.;
vertAttrib[1].xy = qc*.5+.5;
vertAttrib[0]=getCol(brushPos.xy,1.);
vertAttrib[0].w=idxFact;
vertAttrib[1].w=wh0;
vertAttrib[1].z=float(layer);
vertAttrib[2].x=float(pidx);
//if(int(iMouseData.w)/1!=0)
// vertAttrib[1].w=1.;
}
uniform float Canvas;
uniform float StrokeSat;
uniform float StrokeContour;
uniform float StrokeDir;
uniform vec3 CanvasTint;
float getCanv(vec2 fragCoord)
{
float canv=0.;
canv=max(canv,(getRand(fragCoord.xy*vec2(.7,.03).xy)).x);
canv=max(canv,(getRand(fragCoord.xy*vec2(.7,.03).yx)).x);
canv-=.6;
return canv;
}
#ifdef MULTI_STROKE
uniform vec2 strokeNumXY;
#endif
float getStroke(vec2 uv, int pidx, vec2 fragCoord, float canv,vec2 d)
{
uv.y*=1.-step(0.1,StrokeDir)*2.;
vec4 rnd = getRand(pidx);
#ifdef SHADEROO_FRAGMENT_SHADER
uv+=dFdx(uv)*d.x;
uv+=dFdy(uv)*d.y;
#endif
uv+=.5;
#ifdef MULTI_STROKE
ivec2 xynum=ivec2i(max(vec2(strokeNumXY),vec2i(1)));
uv += vec2(pidx%xynum.x,(pidx/xynum.x)%xynum.y);
uv /= vec2i(xynum);
#endif
vec4 stroke = texture(iChannel2,uv);
float s = stroke.x;
float smask = stroke.y;
fragCoord+=d;
s+=clamp(1.-smask*5.,0.,1.)*getCanv(fragCoord)*Canvas*3.;
s+=clamp(1.-smask*5.,0.,1.)*(getRand(fragCoord.xy*.7).z-.5)*Canvas*1.5;
return s;
}
uniform float PaintShiny;
uniform float PaintSpec;
uniform float PaintDiff;
uniform float LightAng;
uniform float LightOffs;
uniform float halfFOV;
uniform float CanvasBg;
void mainFragment( out vec4 fragColor, vec4 fragCoord, vec4 vertAttrib[3] )
{
int pidx = int(vertAttrib[2].x);
int layer = int(vertAttrib[1].z);
float wh0 = vertAttrib[1].w;
float canv=getCanv(fragCoord.xy);
//float w=vertAttrib[0].w/iResolution.x;
// draw a line with smooth falloff
// triangular falloff
vec2 uv=vertAttrib[1].xy-.5;
vec3 n = vec3(0,0,1);
float s=getStroke(uv,pidx,fragCoord.xy,canv,vec2i(0));
float s0=s;
#ifdef SHADEROO_FRAGMENT_SHADER
float ws=fwidth(s);
// use this for non 0-clamped tex
s=smoothstep(-ws,ws,s);
// use this for 0-clamped tex:
//s=clamp(s*10.,0.,1.);
#endif
vec2 d=vec2(.7,0);
vec2 g = vec2(
getStroke(uv,pidx,fragCoord.xy,canv,d.xy)-s0,
getStroke(uv,pidx,fragCoord.xy,canv,d.yx)-s0
)/d.x;
n=normalize(vec3(-g,1.));
vec2 uvs=fragCoord.xy/Res;
vec2 cso=CS(LightOffs);
vec3 light = vec3i(CS(LightAng)*cso.y,cso.x);
float diff=clamp(dot(n,light),0.,1.0);
vec3 eyeDir = normalize(vec3i((-uvs*2.+1.)*tan(halfFOV)*vec2(1.0,Res.y/Res.x),1));
float spec=clamp(dot(reflect(-light,n),eyeDir),0.0,1.0);
//spec=pow(spec,10.0);
spec=pow(spec,20.*PaintShiny+1.01)*(.5+PaintShiny);
fragColor.xyz = vertAttrib[0].xyz*mix(1.,diff,PaintDiff)+spec*PaintSpec;
fragColor.w=s;
vec4 canvCol=vec4i(vec3i(mix(1.,canv+.5,.14*CanvasBg))*CanvasTint,1);
fragColor = pidx==0 ? canvCol : fragColor;
}

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 0151fdce4e93f404c95524c94c44bc24
timeCreated: 1546642427
licenseType: Store
DefaultImporter:
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,314 @@
// created by florian berger (flockaroo) - 2018
// License Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License.
// oil paint brush drawing
// calculating and drawing drawing the brush strokes
#define MULTI_STROKE
////#NumTriangles 0x10000
#ifndef __UNITY3D__
vec2 vec2i(float x) { return vec2(x,x); }
vec3 vec3i(float x) { return vec3(x,x,x); }
vec4 vec4i(vec3 v,int x) { return vec4(v,x); }
#define mul(m,v) (v*m)
#endif
#ifdef __UNITY3D__
uniform int NumTriangles;
#else
#define NumTriangles 0x10000
#endif
#define Res (iResolution.xy)
#define Res0 vec2(textureSize(iChannel0,0))
#define Res1 vec2(textureSize(iChannel1,0))
#define PI 3.1415927
#define N(v) (v.yx*vec2(1,-1))
vec4 getRand(vec2 pos)
{
return textureLod(iChannel1,pos/Res1,0.);
}
vec4 getRand(int idx)
{
ivec2 rres=textureSize(iChannel1,0);
idx=idx%(rres.x*rres.y);
return texelFetch(iChannel1,ivec2(idx%rres.x,idx/rres.x),0);
}
uniform float SrcContrast;
uniform float SrcBright;
uniform float SrcBlur;
vec4 getCol(vec2 pos, float lod)
{
// use max(...) for fitting full image or min(...) for fitting only one dir
vec2 uv = (pos-.5*Res)*min(Res0.y/Res.y,Res0.x/Res.x)/Res0+.5;
vec2 mask = step(vec2i(-.5),-abs(uv-.5));
return clamp(((textureLod(iChannel0,uv,lod+SrcBlur*(log2(Res.x)-1.))-.5)*SrcContrast+.5*SrcBright),0.,1.)*mask.x*mask.y;
}
uniform float FlickerStrength;
vec3 getValCol(vec2 pos, float lod)
{
return getCol(pos,1.5+log2(Res0.x/600.)+lod).xyz*.7+getCol(pos,3.5+log2(Res0.x/600.)+lod).xyz*.3+.003*getRand(pos*.1+iTime*FlickerStrength*10.).xyz;
//return getCol(pos,.5+lod).xyz*.7+getCol(pos,lod+2.5).xyz*0.3+.003*getRand(pos*.1+iTime*FlickerStrength*10.).xyz;
}
float compsignedmax(vec3 c)
{
vec3 s=sign(c);
vec3 a=abs(c);
if (a.x>a.y && a.x>a.z) return c.x;
if (a.y>a.x && a.y>a.z) return c.y;
return c.z;
}
vec2 getGradMax(vec2 pos, float eps)
{
vec2 d=vec2(eps,0);
float lod = log2(2.*eps*Res0.x/Res.x);
lod=0.;
return vec2(
compsignedmax(getValCol(pos+d.xy,lod)-getValCol(pos-d.xy,lod)),
compsignedmax(getValCol(pos+d.yx,lod)-getValCol(pos-d.yx,lod))
)/eps/2.;
}
vec2 quad(vec2 p1, vec2 p2, vec2 p3, vec2 p4, int idx)
{
#ifdef __UNITY3D__
vec2 p[6] = {p1,p2,p3,p2,p4,p3};
#else
vec2[6] p = vec2[6](p1,p2,p3,p2,p4,p3);
#endif
return p[idx%6];
}
uniform float BrushDetail;
uniform float StrokeBend;
int bitinv(int x, int bits)
{
int ret=0;
for(int i=0;i<bits;i++) ret |= ((x>>i)&1)<<(bits-1-i);
return ret;
}
int SCRAMBLE(int idx, int num)
{
return idx;
// sort of a generalized bit conversion - exchange half domains until smallest scale
int idx0=0;
for(int i=0;i<15;i++)
{
if(idx-idx0>=num-num/2) { idx=idx-(num-num/2); idx0+=0; num=num/2; }
else { idx=idx+num/2; idx0+=num/2; num=num-num/2; }
if (num<=0) break;
}
return idx;
}
uniform float BrushSize;
//uniform float StrokeThresh;
uniform float LayerScale;
uniform float StrokeAng;
#define CS(ang) cos(ang-vec2(0,PI/2.))
mat2 ROT2(float ang) { vec2 b=CS(ang); return mat2(b,b.yx*vec2(-1,1)); }
void mainGeom( out vec4 vertCoord, inout vec4 vertAttrib[3], int vertIndex )
{
vertCoord=vec4(0,0,0,1);
int pidx = vertIndex/6;
float idxFact = float(pidx)/float(NumTriangles/2);
vec3 brushPos;
//int layerScalePercent = int(floor(LayerScale*100.));
float ls = pow(LayerScale,2.);
//float pow(ls,
int NumGrid=int(float(NumTriangles/2)*(1.-ls));
float aspect=Res.x/Res.y;
int NumX = int(sqrt(float(NumGrid)*aspect));
int NumY = int(sqrt(float(NumGrid)/aspect));
//int pidx2 = NumX*NumY*4/3-pidx;
int pidx2 = NumTriangles/2-pidx;
int NumX2=NumX;
int NumY2=NumY;
int layer=0;
//int maxLayer=int(-log2(float(NumY))/log2(layerScale));
int imax=8;
layer = imax;
for(int i=0; i<imax; i++) { if(pidx2<NumX2*NumY2) { layer=i; break;} pidx2-=NumX2*NumY2; NumX2=NumX2*int(LayerScale*100.)/100; NumY2=NumY2*int(LayerScale*100.)/100; }
//NumX2=NumX*pow(layerScale,)
//layer=maxLayer-layer;
pidx2=NumX2*NumY2-pidx2;
brushPos.xy = (vec2(SCRAMBLE(pidx2%NumX2,NumX2),SCRAMBLE(pidx2/NumX2,NumY2))+.5)/vec2(NumX2,NumY2)*Res;
//brushPos.xy = vec2(SCRAMBLE(pidx2%NumX2,NumX2),SCRAMBLE(pidx2/NumX2,NumY2))/(vec2(NumX2,NumY2)-1.)*Res;
float gridW = Res.x/float(NumX2);
float gridW0 = Res.x/float(NumX);
// add some noise to grid pos
brushPos.xy += gridW*(getRand(brushPos.xy+float(iFrame)*FlickerStrength).xy-.5);
// more trigonal grid by displacing every 2nd line
brushPos.x += gridW*.5*(float((pidx2/NumX2)%2)-.5);
vec2 g;
g = .5*getGradMax(brushPos.xy,gridW*1.)+.5*getGradMax(brushPos.xy,gridW*.12);
//g = getGradMax(brushPos.xy,gridW*.1);
float gl=length(g);
// add small error to gardient so big plain areas dont get too simple
g+=.007*(getRand(brushPos.xy*.5).xy-.5);
vec2 n = normalize(g);
vec2 t = N(n);
brushPos.z = .5;
//float wh = (gridW-gridW0+1.*min(Res.x/Res0.x,10.))*(.8+.4*getRand(pidx).z)/**pow(1.-idxFact,4.)*/;
//float lh = wh*1.5*exp(float(NumX2)/float(NumX)*.7)*(.8+.4*getRand(pidx).y);
// bigger scales covering at first, smaller scales not covering completely anymore
float wh = (gridW-.6*gridW0)*1.2;
float lh = wh;
float stretch=sqrt(1.5*pow(3.,1./float(layer+1)));
//stretch=1.5;
wh*=BrushSize*(.8+.4*getRand(pidx).y)/stretch;
lh*=BrushSize*(.8+.4*getRand(pidx).z)*stretch;
float wh0=wh;
//wh/=1.-.25*abs(StrokeBend);
wh*=1.25;
//if(imax!=0)
wh = (lh>max(Res.x,Res.y)*.1 && layer!=imax-1) ? 0. : wh;
//float StrokeThresh = iMouse.x/iResolution.x;
//wh = (layer!=int(StrokeThresh*20.)-1 && int(StrokeThresh*20.)>0) ? 0. : wh;
wh = (gl*BrushDetail<.003/wh0 && wh0<Res.x*.03 && layer!=imax-1) ? 0. : wh;
wh = (layer>=imax) ? 0. : wh;
vec2 qc = quad( vec2(-1,-1), vec2(1,-1), vec2(-1,1), vec2(1,1), vertIndex );
// calc the vertCoord of actual line segment
//vertCoord.xy = quad( -wh*n-lh*t, +wh*n-lh*t, -wh*n+lh*t, +wh*n+lh*t, vertIndex);
vertCoord.xy = mul(qc,mat2(wh*n,lh*t));
vertCoord.xy = mul(vertCoord.xy,ROT2(StrokeAng));
vertCoord.xy += brushPos.xy;
//vertCoord.xy -= wh0*.25*StrokeBend*n;
vertCoord.xy = vertCoord.xy/Res*2.-1.;
// bg plane for drawing canvas
vertCoord.xy = (pidx==0) ? qc : vertCoord.xy;
vertCoord.z = brushPos.z*.01;
vertCoord.w = 1.;
vertAttrib[1].xy = qc*.5+.5;
vertAttrib[0]=getCol(brushPos.xy,1.);
vertAttrib[0].w=idxFact;
vertAttrib[1].w=wh0;
vertAttrib[1].z=float(layer);
vertAttrib[2].x=float(pidx);
//if(int(iMouseData.w)/1!=0)
// vertAttrib[1].w=1.;
}
uniform float Canvas;
uniform float StrokeSat;
uniform float StrokeContour;
uniform float StrokeDir;
uniform vec3 CanvasTint;
float getCanv(vec2 fragCoord)
{
float canv=0.;
canv=max(canv,(getRand(fragCoord.xy*vec2(.7,.03).xy)).x);
canv=max(canv,(getRand(fragCoord.xy*vec2(.7,.03).yx)).x);
canv-=.6;
return canv;
}
#ifdef MULTI_STROKE
uniform vec2 strokeNumXY;
#endif
float getStroke(vec2 uv, int pidx, vec2 fragCoord, float canv,vec2 d)
{
uv.y*=1.-step(0.1,StrokeDir)*2.;
vec4 rnd = getRand(pidx);
#ifdef SHADEROO_FRAGMENT_SHADER
uv+=dFdx(uv)*d.x;
uv+=dFdy(uv)*d.y;
#endif
uv+=.5;
#ifdef MULTI_STROKE
ivec2 xynum=ivec2i(max(vec2(strokeNumXY),vec2i(1)));
uv += vec2(pidx%xynum.x,(pidx/xynum.x)%xynum.y);
uv /= vec2i(xynum);
#endif
vec4 stroke = texture(iChannel2,uv);
float s = stroke.x;
float smask = stroke.y;
fragCoord+=d;
s+=clamp(1.-smask*5.,0.,1.)*getCanv(fragCoord)*Canvas*3.;
s+=clamp(1.-smask*5.,0.,1.)*(getRand(fragCoord.xy*.7).z-.5)*Canvas*1.5;
return s;
}
uniform float PaintShiny;
uniform float PaintSpec;
uniform float PaintDiff;
uniform float LightAng;
uniform float LightOffs;
uniform float halfFOV;
uniform float CanvasBg;
void mainFragment( out vec4 fragColor, vec4 fragCoord, vec4 vertAttrib[3] )
{
int pidx = int(vertAttrib[2].x);
int layer = int(vertAttrib[1].z);
float wh0 = vertAttrib[1].w;
float canv=getCanv(fragCoord.xy);
//float w=vertAttrib[0].w/iResolution.x;
// draw a line with smooth falloff
// triangular falloff
vec2 uv=vertAttrib[1].xy-.5;
vec3 n = vec3(0,0,1);
float s=getStroke(uv,pidx,fragCoord.xy,canv,vec2i(0));
float s0=s;
#ifdef SHADEROO_FRAGMENT_SHADER
float ws=fwidth(s);
// use this for non 0-clamped tex
s=smoothstep(-ws,ws,s);
// use this for 0-clamped tex:
//s=clamp(s*10.,0.,1.);
#endif
vec2 d=vec2(.7,0);
vec2 g = vec2(
getStroke(uv,pidx,fragCoord.xy,canv,d.xy)-s0,
getStroke(uv,pidx,fragCoord.xy,canv,d.yx)-s0
)/d.x;
n=normalize(vec3(-g,1.));
vec2 uvs=fragCoord.xy/Res;
vec2 cso=CS(LightOffs);
vec3 light = vec3i(CS(LightAng)*cso.y,cso.x);
float diff=clamp(dot(n,light),0.,1.0);
vec3 eyeDir = normalize(vec3i((-uvs*2.+1.)*tan(halfFOV)*vec2(1.0,Res.y/Res.x),1));
float spec=clamp(dot(reflect(-light,n),eyeDir),0.0,1.0);
//spec=pow(spec,10.0);
spec=pow(spec,20.*PaintShiny+1.01)*(.5+PaintShiny);
fragColor.xyz = vertAttrib[0].xyz*mix(1.,diff,PaintDiff)+spec*PaintSpec;
fragColor.w=s;
vec4 canvCol=vec4i(vec3i(mix(1.,canv+.5,.14*CanvasBg))*CanvasTint,1);
fragColor = pidx==0 ? canvCol : fragColor;
}

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: c9307082ca7291b42a76d24beff03791
timeCreated: 1546642427
licenseType: Store
DefaultImporter:
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,124 @@
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Hidden/Geom_AShader"
{
Properties
{
_MainTex ("Texture", 2D) = "white" {}
//_MainTexMip ("Texture", 2D) = "white" {}
//_RandTex("Texture", 2D) = "white" {}
//_FrameCount("framecount", Int) = 0;
//flipY("Flip Y", Float) = 0.;
//###ShaderUniforms
}
SubShader
{
// No culling or depth
Cull Off
//ZWrite Off
//ZTest Always
//Blend One One
ZTest Always
Blend SrcAlpha OneMinusSrcAlpha
//###RenderAttribs
Pass
{
CGPROGRAM
#pragma vertex vert
#pragma fragment frag
#include "UnityCG.cginc"
sampler2D _MainTex;
float4 _MainTex_TexelSize;
//sampler2D _RandTex;
//float4 _RandTex_TexelSize;
int _FrameCount;
float flipY;
float geomFlipY;
//#define iChannel0 _MainTex
//#define iChannel1 _RandTex
//#define iChannel2 _MainTex
#include "glsl2Cg.cginc"
#include "shaderoo.cginc"
#define __UNITY3D__
#define SHADEROO
#define SHADEROO_GEOM
// define this, so that frag only funcs are also compiled
#define SHADEROO_FRAGMENT_SHADER
#include "Geom_A.cginc"
#undef SHADEROO_FRAGMENT_SHADER
struct appdata
{
float4 vertex : POSITION;
float2 uv : TEXCOORD0;
};
struct v2f
{
float2 uv : TEXCOORD0;
float4 vertex : SV_POSITION;
//float4 vertex : TEXCOORD4;
#ifdef SHADEROO_GEOM
float4 vertAttr0: TEXCOORD1;
float4 vertAttr1: TEXCOORD2;
float4 vertAttr2: TEXCOORD3;
#endif
};
v2f vert (appdata v)
{
v2f o;
#ifdef SHADEROO_GEOM
float4 vertAttr[3] = { float4(0,0,0,0), float4(0,0,0,0), float4(0,0,0,0) };
/*vertAttr[0]=float4(0,0,0,0);
vertAttr[1]=float4(0,0,0,0);
vertAttr[2]=float4(0,0,0,0);*/
int vIdx=int(v.vertex.x+.1);
mainGeom(o.vertex,vertAttr,vIdx);
if(geomFlipY>.5)
o.vertex.y*=-1.;
o.vertAttr0=vertAttr[0];
o.vertAttr1=vertAttr[1];
o.vertAttr2=vertAttr[2];
#else
//o.vertex = UnityObjectToClipPos(float4(v.vertex.xyz, 1.0));
o.vertex = v.vertex;
o.vertex.xy=o.vertex.xy*2.-1.;
o.uv = v.uv;
#endif
return o;
}
fixed4 frag (v2f i) : SV_Target
{
float4 c;
#ifdef SHADEROO_GEOM
float4 vertAttr[3];
vertAttr[0]=i.vertAttr0;
vertAttr[1]=i.vertAttr1;
vertAttr[2]=i.vertAttr2;
//FIXME: is +.5 really needed?
mainFragment(c,i.vertex/*+vec4(.5,.5,0,0)*/,vertAttr);
//mainFragment(c,vec4((i.vertex.xy*.5+.5)*iResolution.xy,i.vertex.zw),vertAttr);
#else
//FIXME: is +.5 really needed?
vec2 res=(i.vertex.xy/*+.5*/)/i.uv.xy;
if(flipY>.5) i.uv.y=1.-i.uv.y;
mainImage(c,i.uv*res.xy);
//mainImage(c,i.uv*iResolution.xy);
//if(flipY>.5) i.vertex.y=1.-i.vertex.y;
//mainImage(c,i.vertex.xy+vec2(.5,.5));
#endif
return c;
}
ENDCG
}
}
}

@ -0,0 +1,9 @@
fileFormatVersion: 2
guid: ce1734820593a45d7b0857130d72639c
ShaderImporter:
externalObjects: {}
defaultTextures: []
nonModifiableTextures: []
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,45 @@
// created by florian berger (flockaroo) - 2018
// License Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License.
// oil paint brush drawing
// final mixing/vignetting/fading
#define ImageTex iChannel0
#define Res iResolution.xy
#define Res0 vec2(textureSize(iChannel0,0))
#define Res1 vec2(textureSize(iChannel1,0))
#define Res2 vec2(textureSize(iChannel2,0))
#define Res3 vec2(textureSize(iChannel3,0))
uniform float Vignette;
uniform float EffectFade;
uniform float PanFade;
void mainImage( out vec4 fragColor, in vec2 fragCoord )
{
vec2 uv = fragCoord/Res;
fragColor = texture(ImageTex,uv);
fragColor.w=1.;
vec2 uv2 = (fragCoord-.5*Res)*min(Res3.y/Res.y,Res3.x/Res.x)/Res3+.5;
vec4 col0 = texture(iChannel3,uv2);
fragColor = mix(fragColor,col0,EffectFade);
#define PANFADE_W 0.025
fragColor.xyz=mix(fragColor.xyz,col0.xyz,smoothstep((1.-PanFade)-PANFADE_W,(1.-PanFade)+PANFADE_W,((1.-fragCoord.x/iResolution.x)-.5)/(1.+2.*PANFADE_W)+.5));
if(true)
{
vec2 scc=(fragCoord-.5*iResolution.xy)/iResolution.x;
float vign = 1.0-Vignette*dot(scc,scc)*1.3;
//float vign = 1.0;
vign*=1.-Vignette*exp(-sin(fragCoord.x/iResolution.x*3.1416)*40.);
vign*=1.-Vignette*exp(-sin(fragCoord.y/iResolution.y*3.1416)*20.);
fragColor.xyz *= vign;
}
//fragColor = texture(iChannel2,fragCoord/Res);
fragColor.w = 1.;
}

@ -0,0 +1,9 @@
fileFormatVersion: 2
guid: 56ffa20020b51486bb6b397f3a275a92
ShaderImporter:
externalObjects: {}
defaultTextures: []
nonModifiableTextures: []
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,119 @@
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)'
Shader "Hidden/ImageShader"
{
Properties
{
_MainTex ("Texture", 2D) = "white" {}
//_MainTexMip ("Texture", 2D) = "white" {}
//_RandTex("Texture", 2D) = "white" {}
//_FrameCount("framecount", Int) = 0;
//flipY("Flip Y", Float) = 0.;
//###ShaderUniforms
}
SubShader
{
// No culling or depth
Cull Off
//ZWrite Off
//ZTest Always
//Blend One One
//###RenderAttribs
Pass
{
CGPROGRAM
#pragma vertex vert
#pragma fragment frag
#include "UnityCG.cginc"
sampler2D _MainTex;
float4 _MainTex_TexelSize;
//sampler2D _RandTex;
//float4 _RandTex_TexelSize;
int _FrameCount;
float flipY;
//#define iChannel0 _MainTex
//#define iChannel1 _RandTex
//#define iChannel2 _MainTex
#include "glsl2Cg.cginc"
#include "shaderoo.cginc"
#define __UNITY3D__
#define SHADEROO
#define __SHADEROO_GEOM
// define this, so that frag only funcs are also compiled
#define SHADEROO_FRAGMENT_SHADER
#include "Image.cginc"
#undef SHADEROO_FRAGMENT_SHADER
struct appdata
{
float4 vertex : POSITION;
float2 uv : TEXCOORD0;
};
struct v2f
{
float2 uv : TEXCOORD0;
float4 vertex : SV_POSITION;
//float4 vertex : TEXCOORD4;
#ifdef SHADEROO_GEOM
float4 vertAttr0: TEXCOORD1;
float4 vertAttr1: TEXCOORD2;
float4 vertAttr2: TEXCOORD3;
#endif
};
v2f vert (appdata v)
{
v2f o;
#ifdef SHADEROO_GEOM
float4 vertAttr[3] = { float4(0,0,0,0), float4(0,0,0,0), float4(0,0,0,0) };
/*vertAttr[0]=float4(0,0,0,0);
vertAttr[1]=float4(0,0,0,0);
vertAttr[2]=float4(0,0,0,0);*/
int vIdx=int(v.vertex.x+.1);
mainGeom(o.vertex,vertAttr,vIdx);
o.vertAttr0=vertAttr[0];
o.vertAttr1=vertAttr[1];
o.vertAttr2=vertAttr[2];
#else
//o.vertex = UnityObjectToClipPos(float4(v.vertex.xyz, 1.0));
o.vertex = v.vertex;
o.vertex.xy=o.vertex.xy*2.-1.;
o.uv = v.uv;
#endif
return o;
}
fixed4 frag (v2f i) : SV_Target
{
float4 c;
#ifdef SHADEROO_GEOM
float4 vertAttr[3];
vertAttr[0]=i.vertAttr0;
vertAttr[1]=i.vertAttr1;
vertAttr[2]=i.vertAttr2;
//FIXME: is +.5 really needed?
mainFragment(c,i.vertex/*+vec4(.5,.5,0,0)*/,vertAttr);
//mainFragment(c,vec4((i.vertex.xy*.5+.5)*iResolution.xy,i.vertex.zw),vertAttr);
#else
//FIXME: is +.5 really needed?
vec2 res=(i.vertex.xy/*+.5*/)/i.uv.xy;
if(flipY>.5) i.uv.y=1.-i.uv.y;
//mainImage(c,i.uv*res.xy);
mainImage(c,i.uv*iResolution.xy);
//if(flipY>.5) i.vertex.y=1.-i.vertex.y;
//mainImage(c,i.vertex.xy+vec2(.5,.5));
#endif
return c;
}
ENDCG
}
}
}

@ -0,0 +1,9 @@
fileFormatVersion: 2
guid: 5ce624c6dda054e5ebc566562bf05751
ShaderImporter:
externalObjects: {}
defaultTextures: []
nonModifiableTextures: []
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,164 @@
// glsl -> Cg
// many things can be covered here, but...
// not possible by typedef or #define are:
// (at least not with the limited preprocess abilities of Cg)
//
// array initializers
// glsl: type arr[n] = type[](a,b,c,...);
// Cg: type arr[n] = {a,b,c,...}
//
// vec initializers with 1 arg:
// glsl: vec4(x)
// Cg: vec4i(x) (see helpers below - or float4(x,x,x,x))
//
// matrix multiplications
// glsl: m*v
// Cg: mul(m,v)
//
// matrix initializers (column first in glsl)
// glsl: mat4(a,b,c,...)
// Cg: transpose(mat4(a,b,c,...))
// (or dont transpose and use mulX(m,v) defined below)
//
// forget global variables (even const ones) - need to be defines in Cg
//
// in mainGeom(...) vertAttrib[] not initialized
// so either inout as argument, or actually init them in mainGeom()
//
float4 vec4i(float x) { return float4(x,x,x,x); }
float4 vec4i(float x, float3 v) { return float4(x,v.x,v.y,v.z); }
float4 vec4i(float3 v, float x) { return float4(v.x,v.y,v.z,x); }
float4 vec4i(float2 v1, float2 v2) { return float4(v1.x,v1.y,v2.x,v2.y); }
float4 vec4i(float2 v, float z, float w) { return float4(v.x,v.y,z,w); }
float4 vec4i(float x, float y, float2 v) { return float4(x,y,v.x,v.y); }
float4 vec4i(float x, float y, float z, float w) { return float4(x,y,z,w); }
float3 vec3i(float x) { return float3(x,x,x); }
float3 vec3i(float3 v) { return v; }
float3 vec3i(float2 v, float x) { return float3(v.x,v.y,x); }
float3 vec3i(float x, float2 v) { return float3(x,v.x,v.y); }
float3 vec3i(float x, float y, float z) { return float3(x,y,z); }
float2 vec2i(float2 v) { return v; }
float2 vec2i(float x) { return float2(x,x); }
float2 vec2i(float x, float y) { return float2(x,y); }
int2 ivec2i(float2 v) { return int2(v); }
int2 ivec2i(float x) { return int2(x,x); }
int3 ivec3i(float x) { return int3(x,x,x); }
int4 ivec4i(float x) { return int4(x,x,x,x); }
// use this for matrix multiplications (same as transpose(m)*v)
#define mulX(a,b) mul(b,a)
//float4 clamp(float4 v, float a, float b) { return clamp(v,float4(a,a,a,a),float4(b,b,b,b)); }
//float3 clamp(float3 v, float a, float b) { return clamp(v,float3(a,a,a),float3(b,b,b)); }
//float2 clamp(float2 v, float a, float b) { return clamp(v,float2(a,a),float2(b,b)); }
typedef float2 vec2;
typedef float3 vec3;
typedef float4 vec4;
typedef int4 ivec4;
typedef int3 ivec3;
typedef int2 ivec2;
typedef float4x4 mat4;
typedef float3x3 mat3;
typedef float2x2 mat2;
#define atan(a,b) atan2(a,b)
#define texture textureX
//#define texture(a,b) tex2D(a,b)
float4 textureX(sampler2D s, float2 uv, float bias) { return tex2Dbias(s,float4(uv,0,bias)); }
// use this instead of above when needed in vertex shader (bias makes no sense there!!!)
//float4 textureX(sampler2D s, float2 uv, float bias) { return tex2Dlod(s,float4(uv,0,bias)); }
float4 textureX(sampler2D s, float2 uv) { return tex2D(s,uv); }
//#define texture(a,b,c) tex2Dbias(a,float4(b,0,c))
#define textureLod(a,b,c) tex2Dlod(a,float4(b,0,c))
//#define textureLod(a,b,c) tex2D(a,b)
//#define texelFetch(a,b,c) tex2Dfetch(a,int4(b,0,c))
#define texelFetch(a,b,c) tex2Dlod(a,float4((float2(b)+.5)/float2(textureSize(a,0)),0,c))
//#define GET_VARARG_MACRO(_1,_2,_3,_4,NAME,...) NAME
//#define vec4(...) GET_VARARG_MACRO(__VA_ARGS__, vec4i, vec4i, vec4i, vec4i, vec4)(__VA_ARGS__)
//#define vec4 float4
//#define vec3 float3
//#define vec2 float2
//#define ivec4 int4
//#define ivec3 int3
//#define ivec2 int2
//#define mat4 float4x4
//#define mat3 float3x3
//#define mat2 float2x2
#define dFdx(x) ddx(x)
#define dFdy(x) ddy(x)
#define mix(a,b,c) lerp(a,b,c)
#define fract(a) frac(a)
#define mod(a,b) fmod(a,b)
#define textureSize(a,b) (a##_TexelSize.zw/(1<<b))
mat4 inverseX(mat4 m)
{
#define m00 m[0][0]
#define m01 m[0][1]
#define m02 m[0][2]
#define m03 m[0][3]
#define m10 m[1][0]
#define m11 m[1][1]
#define m12 m[1][2]
#define m13 m[1][3]
#define m20 m[2][0]
#define m21 m[2][1]
#define m22 m[2][2]
#define m23 m[2][3]
#define m30 m[3][0]
#define m31 m[3][1]
#define m32 m[3][2]
#define m33 m[3][3]
mat4 mi;
mi[0][0] = m12*m23*m31 - m13*m22*m31 + m13*m21*m32 - m11*m23*m32 - m12*m21*m33 + m11*m22*m33 ;
mi[0][1] = m03*m22*m31 - m02*m23*m31 - m03*m21*m32 + m01*m23*m32 + m02*m21*m33 - m01*m22*m33 ;
mi[0][2] = m02*m13*m31 - m03*m12*m31 + m03*m11*m32 - m01*m13*m32 - m02*m11*m33 + m01*m12*m33 ;
mi[0][3] = m03*m12*m21 - m02*m13*m21 - m03*m11*m22 + m01*m13*m22 + m02*m11*m23 - m01*m12*m23 ;
mi[1][0] = m13*m22*m30 - m12*m23*m30 - m13*m20*m32 + m10*m23*m32 + m12*m20*m33 - m10*m22*m33 ;
mi[1][1] = m02*m23*m30 - m03*m22*m30 + m03*m20*m32 - m00*m23*m32 - m02*m20*m33 + m00*m22*m33 ;
mi[1][2] = m03*m12*m30 - m02*m13*m30 - m03*m10*m32 + m00*m13*m32 + m02*m10*m33 - m00*m12*m33 ;
mi[1][3] = m02*m13*m20 - m03*m12*m20 + m03*m10*m22 - m00*m13*m22 - m02*m10*m23 + m00*m12*m23 ;
mi[2][0] = m11*m23*m30 - m13*m21*m30 + m13*m20*m31 - m10*m23*m31 - m11*m20*m33 + m10*m21*m33 ;
mi[2][1] = m03*m21*m30 - m01*m23*m30 - m03*m20*m31 + m00*m23*m31 + m01*m20*m33 - m00*m21*m33 ;
mi[2][2] = m01*m13*m30 - m03*m11*m30 + m03*m10*m31 - m00*m13*m31 - m01*m10*m33 + m00*m11*m33 ;
mi[2][3] = m03*m11*m20 - m01*m13*m20 - m03*m10*m21 + m00*m13*m21 + m01*m10*m23 - m00*m11*m23 ;
mi[3][0] = m12*m21*m30 - m11*m22*m30 - m12*m20*m31 + m10*m22*m31 + m11*m20*m32 - m10*m21*m32 ;
mi[3][1] = m01*m22*m30 - m02*m21*m30 + m02*m20*m31 - m00*m22*m31 - m01*m20*m32 + m00*m21*m32 ;
mi[3][2] = m02*m11*m30 - m01*m12*m30 - m02*m10*m31 + m00*m12*m31 + m01*m10*m32 - m00*m11*m32 ;
mi[3][3] = m01*m12*m20 - m02*m11*m20 + m02*m10*m21 - m00*m12*m21 - m01*m10*m22 + m00*m11*m22 ;
float det =
m03*m12*m21*m30 - m02*m13*m21*m30 - m03*m11*m22*m30 + m01*m13*m22*m30 +
m02*m11*m23*m30 - m01*m12*m23*m30 - m03*m12*m20*m31 + m02*m13*m20*m31 +
m03*m10*m22*m31 - m00*m13*m22*m31 - m02*m10*m23*m31 + m00*m12*m23*m31 +
m03*m11*m20*m32 - m01*m13*m20*m32 - m03*m10*m21*m32 + m00*m13*m21*m32 +
m01*m10*m23*m32 - m00*m11*m23*m32 - m02*m11*m20*m33 + m01*m12*m20*m33 +
m02*m10*m21*m33 - m00*m12*m21*m33 - m01*m10*m22*m33 + m00*m11*m22*m33 ;
return mi/det;
#undef m00
#undef m01
#undef m02
#undef m03
#undef m10
#undef m11
#undef m12
#undef m13
#undef m20
#undef m21
#undef m22
#undef m23
#undef m30
#undef m31
#undef m32
#undef m33
}
//#define smoothstep(a,b,c) step(.5*(a+b),c)

@ -0,0 +1,9 @@
fileFormatVersion: 2
guid: a2c852431fdc94af693307c96c9731a1
ShaderImporter:
externalObjects: {}
defaultTextures: []
nonModifiableTextures: []
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,22 @@
#define iTime (_Time.y)
#define iMouse float4(0,0,0,0)
#define iResolution float3(_ScreenParams.xy,0)
#define iFrame _FrameCount
#define iMouseData float4(0,0,0,0)
#define iCaptureGeom 0
sampler2D iChannel0;
sampler2D iChannel1;
sampler2D iChannel2;
sampler2D iChannel3;
sampler2D iChannel4;
sampler2D iChannel5;
sampler2D iChannel6;
sampler2D iChannel7;
float4 iChannel0_TexelSize;
float4 iChannel1_TexelSize;
float4 iChannel2_TexelSize;
float4 iChannel3_TexelSize;
float4 iChannel4_TexelSize;
float4 iChannel5_TexelSize;
float4 iChannel6_TexelSize;
float4 iChannel7_TexelSize;

@ -0,0 +1,9 @@
fileFormatVersion: 2
guid: b598943125188435bb8a65ce228dcdf6
ShaderImporter:
externalObjects: {}
defaultTextures: []
nonModifiableTextures: []
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: a8f69f4d05432b341b9c96775d9112ce
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 6ec76a54a5ad6b04b8ffba46cf5b5721
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,305 @@
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
namespace Flockaroo
{
[ExecuteInEditMode]
[RequireComponent(typeof (Camera))]
//[AddComponentMenu("Image Effects/Artistic/ColoredPencils")]
public class ColoredPencilsEffect : MonoBehaviour {
private Shader shader = null;
private Texture2D RandTex = null;
private Material mat = null;
[Header("Input/Output")]
[Tooltip("take a texture as input instead of the camera")]
public Texture inputTexture;
[Tooltip("render to a texture instead of the screen")]
public bool renderToTexture;
[Tooltip("texture being rendered to if above is checked")]
public RenderTexture outputTexture;
[Tooltip("generate mipmap for output texture")]
public bool outputMipmap;
[Header("Main faders")]
[Range(0.0f,1.0f)]
public float fade=0.0f;
[Range(0.0f,1.0f)]
public float panFade=0.0f;
[Header("Source")]
[Range(0.0f,2.0f)]
public float brightness=1.0f;
[Range(0.0f,2.0f)]
public float contrast=1.0f;
[Range(0.0f,2.0f)]
public float color=1.0f;
[Header("Effect")]
[Range(0,1)]
public int shaderMethod=0;
private int shaderMethodOld=0;
[Range(0.0f,2.0f)]
public float outlines=1.0f;
[Range(0.0f,2.0f)]
public float hatches=1.0f;
[Range(0.0f,2.0f)]
public float outlineError=1.0f;
[Range(0.0f,1.0f)]
public float flicker=0.3f;
[Range(0.0f,100.0f)]
public float flickerFreq=10.0f;
[Range(0.0f,1.0f)]
public float fixedHatchDir=0.0f;
[Range(0.7f,1.5f)]
public float hatchScale=1.0f;
[Range(0.001f,200.0f)]
public float hatchLength=10.0f;
[Range(0.0f,3.0f)]
public float mipLevel=0.0f;
private bool useMipmaps=false;
[Range(0.0f,1.0f)]
public float vignetting=1.0f;
[Range(0.0f,1.0f)]
public float contentVignetting=0.0f;
[Header("Background")]
public Color paperTint = new Color(1.0f,0.97f,0.85f);
[Range(0.0f,2.0f)]
public float paperRoughness = 1.0f;
public Texture2D paperTex = null;
[Header("Other")]
public bool flipY=false;
private RenderTexture rtmip = null;
private Mesh mesh;
private bool isShaderooGeom = false;
List<Mesh> meshes;
// Use this for initialization
/*protected Material mat
{
get
{
if (m_Material == null)
{
m_Material = new Material(shader);
m_Material.hideFlags = HideFlags.HideAndDontSave;
}
return m_Material;
}
}*/
void initShader()
{
if (shader == null)
{
if(shaderMethod==0)
shader = Resources.Load<Shader>("flockaroo_ColoredPencils/imageEffShader");
if(shaderMethod==1)
shader = Resources.Load<Shader>("flockaroo_ColoredPencils/imageEffShader1");
}
//if (shader == null)
// shader = Resources.Load<Shader>("Assets/pencil-effect/imageEffShader");
}
void initRandTex()
{
//if (RandTex == null)
// RandTex = Resources.Load<Texture2D>("rand256");
if (RandTex == null)
{
//RandTex = new Texture2D(256, 256, TextureFormat.RGBAFloat, true);
//RandTex = new Texture2D(256, 256, TextureFormat.RGBAHalf, true);
RandTex = new Texture2D(256, 256, TextureFormat.RGBA32, true);
for (int x = 0; x < RandTex.width; x++)
{
for (int y = 0; y < RandTex.height; y++)
{
float r = Random.Range(0.0f, 1.0f);
float g = Random.Range(0.0f, 1.0f);
float b = Random.Range(0.0f, 1.0f);
float a = Random.Range(0.0f, 1.0f);
RandTex.SetPixel(x, y, new Color(r, g, b, a) );
}
}
RandTex.Apply();
}
}
void initMipmapRenderTexture(RenderTexture src)
{
if(rtmip == null)
{
rtmip = new RenderTexture(src.width, src.height,0,RenderTextureFormat.ARGB32);
//rtmip = new RenderTexture(src);
rtmip.antiAliasing=1; // must be for mipmapping to work!!
rtmip.useMipMap=true;
#if UNITY_5_5_OR_NEWER
//rtmip.autoGenerateMips=false;
#endif
}
}
void Start () {
initShader();
initRandTex();
if (isShaderooGeom)
{
meshes = new List<Mesh>();
int trinum = 300000;
int maxMeshSize = 0x10000/3*3;
int mnum = (trinum*3+maxMeshSize-1)/maxMeshSize;
for(int j=0;j<mnum;j++)
{
mesh = new Mesh();
meshes.Add(mesh);
mesh.Clear();
//GetComponent<MeshFilter>().mesh = mesh;
int vnum = maxMeshSize;
Vector3[] verts = new Vector3 [vnum];
//Vector2[] uvs = new Vector2 [vnum];
int[] tris = new int [vnum];
for(int i=0;i<vnum;i++)
{
verts[i].x=i+j*maxMeshSize;
verts[i].y=1;
verts[i].z=2;
//uvs[i].x=i;
//uvs[i].y=0;
tris[i]=i;
}
mesh.vertices = verts;
//mesh.uv = uvs;
mesh.triangles = tris;
}
}
}
// Update is called once per frame
void Update () {
}
private void OnRenderImage(RenderTexture src, RenderTexture dest) {
RenderTexture mySrc=src;
if(inputTexture)
{
mySrc = new RenderTexture(inputTexture.width, inputTexture.height, 0, RenderTextureFormat.ARGBFloat);
Graphics.Blit(inputTexture, mySrc);
}
if(renderToTexture)
{
if(outputTexture==null
|| outputTexture.width!=mySrc.width
|| outputTexture.height!=mySrc.height)
{
outputTexture = new RenderTexture(mySrc.width, mySrc.height, 0, RenderTextureFormat.ARGBFloat);
if(outputMipmap)
{
outputTexture.antiAliasing=1; // must be for mipmapping to work!!
outputTexture.useMipMap=true;
outputTexture.filterMode=FilterMode.Trilinear;
}
}
}
else
outputTexture = null;
if(shaderMethodOld!=shaderMethod) { shader=null; mat=null; shaderMethodOld=shaderMethod; }
initShader();
initRandTex();
if (mat == null)
{
mat = new Material(shader);
mat.hideFlags = HideFlags.HideAndDontSave;
}
mat.SetTexture("_PaperTex", paperTex);
mat.SetTexture("_RandTex", RandTex);
mat.SetFloat("effectFade", fade);
mat.SetFloat("panFade", panFade);
mat.SetFloat("brightness", brightness);
mat.SetFloat("contrast", contrast);
mat.SetFloat("colorStrength", color);
mat.SetFloat("flicker", flicker);
mat.SetFloat("flickerFreq", flickerFreq);
mat.SetFloat("fixedHatchDir", fixedHatchDir);
mat.SetFloat("outlines", outlines);
mat.SetFloat("hatches", hatches);
mat.SetFloat("outlineRand", outlineError);
mat.SetFloat("vignetting", vignetting);
mat.SetFloat("contentWhiteVign", contentVignetting);
mat.SetFloat("hatchScale", hatchScale);
mat.SetFloat("hatchLen", hatchLength);
mat.SetFloat("mipLevel", mipLevel);
mat.SetFloat("flipY", flipY?1.0f:0.0f);
mat.SetColor("paperTint", paperTint);
mat.SetFloat("paperRough", paperRoughness);
mat.SetFloat("paperTexFade", (paperTex==null)?0.0f:1.0f);
mat.SetInt("_FrameCount", Time.frameCount);
useMipmaps=(mipLevel>0.0001f);
if (useMipmaps)
{
initMipmapRenderTexture(mySrc);
Graphics.Blit(mySrc, rtmip);
#if UNITY_5_5_OR_NEWER
//rtmip.GenerateMips();
#endif
Graphics.SetRenderTarget(dest);
mat.SetTexture("_MainTex", rtmip);
Graphics.Blit(rtmip, dest, mat);
//rtmip.filterMode = FilterMode.Trilinear;
}
else
{
mat.SetTexture("_MainTex", src);
if(isShaderooGeom)
{
//initMipmapRenderTexture(src);
Graphics.Blit(src, dest);
//Graphics.SetRenderTarget(rtmip);
//rtmip.DiscardContents(true,true);
//Graphics.SetRenderTarget(dest);
mat.SetPass(0);
foreach(Mesh mesh in meshes)
{
Graphics.DrawMeshNow(mesh, Vector3.zero, Quaternion.identity);
}
//rtmip.GenerateMips();
//Graphics.SetRenderTarget(dest);
//Graphics.Blit(rtmip, dest);
}
else
{
if(outputTexture)
{
Graphics.Blit(mySrc, outputTexture, mat);
// default blit of screen - no effect
Graphics.Blit(src, dest);
}
else
Graphics.Blit(mySrc, dest, mat);
}
}
}
/*public void OnPostRender() {
if (mat == null)
{
mat = new Material(shader);
mat.hideFlags = HideFlags.HideAndDontSave;
}
mat.SetPass(0);
Graphics.DrawMeshNow(mesh, Vector3.zero, Quaternion.identity);
}*/
}
}

@ -0,0 +1,12 @@
fileFormatVersion: 2
guid: 79621082da8ba124eba3da9eba119a06
timeCreated: 1529867923
licenseType: Store
MonoImporter:
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

Binary file not shown.

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: b242660a58802d04cb1102491d84a2b9
timeCreated: 1531243294
licenseType: Store
DefaultImporter:
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,70 @@
# Colored Pencils - Unity3D Image Effect
#### (c) 2018 by [flockaroo](http://www.flockaroo.at) (Florian Berger) - email: <flockaroo@gmail.com>
******
### How to use
Select your camera node and then simply add "ColoredPencilsEffect" script to camera components (can be found in Assets/flockaroo/ColoredPencils/).
You can drag/drop it to there or choose it from the menu (Component/Scripts/Flockaroo/ColoredPencils).
![How to use - Image](/unityprj/Unity_ColoredPencils/Assets/flockaroo/ColoredPencils/howto.png){ width="100%" }
__Warning!!__ The subfolder "flockaroo_[effect name]" in "Resources" is needed by the effect script for unique identification of files and should not be removed or renamed.
<div style="page-break-after: always;"></div>
### Parameters
The shader provides the following parameters:
#### Input/Output
| Parameter | function
|-----------------|--------------
| Input Texture | take this texture as input instead of the camera
| Render To Texture | render to texture instead of screen
| Output Texture | texture being rendered to if above is checked
| Output Mipmap | generate mipmap for output texture
#### Main faders
| Parameter | function
|-----------------|--------------
| Fade | 0 = effect image ... 1 = original content
| Pan Fade | 0 = effect image ... 1 = original content - pan from left to right
#### Source
| Parameter | function
|-----------------|--------------
| Brightness | adjust brightness of the content before applying the effect
| Contrast | adjust contrast of the content before applying the effect
| Color | the color intensity of the effect
#### Effect
| Parameter | function
|-----------------|--------------
| Shader Method | 0 = original shader <br> 1 = newer version (faster, other color scheme)
| Outlines | strength of the pencil outlines
| Hatches | strength of the pencil hatches
| Outline Error | drawing-error of the pencil outlines
| Flicker | activates a flicker effect on cross-hatches and outlines
| Flicker Freq | flicker frequency in Hz
| Fixed Hatch Dir | makes crosshatches all parallel and content independent
| Hatch Scale | scale of the hatch strokes (line thickness)
| Hatch Length | length of the hatch strokes
| Mip Level | affects the detail of the strokes, and slightly disorients the strokes direction close to color jumps (only works properly for Unity versions higher than 5.5)
| Vignetting | darkening the window border
| Content Vignetting | fade content to white paper on border
<div style="page-break-after: always;"></div>
#### Background
| Parameter | function
|-----------------|--------------
| Paper Tint | color of the paper being drawn on
| Paper Roughness | roughness of paper surface
| Paper Texture | custom paper texture (background)
#### Other
| Parameter | function
|-----------------|--------------
| Flip Y | image Y flip

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 16a5051bb3c65104dbd623d3dfdaceb3
timeCreated: 1531243306
licenseType: Store
TextScriptImporter:
userData:
assetBundleName:
assetBundleVariant:

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 MiB

@ -0,0 +1,55 @@
fileFormatVersion: 2
guid: f5c5571ab67843044b2f0e774146b2ae
timeCreated: 1531243301
licenseType: Store
TextureImporter:
fileIDToRecycleName: {}
serializedVersion: 2
mipmaps:
mipMapMode: 0
enableMipMap: 1
linearTexture: 0
correctGamma: 0
fadeOut: 0
borderMipMap: 0
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: .25
normalMapFilter: 0
isReadable: 0
grayScaleToAlpha: 0
generateCubemap: 0
cubemapConvolution: 0
cubemapConvolutionSteps: 8
cubemapConvolutionExponent: 1.5
seamlessCubemap: 0
textureFormat: -1
maxTextureSize: 2048
textureSettings:
filterMode: -1
aniso: -1
mipBias: -1
wrapMode: -1
nPOTScale: 1
lightmap: 0
rGBM: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: .5, y: .5}
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spritePixelsToUnits: 100
alphaIsTransparency: 0
textureType: -1
buildTargetSettings: []
spriteSheet:
sprites: []
spritePackingTag:
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 5912791aaab07984ea2513ca03d988aa
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,421 @@
using System.Collections;
using System.Collections.Generic;
using System.Text.RegularExpressions;
using UnityEngine;
namespace Flockaroo
{
[ExecuteInEditMode]
[RequireComponent(typeof (Camera))]
//[AddComponentMenu("Image Effects/Artistic/OilPainting")]
public class OilPaintingEffect : MonoBehaviour {
List <string> bufferOrder = new List <string>();
Dictionary<string, RenderTexture> buffers = new Dictionary<string, RenderTexture>();
Dictionary<string, Material> shaders = new Dictionary<string, Material>();
Dictionary<string, Texture> textures = new Dictionary<string, Texture>();
Dictionary<string, Dictionary <int,string>> textureCh = new Dictionary<string, Dictionary <int,string>>();
Dictionary<string, Dictionary <int,bool>> textureDemandsMip = new Dictionary<string, Dictionary <int,bool>>();
Dictionary<string, List<Mesh>> meshes = new Dictionary<string, List<Mesh>>();
RenderTexture mainTex = null;
RenderTexture mainMip = null;
Regex refRegex = new Regex(@"Ref:([^:]+):Tex([0-9]+)");
private int actWidth=0;
private int actHeight=0;
private int NumTriangles=0;
//FIXME: automate useMipOnMain - activate when needed
private bool useMipOnMain = false;
[Header("Input/Output")]
[Tooltip("take a texture as input instead of the camera")]
public Texture inputTexture;
[Tooltip("render to a texture instead of the screen")]
public bool renderToTexture;
[Tooltip("texture being rendered to if above is checked")]
public RenderTexture outputTexture;
[Tooltip("generate mipmap for output texture")]
public bool outputMipmap;
[Header("Common")]
[Range(0.0f,1.0f)]
public float EffectFade = 0.0f;
[Range(0.0f,1.0f)]
public float PanFade = 0.0f;
[Header("Source")]
[Range(0.0f,2.0f)]
public float SrcBright = 1.0f;
[Range(0.0f,2.0f)]
public float SrcContrast = 1.4f;
[Range(0.0f,4.0f)]
public float SrcColor = 1.0f;
[Range(0.0f,1.0f)]
public float SrcBlur = 0.0f;
[Header("Effect")]
[Range(0.0f,1.0f)]
public float BrushDetail = 0.1f;
[Range(0.0f,1.0f)]
public float BrushFill = 0.5f;
[Range(5000,200000)]
public int NumStrokes=0x8000;
[Range(0.5f,0.95f)]
public float LayerScale = 0.8f;
[Range(0.0f,1.0f)]
public float Canvas = 0.4f;
[Range(0.0f,100.0f)]
public float FlickerFreq = 15.0f;
[Range(0.0f,1.0f)]
public float FlickerStrength = 0.0f;
[Range(0.0f,360.0f)]
public float LightAng = 135.0f;
[Range(0.0f,90.0f)]
public float LightOffs = 60.0f;
[Range(0.0f,1.0f)]
public float PaintDiff = 0.15f;
[Range(0.0f,1.0f)]
public float PaintSpec = 0.15f;
[Range(0.0f,1.0f)]
public float PaintShiny = 0.5f;
[Range(0.0f,2.0f)]
public float ColorSpread = 0.0f;
[Range(0.0f,120.0f)]
public float ScreenFOV = 0.0f;
[Range(0.0f,360.0f)]
public float StrokeAng = 0.0f;
[Range(-1.0f,1.0f)]
public float StrokeBend = -1.0f;
[Range(0.0f,1.0f)]
public float StrokeDir = 0.0f;
[Range(0.0f,1.0f)]
public float StrokeContour = 1.0f;
[Range(0.0f,16.0f)]
public float MultiStroke = 6.0f;
[Range(0.0f,100000.0f)]
public float strokeSeed = 10.0f;
[Range(0.0f,1.0f)]
public float Vignette = 1.0f;
[Range(0.0f,1.0f)]
public float CanvasBg = 0.5f;
public Color CanvasTint = new Color(1.0f,0.97f,0.85f);
//###PublicVars
[Header("Other")]
public bool flipY=false;
public bool geomFlipY=false;
Material createShader(string resname)
{
Shader shader = Resources.Load<Shader>(resname);
Material mat = new Material(shader);
mat.hideFlags = HideFlags.HideAndDontSave;
return mat;
}
RenderTexture createRenderTex(int w = -1, int h = -1, bool mip = false, int aa = 1)
{
RenderTexture rt;
//if(w==-1) w=Screen.width;
//if(h==-1) h=Screen.height;
if(w==-1) w=actWidth;
if(h==-1) h=actHeight;
rt = new RenderTexture(w, h,0,RenderTextureFormat.ARGBFloat);
rt.antiAliasing=aa; // must be 1 for mipmapping to work!!
rt.useMipMap=mip;
if(mip)
rt.filterMode=FilterMode.Trilinear;
return rt;
}
Texture2D createRandTex(int w, int h)
{
//if (RandTex == null)
// RandTex = Resources.Load<Texture2D>("rand256");
Texture2D RandTex;
{
RandTex = new Texture2D(w, h, TextureFormat.RGBAFloat, true);
//RandTex = new Texture2D(w, h, TextureFormat.RGBAHalf, true);
//RandTex = new Texture2D(w, h, TextureFormat.RGBA32, true);
for (int x = 0; x < RandTex.width; x++)
{
for (int y = 0; y < RandTex.height; y++)
{
float r = Random.Range(0.0f, 1.0f);
float g = Random.Range(0.0f, 1.0f);
float b = Random.Range(0.0f, 1.0f);
float a = Random.Range(0.0f, 1.0f);
RandTex.SetPixel(x, y, new Color(r, g, b, a) );
}
}
RandTex.Apply();
}
RandTex.filterMode=FilterMode.Trilinear;
return RandTex;
}
List<Mesh> createMesh(int trinum = 0x10000)
{
List<Mesh> meshes = new List<Mesh>();
int maxMeshSize = 0x10000/3*3;
int mnum = (trinum*3+maxMeshSize-1)/maxMeshSize;
for(int j=0;j<mnum;j++)
{
Mesh mesh = new Mesh();
meshes.Add(mesh);
mesh.Clear();
int vnum = maxMeshSize;
Vector3[] verts = new Vector3 [vnum];
int[] tris = new int [vnum];
for(int i=0;i<vnum;i++)
{
verts[i].x=i+j*maxMeshSize;
verts[i].y=1;
verts[i].z=2;
tris[i]=i;
}
mesh.vertices = verts;
mesh.triangles = tris;
}
return meshes;
}
void initMainMipmapRenderTexture(RenderTexture src)
{
if(mainMip == null)
{
mainMip = new RenderTexture(src.width, src.height,0,RenderTextureFormat.ARGB32);
mainMip.antiAliasing=1; // must be for mipmapping to work!!
mainMip.useMipMap=true;
mainMip.filterMode=FilterMode.Trilinear;
#if UNITY_5_5_OR_NEWER
//rtmip.autoGenerateMips=false;
#endif
}
}
void initAll(int width, int height)
{
if(renderToTexture)
{
outputTexture = new RenderTexture(width, height, 0, RenderTextureFormat.ARGBFloat);
if(outputMipmap)
{
outputTexture.antiAliasing=1; // must be for mipmapping to work!!
outputTexture.useMipMap=true;
outputTexture.filterMode=FilterMode.Trilinear;
}
}
else
outputTexture = null;
actWidth=width;
actHeight=height;
bufferOrder.Clear();
textureCh.Clear();
buffers.Clear();
shaders.Clear();
meshes.Clear();
if(!textures.ContainsKey("rand256")) textures["rand256"] = createRandTex(256,256);
if(!textures.ContainsKey("rand64")) textures["rand64"] = createRandTex(64,64);
bufferOrder.Add("Buff_A");
buffers["Buff_A"] = createRenderTex();
textureCh["Buff_A"] = new Dictionary <int,string> ();
textureDemandsMip["Buff_A"] = new Dictionary <int,bool> ();
shaders["Buff_A"] = createShader("flockaroo_OilPainting/Buff_A");
textureCh["Buff_A"][0] = "none";
textureCh["Buff_A"][1] = "rand256";
textureCh["Buff_A"][2] = "Buff_A";
buffers["Buff_A"].width=512;
buffers["Buff_A"].height=512;
buffers["Buff_A"].useMipMap=true;
buffers["Buff_A"].filterMode=FilterMode.Trilinear;
bufferOrder.Add("Geom_A");
buffers["Geom_A"] = createRenderTex();
buffers["Geom_A"].depth = 24;
textureCh["Geom_A"] = new Dictionary <int,string> ();
textureDemandsMip["Geom_A"] = new Dictionary <int,bool> ();
shaders["Geom_A"] = createShader("flockaroo_OilPainting/Geom_A");
meshes["Geom_A"] = createMesh(NumStrokes*2);
NumTriangles=NumStrokes*2;
textureCh["Geom_A"][0] = "https://ak1.picdn.net/shutterstock/videos/15325111/preview/stock-footage-beautiful-young-woman-enjoying-her-vacation-on-santorini-happy-tourist-is-wearing-sunhat.webm";
textureCh["Geom_A"][1] = "rand256";
textureCh["Geom_A"][2] = "Buff_A";
textureDemandsMip["Geom_A"][0]=true;
bufferOrder.Add("Image");
buffers["Image"] = createRenderTex();
textureCh["Image"] = new Dictionary <int,string> ();
textureDemandsMip["Image"] = new Dictionary <int,bool> ();
shaders["Image"] = createShader("flockaroo_OilPainting/Image");
textureCh["Image"][0] = "Geom_A";
textureCh["Image"][1] = "rand256";
textureCh["Image"][2] = "Buff_A";
textureCh["Image"][3] = "https://ak1.picdn.net/shutterstock/videos/15325111/preview/stock-footage-beautiful-young-woman-enjoying-her-vacation-on-santorini-happy-tourist-is-wearing-sunhat.webm";
//###InitMarker
}
void Start () {
//initAll(Screen.width,Screen.height);
}
// Update is called once per frame
void Update () {
}
Texture getTexture(string name)
{
if(name.StartsWith("Ref:")) {
Match match = refRegex.Match(name);
if (match.Success)
{
string buff = match.Groups[1].Value;
int chan = int.Parse(match.Groups[2].Value);
return getTexture(textureCh[buff][chan]);
}
return null;
}
if(buffers.ContainsKey(name)) return buffers[name];
if(textures.ContainsKey(name)) return textures[name];
if(name.EndsWith(".mp4")) return mainTex;
if(name.EndsWith(".webm")) return mainTex;
return mainTex;
// FIXME: alloc textures if not present
//return textures["rand256"];
}
private void OnRenderImage(RenderTexture src, RenderTexture dest) {
mainTex=src;
bool reinit=false;
if(inputTexture)
{
mainTex = new RenderTexture(inputTexture.width, inputTexture.height, 0, RenderTextureFormat.ARGBFloat);
Graphics.Blit(inputTexture, mainTex);
}
if (renderToTexture && outputTexture==null) { reinit=true; }
if (!renderToTexture && outputTexture!=null) { reinit=true; }
if( mainTex.width!=actWidth || mainTex.height!=actHeight || reinit )
{
Debug.Log("OilPainting 1st init (or Resolution changed)");
initAll(mainTex.width,mainTex.height);
}
if(NumTriangles!=NumStrokes*2)
{
meshes["Geom_A"] = createMesh(NumStrokes*2);
NumTriangles=NumStrokes*2;
}
if(useMipOnMain)
{
initMainMipmapRenderTexture(mainTex);
Graphics.Blit(mainTex, mainMip);
mainTex = mainMip;
}
foreach( string buffName in bufferOrder )
{
Material mat = null;
if(shaders.ContainsKey(buffName)) mat = shaders[buffName];
if(mat==null) { continue; }
mat.SetFloat("geomFlipY", geomFlipY?1.0f:0.0f);
mat.SetFloat("flipY", flipY?1.0f:0.0f);
mat.SetInt("_FrameCount", Time.frameCount);
mat.SetFloat("BrushDetail",(BrushDetail*0.8f+0.2f)*(BrushDetail*0.8f+0.2f));
mat.SetFloat("BrushSize",BrushFill*2.0f+0.25f);
mat.SetFloat("Canvas",Canvas);
mat.SetFloat("EffectFade",EffectFade);
mat.SetFloat("FlickerFreq",FlickerFreq);
mat.SetFloat("FlickerStrength",FlickerStrength);
mat.SetFloat("halfFOV",ScreenFOV/180.0f*3.14159265359f*0.5f);
mat.SetFloat("LayerScale",LayerScale);
mat.SetFloat("LightAng",LightAng/180.0f*3.14159265359f);
mat.SetFloat("LightOffs",LightOffs/180.0f*3.14159265359f);
mat.SetFloat("NumTriangles",NumStrokes*2);
mat.SetFloat("PaintDiff",PaintDiff);
mat.SetFloat("PaintSpec",PaintSpec);
mat.SetFloat("PaintShiny",PaintShiny);
mat.SetFloat("PanFade",PanFade);
mat.SetFloat("SrcBlur",SrcBlur);
mat.SetFloat("SrcBright",SrcBright);
mat.SetFloat("SrcContrast",SrcContrast);
mat.SetFloat("SrcColor",SrcColor);
mat.SetFloat("ColorSpread",ColorSpread);
mat.SetFloat("StrokeAng",StrokeAng/180.0f*3.14159265359f);
mat.SetFloat("StrokeBend",StrokeBend);
mat.SetFloat("StrokeContour",StrokeContour);
mat.SetFloat("StrokeDir",StrokeDir);
mat.SetVector("strokeNumXY",new Vector4(MultiStroke,MultiStroke,0.0f,0.0f));
mat.SetFloat("strokeSeed",strokeSeed);
mat.SetFloat("Vignette",Vignette);
mat.SetColor("CanvasTint", CanvasTint);
mat.SetFloat("CanvasBg", CanvasBg);
//###MatParams
for(int i=0;i<8;i++)
{
if(textureCh.ContainsKey(buffName) &&
textureCh[buffName].ContainsKey(i))
{
Texture tex = getTexture(textureCh[buffName][i]);
if(mat!=null) mat.SetTexture("iChannel"+i, tex);
if(textureDemandsMip.ContainsKey(buffName) &&
textureDemandsMip[buffName].ContainsKey(i) &&
textureDemandsMip[buffName][i])
{
if(tex==mainTex) useMipOnMain=true;
else if(tex is RenderTexture) ((RenderTexture)tex).useMipMap=true;
}
}
}
if(meshes.ContainsKey(buffName))
{
Graphics.SetRenderTarget(buffers[buffName]);
GL.Clear(true, true, Color.clear);
if(mat!=null) mat.SetPass(0);
foreach(Mesh mesh in meshes[buffName])
{
Graphics.DrawMeshNow(mesh, Vector3.zero, Quaternion.identity);
}
}
else
{
if(buffName=="Image")
{
if(mat!=null)
if(outputTexture)
{
Graphics.Blit(mainTex, outputTexture, mat);
// default blit of screen - no effect
Graphics.Blit(src, dest);
}
else
Graphics.Blit(mainTex, dest, mat);
}
else
{
if(mat!=null) Graphics.Blit(mainTex, buffers[buffName], mat);
}
}
}
}
/*public void OnPostRender() {
}*/
}
}

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 91a9cabf19a634d2fac557d213b89a59
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,97 @@
# Oil Painting - Unity3D Image Effect
#### (c) 2018 by [flockaroo](http://www.flockaroo.at) (Florian Berger) - email: <flockaroo@gmail.com>
******
### How to use
Select your camera node and then simply add "OilPaintingEffect" script to camera components (can be found in Assets/flockaroo/OilPainting/).
You can drag/drop it to there or choose it from the menu (Component/Scripts/Flockaroo/OilPainting).
![How to use - Image](/home/floh/floh/projects/unity/Unity_OilPainting/Assets/flockaroo/OilPainting/howto.png){ width="100%" }
__Warning!!__ The subfolder "flockaroo_[effect name]" in "Resources" is needed by the effect script for unique identification of files and should not be removed or renamed.
<div style="page-break-after: always;"></div>
### Parameters
The shader provides the following parameters:
#### Input/Output
| Parameter | function
|-----------------|--------------
| Input Texture | take this texture as input instead of the camera
| Render To Texture | render to texture instead of screen
| Output Texture | texture being rendered to if above is checked
| Output Mipmap | generate mipmap for output texture
#### Main faders
| Parameter | function
|-----------------|--------------
| Effect Fade | 0 = effect image ... 1 = original content
| Pan Fade | 0 = effect image ... 1 = original content - pan from left to right
#### Source
| Parameter | function
|-----------------|--------------
| Src Bright | adjust brightness of the content before applying the effect
| Src Contrast | adjust contrast of the content before applying the effect
| Src Color | adjust color intensity of the content before applying the effect
| Src Blur | blur the content before applying effect (only works from Unity-5.5 upwards)
<!-- | Src Color | the color intensity of the effect-->
#### Effect
| Parameter | function
|-----------------|--------------
| Brush Detail | detail of the brush strokes
| Brush Fill | how much the brush strokes fill the screen area
| Num Strokes | number of strokes to be drawn
| LayerScale | lower number gives less different scales of strokes
| Canvas | roughness of canvas (bumpyness in the brush strokes)
| Flicker Freq | controls the frequency of the flickering (flickers/sec)
| Flicker Strength| makes the stroke position vary from frame to frame
| Light Ang | angle of light in screen plane [degrees] 0..360
| Light Offs | angle of light to screen plane normal [degrees] 0..90
| Paint Diff | diffuse lighting of paint strokes
| Paint Spec | specular reflections of paint strokes
| Paint Shiny | shininess of paint strokes
| Color Spread | adds some color variance between different strokes
| Screen FOV | field of view of screen in degrees (affects specular reflection)
| Stroke Ang | rotate strokes relative to gradient (e.g. 90 degree gives a very fuzzy look)
| Stroke Bend | -1.0 bend towards dark content, +1.0 bend towards bright content (e.g. for clouds)
| Stroke Dir | swaps front and back of stroke while maintaining its curve
| Stroke Contour | harder contour of strokes - gives a slight color blob at the start of the stroke
| Multi Stroke | if you enter 6 here you get 6*6 = 36 different strokes
| Stroke Seed | seed for randomly generated strokes
| Vignette | darkening the window border
| Canvas Bg | strength of background canvas pattern
| Canvas Tint | color tint of background
##### Some Hints:
Lower Values of "Brush Fill", "Brush Detail", "Layer Scale" and "Num Strokes" give a sketchier look. <br>
A negative "Stroke Bend" would be best for images with clouds (bending the white strokes around the cloud shape),
whereas a positive value is more usful if you have dark ojects painted on a bright background. <br>
A "Screen FOV" of makes a specular with contant light/eye angles, as if viewer and light are far away from the image.
the bigger you make this angle the more you get a localized hilight on the image plane. <br>
If "Multi Stroke" is 0 or 1 then all strokes look the same (apart from their size), if on very plain areas the similarity is too obvious to the eye you can use bigger values so you get a diversity of different stroke shapes.<br>
<!--<div style="page-break-after: always;"></div>-->
#### Other
| Parameter | function
|-----------------|--------------
| Flip Y | image Y flip
| Geom Flip Y | Y-flip of effect-internal geometry (use this if "Effect Fade" and "Pan Fade" wont work properly)
##### concerning "Flip Y" and "Geom Flip Y":
The screen coordinates of unity are a bit mysterious. even more when working on different platforms. The Y-coordinate seems to be flipped between versions even on the same system, and also flipped depending on the system.
So for "Flip Y" and "Geom Flip Y" follow these rules:
If you have the source ("Effect Fade" to 1) flipped and the effect correct, just check "Geom Flip Y".
If you have the source correct and the effect flipped, check both "Geom Flip Y" and "Flip Y".
If both are equally flipped just check "Flip Y".

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 469f9859058084e1ebd8b6aecd11632e
TextScriptImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

Binary file not shown.

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 7e900392d8b7149818271f0970952727
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

Binary file not shown.

After

Width:  |  Height:  |  Size: 567 KiB

@ -0,0 +1,88 @@
fileFormatVersion: 2
guid: 053a9dbef784240a89a1492e08ba2ab9
TextureImporter:
fileIDToRecycleName: {}
externalObjects: {}
serializedVersion: 7
mipmaps:
mipMapMode: 0
enableMipMap: 1
sRGBTexture: 1
linearTexture: 0
fadeOut: 0
borderMipMap: 0
mipMapsPreserveCoverage: 0
alphaTestReferenceValue: 0.5
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: 0.25
normalMapFilter: 0
isReadable: 0
streamingMipmaps: 0
streamingMipmapsPriority: 0
grayScaleToAlpha: 0
generateCubemap: 6
cubemapConvolution: 0
seamlessCubemap: 0
textureFormat: 1
maxTextureSize: 2048
textureSettings:
serializedVersion: 2
filterMode: -1
aniso: -1
mipBias: -100
wrapU: -1
wrapV: -1
wrapW: -1
nPOTScale: 1
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: 0.5, y: 0.5}
spritePixelsToUnits: 100
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spriteGenerateFallbackPhysicsShape: 1
alphaUsage: 1
alphaIsTransparency: 0
spriteTessellationDetail: -1
textureType: 0
textureShape: 1
singleChannelComponent: 0
maxTextureSizeSet: 0
compressionQualitySet: 0
textureFormatSet: 0
platformSettings:
- serializedVersion: 2
buildTarget: DefaultTexturePlatform
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
androidETC2FallbackOverride: 0
spriteSheet:
serializedVersion: 2
sprites: []
outline: []
physicsShape: []
bones: []
spriteID:
vertices: []
indices:
edges: []
weights: []
spritePackingTag:
pSDRemoveMatte: 0
pSDShowRemoveMatteOption: 0
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,12 @@
{
"name": "UltraCombos.Flockaroo.Runtime",
"references": [],
"optionalUnityReferences": [],
"includePlatforms": [],
"excludePlatforms": [],
"allowUnsafeCode": false,
"overrideReferences": false,
"precompiledReferences": [],
"autoReferenced": true,
"defineConstraints": []
}

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: b7367eeab1c7d8c49ba5a96fa8ab3fe8
AssemblyDefinitionImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 1303dfdfb632cb94d89824ec7f131b4f
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: d9c31e70baf74a3438577ce5c2fa410f
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,9 @@
fileFormatVersion: 2
guid: f8424cdf21e5e4743aef8887ff6da914
folderAsset: yes
timeCreated: 1531243294
licenseType: Store
DefaultImporter:
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,607 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!29 &1
SceneSettings:
m_ObjectHideFlags: 0
m_PVSData:
m_PVSObjectsArray: []
m_PVSPortalsArray: []
m_OcclusionBakeSettings:
smallestOccluder: 5
smallestHole: .25
backfaceThreshold: 100
--- !u!104 &2
RenderSettings:
m_ObjectHideFlags: 0
serializedVersion: 6
m_Fog: 0
m_FogColor: {r: .5, g: .5, b: .5, a: 1}
m_FogMode: 3
m_FogDensity: .00999999978
m_LinearFogStart: 0
m_LinearFogEnd: 300
m_AmbientSkyColor: {r: .211999997, g: .226999998, b: .259000003, a: 1}
m_AmbientEquatorColor: {r: .114, g: .125, b: .133000001, a: 1}
m_AmbientGroundColor: {r: .0469999984, g: .0430000015, b: .0350000001, a: 1}
m_AmbientIntensity: 1
m_AmbientMode: 0
m_SkyboxMaterial: {fileID: 10304, guid: 0000000000000000f000000000000000, type: 0}
m_HaloStrength: .5
m_FlareStrength: 1
m_FlareFadeSpeed: 3
m_HaloTexture: {fileID: 0}
m_SpotCookie: {fileID: 10001, guid: 0000000000000000e000000000000000, type: 0}
m_DefaultReflectionMode: 0
m_DefaultReflectionResolution: 128
m_ReflectionBounces: 1
m_ReflectionIntensity: 1
m_CustomReflection: {fileID: 0}
m_Sun: {fileID: 0}
--- !u!127 &3
LevelGameManager:
m_ObjectHideFlags: 0
--- !u!157 &4
LightmapSettings:
m_ObjectHideFlags: 0
serializedVersion: 5
m_GIWorkflowMode: 0
m_LightmapsMode: 1
m_GISettings:
serializedVersion: 2
m_BounceScale: 1
m_IndirectOutputScale: 1
m_AlbedoBoost: 1
m_TemporalCoherenceThreshold: 1
m_EnvironmentLightingMode: 0
m_EnableBakedLightmaps: 1
m_EnableRealtimeLightmaps: 1
m_LightmapEditorSettings:
serializedVersion: 3
m_Resolution: 2
m_BakeResolution: 40
m_TextureWidth: 1024
m_TextureHeight: 1024
m_AOMaxDistance: 1
m_Padding: 2
m_CompAOExponent: 0
m_LightmapParameters: {fileID: 0}
m_TextureCompression: 1
m_FinalGather: 0
m_FinalGatherRayCount: 1024
m_LightmapSnapshot: {fileID: 0}
m_RuntimeCPUUsage: 25
--- !u!196 &5
NavMeshSettings:
serializedVersion: 2
m_ObjectHideFlags: 0
m_BuildSettings:
serializedVersion: 2
agentRadius: .5
agentHeight: 2
agentSlope: 45
agentClimb: .400000006
ledgeDropHeight: 0
maxJumpAcrossDistance: 0
accuratePlacement: 0
minRegionArea: 2
cellSize: .166666672
manualCellSize: 0
m_NavMeshData: {fileID: 0}
--- !u!1 &124582537
GameObject:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
serializedVersion: 4
m_Component:
- 4: {fileID: 124582538}
- 33: {fileID: 124582541}
- 136: {fileID: 124582540}
- 23: {fileID: 124582539}
m_Layer: 0
m_Name: Capsule
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &124582538
Transform:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 124582537}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 3.31999993, y: 2.78999996, z: 3.17000008}
m_LocalScale: {x: 1.9904418, y: 1.99044204, z: 1.99044204}
m_Children: []
m_Father: {fileID: 556234651}
m_RootOrder: 3
--- !u!23 &124582539
MeshRenderer:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 124582537}
m_Enabled: 1
m_CastShadows: 1
m_ReceiveShadows: 1
m_Materials:
- {fileID: 2100000, guid: 9a131ad318d1c864f877dca7c51047c2, type: 2}
m_SubsetIndices:
m_StaticBatchRoot: {fileID: 0}
m_UseLightProbes: 1
m_ReflectionProbeUsage: 1
m_ProbeAnchor: {fileID: 0}
m_ScaleInLightmap: 1
m_PreserveUVs: 1
m_ImportantGI: 0
m_AutoUVMaxDistance: .5
m_AutoUVMaxAngle: 89
m_LightmapParameters: {fileID: 0}
m_SortingLayerID: 0
m_SortingOrder: 0
--- !u!136 &124582540
CapsuleCollider:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 124582537}
m_Material: {fileID: 0}
m_IsTrigger: 0
m_Enabled: 1
m_Radius: .5
m_Height: 2
m_Direction: 1
m_Center: {x: 0, y: 0, z: 0}
--- !u!33 &124582541
MeshFilter:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 124582537}
m_Mesh: {fileID: 10208, guid: 0000000000000000e000000000000000, type: 0}
--- !u!1 &261853471
GameObject:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
serializedVersion: 4
m_Component:
- 4: {fileID: 261853472}
- 33: {fileID: 261853475}
- 135: {fileID: 261853474}
- 23: {fileID: 261853473}
m_Layer: 0
m_Name: Sphere
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &261853472
Transform:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 261853471}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: .150000006, y: 2.67000008, z: -4.11999989}
m_LocalScale: {x: 1.88985467, y: 1.88985395, z: 1.88985395}
m_Children: []
m_Father: {fileID: 556234651}
m_RootOrder: 2
--- !u!23 &261853473
MeshRenderer:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 261853471}
m_Enabled: 1
m_CastShadows: 1
m_ReceiveShadows: 1
m_Materials:
- {fileID: 2100000, guid: 4074049c4e7e1984689e60e030adf2c7, type: 2}
m_SubsetIndices:
m_StaticBatchRoot: {fileID: 0}
m_UseLightProbes: 1
m_ReflectionProbeUsage: 1
m_ProbeAnchor: {fileID: 0}
m_ScaleInLightmap: 1
m_PreserveUVs: 1
m_ImportantGI: 0
m_AutoUVMaxDistance: .5
m_AutoUVMaxAngle: 89
m_LightmapParameters: {fileID: 0}
m_SortingLayerID: 0
m_SortingOrder: 0
--- !u!135 &261853474
SphereCollider:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 261853471}
m_Material: {fileID: 0}
m_IsTrigger: 0
m_Enabled: 1
serializedVersion: 2
m_Radius: .5
m_Center: {x: 0, y: 0, z: 0}
--- !u!33 &261853475
MeshFilter:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 261853471}
m_Mesh: {fileID: 10207, guid: 0000000000000000e000000000000000, type: 0}
--- !u!1 &378624258
GameObject:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
serializedVersion: 4
m_Component:
- 4: {fileID: 378624259}
- 33: {fileID: 378624262}
- 64: {fileID: 378624261}
- 23: {fileID: 378624260}
m_Layer: 0
m_Name: Plane
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &378624259
Transform:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 378624258}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: []
m_Father: {fileID: 556234651}
m_RootOrder: 0
--- !u!23 &378624260
MeshRenderer:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 378624258}
m_Enabled: 1
m_CastShadows: 1
m_ReceiveShadows: 1
m_Materials:
- {fileID: 2100000, guid: 8c810c4fefa6ab3498f0aa0a420cee25, type: 2}
m_SubsetIndices:
m_StaticBatchRoot: {fileID: 0}
m_UseLightProbes: 1
m_ReflectionProbeUsage: 1
m_ProbeAnchor: {fileID: 0}
m_ScaleInLightmap: 1
m_PreserveUVs: 1
m_ImportantGI: 0
m_AutoUVMaxDistance: .5
m_AutoUVMaxAngle: 89
m_LightmapParameters: {fileID: 0}
m_SortingLayerID: 0
m_SortingOrder: 0
--- !u!64 &378624261
MeshCollider:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 378624258}
m_Material: {fileID: 0}
m_IsTrigger: 0
m_Enabled: 1
serializedVersion: 2
m_Convex: 0
m_Mesh: {fileID: 10209, guid: 0000000000000000e000000000000000, type: 0}
--- !u!33 &378624262
MeshFilter:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 378624258}
m_Mesh: {fileID: 10209, guid: 0000000000000000e000000000000000, type: 0}
--- !u!1 &486745529
GameObject:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
serializedVersion: 4
m_Component:
- 4: {fileID: 486745531}
- 108: {fileID: 486745530}
m_Layer: 0
m_Name: Directional Light
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!108 &486745530
Light:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 486745529}
m_Enabled: 1
serializedVersion: 6
m_Type: 1
m_Color: {r: 1, g: .956862748, b: .839215696, a: 1}
m_Intensity: 1
m_Range: 10
m_SpotAngle: 30
m_CookieSize: 10
m_Shadows:
m_Type: 2
m_Resolution: -1
m_Strength: 1
m_Bias: .0500000007
m_NormalBias: .400000006
m_Cookie: {fileID: 0}
m_DrawHalo: 0
m_Flare: {fileID: 0}
m_RenderMode: 0
m_CullingMask:
serializedVersion: 2
m_Bits: 4294967295
m_Lightmapping: 4
m_BounceIntensity: 1
m_ShadowRadius: 0
m_ShadowAngle: 0
m_AreaSize: {x: 1, y: 1}
--- !u!4 &486745531
Transform:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 486745529}
m_LocalRotation: {x: .408217937, y: -.234569728, z: .109381676, w: .875426054}
m_LocalPosition: {x: 0, y: 3, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: []
m_Father: {fileID: 0}
m_RootOrder: 1
--- !u!1 &556234650
GameObject:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
serializedVersion: 4
m_Component:
- 4: {fileID: 556234651}
- 114: {fileID: 556234652}
m_Layer: 0
m_Name: uber1
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &556234651
Transform:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 556234650}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children:
- {fileID: 378624259}
- {fileID: 1725950362}
- {fileID: 261853472}
- {fileID: 124582538}
m_Father: {fileID: 0}
m_RootOrder: 2
--- !u!114 &556234652
MonoBehaviour:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 556234650}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: c8a8ca4c86123cb49bc2697d2de0de1e, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!1 &991725394
GameObject:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
serializedVersion: 4
m_Component:
- 4: {fileID: 991725400}
- 20: {fileID: 991725399}
- 92: {fileID: 991725398}
- 124: {fileID: 991725397}
- 81: {fileID: 991725396}
- 114: {fileID: 991725395}
m_Layer: 0
m_Name: Main Camera
m_TagString: MainCamera
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!114 &991725395
MonoBehaviour:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 991725394}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 79621082da8ba124eba3da9eba119a06, type: 3}
m_Name:
m_EditorClassIdentifier:
inputTexture: {fileID: 0}
renderToTexture: 0
outputTexture: {fileID: 0}
outputMipmap: 0
fade: 0
panFade: 0
brightness: 1
contrast: 1
color: 1
shaderMethod: 0
outlines: 1
hatches: 1
outlineError: 1
flicker: .300000012
flickerFreq: 10
fixedHatchDir: 0
hatchScale: 1
hatchLength: 10
mipLevel: 0
vignetting: 1
contentVignetting: 0
paperTint: {r: 1, g: .970000029, b: .850000024, a: 1}
paperRoughness: 1
paperTex: {fileID: 0}
flipY: 0
--- !u!81 &991725396
AudioListener:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 991725394}
m_Enabled: 1
--- !u!124 &991725397
Behaviour:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 991725394}
m_Enabled: 1
--- !u!92 &991725398
Behaviour:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 991725394}
m_Enabled: 1
--- !u!20 &991725399
Camera:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 991725394}
m_Enabled: 1
serializedVersion: 2
m_ClearFlags: 1
m_BackGroundColor: {r: .192156866, g: .301960796, b: .474509805, a: .0196078438}
m_NormalizedViewPortRect:
serializedVersion: 2
x: 0
y: 0
width: 1
height: 1
near clip plane: .300000012
far clip plane: 1000
field of view: 60
orthographic: 0
orthographic size: 5
m_Depth: -1
m_CullingMask:
serializedVersion: 2
m_Bits: 4294967295
m_RenderingPath: -1
m_TargetTexture: {fileID: 0}
m_TargetDisplay: 0
m_HDR: 0
m_OcclusionCulling: 1
m_StereoConvergence: 10
m_StereoSeparation: .0219999999
m_StereoMirrorMode: 0
--- !u!4 &991725400
Transform:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 991725394}
m_LocalRotation: {x: .00242051878, y: 0, z: 0, w: .999997079}
m_LocalPosition: {x: 0, y: 2, z: -9.85999966}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: []
m_Father: {fileID: 0}
m_RootOrder: 0
--- !u!1 &1725950358
GameObject:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
serializedVersion: 4
m_Component:
- 4: {fileID: 1725950362}
- 33: {fileID: 1725950361}
- 65: {fileID: 1725950360}
- 23: {fileID: 1725950359}
m_Layer: 0
m_Name: Cube
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!23 &1725950359
MeshRenderer:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 1725950358}
m_Enabled: 1
m_CastShadows: 1
m_ReceiveShadows: 1
m_Materials:
- {fileID: 2100000, guid: b99c56aa1f07add48bee395d7c445161, type: 2}
m_SubsetIndices:
m_StaticBatchRoot: {fileID: 0}
m_UseLightProbes: 1
m_ReflectionProbeUsage: 1
m_ProbeAnchor: {fileID: 0}
m_ScaleInLightmap: 1
m_PreserveUVs: 1
m_ImportantGI: 0
m_AutoUVMaxDistance: .5
m_AutoUVMaxAngle: 89
m_LightmapParameters: {fileID: 0}
m_SortingLayerID: 0
m_SortingOrder: 0
--- !u!65 &1725950360
BoxCollider:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 1725950358}
m_Material: {fileID: 0}
m_IsTrigger: 0
m_Enabled: 1
serializedVersion: 2
m_Size: {x: 1, y: 1, z: 1}
m_Center: {x: 0, y: 0, z: 0}
--- !u!33 &1725950361
MeshFilter:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 1725950358}
m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0}
--- !u!4 &1725950362
Transform:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 1725950358}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: -3.04999995, y: 1.91999996, z: 2.92000008}
m_LocalScale: {x: 2.21319747, y: 2.21319795, z: 2.21319795}
m_Children: []
m_Father: {fileID: 556234651}
m_RootOrder: 1

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 5abe80dfba13d574d88fab89dfa6a420
timeCreated: 1529633512
licenseType: Store
DefaultImporter:
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,146 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!21 &2100000
Material:
serializedVersion: 6
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_Name: New Material 1
m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0}
m_ShaderKeywords:
m_LightmapFlags: 5
m_CustomRenderQueue: -1
stringTagMap: {}
m_SavedProperties:
serializedVersion: 2
m_TexEnvs:
data:
first:
name: _MainTex
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _BumpMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _DetailNormalMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _ParallaxMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _OcclusionMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _EmissionMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _DetailMask
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _DetailAlbedoMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _MetallicGlossMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Floats:
data:
first:
name: _SrcBlend
second: 1
data:
first:
name: _DstBlend
second: 0
data:
first:
name: _Cutoff
second: .5
data:
first:
name: _Parallax
second: .0199999996
data:
first:
name: _ZWrite
second: 1
data:
first:
name: _Glossiness
second: .5
data:
first:
name: _BumpScale
second: 1
data:
first:
name: _OcclusionStrength
second: 1
data:
first:
name: _DetailNormalMapScale
second: 1
data:
first:
name: _UVSec
second: 0
data:
first:
name: _Mode
second: 0
data:
first:
name: _Metallic
second: 0
data:
first:
name: _EmissionScaleUI
second: 0
m_Colors:
data:
first:
name: _EmissionColor
second: {r: 0, g: 0, b: 0, a: 0}
data:
first:
name: _Color
second: {r: 0, g: .296551704, b: 1, a: 1}
data:
first:
name: _EmissionColorUI
second: {r: 1, g: 1, b: 1, a: 1}

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: b99c56aa1f07add48bee395d7c445161
timeCreated: 1529654577
licenseType: Store
NativeFormatImporter:
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,146 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!21 &2100000
Material:
serializedVersion: 6
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_Name: New Material 2
m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0}
m_ShaderKeywords:
m_LightmapFlags: 5
m_CustomRenderQueue: -1
stringTagMap: {}
m_SavedProperties:
serializedVersion: 2
m_TexEnvs:
data:
first:
name: _MainTex
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _BumpMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _DetailNormalMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _ParallaxMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _OcclusionMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _EmissionMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _DetailMask
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _DetailAlbedoMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _MetallicGlossMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Floats:
data:
first:
name: _SrcBlend
second: 1
data:
first:
name: _DstBlend
second: 0
data:
first:
name: _Cutoff
second: .5
data:
first:
name: _Parallax
second: .0199999996
data:
first:
name: _ZWrite
second: 1
data:
first:
name: _Glossiness
second: .5
data:
first:
name: _BumpScale
second: 1
data:
first:
name: _OcclusionStrength
second: 1
data:
first:
name: _DetailNormalMapScale
second: 1
data:
first:
name: _UVSec
second: 0
data:
first:
name: _Mode
second: 0
data:
first:
name: _Metallic
second: 0
data:
first:
name: _EmissionScaleUI
second: 0
m_Colors:
data:
first:
name: _EmissionColor
second: {r: 0, g: 0, b: 0, a: 0}
data:
first:
name: _Color
second: {r: 1, g: .694058537, b: .154411793, a: 1}
data:
first:
name: _EmissionColorUI
second: {r: 1, g: 1, b: 1, a: 1}

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 4074049c4e7e1984689e60e030adf2c7
timeCreated: 1529654586
licenseType: Store
NativeFormatImporter:
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,146 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!21 &2100000
Material:
serializedVersion: 6
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_Name: New Material 3
m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0}
m_ShaderKeywords:
m_LightmapFlags: 5
m_CustomRenderQueue: -1
stringTagMap: {}
m_SavedProperties:
serializedVersion: 2
m_TexEnvs:
data:
first:
name: _MainTex
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _BumpMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _DetailNormalMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _ParallaxMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _OcclusionMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _EmissionMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _DetailMask
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _DetailAlbedoMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _MetallicGlossMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Floats:
data:
first:
name: _SrcBlend
second: 1
data:
first:
name: _DstBlend
second: 0
data:
first:
name: _Cutoff
second: .5
data:
first:
name: _Parallax
second: .0199999996
data:
first:
name: _ZWrite
second: 1
data:
first:
name: _Glossiness
second: .5
data:
first:
name: _BumpScale
second: 1
data:
first:
name: _OcclusionStrength
second: 1
data:
first:
name: _DetailNormalMapScale
second: 1
data:
first:
name: _UVSec
second: 0
data:
first:
name: _Mode
second: 0
data:
first:
name: _Metallic
second: 0
data:
first:
name: _EmissionScaleUI
second: 0
m_Colors:
data:
first:
name: _EmissionColor
second: {r: 0, g: 0, b: 0, a: 0}
data:
first:
name: _Color
second: {r: 1, g: .389705896, b: .907403529, a: 1}
data:
first:
name: _EmissionColorUI
second: {r: 1, g: 1, b: 1, a: 1}

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 9a131ad318d1c864f877dca7c51047c2
timeCreated: 1529654595
licenseType: Store
NativeFormatImporter:
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,146 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!21 &2100000
Material:
serializedVersion: 6
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_Name: New Material
m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0}
m_ShaderKeywords:
m_LightmapFlags: 5
m_CustomRenderQueue: -1
stringTagMap: {}
m_SavedProperties:
serializedVersion: 2
m_TexEnvs:
data:
first:
name: _MainTex
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _BumpMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _DetailNormalMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _ParallaxMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _OcclusionMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _EmissionMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _DetailMask
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _DetailAlbedoMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _MetallicGlossMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Floats:
data:
first:
name: _SrcBlend
second: 1
data:
first:
name: _DstBlend
second: 0
data:
first:
name: _Cutoff
second: .5
data:
first:
name: _Parallax
second: .0199999996
data:
first:
name: _ZWrite
second: 1
data:
first:
name: _Glossiness
second: .5
data:
first:
name: _BumpScale
second: 1
data:
first:
name: _OcclusionStrength
second: 1
data:
first:
name: _DetailNormalMapScale
second: 1
data:
first:
name: _UVSec
second: 0
data:
first:
name: _Mode
second: 0
data:
first:
name: _Metallic
second: 0
data:
first:
name: _EmissionScaleUI
second: 0
m_Colors:
data:
first:
name: _EmissionColor
second: {r: 0, g: 0, b: 0, a: 0}
data:
first:
name: _Color
second: {r: .352941185, g: 1, b: .811764717, a: 1}
data:
first:
name: _EmissionColorUI
second: {r: 1, g: 1, b: 1, a: 1}

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 8c810c4fefa6ab3498f0aa0a420cee25
timeCreated: 1529654573
licenseType: Store
NativeFormatImporter:
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,16 @@
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class youSpinMeRiseRound_ColoredPencils : MonoBehaviour {
// Use this for initialization
void Start () {
}
// Update is called once per frame
void Update () {
transform.Rotate(Vector3.up, 50*Time.deltaTime);
}
}

@ -0,0 +1,12 @@
fileFormatVersion: 2
guid: c8a8ca4c86123cb49bc2697d2de0de1e
timeCreated: 1546809074
licenseType: Store
MonoImporter:
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 5928b28a2d3ab69468723d76c64e4908
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 06e177f4559b14cf49d3f0adb18940e8
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,607 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!29 &1
SceneSettings:
m_ObjectHideFlags: 0
m_PVSData:
m_PVSObjectsArray: []
m_PVSPortalsArray: []
m_OcclusionBakeSettings:
smallestOccluder: 5
smallestHole: .25
backfaceThreshold: 100
--- !u!104 &2
RenderSettings:
m_ObjectHideFlags: 0
serializedVersion: 6
m_Fog: 0
m_FogColor: {r: .5, g: .5, b: .5, a: 1}
m_FogMode: 3
m_FogDensity: .00999999978
m_LinearFogStart: 0
m_LinearFogEnd: 300
m_AmbientSkyColor: {r: .211999997, g: .226999998, b: .259000003, a: 1}
m_AmbientEquatorColor: {r: .114, g: .125, b: .133000001, a: 1}
m_AmbientGroundColor: {r: .0469999984, g: .0430000015, b: .0350000001, a: 1}
m_AmbientIntensity: 1
m_AmbientMode: 0
m_SkyboxMaterial: {fileID: 10304, guid: 0000000000000000f000000000000000, type: 0}
m_HaloStrength: .5
m_FlareStrength: 1
m_FlareFadeSpeed: 3
m_HaloTexture: {fileID: 0}
m_SpotCookie: {fileID: 10001, guid: 0000000000000000e000000000000000, type: 0}
m_DefaultReflectionMode: 0
m_DefaultReflectionResolution: 128
m_ReflectionBounces: 1
m_ReflectionIntensity: 1
m_CustomReflection: {fileID: 0}
m_Sun: {fileID: 0}
--- !u!127 &3
LevelGameManager:
m_ObjectHideFlags: 0
--- !u!157 &4
LightmapSettings:
m_ObjectHideFlags: 0
serializedVersion: 5
m_GIWorkflowMode: 0
m_LightmapsMode: 1
m_GISettings:
serializedVersion: 2
m_BounceScale: 1
m_IndirectOutputScale: 1
m_AlbedoBoost: 1
m_TemporalCoherenceThreshold: 1
m_EnvironmentLightingMode: 0
m_EnableBakedLightmaps: 1
m_EnableRealtimeLightmaps: 1
m_LightmapEditorSettings:
serializedVersion: 3
m_Resolution: 2
m_BakeResolution: 40
m_TextureWidth: 1024
m_TextureHeight: 1024
m_AOMaxDistance: 1
m_Padding: 2
m_CompAOExponent: 0
m_LightmapParameters: {fileID: 0}
m_TextureCompression: 1
m_FinalGather: 0
m_FinalGatherRayCount: 1024
m_LightmapSnapshot: {fileID: 0}
m_RuntimeCPUUsage: 25
--- !u!196 &5
NavMeshSettings:
serializedVersion: 2
m_ObjectHideFlags: 0
m_BuildSettings:
serializedVersion: 2
agentRadius: .5
agentHeight: 2
agentSlope: 45
agentClimb: .400000006
ledgeDropHeight: 0
maxJumpAcrossDistance: 0
accuratePlacement: 0
minRegionArea: 2
cellSize: .166666672
manualCellSize: 0
m_NavMeshData: {fileID: 0}
--- !u!1 &124582537
GameObject:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
serializedVersion: 4
m_Component:
- 4: {fileID: 124582538}
- 33: {fileID: 124582541}
- 136: {fileID: 124582540}
- 23: {fileID: 124582539}
m_Layer: 0
m_Name: Capsule
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &124582538
Transform:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 124582537}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 3.31999993, y: 2.78999996, z: 3.17000008}
m_LocalScale: {x: 1.9904418, y: 1.99044204, z: 1.99044204}
m_Children: []
m_Father: {fileID: 556234651}
m_RootOrder: 3
--- !u!23 &124582539
MeshRenderer:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 124582537}
m_Enabled: 1
m_CastShadows: 1
m_ReceiveShadows: 1
m_Materials:
- {fileID: 2100000, guid: 9e1b302554cc7b741810c43ec96d4bf3, type: 2}
m_SubsetIndices:
m_StaticBatchRoot: {fileID: 0}
m_UseLightProbes: 1
m_ReflectionProbeUsage: 1
m_ProbeAnchor: {fileID: 0}
m_ScaleInLightmap: 1
m_PreserveUVs: 1
m_ImportantGI: 0
m_AutoUVMaxDistance: .5
m_AutoUVMaxAngle: 89
m_LightmapParameters: {fileID: 0}
m_SortingLayerID: 0
m_SortingOrder: 0
--- !u!136 &124582540
CapsuleCollider:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 124582537}
m_Material: {fileID: 0}
m_IsTrigger: 0
m_Enabled: 1
m_Radius: .5
m_Height: 2
m_Direction: 1
m_Center: {x: 0, y: 0, z: 0}
--- !u!33 &124582541
MeshFilter:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 124582537}
m_Mesh: {fileID: 10208, guid: 0000000000000000e000000000000000, type: 0}
--- !u!1 &261853471
GameObject:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
serializedVersion: 4
m_Component:
- 4: {fileID: 261853472}
- 33: {fileID: 261853475}
- 135: {fileID: 261853474}
- 23: {fileID: 261853473}
m_Layer: 0
m_Name: Sphere
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &261853472
Transform:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 261853471}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: .150000006, y: 2.67000008, z: -4.11999989}
m_LocalScale: {x: 1.88985467, y: 1.88985395, z: 1.88985395}
m_Children: []
m_Father: {fileID: 556234651}
m_RootOrder: 2
--- !u!23 &261853473
MeshRenderer:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 261853471}
m_Enabled: 1
m_CastShadows: 1
m_ReceiveShadows: 1
m_Materials:
- {fileID: 2100000, guid: 70c29e2b5f70dde4a822ced9affdf16a, type: 2}
m_SubsetIndices:
m_StaticBatchRoot: {fileID: 0}
m_UseLightProbes: 1
m_ReflectionProbeUsage: 1
m_ProbeAnchor: {fileID: 0}
m_ScaleInLightmap: 1
m_PreserveUVs: 1
m_ImportantGI: 0
m_AutoUVMaxDistance: .5
m_AutoUVMaxAngle: 89
m_LightmapParameters: {fileID: 0}
m_SortingLayerID: 0
m_SortingOrder: 0
--- !u!135 &261853474
SphereCollider:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 261853471}
m_Material: {fileID: 0}
m_IsTrigger: 0
m_Enabled: 1
serializedVersion: 2
m_Radius: .5
m_Center: {x: 0, y: 0, z: 0}
--- !u!33 &261853475
MeshFilter:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 261853471}
m_Mesh: {fileID: 10207, guid: 0000000000000000e000000000000000, type: 0}
--- !u!1 &378624258
GameObject:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
serializedVersion: 4
m_Component:
- 4: {fileID: 378624259}
- 33: {fileID: 378624262}
- 64: {fileID: 378624261}
- 23: {fileID: 378624260}
m_Layer: 0
m_Name: Plane
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &378624259
Transform:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 378624258}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: []
m_Father: {fileID: 556234651}
m_RootOrder: 0
--- !u!23 &378624260
MeshRenderer:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 378624258}
m_Enabled: 1
m_CastShadows: 1
m_ReceiveShadows: 1
m_Materials:
- {fileID: 2100000, guid: aa27b368bf93a104585160b830fed08a, type: 2}
m_SubsetIndices:
m_StaticBatchRoot: {fileID: 0}
m_UseLightProbes: 1
m_ReflectionProbeUsage: 1
m_ProbeAnchor: {fileID: 0}
m_ScaleInLightmap: 1
m_PreserveUVs: 1
m_ImportantGI: 0
m_AutoUVMaxDistance: .5
m_AutoUVMaxAngle: 89
m_LightmapParameters: {fileID: 0}
m_SortingLayerID: 0
m_SortingOrder: 0
--- !u!64 &378624261
MeshCollider:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 378624258}
m_Material: {fileID: 0}
m_IsTrigger: 0
m_Enabled: 1
serializedVersion: 2
m_Convex: 0
m_Mesh: {fileID: 10209, guid: 0000000000000000e000000000000000, type: 0}
--- !u!33 &378624262
MeshFilter:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 378624258}
m_Mesh: {fileID: 10209, guid: 0000000000000000e000000000000000, type: 0}
--- !u!1 &486745529
GameObject:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
serializedVersion: 4
m_Component:
- 4: {fileID: 486745531}
- 108: {fileID: 486745530}
m_Layer: 0
m_Name: Directional Light
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!108 &486745530
Light:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 486745529}
m_Enabled: 1
serializedVersion: 6
m_Type: 1
m_Color: {r: 1, g: .956862748, b: .839215696, a: 1}
m_Intensity: 1
m_Range: 10
m_SpotAngle: 30
m_CookieSize: 10
m_Shadows:
m_Type: 2
m_Resolution: -1
m_Strength: 1
m_Bias: .0500000007
m_NormalBias: .400000006
m_Cookie: {fileID: 0}
m_DrawHalo: 0
m_Flare: {fileID: 0}
m_RenderMode: 0
m_CullingMask:
serializedVersion: 2
m_Bits: 4294967295
m_Lightmapping: 4
m_BounceIntensity: 1
m_ShadowRadius: 0
m_ShadowAngle: 0
m_AreaSize: {x: 1, y: 1}
--- !u!4 &486745531
Transform:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 486745529}
m_LocalRotation: {x: .408217937, y: -.234569728, z: .109381676, w: .875426054}
m_LocalPosition: {x: 0, y: 3, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: []
m_Father: {fileID: 0}
m_RootOrder: 1
--- !u!1 &556234650
GameObject:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
serializedVersion: 4
m_Component:
- 4: {fileID: 556234651}
- 114: {fileID: 556234652}
m_Layer: 0
m_Name: uber1
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &556234651
Transform:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 556234650}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children:
- {fileID: 378624259}
- {fileID: 1725950362}
- {fileID: 261853472}
- {fileID: 124582538}
m_Father: {fileID: 0}
m_RootOrder: 2
--- !u!114 &556234652
MonoBehaviour:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 556234650}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: e8778bdd87f1849938600bd5f8b2fe0b, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!1 &991725394
GameObject:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
serializedVersion: 4
m_Component:
- 4: {fileID: 991725400}
- 20: {fileID: 991725399}
- 92: {fileID: 991725398}
- 124: {fileID: 991725397}
- 81: {fileID: 991725396}
- 114: {fileID: 991725395}
m_Layer: 0
m_Name: Main Camera
m_TagString: MainCamera
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!114 &991725395
MonoBehaviour:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 991725394}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 91a9cabf19a634d2fac557d213b89a59, type: 3}
m_Name:
m_EditorClassIdentifier:
EffectFade: 0
PanFade: 0
SrcBright: 1
SrcContrast: 1.39999998
SrcBlur: 0
BrushDetail: .100000001
BrushFill: .5
NumStrokes: 32768
LayerScale: .800000012
Canvas: .400000006
FlickerStrength: 0
LightAng: 135
LightOffs: 60
PaintDiff: .150000006
PaintSpec: .150000006
PaintShiny: .5
ScreenFOV: 0
StrokeAng: 0
StrokeBend: -1
StrokeDir: 0
StrokeContour: 1
MultiStroke: 6
strokeSeed: 10
Vignette: 1
flipY: 0
--- !u!81 &991725396
AudioListener:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 991725394}
m_Enabled: 1
--- !u!124 &991725397
Behaviour:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 991725394}
m_Enabled: 1
--- !u!92 &991725398
Behaviour:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 991725394}
m_Enabled: 1
--- !u!20 &991725399
Camera:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 991725394}
m_Enabled: 1
serializedVersion: 2
m_ClearFlags: 1
m_BackGroundColor: {r: .192156866, g: .301960796, b: .474509805, a: .0196078438}
m_NormalizedViewPortRect:
serializedVersion: 2
x: 0
y: 0
width: 1
height: 1
near clip plane: .300000012
far clip plane: 1000
field of view: 60
orthographic: 0
orthographic size: 5
m_Depth: -1
m_CullingMask:
serializedVersion: 2
m_Bits: 4294967295
m_RenderingPath: -1
m_TargetTexture: {fileID: 0}
m_TargetDisplay: 0
m_HDR: 0
m_OcclusionCulling: 1
m_StereoConvergence: 10
m_StereoSeparation: .0219999999
m_StereoMirrorMode: 0
--- !u!4 &991725400
Transform:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 991725394}
m_LocalRotation: {x: .00242051878, y: 0, z: 0, w: .999997079}
m_LocalPosition: {x: 0, y: 2, z: -9.85999966}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: []
m_Father: {fileID: 0}
m_RootOrder: 0
--- !u!1 &1725950358
GameObject:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
serializedVersion: 4
m_Component:
- 4: {fileID: 1725950362}
- 33: {fileID: 1725950361}
- 65: {fileID: 1725950360}
- 23: {fileID: 1725950359}
m_Layer: 0
m_Name: Cube
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!23 &1725950359
MeshRenderer:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 1725950358}
m_Enabled: 1
m_CastShadows: 1
m_ReceiveShadows: 1
m_Materials:
- {fileID: 2100000, guid: 651ed8109c496064e8f315643f67b3c7, type: 2}
m_SubsetIndices:
m_StaticBatchRoot: {fileID: 0}
m_UseLightProbes: 1
m_ReflectionProbeUsage: 1
m_ProbeAnchor: {fileID: 0}
m_ScaleInLightmap: 1
m_PreserveUVs: 1
m_ImportantGI: 0
m_AutoUVMaxDistance: .5
m_AutoUVMaxAngle: 89
m_LightmapParameters: {fileID: 0}
m_SortingLayerID: 0
m_SortingOrder: 0
--- !u!65 &1725950360
BoxCollider:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 1725950358}
m_Material: {fileID: 0}
m_IsTrigger: 0
m_Enabled: 1
serializedVersion: 2
m_Size: {x: 1, y: 1, z: 1}
m_Center: {x: 0, y: 0, z: 0}
--- !u!33 &1725950361
MeshFilter:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 1725950358}
m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0}
--- !u!4 &1725950362
Transform:
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_GameObject: {fileID: 1725950358}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: -3.04999995, y: 1.91999996, z: 2.92000008}
m_LocalScale: {x: 2.21319747, y: 2.21319795, z: 2.21319795}
m_Children: []
m_Father: {fileID: 556234651}
m_RootOrder: 1

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 011dbb86a988d9440ba31725043d8a19
timeCreated: 1546619418
licenseType: Store
DefaultImporter:
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,146 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!21 &2100000
Material:
serializedVersion: 6
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_Name: New Material 1
m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0}
m_ShaderKeywords:
m_LightmapFlags: 5
m_CustomRenderQueue: -1
stringTagMap: {}
m_SavedProperties:
serializedVersion: 2
m_TexEnvs:
data:
first:
name: _MainTex
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _BumpMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _DetailNormalMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _ParallaxMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _OcclusionMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _EmissionMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _DetailMask
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _DetailAlbedoMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _MetallicGlossMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Floats:
data:
first:
name: _SrcBlend
second: 1
data:
first:
name: _DstBlend
second: 0
data:
first:
name: _Cutoff
second: .5
data:
first:
name: _Parallax
second: .0199999996
data:
first:
name: _ZWrite
second: 1
data:
first:
name: _Glossiness
second: .5
data:
first:
name: _BumpScale
second: 1
data:
first:
name: _OcclusionStrength
second: 1
data:
first:
name: _DetailNormalMapScale
second: 1
data:
first:
name: _UVSec
second: 0
data:
first:
name: _Mode
second: 0
data:
first:
name: _Metallic
second: 0
data:
first:
name: _EmissionScaleUI
second: 0
m_Colors:
data:
first:
name: _EmissionColor
second: {r: 0, g: 0, b: 0, a: 0}
data:
first:
name: _Color
second: {r: 0, g: .296551704, b: 1, a: 1}
data:
first:
name: _EmissionColorUI
second: {r: 1, g: 1, b: 1, a: 1}

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 9e1b302554cc7b741810c43ec96d4bf3
timeCreated: 1546619418
licenseType: Store
NativeFormatImporter:
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,146 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!21 &2100000
Material:
serializedVersion: 6
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_Name: New Material 2
m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0}
m_ShaderKeywords:
m_LightmapFlags: 5
m_CustomRenderQueue: -1
stringTagMap: {}
m_SavedProperties:
serializedVersion: 2
m_TexEnvs:
data:
first:
name: _MainTex
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _BumpMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _DetailNormalMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _ParallaxMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _OcclusionMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _EmissionMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _DetailMask
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _DetailAlbedoMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _MetallicGlossMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Floats:
data:
first:
name: _SrcBlend
second: 1
data:
first:
name: _DstBlend
second: 0
data:
first:
name: _Cutoff
second: .5
data:
first:
name: _Parallax
second: .0199999996
data:
first:
name: _ZWrite
second: 1
data:
first:
name: _Glossiness
second: .5
data:
first:
name: _BumpScale
second: 1
data:
first:
name: _OcclusionStrength
second: 1
data:
first:
name: _DetailNormalMapScale
second: 1
data:
first:
name: _UVSec
second: 0
data:
first:
name: _Mode
second: 0
data:
first:
name: _Metallic
second: 0
data:
first:
name: _EmissionScaleUI
second: 0
m_Colors:
data:
first:
name: _EmissionColor
second: {r: 0, g: 0, b: 0, a: 0}
data:
first:
name: _Color
second: {r: 1, g: .694058537, b: .154411793, a: 1}
data:
first:
name: _EmissionColorUI
second: {r: 1, g: 1, b: 1, a: 1}

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 70c29e2b5f70dde4a822ced9affdf16a
timeCreated: 1546619418
licenseType: Store
NativeFormatImporter:
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,146 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!21 &2100000
Material:
serializedVersion: 6
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_Name: New Material 3
m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0}
m_ShaderKeywords:
m_LightmapFlags: 5
m_CustomRenderQueue: -1
stringTagMap: {}
m_SavedProperties:
serializedVersion: 2
m_TexEnvs:
data:
first:
name: _MainTex
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _BumpMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _DetailNormalMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _ParallaxMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _OcclusionMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _EmissionMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _DetailMask
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _DetailAlbedoMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _MetallicGlossMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Floats:
data:
first:
name: _SrcBlend
second: 1
data:
first:
name: _DstBlend
second: 0
data:
first:
name: _Cutoff
second: .5
data:
first:
name: _Parallax
second: .0199999996
data:
first:
name: _ZWrite
second: 1
data:
first:
name: _Glossiness
second: .5
data:
first:
name: _BumpScale
second: 1
data:
first:
name: _OcclusionStrength
second: 1
data:
first:
name: _DetailNormalMapScale
second: 1
data:
first:
name: _UVSec
second: 0
data:
first:
name: _Mode
second: 0
data:
first:
name: _Metallic
second: 0
data:
first:
name: _EmissionScaleUI
second: 0
m_Colors:
data:
first:
name: _EmissionColor
second: {r: 0, g: 0, b: 0, a: 0}
data:
first:
name: _Color
second: {r: 1, g: .389705896, b: .907403529, a: 1}
data:
first:
name: _EmissionColorUI
second: {r: 1, g: 1, b: 1, a: 1}

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 651ed8109c496064e8f315643f67b3c7
timeCreated: 1546619418
licenseType: Store
NativeFormatImporter:
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,146 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!21 &2100000
Material:
serializedVersion: 6
m_ObjectHideFlags: 0
m_PrefabParentObject: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_Name: New Material
m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0}
m_ShaderKeywords:
m_LightmapFlags: 5
m_CustomRenderQueue: -1
stringTagMap: {}
m_SavedProperties:
serializedVersion: 2
m_TexEnvs:
data:
first:
name: _MainTex
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _BumpMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _DetailNormalMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _ParallaxMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _OcclusionMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _EmissionMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _DetailMask
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _DetailAlbedoMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
data:
first:
name: _MetallicGlossMap
second:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Floats:
data:
first:
name: _SrcBlend
second: 1
data:
first:
name: _DstBlend
second: 0
data:
first:
name: _Cutoff
second: .5
data:
first:
name: _Parallax
second: .0199999996
data:
first:
name: _ZWrite
second: 1
data:
first:
name: _Glossiness
second: .5
data:
first:
name: _BumpScale
second: 1
data:
first:
name: _OcclusionStrength
second: 1
data:
first:
name: _DetailNormalMapScale
second: 1
data:
first:
name: _UVSec
second: 0
data:
first:
name: _Mode
second: 0
data:
first:
name: _Metallic
second: 0
data:
first:
name: _EmissionScaleUI
second: 0
m_Colors:
data:
first:
name: _EmissionColor
second: {r: 0, g: 0, b: 0, a: 0}
data:
first:
name: _Color
second: {r: .352941185, g: 1, b: .811764717, a: 1}
data:
first:
name: _EmissionColorUI
second: {r: 1, g: 1, b: 1, a: 1}

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: aa27b368bf93a104585160b830fed08a
timeCreated: 1546619418
licenseType: Store
NativeFormatImporter:
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,16 @@
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class youSpinMeRiseRound_OilPainting : MonoBehaviour {
// Use this for initialization
void Start () {
}
// Update is called once per frame
void Update () {
transform.Rotate(Vector3.up, 50*Time.deltaTime);
}
}

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: e8778bdd87f1849938600bd5f8b2fe0b
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

@ -0,0 +1,8 @@
{
"name": "com.ultracombos.flockaroo",
"displayName": "flockaroo Filter",
"version": "0.0.1",
"unity": "2018.1",
"description": "flockaroo Filter (OilPainting / ColoredPencils) for Unity.",
"dependencies": { }
}

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 847e2adc0c05288438097a491486b46b
TextScriptImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
Loading…
Cancel
Save