splash image background fix

function makeImageFromBackground( pArray )
{
for (var i = 0; i < pArray.length; i++) {
var ID = pArray[i];

var origImage = $(ID).get( 0 );

var image = document.createElement(‘img’);
image.id = ID.substr(1);
image.style.width = origImage.style.width;
image.style.height = origImage.style.height;
image.style.left = origImage.style.left;
image.style.top = origImage.style.top;
image.style.position = ‘absolute';

var imageUrl = origImage.style.backgroundImage.slice(4, -1);
image.src = imageUrl.replace(/”/g, “” );

$( ID ).replaceWith( image );
}

TweenMax.set(pArray,{rotation:0.001});
}

var imageArray = [
“#”,

];

makeImageFromBackground( imageArray );

TEXT RENDER

*{

-webkit-box-sizing:border-box;
-moz-box-sizing:border-box;
box-sizing:border-box;
text-rendering:geometricPrecision;
-webkit-backface-visibility:hidden;
-moz-backface-visibility:hidden;
-ms-backface-visibility:hidden;
-o-backface-visibility:hidden;
backface-visibility:hidden;
-webkit-font-smoothing:antialiased;
-moz-osx-font-smoothing:grayscale;
}

compass

@import “compass”;
@import “compass/utilities/sprites”;
@import “images/*.png”;

@include all-images-sprites;

@mixin useSprite( $name) {
@include images-sprite($name);
height: images-sprite-height($name);
width: images-sprite-width($name);
}

.cta{
@include useSprite(‘cta’);
display: block;
}

.logo {
@include useSprite(‘logo’);
}

Kip in Meestersaus

http://www.aziatische-ingredienten.nl/kip-in-meestersaus/

Ingrediënten voor de saus

  • 250 ml lichte sojasaus
  • 250 ml Shaoxing rijstwijn
  • 400 ml water
  • 150 gr Chinese, gele kandijsuiker (gewone suiker is ook goed)
  • 3 teentjes knoflook, gekneusd
  • 4 cm gember in gekneusde plakjes
  • 3 steranijsjes
  • 1 kaneelstokje
  • 1½ tl Sichuan pepertjes
  • ¼ tl 5-kruidenpoeder (echt niet teveel! , anders over heest het !!)
  • ½ tl sesamolie

WAMP installeren GUIDE

http://www.wampserver.com/en/

WAMPSERVER WAMPSERVER (32 BITS & PHP 5.4) 2.4

kies  you can download it directly.

aanpassen !! voor localhost 

  1. in het bestand httpd.conf  locatie –> C:\wamp\bin\apache\Apache2.4.4\conf 
  • DocumentRoot “[bestand locatie voor localhost] “
  • <Directory “[bestand locatie voor localhost] “>
  • virtualHost uit commend
  1. in het bestand httpd-vhosts.conf  locatie –> C:\wamp\bin\apache\Apache2.4.4\conf\extra
  • <VirtualHost *:80>
    DocumentRoot “[bestand locatie voor localhost] ”
    ServerName localhost
    </VirtualHost>

 

 

popcorn classs

import com.greensock.*;
import com.greensock.easing.*;
import flash.filters.*;
import flash.geom.Point;
var center:Point = new Point( 30, 30 );

var longest:Number = Math.sqrt( Stage.width * Stage.width + Stage.height * Stage.height );
var popcornElements:Array = [];
var popcornClasses:Array = [ 'PC1', 'PC2'/*, 'PC3'*/, 'PC4', 'PC5', 'PC6', 'PC7', 'PC8' ];

var xSpace:Number = 19;
var ySpace:Number = 19;

var xVar:Number = 3;
var yVar:Number = 3;

var xPos:Number = 0;
var yPos:Number = 0;

var pc:MovieClip;
var amount:Number = popcornClasses.length;
var done:Boolean = false;

var delayCurrent:Number = 3;
var delayMin:Number = 0;
var delayStep:Number = delayCurrent / ( Stage.height / ySpace );

