Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
F
Front-End
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
abdullh.alsoleman
Front-End
Commits
7b4f41e3
Commit
7b4f41e3
authored
Aug 10, 2015
by
Viktor Lidholt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Adds new Layer class
parent
32359d4b
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
0 deletions
+20
-0
layer.dart
examples/game/lib/layer.dart
+19
-0
sprites.dart
examples/game/lib/sprites.dart
+1
-0
No files found.
examples/game/lib/layer.dart
0 → 100644
View file @
7b4f41e3
part of
sprites
;
class
Layer
extends
Node
with
SpritePaint
{
Paint
_cachedPaint
=
new
Paint
()
..
setFilterQuality
(
FilterQuality
.
low
)
..
isAntiAlias
=
false
;
void
_prePaint
(
PaintingCanvas
canvas
,
Matrix4
matrix
)
{
super
.
_prePaint
(
canvas
,
matrix
);
_updatePaint
(
_cachedPaint
);
canvas
.
saveLayer
(
null
,
_cachedPaint
);
}
void
_postPaint
(
PaintingCanvas
canvas
,
Matrix4
totalMatrix
)
{
canvas
.
restore
();
super
.
_postPaint
(
canvas
,
totalMatrix
);
}
}
examples/game/lib/sprites.dart
View file @
7b4f41e3
...
@@ -21,6 +21,7 @@ import 'package:vector_math/vector_math.dart';
...
@@ -21,6 +21,7 @@ import 'package:vector_math/vector_math.dart';
part
'action.dart'
;
part
'action.dart'
;
part
'color_secuence.dart'
;
part
'color_secuence.dart'
;
part
'image_map.dart'
;
part
'image_map.dart'
;
part
'layer.dart'
;
part
'node.dart'
;
part
'node.dart'
;
part
'node3d.dart'
;
part
'node3d.dart'
;
part
'node_with_size.dart'
;
part
'node_with_size.dart'
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment