PIXNET Logo登入

遊戲人生 人生遊戲

跳到主文

如果工作是玩樂就太好了

部落格全站分類:攝影寫真

  • 相簿
  • 部落格
  • 留言
  • 名片
  • 5月 10 週二 201118:29
  • Corona Animation and Motion Basic Motion and Transitions Part1

Basic Motion and Transitions
基本運動和轉換

One of the most powerful things about the Corona SDK is that any display object can be animated. This is a testament to the flexible graphics model that Corona offers.
其中最強大的東西有關Corona SDK的是,任何顯示對象可以是動畫。這是一個證明了靈活的圖形模型,Corona 優惠。
Animations allow you to create visually-rich and engaging user experiences. Animations are accomplished by generating a sequence of frames that evolve smoothly from frame to frame. The term tween (short for inbetween) is a term describing the process in which such intermediate frames are generated. It is often used as shorthand to indicate that a property of an object will change during the animation, as in tweening the position.
動畫讓你創建視覺效果豐富,引人入勝的用戶體驗。動畫過程是通過產生一個序列平滑演進的幀幀與幀。這個詞之間(簡稱插圖中)是一個術語描述的過程中產生這些中間幀。它經常被用來作為縮寫,表示一個對象的屬性將改變在動畫,如在補間的立場。
Transitions 轉換
The transition library allows you to easily create animations with only a single line of code by allowing you to tween one or more properties of a display object. For example, you can fadeout a display object by tweening its alpha property (the alpha property transitions from 1.0 to 0).
轉換庫允許您輕鬆地創建動畫,只有一行的代碼,讓您一個或多個屬性之間的顯示對象。例如,您可以淡出顯示其α補間對象屬性(從 1.0 alpha屬性轉換為 0)。
The simplest way to do this is to use the transition.to method which takes a display object as its first argument and a table containing the control parameters as its second. The control parameters specify the duration of the animation, an optional delay for when to start the animation, and the final values of properties for the display object. The intermediate values for a property are determined by an easing function that is also specified as a control parameter. By default this is a linear function.
最簡單的方式做,這是使用方法,需要一個 transition.to顯示對象作為它的第一個參數,一個包含了控制參數作為其第二個。控制參數指定的期限動畫,可選延遲何時開始動畫,最終值屬性的顯示對象。中間值的屬性是由一個緩和功能,也被指定為控制參數。默認情況下這是一個線性函數。
Below are some examples of how to animate a square (see Transition2 in the sample code):
下面是一些例子如何動畫一個正方形(見 Transition2在示例代碼):
 
(繼續閱讀...)
文章標籤

createps 發表在 痞客邦 留言(0) 人氣(428)

  • 個人分類:Corona
▲top
  • 5月 09 週一 201118:36
  • Corona Images, Shapes, and Text About Display Objects Part6




Bitmap Mask
Corona's Bitmap Mask feature allows you to use an image as a
bitmap and apply it to other display objects. Corona converts the image
internally to grayscale; black values are then masked, while white values are
not. A mask has it own transform that can be tweened. Its properties are
accessible via the display object being masked.
 
A bitmap mask can be applied to other display objects, but certain objects
cannot be masked. These include text display objects and native display
objects.

Bitmap Mask
Corona's 的位圖掩碼功能可讓您使用圖像作為位圖,並將其應用於其它顯示對象。Corona 內部的圖像轉換為灰度,黑色值,然後蒙面,而白色的價值觀都沒有。一個口罩有它自己的轉換,可以補間。其特性都可以通過顯示對象被屏蔽。
一個位圖掩碼可以應用於其它顯示對象,但某些對象不能被屏蔽。這些措施包括文本顯示對象和本地顯示對象。

(繼續閱讀...)
文章標籤

createps 發表在 痞客邦 留言(0) 人氣(109)

  • 個人分類:Corona
▲top
  • 5月 09 週一 201117:38
  • Corona Images, Shapes, and Text About Display Objects Part5