var inTweens:Array = [];
var outTweens:Array = [];
var smallestDistance:Number = 10000;
while(!done)
{
pc = MovieClip( attachMovie( popcornClasses[ AlmostRandom.getRandomInt( 0, amount - 1 ) ], 'p_' + popcornElements.length, getNextHighestDepth() ) );
pc.origX = pc._x = xPos + AlmostRandom.getRandomRange( -xVar, xVar );
pc.origY = pc._y = yPos + AlmostRandom.getRandomRange( -yVar, yVar );
pc._rotation = AlmostRandom.getRandomRange( 0, 360 );

pc.filters = [ new DropShadowFilter( 2, 45, 0x0, 1, 4, 4, 0.4 ) ];

xPos += xSpace;

if ( xPos > Stage.width )
{
xPos = 0;
yPos += ySpace;
delayCurrent -= delayStep;
}

if ( yPos > Stage.height + 10 )
{
done = true;
}

popcornElements.push( pc );
pc.distanceToCenter = Point.distance( center, new Point( pc._x, pc._y ) );
pc.distancePercentage = pc.distanceToCenter / longest;
pc.distancePercentageInverted = 1 - pc.distancePercentage;

inTweens.push( TweenLite.from( pc, 1, { _y:-Stage.height*2 , _rotation:AlmostRandom.getRandomRange( -360, 360 ),ease:Sine.easeIn, delay:delayCurrent + AlmostRandom.getRandomRange( 0, .5 ) } ) );
}

popcornElements.sort( function( p1:MovieClip, p2:MovieClip ):Number {
return p1.distanceToCenter - p2.distanceToCenter;
} );

var i:Number = 0;
var len:Number = popcornElements.length;
var outPos:Point;
var outPosClone:Point;

for ( ;i < len; i++ )
{
pc = popcornElements[i];
outPos = new Point( pc.origX - center.x, pc.origY - center.y );
outPos.normalize(longest + 50);

outTweens.push(
TweenLite.to( pc, 1.5, {
_x:center.x + outPos.x,
_y:center.y + outPos.y,
_xscale:100,
_yscale:100,
ease:Cubic.easeIn
} )
);
}

var inAnimation:TimelineLite = new TimelineLite( { tweens:inTweens, onComplete:Delegate.create( this, prepStage ) } );
var outAnimation:TimelineLite = new TimelineLite( { tweens:outTweens } );

var inAnimTime:Number = 3;
var outAnimTime:Number = 2;

inAnimation.timeScale = inAnimation.totalDuration / inAnimTime;
outAnimation.timeScale = outAnimation.totalDuration / outAnimTime;

var animation:TimelineLite = new TimelineLite( { tweens:[
inAnimation,
TweenLite.delayedCall(1, _parent.reveal.playBanner),
outAnimation

], align:TweenAlign.SEQUENCE, onComplete:Delegate.create( this, cleanUp ) } );
function prepStage():Void
{
//._visible = false;
TweenLite.to( _parent.intro, 0.5, { _alpha:0, ease:Sine.easeIn });
_parent.reveal._alpha = 100;
}
function cleanUp():Void
{
this.removeMovieClip();

for ( var i:Number = 0, len:Number = popcornElements.length;i < len; i++ )
{
TweenLite.killTweensOf( pc );
pc = popcornElements[i];
pc.removeMovieClip();
}
}

3d meuk

maken van 3d tekeningen

onderdelen voor de printer

  1. https://iprototype.nl/products/components/sensors
  2. https://iprototype.nl/products/other-dev-tools/raspberry-pi

3 printer bouwproject

  1. http://www.lulzbot.com/?q=catalog
  2. http://www.conrad.nl/ce/nl/product/409630/
  3. http://www.3dprinterskopen.com/reprap-3d-printer/

 

learn  arduino

http://www.tinkerkit.com

cat feeder

