Total Pageviews

Tuesday, May 27, 2014

នេះជា Type bitmapPaint របស់ Corona SDK

នេះជា Type bitmapPaint របស់ Corona SDK
វាជា bitmap paint ដែលជា paint ផ្ទុកនៅ single texture
Syntax: វាត្រូវមាន lua table
Local paint = {
        Type = “image”,
        Filename = ,
        baseDir =
}
Local rect = display.newRect (0,0,100,100)
Rect.fill = paint
Type(តំរូវការ) វាជា String ដែលត្រូវតែជា image
Filename(តំរូវការ)  វាជា String ដែលជា filename របស់ image file
baseDir(ជំរើស) វាជា base directory ដែលហ្វាល់នេមត្រូវបានដាក់
ជំរើសរួមមានះ system.ResourceDirectory, system.DocumentsDirectory, system.TemporaryDirectory & system.CachesDirectorydefault របស់វា system.ResourceDirectory

Properties
paint.rotation ប្រើសំរាប់ rotate
paint.scaleX ជាតំលៃលេខនៃ scaleX
paint.scaleY ជាតំលៃលេខនៃ scaleY
paint.x ជាតំលៃលេខនៃ X
paint.y ជាតំលៃលេខនៃ Y


No comments:

Post a Comment