Working with Display Objects and the Stage


Creating Display Objects
You don't actually create these objects directly. Instead,
you create special kinds of DisplayObjects such as rectangles,
circles, images, text, groups, etc.
(繼續閱讀...)
文章標籤

createps 發表在 痞客邦 留言(0) 人氣(237)

  • 個人分類:Corona
▲top
  • 5月 09 週一 201115:19
  • Corona Images, Shapes, and Text About Display Objects Part4

Corona Images, Shapes, and Text About Display Objects Part4
Text
display.newText( [parentGroup,] string, x, y, font, size ) creates a text object with its top-left
corner at (x, y). The local origin is at the center of the text; the reference
point is initialized to this local origin. By default, there is no text
color.
(繼續閱讀...)
文章標籤

createps 發表在 痞客邦 留言(0) 人氣(137)

  • 個人分類:Corona
▲top
  • 5月 09 週一 201114:11
  • VB.NET 取亂數

Dim RndNum As New Random() '最好在程式一開始就設定好

RndNum.Next() '產生大於等於0,小於2,147,483,647之亂數
RndNum.Next(10) '產生大於等於0,小於10之亂數
RndNum.Next(10, 20) '產生大於等於10,小於20之亂數
RndNum.NextDouble() '產生大於或等於 0.0,且小於 1.0雙精度浮點數
RndNum.NextBytes(bytes) '以亂數填入指定位元組陣列的元素
(繼續閱讀...)
文章標籤

createps 發表在 痞客邦 留言(0) 人氣(11,464)

  • 個人分類:VB.NET
▲top
  • 5月 06 週五 201116:37
  • Corona Images, Shapes, and Text About Display Objects Part3

Images
Bitmap
image objects are a type of DisplayObject.
(繼續閱讀...)
文章標籤

createps 發表在 痞客邦 留言(0) 人氣(109)

  • 個人分類:Corona
▲top
  • 5月 06 週五 201115:34
  • Corona Images, Shapes, and Text About Display Objects Part2

Corona Images, Shapes, and Text About Display Objects Part2
Common Object Methods
通用對象的方法
Object
methods are accessed via the colon operator. For example, if we have a DisplayObject represented by the
variable object, we can translate the object 10 pixels to the right (of it's
current position): object:translate( 10, 0 ).
(繼續閱讀...)
文章標籤

createps 發表在 痞客邦 留言(0) 人氣(56)

  • 個人分類:Corona
▲top
  • 5月 06 週五 201114:29
  • Corona Images, Shapes, and Text About Display Objects Part1



Corona Images, Shapes, and Text About Display Objects Part1
About Display Objects
All
drawing that occurs on the screen is accomplished by creating DisplayObjects. Anything that appears
on the screen is an instance of a DisplayObject. You don’t actually
create these objects directly. Instead, you create special kinds of DisplayObject such as rectangles, circles, images, text,
etc.
(繼續閱讀...)
文章標籤

createps 發表在 痞客邦 留言(0) 人氣(85)

  • 個人分類:Corona
▲top
  • 5月 06 週五 201109:34
  • Lua 一些功能

串接字串
s1="a"
s2="b"
s3 = s1 .. s2
print("s3:",s3 )  --印出 s3  ab
(繼續閱讀...)
文章標籤

createps 發表在 痞客邦 留言(0) 人氣(2,832)

  • 個人分類:Lua
▲top
  • 5月 04 週三 201118:04
  • Lua and Corona 基本語法

Corona:
assert(條件,"訊息")
local v=1
assert (v~=1,"error message"), 如果v是1,就印出訊息
//===========================================
(繼續閱讀...)
文章標籤

createps 發表在 痞客邦 留言(0) 人氣(4,311)

  • 個人分類:Lua
▲top
«1...67820»