http://myrobotlab.net/tutorial-phone-controlled-cat-feeder-with-arduino/

mute unmute

var prVidObj:PointrollVideo = new PointrollVideo(theVideoScreen, pointroll.info.getVideoDeliveryMethod());

var myDef:PointRollBasicVideoDefinition = new PointRollBasicVideoDefinition(Advertiser,VideoFileName,VideoInstance);
//prVidObj.playVideo(myDef);
pr_audio.pr_audioOnBtn.visible = true ;
pr_audio.pr_audioOffBtn.visible = false ;

prVidObj.addEventListener(PrVideoEvent.MUTE, videoMuteHandler);
prVidObj.addEventListener(PrVideoEvent.UNMUTE, videoUnMuteHandler);
pr_audio.pr_audioOnBtn.addEventListener(MouseEvent.CLICK, audioOnButtonClick);
pr_audio.pr_audioOffBtn.addEventListener(MouseEvent.CLICK, audiOffButtonClick);

function videoMuteHandler(e:PrVideoEvent):void{
pr_audio.pr_audioOnBtn.visible = false ;
pr_audio.pr_audioOffBtn.visible = true ;
}

function videoUnMuteHandler(e:PrVideoEvent):void{
pr_audio.pr_audioOnBtn.visible = true ;
pr_audio.pr_audioOffBtn.visible = false ;
}

function audioOnButtonClick(e:MouseEvent):void{
prVidObj.mute();
}
function audiOffButtonClick(e:MouseEvent):void{
prVidObj.unmute();
}

Photoshop

DOCUMENT new document

var docRef = documents.add(300, 250, 72, "docRef", NewDocumentMode.RGB); for (var i=0; i < 10 ; i ++){

var docRef = documents.add(300, 250, 72, "docRef" + i, NewDocumentMode.RGB); }

openFile var duckDoc = open(File("C:/Users/ting/Desktop/photoshopTest/Samples/ei.jpg"))

saveFile app.activeDocument.save()

Close

app.activeDocument.close() app.activeDocument.close(SaveOptions.DONOTSAVECHANGES)

close all programma

while (app.documents.length) { app.activeDocument.close() }

width

app.activeDocument.width.value

BEWERKEN artLayers

