Another method to look at 2D drawing. (Glitter SS)

Community Forums/Graphic Chat/Another method to look at 2D drawing. (Glitter SS)

mk2y10(Posted 2012) [#1]
Everyone in Blitz3D who tried creating particle programs know of three methods:

-WritePixel (The slowest way to draw something)
-WritePixelFast (A kind-of fast way to draw something, but riskier than writepixel)
-WritePixel/WritePixelFast to Textures (This is a moderately fast way to draw individual particles, but could be risky if you do it wrong.)

All the above don't even support alpha in those pixels. You have to add it manually, and when you do, it slows the process down even more!

I want to let others know there is another way!

This is the best way to take advantage of the Graphics Hardware acceleration provided by PCs today, rather the relying strictly on the processor to do the drawing.

I have an example link below to a screensaver that demonstrates this drawing method.

By using 3D graphics while in Orthographic view from the camera, we can create a much faster frame rate with many more particles than writepixel and writepixelfast could ever achieve. Using sprites instead of images and textures and editing them using EntityColor, ScaleSprite, and so on, we can improve proficiency in all 2D applications we make. Another great advantage is that 3D hardware is what is 'in,' it's what companies are focusing on more than the older, 2D methods. This means that all the new machines being released are better and faster, making your program better and faster along with it!

So, what do you think about this method? Have you ever used it before? If not give it a try and let me know what you think! Also, if you want to see a demonstration of the method, do checkout the Glitter SS at this link: http://paxapps.weebly.com/glitter-ss.html

Thank you :)


RifRaf(Posted 2012) [#2]
prites instead of images and textures and editing them using EntityColor, ScaleSprite, and so on

the basis of most particle systems made with b3d



Cant tell much from the single frame shot, so ill give it a download.


what part of it requires DirectX 9 or higher ?

Last edited 2012


mk2y10(Posted 2012) [#3]
what part of it requires DirectX 9 or higher ?


It is recommended because of the speed DirectX 9 provides when it comes to hardware acceleration, other lower versions should work fine tho, just might have a slower frame rate... One thing that is on the site, but is not real noticeable is that after installing, Windows 7 will say it might not have installed correctly. It lies :), just check under your screensaver settings. Running the beta setup file again will cause the screensaver to uninstall. The real installer is not used for beta installations.


Bobysait(Posted 2012) [#4]
mmmmm ...
You're probably the first person since long time I read, who makes particles with writepixel/writepixelfast
We probably all use the 3D acceleration since few years already, so "Yes", it speeds up compared to the old method.

post-scriptum : there is also a nice library called FastImage that render 2D faster than blitz3d usually does, with support for alpha blending and else.