On Thu, Jan 29, 2009 at 5:51 PM, Hordeling <[email protected]> wrote:
> Hordeling's back again <oh noes!>

Hi :)

> 1. Is there an easier place to start without having to learn the
> internals of both pyglet and cocos?

If you look closely to the two implementation files of the particle
systems of cocos you'll notice that particle.py implements a generic
particle system and particle_systems.py just have a bunch of
subclasses that defines particle systems parameters in such a way that
causes the desired effect. While it still is lacking in documentation
(and maybe a visual editor), reading the particle_systems.py should
give you an idea of how the parameters affect the behaviour of the
particle system and how can you achieve the effect that you want.

> 2. If I want an alpha channel for a snowflake sprite with soft edges,
> what is the best way to accomplish that in cocos?

AFAIK, using a PNG with alpha and borders already "pre-smoothed" would
be the easiest way to accomplish that.

> 2a. Going back to the fire example, there seem to be two images
> FIRE.JPG and FIRE.PNG - the former has no alpha channel, the latter
> has a transparency channel. It looks like the demo is using the JPG
> and thus handling alpha manually.  Is that true? Is it necessary or
> can I use PNG with transparency/translucency? or TGA with an alpha
> channel?

In my version of the file (I have the latest svn) the file used is
'fire.png', loaded on line 125 of particle.py:

    texture = pyglet.resource.image('fire.png').texture

It should be no problem to use a PNG with alpha.

> Thanks!

You're welcome :)

-- 
Kao Cardoso Félix

Página pessoal: http://www.inf.ufrgs.br/~kcfelix
Blog: http://kaofelix.blogspot.com

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"cocos2d discuss" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/cocos-discuss?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to