app.activeDocument.layers.length for (var i=0; i app.activeDocument.artLayers[i].visible = true; }

 

  1. 3DTransform ‘TdT ‘
  2. Average ‘Avrg’
  3. ApplyStyle ‘ASty’
  4. Assert ‘Asrt’
  5. AccentedEdges ‘AccE’
  6. Add ‘Add ‘
  7. AddNoise ‘AdNs’
  8. AddTo ‘AddT’
  9. Align ‘Algn’ All ‘All ‘
  10. AngledStrokes ‘AngS’
  11. ApplyImage ‘AppI’
  12. BackLight ‘BacL’
  13. BasRelief ‘BsRl’
  14. Batch ‘Btch’
  15. BatchFromDroplet ‘BtcF’
  16. Blur ‘Blr ‘
  17. BlurMore ‘BlrM’
  18. Border ‘Brdr’
  19. Brightness ‘BrgC’
  20. CanvasSize ‘CnvS’
  21. ChalkCharcoal ‘ChlC’
  22. ChannelMixer ‘ChnM’
  23. Charcoal ‘Chrc’
  24. Chrome ‘Chrm’
  25. Clear ‘Cler’ Close ‘Cls ‘
  26. Clouds ‘Clds’
  27. ColorBalance ‘ClrB’
  28. ColorCast ‘ColE’
  29. ColorHalftone ‘ClrH’
  30. ColorRange ‘ClrR’
  31. ColoredPencil ‘ClrP’
  32. ConteCrayon ‘CntC’
  33. Contract ‘Cntc’
  34. ConvertMode ‘CnvM’
  35. Copy ‘copy’
  36. CopyEffects ‘CpFX’
  37. CopyMerged ‘CpyM’
  38. CopyToLayer ‘CpTL’
  39. Craquelure ‘Crql’
  40. CreateDroplet ‘CrtD’
  41. Crop ‘Crop’
  42. Crosshatch ‘Crsh’
  43. Crystallize ‘Crst’
  44. Curves ‘Crvs’
  45. Custom ‘Cstm’
  46. Cut ‘cut ‘
  47. CutToLayer ‘CtTL’
  48. Cutout ‘Ct ‘
  49. DarkStrokes ‘DrkS’
  50. DeInterlace ‘Dntr’
  51. DefinePattern ‘DfnP’
  52. Defringe ‘Dfrg’
  53. Delete ‘Dlt ‘
  54. Desaturate ‘Dstt’
  55. Deselect ‘Dslc’
  56. Despeckle ‘Dspc’
  57. DifferenceClouds ‘DrfC’
  58. Diffuse ‘Dfs ‘
  59. DiffuseGlow ‘DfsG’
  60. DisableLayerFX ‘dlfx’
  61. Displace ‘Dspl’
  62. Distribute ‘Dstr’
  63. Draw ‘Draw’
  64. DryBrush ‘DryB’
  65. Duplicate ‘Dplc’
  66. DustAndScratches ‘DstS’
  67. Emboss ‘Embs’
  68. Equalize ‘Eqlz’
  69. Exchange ‘Exch’
  70. Expand ‘Expn’
  71. Export ‘Expr’
  72. Jumpto ‘Jpto’
  73. Extrude ‘Extr’
  74. Facet ‘Fct ‘
  75. Fade ‘Fade’
  76. Feather ‘Fthr’
  77. Fibers ‘Fbrs’
  78. Fill ‘Fl ‘
  79. FillFlash ‘FilE’
  80. FilmGrain ‘FlmG’
  81. Filter ‘Fltr’
  82. FindEdges ‘FndE’
  83. FlattenImage ‘FltI’
  84. Flip ‘Flip’
  85. Fragment ‘Frgm’
  86. Fresco ‘Frsc’
  87. GaussianBlur ‘GsnB’
  88. Get ‘getd’
  89. Glass ‘Gls ‘
  90. GlowingEdges ‘GlwE’
  91. Gradient ‘Grdn’
  92. GradientMap ‘GrMp’
  93. Grain ‘Grn ‘
  94. GraphicPen ‘GraP’
  95. Group ‘GrpL’
  96. Grow ‘Grow’
  97. HalftoneScreen ‘HlfS’
  98. Hide ‘Hd ‘
  99. HighPass ‘HghP’
  100. HSBHSL ‘HsbP’
  101. HueSaturation ‘HStr’
  102. ImageSize ‘ImgS’
  103. Import ‘Impr’
  104. InkOutlines ‘InkO’
  105. Intersect ‘Intr’
  106. IntersectWith ‘IntW’
  107. Inverse ‘Invs’
  108. Invert ‘Invr’
  109. LensFlare ‘LnsF’
  110. Levels ‘Lvls’
  111. LightingEffects ‘LghE’
  112. Link ‘Lnk ‘
  113. Make ‘Mk ‘
  114. Maximum ‘Mxm ‘
  115. Median ‘Mdn ‘
  116. MergeLayers ‘Mrg2′
  117. MergeLayersOld ‘MrgL’
  118. MergeSpotChannel ‘MSpt’
  119. MergeVisible ‘MrgV’
  120. Mezzotint ‘Mztn’
  121. Minimum ‘Mnm ‘
  122. Mosaic ‘Msc ‘
  123. Mosaic_PLUGIN ‘MscT’
  124. MotionBlur ‘MtnB’
  125. Move ‘move’
  126. NTSCColors ‘NTSC’
  127. NeonGlow ‘NGlw’
  128. Next ‘Nxt ‘
  129. NotePaper ‘NtPr’
  130. Notify ‘Ntfy’
  131. OceanRipple ‘OcnR’
  132. Offset ‘Ofst’
  133. Open ‘Opn ‘
  134. Paint ‘Pnt ‘
  135. PaintDaubs ‘PntD’
  136. PaletteKnife ‘PltK’
  137. Paste ‘past’
  138. PasteEffects ‘PaFX’
  139. PasteInto ‘PstI’
  140. PasteOutside ‘PstO’
  141. Patchwork ‘Ptch’
  142. Photocopy ‘Phtc’
  143. Pinch ‘Pnch’
  144. Place ‘Plc ‘
  145. Plaster ‘Plst’
  146. PlasticWrap ‘PlsW’
  147. Play ‘Ply ‘
  148. Pointillize ‘Pntl’
  149. Polar ‘Plr ‘
  150. PosterEdges ‘PstE’
  151. Posterize ‘Pstr’
  152. Previous ‘Prvs’
  153. Print ‘Prnt’
  154. ProfileToProfile ‘PrfT’
  155. Purge ‘Prge’
  156. Quit ‘quit’
  157. RadialBlur ‘RdlB’
  158. Rasterize ‘Rstr’
  159. RasterizeTypeSheet ‘RstT’
  160. RemoveBlackMatte ‘RmvB’
  161. RemoveLayerMask ‘RmvL’
  162. RemoveWhiteMatte ‘RmvW’
  163. Rename ‘Rnm ‘
  164. ReplaceColor ‘RplC’
  165. Reset ‘Rset’
  166. Reticulation ‘Rtcl’
  167. Revert ‘Rvrt’
  168. Ripple ‘Rple’
  169. Rotate ‘Rtte’
  170. RoughPastels ‘RghP’
  171. Save ‘save’
  172. Select ‘slct’
  173. SelectiveColor ‘SlcC’
  174. Set ‘setd’
  175. Sharpen ‘Shrp’
  176. SharpenEdges ‘ShrE’
  177. SharpenMore ‘ShrM’
  178. Shear ‘Shr ‘
  179. Show ‘Shw ‘
  180. Similar ‘Smlr’
  181. SmartBlur ‘SmrB’
  182. Smooth ‘Smth’
  183. SmudgeStick ‘SmdS’
  184. Solarize ‘Slrz’
  185. Spatter ‘Spt ‘
  186. Spherize ‘Sphr’
  187. SplitChannels ‘SplC’
  188. Sponge ‘Spng’
  189. SprayedStrokes ‘SprS’
  190. StainedGlass ‘StnG’
  191. Stamp ‘Stmp’
  192. Stop ‘Stop’
  193. Stroke ‘Strk’
  194. Subtract ‘Sbtr’
  195. SubtractFrom ‘SbtF’
  196. Sumie ‘Smie’
  197. TakeMergedSnapshot ‘TkMr’
  198. TakeSnapshot ‘TkSn’
  199. TextureFill ‘TxtF’
  200. Texturizer ‘Txtz’
  201. Threshold ‘Thrs’
  202. Tiles ‘Tls ‘
  203. TornEdges ‘TrnE’
  204. TraceContour ‘TrcC’
  205. Transform ‘Trnf’
  206. Trap ‘Trap’
  207. Twirl ‘Twrl’
  208. Underpainting ‘Undr’
  209. Undo ‘undo’
  210. Ungroup ‘Ungr’
  211. Unlink ‘Unlk’
  212. UnsharpMask ‘UnsM’
  213. Variations ‘Vrtn’
  214. Wait ‘Wait’
  215. WaterPaper ‘WtrP’
  216. Watercolor ‘Wtrc’
  217. Wave ‘Wave’
  218. Wind ‘Wnd ‘
  219. ZigZag ‘ZgZg’