最新文章

  • 中華電信、無線IP分享器和網路交換器如何連接
  • 把大容量的照片縮小, 圖片壓縮
  • 如何在Facebook建立應用程式
  • C# 網卡實體位置 record
  • C# 透過 WMI 取得硬碟序號 ( 物理 / 邏輯磁碟) record
  • C# ComboBox的MaxDropDownItems 沒反應 record
  • XNA 3D動畫,模型變型 record
  • C# 讀取大的圖檔時發生記憶體不足的問題。(轉載) record
  • C# 取得檔案類型 record
  • C# 是否為JPG檔案 record

文章精選

個人資訊

createps
暱稱:
createps
分類:
攝影寫真
好友:
累積中
地區:

熱門文章

  • (37,170)C# 取亂數 record
  • (20,934)C# 十進制轉各進制,再轉回來 record
  • (16,199)C# Dictionary用法 record
  • (15,017)C# lock record
  • (8,748)C# 取得目前時間:年 月 日 record
  • (7,017)C# 讀檔寫檔 record
  • (5,849)C# ListView record
  • (2,213)C# 開啟執行檔 record
  • (1,266)VB和C# 字串比較 record
  • (253)用1-52數字表示撲克牌的每一張牌 record

文章分類

  • 網路硬體 (1)
  • Facebook (1)
  • 懷孕 (1)
  • 程式使用 (1)
  • XNA 4.0 (2)
  • DirectX (15)
  • Corona (29)
  • Lua (2)
  • Unity3D (3)
  • OS (2)
  • 輸入法 (1)
  • 大易 (1)
  • VB.NET (2)
  • Shader (1)
  • 技巧 (2)
  • 笑話 (1)
  • 創業 (4)
  • FTP (2)
  • SQL (1)
  • 歌曲 (4)
  • 物理 (1)
  • Apple (3)
  • Game (1)
  • Game (1)
  • C++ (4)
  • XNA (12)
  • GRD3 (1)
  • 喜歡的歌 (1)
  • C# (87)
  • 國外旅遊 (2)
  • 未分類文章 (1)

最新留言

  • [22/06/15] 訪客 於文章「中華電信、無線IP分享器和網路交換器如何...」留言:
    你好 為什麼我根據你的接法使用後 Wi-fi能使用 但是在交...
  • [22/04/15] 訪客 於文章「C# 大樂透對獎程式...」留言:
    回饋您這方面資訊,我是從 PTT搜尋引擎的排名,看...
  • [18/05/31] dwchen52 於文章「C# 讀取大的圖檔時發生記憶體不足的問題...」留言:
    謝謝你的建議,讓解決我的問題....
  • [18/05/11] y257574 於文章「把大容量的照片縮小, 圖片壓縮 ...」留言:
    x5PKD9ozVGQUIn5R1奢侈品仿牌,保固說到做到,...
  • [15/09/01] 菁 於文章「iphone 在首頁新增資料夾...」留言:
    謝謝您!...
  • [15/08/16] 訪客 於文章「C# 大樂透對獎程式...」留言:
    你好,我剛剛做出來了,原來我犯了一個很不該犯的錯誤… 因為...
  • [15/08/16] 訪客 於文章「C# 大樂透對獎程式...」留言:
    是的,我也是這麼想的,用f11看了幾次程式跑的流程… 很抱...
  • [15/08/15] 訪客 於文章「C# 大樂透對獎程式...」留言:
    你好,目前我在學寫程式 老師上課的範例 在中了幾號碼那邊...
  • [15/03/08] 俴 誏 ? 闚 於文章「把大容量的照片縮小, 圖片壓縮 ...」留言:
    比們地要點重他一並開物我不工問得到時多點要為上 氣~質...
  • [15/02/25] 訪客 於文章「C# 大樂透對獎程式...」留言:
    大大可以私密教我寫兌獎嗎?我剩下兌獎了 其他都好了...

文章搜尋

誰來我家

參觀人氣

  • 本日人氣:
  • 累積人氣: