[GIF] The Phase Property in GIF Loop Coder
In this lesson, we look at one of the most powerful features in GIF Loop Coder, the phase property, which allows you to let different objects run animations shifted in time.
function onGLC(glc) {
glc.loop();
// glc.size(400, 400);
// glc.setDuration(5);
// glc.setFPS(20);
//glc.setMode('single');
glc.setEasing(false);
var list = glc.renderList,
width = glc.w,
height = glc.h,
color = glc.color; // your code goes here: glc.styles.backgroundColor = "black"; for(var i = 0; i < 1000; i++){ list.addCircle({
x: Math.random() * width,
y: Math.random() * height,
radius: [0.25,1],
fillStyle: "white",
phase: Math.random() + 10
})
} list.addText({
x: width / 2,
y: height / 2 + 20,
fontSize: [18, 24],
text: "Tecnotree Way of Work (WoW)",
fillStyle: ["white", "yellow"],
})
}
function onGLC(glc) {
glc.loop();
// glc.size(400, 400);
// glc.setDuration(5);
// glc.setFPS(20);
//glc.setMode('single');
//glc.setEasing(false);
var list = glc.renderList,
width = glc.w,
height = glc.h,
color = glc.color; // your code goes here: var res = 10;
for(var y = 0; y < height; y += res){
for(var x = 0; x < width; x +=res){
var dx = x - width / 2,
dy = y - height / 2,
dist = Math.sqrt(dx * dx+dy*dy); list.addCircle({
translationX: x,
translationY: y,
x: res / 2,
y: res / 2,
radius: res / 2,
fillStyle: ["red", "yellow"],
phase: -dist / 100
})
}
}
}
[GIF] The Phase Property in GIF Loop Coder的更多相关文章
- [GIF] GIF Loop Coder - Interpolation
This video discusses the default interpolation in GIF Loop Coder, and four distinct ways to change t ...
- [GIF] Shape Objects in GIF Loop Coder
This lesson is a quick tour of the predefined shape objects in GIF Loop Coder. function onGLC(glc) { ...
- [GIF] Colors in GIF Loop Coder
In this lesson we cover the different methods for defining and animating colors in GIF Loop Coder. f ...
- [GIF] GIF Loop Coder - Introduction
Introducing the program, GIF Loop Coder, which allows you to make looping animated gifs (and other t ...
- [GIF] GIF Loop Coder - Animation Functions
Previous, we animate the item by passing an array to tell the start position and end position. To ma ...
- [GIF] GIF Loop Coder Single Mode
We'll take a look at Single Mode animations and strategies for making this type of animation smoothl ...
- [GIF] Parenting in GIF Loop Coder
In this lesson, we look at how you can build up complex animations by assigning one shape as the par ...
- [GIF] GIF Loop Coder - Animating with Arrays
In this lesson, we discuss animating using arrays, and how different data types are interpolated whi ...
- The Node.js Event Loop, Timers, and process.nextTick() Node.js事件循环,定时器和process.nextTick()
个人翻译 原文:https://nodejs.org/en/docs/guides/event-loop-timers-and-nexttick/ The Node.js Event Loop, Ti ...
随机推荐
- Oracle 客户端安装 + pl/sql工具安装配置
Oracle 客户端安装 + pl/sql工具安装配置 下载oracle客户端,并在本地安装. 11g下载地址为: http://www.oracle.com/technetwork/databas ...
- HDU5779 Tower Defence (BestCoder Round #85 D) 计数dp
分析(官方题解): 一点感想:(这个题是看题解并不是特别会转移,当然写完之后看起来题解说得很清晰,主要是人太弱 这个题是参考faebdc神的代码写的,说句题外话,很荣幸高中和faebdc巨一个省,虽然 ...
- 【LeetCode 229】Majority Element II
Given an integer array of size n, find all elements that appear more than ⌊ n/3 ⌋ times. The algorit ...
- cadence异型孔
1:画route path的边框,画在board geometry的ncroute_path层上,可以用zcopy (暂时没用过) 没有的话可能:WARNING: No route path ...
- LeetCode题解——Regular Expression Matching
题目: 正则表达式的匹配,'.'能匹配任何一个字符,'*'之前必须有一个字符,两个结合起来表示之前那个字符出现0到无穷次. 解法: 一定要注意'*'必须结合前面的字符一起使用. 代码: class S ...
- matlab中图像处理常见用法
一. 读写图像文件 1. imread imread函数用于读入各种图像文件,如:a=imread('e:/w01.tif') 注:计算机E盘上要有w01相应的.tif文件. 2. imwrite i ...
- iOS完结篇
从去年自己陆陆续续接触iOS开发,几个月过去了,对于苹果的体验,流程,以及规范都有了一定的认 识,还会定期关注iOS的发展. 即将要做win10系统了,为了纪念把自己的虚拟机截图留念吧.也希望微软能在 ...
- HTTP知识填补
1.HTTP协议 HTTP协议是计算机通信的一种协议 流程: 1.http客户端发起请求,例如手机访问baidu.com,创建端口,一般位80 2.http服务器在端口监听客户端请求 3.http接收 ...
- 二、python 函数
1.定义函数 def max(x,y): if x>y: return x else: return y 如果定义空函数(函数还没想好怎么编写,只是为了让整个代码能够运行起来) def max( ...
- lamda表达式相关知识
lamda表达式写法 dt = datado.SelectDalMeath(sqlStr.ToString()); var x = (from r in dt.AsEnumerable() selec ...