AS3 URLRequest URLLoader


Security.allowDomain("*");
Security.loadPolicyFile("");
//Security.loadPolicyFile("crossdomain.xml");
var scriptRequest:URLRequest = new URLRequest("");
var scriptLoader : URLLoader = new URLLoader();

scriptLoader.addEventListener(Event.COMPLETE, handleLoadSuccessful);
scriptLoader.addEventListener(IOErrorEvent.IO_ERROR, handleLoadError);
scriptLoader.load(scriptRequest);

AS2
System.security.allowDomain("");
var myVars = new LoadVars();
System.security.loadPolicyFile("crossdomain.xml");
myVars.load("");
myVars.onLoad = function(success)
{
if (success)
{

}
else
{
}
};

XML load

AS3
var _xml:XML;
var _xmlList:XMLList;
var _urlLoader:URLLoader = new URLLoader();
urlLoader.load(new URLRequest("content.xml"));
//urlLoader.load(new URLRequest(""));
urlLoader.addEventListener(Event.COMPLETE, processXMLSuccessful);
urlLoader.addEventListener(IOErrorEvent.IO_ERROR, processXMLError);

function processXMLSuccessful(e:Event):void
{
_xml = new XML(e.target.data);

}
function processXMLError(e : IOErrorEvent):void
{
}

