Starling-Framework icon indicating copy to clipboard operation
Starling-Framework copied to clipboard

Add graphics API for drawing

Open alevys opened this issue 7 years ago • 12 comments
trafficstars

Really need the ability to draw lines as in classic flash. Need native capability of the library. External libraries like starling-extension-graphics is already abandoned and will not be updated to match the current development of the Starling.

alevys avatar Nov 28 '17 19:11 alevys

It's definitely not a straightforward feature to add, but I know it would be super useful, and it's been on the back of my mind for a long time. Thanks for adding the issue!

I changed the title a little since I'd be adding lines as part of a more general drawing API, and I wouldn't force myself to stick 100% with the Flash API.

PrimaryFeather avatar Nov 29 '17 13:11 PrimaryFeather

Do not have to repeat the flash API, the main thing that it were possible to draw. Very, very'll wait for this feature. :)

alevys avatar Nov 29 '17 19:11 alevys

+1

22Round avatar Dec 01 '17 11:12 22Round

+1

hardcoremore avatar Dec 04 '17 15:12 hardcoremore

http://blog.bwhiting.co.uk/?p=423

matrix3d avatar Dec 13 '17 12:12 matrix3d

@alevys Actually, there is a usable starling-extension-graphics for starling v2 which will be working after some minor tweaks. ( And here is my fork)

I believe there are more effective ways to do vector triangulation, and no Ex-version ( editable vector ). But at least it's working.

Below is what I've done with the help of this extension: Gear&Chain Simulator

soimy avatar Dec 13 '17 16:12 soimy

@alevys Actually, there is a usable starling-extension-graphics for starling v2 which will be working after some minor tweaks. ( And here is my fork)

I believe there are more effective ways to do vector triangulation, and no Ex-version ( editable vector ). But at least it's working.

Below is what I've done with the help of this extension: Gear&Chain Simulator

I need starling grpahics extention too. But It looks like "beginTextureFill" and "lineTexture" doesn't works in oringal and your fork of graphic. Can you help me with it?

Dima107 avatar Sep 10 '19 10:09 Dima107

Yes texture fill does not work as well. I would like to have that but don't know how to implement it. I also have my own port here https://bitbucket.org/hardcoremore/starlinggraphicsextension/src/master/

hardcoremore avatar Sep 10 '19 13:09 hardcoremore

@alevys Actually, there is a usable starling-extension-graphics for starling v2 which will be working after some minor tweaks. ( And here is my fork)

I believe there are more effective ways to do vector triangulation, and no Ex-version ( editable vector ). But at least it's working.

Below is what I've done with the help of this extension: Gear&Chain Simulator

Is the code you used to triangulate the vectors available anywhere? I've been looking into trying to allow HW Vectors in flash/starling and I'd love to see how other people have done it for ideas

Fancy2209 avatar May 10 '24 13:05 Fancy2209

Just want to add in my fork: https://bitbucket.org/hardcoremore/starlinggraphicsextension/src/master/

Texture fill is working. Also you can draw lines with texture. I have also implemented miter, bevel and round joint types. I have fixed many bugs and added features. But still there are some things to be fixed.

hardcoremore avatar May 10 '24 21:05 hardcoremore