Are vector graphics possible?

0 favourites
  • 6 posts
From the Asset Store
Over 1700 16x16 pixel art RPG icons for item and skills
  • The title says it all, really. Are vector graphics a realistic possibility? Perhaps svg format or something? Would it be a performance killer or are there other reasons why this would not be feasible?

  • You can't draw SVG inside an HTML5 canvas. One solution would be to use an hidden SVG context as a plugin, and dump the drawing done on that SVG context in a PNG, which is then pasted inside C2's canvas...

  • I think it's possible, it's just not particularly easy. Do many people use SVG graphics for games anyway? I thought most games used bitmaps. Another problem is it's not as simple as getting it in the canvas - the editor should have good SVG support too so you can accurately preview what you've done, and that's tricky too. TBH it's not high on our priority list.

  • Svg uses the xml format, so parsing most of it, and then using the canvas paths should be relatively straight forward.

    The problem would be animating it, and as Ashley said making a reference in the editor. Then there are several other issues such as collision detection, etc.

    Would people use it?

    I believe so, but unlike bitmaps more detail would mean more processing time. I mean one nice looking image could have hundreds of paths.

  • Yeah, I know there would be drawbacks, and most people would use bitmaps. But, I could see some situations where it would be the better choice.

    Obviously you'd have to choose between certain functionality ... as with any other use of vector v bitmap. Bitmaps have drawbacks too... more detail does mean more resource usage... If C2 had the ability to actually generate the vector graphics within the game it would mean, if you did things right, a super small download in comparison?

    I wouldn't expect it to be a priority. But I think it could be particularly powerful as an added bonus.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Any time you use scaling or rotation vectors always look far better than bitmaps, plus you can let it scale to suit any mobile device's resolution so you don't get the images coming up smaller on higher res screens, or having to put multiple copies of the images in at different sizes. Still it allows your games to scale to any size the user wants without any problems.

    Inkscape is a v nice free SVG drawing program if you haven't seen that yet.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)