AS2
var _xml:XML = new XML();
_xml.ignoreWhite = true;
_xml.onLoad = function(success:Boolean)
{
if (success)
{

}
else
{
}
};

_xml.load("content.xml");
var node:XMLNode;

as3 text

_textformat = new TextFormat();
_textformat.size = 20;
_textformat.color = 0xffffff;
_textformat.align = TextFormatAlign.LEFT;

_textformat.font = "Verdana";
_text = new TextField ();
_text.defaultTextFormat = _textformat;
_text.autoSize = TextFieldAutoSize.LEFT,
_text.wordWrap = false;
_text.multiline = false;

requestAnimFrame

window.requestAnimFrame = (function(){
return
window.requestAnimationFrame ||
window.webkitRequestAnimationFrame ||
window.mozRequestAnimationFrame ||
window.oRequestAnimationFrame ||
window.msRequestAnimationFrame ||

function(/* function FrameRequestCallback */ callback, /* DOMElement Element */ element){
window.setTimeout(callback, 1000 / 60); }; })();

function animationloop(){ console.log(“hallo”)
requestAnimFrame(animationloop); }

requestAnimFrame(animationloop);

flash as3 random colour

import flash.display.Sprite;
import flash.events.MouseEvent;

var _num:Number = 0 ;
var j:Number = 0 ;
var _vlak:Sprite = new Sprite();
addChild(_vlak);

var collorArray:Array= [0x0182C1,0xA08853, 0x877342, 0xffffff,0x48851E,0x392C1C,0xEBF197,0x113F8C,0xF18D05,0xffffff,0xffffff,0xE54028,0xF18D05, 0x61AE24,0xE54028,
0xE54028,0xF18D05, 0xE54028, 0x660000, 0xCC0000, 0x839C86, 0x39C69E,0x21D630, 0xDDA947,0xB18675, 0x8B5A53, 0xD5E052];

changeBeeld();
function changeBeeld():void{

for (var i:Number = 0; i<400; i++){

var a:Sprite = new Sprite();
a.graphics.beginFill(collorArray[Number(Math.floor(Math.random()*collorArray.length))],1);
a.graphics.drawRect(_num*40,j*40,40,40);
a.graphics.endFill();
_vlak.addChild(a);

_num++;

if (_num > 19){

_num = 0 ;
j++;
}

}
}

_vlak.addEventListener(MouseEvent.CLICK, mouseClickHandler);

function changeColour():void{
for (var i:uint = 0; i < _vlak.numChildren; i++){
var my_color:ColorTransform = new ColorTransform();
my_color.color = collorArray[Number(Math.floor(Math.random()*collorArray.length))];
_vlak.getChildAt(i).transform.colorTransform = my_color;
}

}

function mouseClickHandler(e:MouseEvent):void{

changeColour();

}

Ting Yuen Dropbox