Re: SVGCards?




The choice of a monolithic file made sense from the perspective of
simplicity of code and the versatility of images. Unfortunately it makes
drawing the cards in the first-place an absolute nightmare. I'm
seriously thinking of changing it to individual files for each card.

I'm sure David Bellot (who created SVGCards) has something to say about
this.
Yes indeed ;-)
SVG-cards has been made especially for gnome-games. I think having a single file works pretty well and is usually the kind of techniques people use in all kind of games (have you ever disassembled amstad and amiga games ? ;-) ) For pixmap based games, there is no real difference between a file for each card or a big file. For SVG it is quite different as complex symbols are usually put into <defs> and used through the <use> mechanism. It saves a lot of space and it is especially true for cards games. What I'm thinking about is to access each card separately using the DOM api. It is possible to do that in a web browser (still waiting for a full svg implementation in firefox) and you can even do nice things like just loading the cards you want (with xmlhttprequest for example). I guess it would be a better solution. The second point in favor of having a single file is that small devices would prefer not to duplicate data because of their small memory. I know already about several projects planning to use svg-cards 2.0 into cellphone and PDF games, and usually they prefer to have a small file even if it's a bit more complex to deal with.

Best,
David




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]