• Welcome to Theos PowerBasic Museum 2017.

News:

Attachments are only available to registered users.
Please register using your full, real name.

Main Menu

BassBox

Started by Patrice Terrier, October 08, 2007, 10:57:44 PM

Previous topic - Next topic

0 Members and 2 Guests are viewing this topic.

Patrice Terrier

#270
I have been playing with the idea of a logo for BassBox, and this one is my first shot.
(I have also done some tests with the "Leornardo.png" that is in the "texture" folder)

See it in the updated SpotLights.zip
(Better to see it full screen)
Patrice Terrier
GDImage (advanced graphic addon)
http://www.zapsolution.com

Kent Sarikaya

RRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRReally clever design Patrice and NICE looking!!!
I love so many aspects of it and to throw in an effect into the logo, brilliant all ways around!!

Petr Schreiber

Very nice logo Patrice,

also the plugin looks very good!


Thanks,
Petr

AMD Sempron 3400+ | 1GB RAM @ 533MHz | GeForce 6200 / GeForce 9500GT | 32bit Windows XP SP3

psch.thinbasic.com

Charles Pegge


Continuing the space theme:

Cartesian Space

and update for Vulcan




Patrice,
You can remove Plugin005 from the BassBox distribution if you like. The most useful components will be recycled anyway. :)

PS:
Nice logo!

Petr Schreiber

Charles,

very nice new plugins!

Modified Volcano looks very good and cartesian space reminds me of StarWars - when Luke Skywalker drops into the DeathStar canyon and looks into the navigation machine.


Bye,
Petr
AMD Sempron 3400+ | 1GB RAM @ 533MHz | GeForce 6200 / GeForce 9500GT | 32bit Windows XP SP3

psch.thinbasic.com

Kent Sarikaya

Nice update and new one Charles. Petr I am so glad you said it reminded you of Luke's run on the DeathStar, ...I would have been like... it reminds me of something and been stuck on remembering what. It definitely has that feel to it!

Patrice Terrier

#276
--Charles

Thank you for your last post.

I have one suggestion that would make them looking more realistic.
For the star background, try using the OpenGL 2.0 sprite feature as shown in "Encounter" when drawing the etheral sphere, and use a pulsating white color instead of random colors.

Also because the main purpose of BassBox is playing audio, I think it would be better to redraw the fft in real time in your cartesian plugin. I could post an example showing how to represent a moving FFT in real time if you want.

Something very important to keep in mind when writing a plugin for BassBox: all the animated drawing must be done in real time. If the OpenGL effect computation is too long, it produces nasty sounds, because the player get out of synch, especialy when the host computer is not a dual core processor.

Thank you

...


Patrice Terrier
GDImage (advanced graphic addon)
http://www.zapsolution.com

Charles Pegge

#277

Thanks for your comments Patrice.

CPU performance is a very interesting issue with animation. I have found that Windows Task Manager (CtrlpAltpDel) is a very useful way of getting feedback, and it usually shows that dynamically generating a mesh of any substantial size is a performance killer. Compiling meshes into glLists in advance delegates most of the work to the GPU. Here are some rough figures using my HP Desktop which is a dual core AMD64 / Nvidia setup. These measurements are for the default BassBox Window playing 'Blue Star'


PLUGIN        CPU Load%
-----------------------
Cartesian     18
Day0          21
Day1          27
Encounter     35
Fireworks      4
Hal           15
Laser         21
Magic D        4
Matrix         6
Spectrum       4
Spotlights     6
Stick Dance    6
Tilt          15
Vulcan        28
Woofer        15


For 'Encounter' for instance, if you disable the gluquadrics (in the central axis) you will find that the CPU loading goes way down.

Similarly I found that removing the atmosphere from Vulcan reduced the CPU loading from 22% to 12%. And when the music is halted, this figure drops to 4% !



Realistic stars:

I have not looked at point sprites yet - I look forward to trying them out as you have used them. How about a Milky Way.


Real Time FFT:

We could put 'Cartesian into reverse gear and take a few more frame samples, it would then be more closely tied to the music. But my aspiration is to produce Sonic Landscapes - without imposing an excessive CPU load.



Patrice Terrier

--Charles

The test you have done are very interresting.
I did the same on my VISTA Intel Core Duo 2, and here are my results:


USER          Charles        Patrice
CPU           AMD 64         Intel Core Duo 2
GRAPHIC CARD                 NVIDIA Go 7600
OS            XP             VISTA

PLUGIN        CPU Load%      average%
---------------------------------------------
Cartesian     18                 9     
Day0          21                22
Day1          27                25
Encounter     35                34
Fireworks      4                 4
Hal           15                14
Laser         21                14
Magic D        4                 4
Matrix         6                 5
Mikado                           5         
Spectrum       4                 6         
Spotlights     6                11
Stick Dance    6                 6
Tilt          15                13           
Vulcan        28                14     
Woofer        15                15


While doing these tests, I found in BassBox.bas that changing in the procedure RenderOpenGL:

       '// Refresh display
       'CALL SwapBuffers(glDC)
       'CALL zUpdateWindow(glCtrl, 0)

       CALL wglSwapBuffers(glDC)

produces better performances with the VISTA DWM, thus my own test have been done using it.

...
Patrice Terrier
GDImage (advanced graphic addon)
http://www.zapsolution.com

Patrice Terrier

In the "Encounter" plugin you can reduce the drawback of using quadric sphere object
changing from 48 to 3, that will indeed produce a very nice GEM effect and decrease CPU usage by a factor 3.


SUB DrawSphere(BYVAL Radius AS SINGLE)
    LOCAL quadObj AS LONG
    quadObj = gluNewQuadric()                        ' Pointer to the Quadric Object (Return 0 If No Memory))
    IF quadObj THEN
       CALL gluQuadricNormals(quadObj, %GLU_SMOOTH)  ' Create Smooth Normals
       CALL gluQuadricTexture(quadObj, %GL_TRUE)     ' Create Texture Coords
       CALL gluSphere(quadObj, Radius, 3, 3) ' 48, 48)
       CALL gluDeleteQuadric(quadObj)
    END IF
END SUB
Patrice Terrier
GDImage (advanced graphic addon)
http://www.zapsolution.com

Charles Pegge

Nice solution Patrice. I tried to put the gluspheres into a glList but found that the spheres would not scale properly with glScalef when they were glCalled. The only alternative would be to generate your own spheres.

It is interesting to see how the processing is distributed between the two CPU cores. Usually its one core or the other but sometimes they share the processing equally. One curious effect I found with Vulcan in full screen mode only,  is that the CPU load goes into a long oscillation about 10 seconds frequency,  varying between 25% and 55%. I would like to find out what causes this. - possibly some memory housekeeping but why?

Kent Sarikaya

Beautiful looking Patrice. One thing... it would be nice if the bassbox logo was smaller and sort of moved around in the black area at top allowing full viewing of it and beautiful colored spectrum cylinder bars.

Very Very nice!!

Patrice Terrier

This is the new "Impulse" plugin, it has been reworked to achieve closer FFT accuracy and very sharp representation of the playing audio.

Because it is not obvious at the first look, i tell you that the histogramme part is not made of rectangles but pulsating cylinders. 

Enjoy

... 
Patrice Terrier
GDImage (advanced graphic addon)
http://www.zapsolution.com

Kent Sarikaya

Beautiful new version of Impulse Patrice, thanks.

Patrice Terrier

Thank you Kent, i like it very much too ;)
Patrice Terrier
GDImage (advanced graphic addon)
http://www.zapsolution.com