Search found 635 matches

by Ats
Fri May 03, 2024 3:00 pm
Forum: Your projects
Topic: SFXR
Replies: 16
Views: 17164

Re: SFXR

Thanks, both of you. So here's my last zsfxr test, which preloads 100 sounds (10 sounds per type, but tone isn't the most interesting). I deactivated the Random sounds and the Right click mutation. During the initialization of the sound, as suggested by Kjell, I'm playing them once, all while checki...
by Ats
Fri May 03, 2024 8:28 am
Forum: Your projects
Topic: SFXR
Replies: 16
Views: 17164

Re: SFXR

Thanks Ville. I think I'm getting pretty good at randomly finding bugs in ZGE :lol: So, setting the buffer.SizeDim1 before the sample.Length seems to fix the crash that could occur during the initialization. (I update the project above) buffer.SizeDim1 = S + 1; // Set buffer size MySampleIndex = 0; ...
by Ats
Thu May 02, 2024 11:04 pm
Forum: Your projects
Topic: SFXR
Replies: 16
Views: 17164

Re: SFXR

So I tried to initialize a bunch of sounds when starting the app, but there's something wrong with it and I don't know where... So I'm wondering if I can really pass a Sample as a variable in a function, then do a RefreshContent on that variable, or if I messed up somewhere else with the calculation...
by Ats
Thu May 02, 2024 4:56 pm
Forum: General discussion
Topic: Edition of the Sound component
Replies: 5
Views: 6936

Re: Edition of the Sound component

There was an idea to add some kind of high-level wizard interface on top of this. Something like SFXR. I remember that Kjell even had a prototype of this. Is that right, Kjell? After playing with sfxr and seeing the limitations, I would be more than happy to see that, and to help to make it, if nee...
by Ats
Thu May 02, 2024 4:00 pm
Forum: Your projects
Topic: SFXR
Replies: 16
Views: 17164

Re: SFXR

With the new method, I still had to add a little +1 to prevent crashing. But it's running just fine :wink: buffer.SizeDim1 = S + 1; // Set buffer size MySampleIndex = 0; That's because SFXR uses doubles ( 64-bit floating point ) for some variables, which is something ZGE doesn't support. So I trimme...
by Ats
Thu May 02, 2024 1:04 pm
Forum: Your projects
Topic: SFXR
Replies: 16
Views: 17164

Re: SFXR

Hahaha, I've fallen into a new loophole. All right. So from what I understand, the buffer size should be equal to the sample lenght, right? float S = SampleLength(); // Get the sample length float L = S/44100; // Get the sample length in seconds // MySound.Length = L; // Set the Sound component leng...
by Ats
Wed May 01, 2024 8:58 pm
Forum: Your projects
Topic: SFXR
Replies: 16
Views: 17164

Re: SFXR

Following Kjell's concerns about the amount of time the generation of the sound can take, I made an example that runs all the sounds presets of jsfxr. 0 key = pickupCoin 1 key = laserShoot 2 key = explosion 3 key = powerUp 4 key = hitHurt 5 key = jump 6 key = blipSelect 7 key = synth 8 key = tone 9 ...
by Ats
Wed May 01, 2024 5:39 pm
Forum: Your projects
Topic: SFXR
Replies: 16
Views: 17164

Re: SFXR

it would have been nice if ZGE exposed the audio interface ( DirectSound on Windows ) so you don't have to run a second interface Oh, ok, I get it. Alternatively, how could I import several sfx sounds without having to loop on each file to read their data? Maybe I could simply copy/paste the serial...
by Ats
Wed May 01, 2024 5:03 pm
Forum: Your projects
Topic: SFXR
Replies: 16
Views: 17164

Re: SFXR

I quickly updated Kjell's example, as ZGE isn't happy anymore with names being the same as components File:File, Sound:Sound and Sample:Sample. Weirdly enough, KeyPress:KeyPress isn't an issue. <?xml version="1.0" encoding="iso-8859-1" ?> <ZApplication Name="App" Captio...
by Ats
Wed May 01, 2024 12:16 pm
Forum: Feature requests
Topic: Triple mouse-click to select entire line of text
Replies: 5
Views: 51

Re: Triple mouse-click to select entire line of text

It was just an idea to improve the UX. If it's much more complicated than simply updating an external library, forget about it :lol:
by Ats
Tue Apr 30, 2024 7:38 am
Forum: Feature requests
Topic: Triple mouse-click to select entire line of text
Replies: 5
Views: 51

Re: Triple mouse-click to select entire line of text

Thanks. So I tried to replace included SynEdit by the new one, but it's not that simple :lol: Here's what I did: Install Delphi RADStudio Download ZGameEditor: https://github.com/VilleKrumlinde/zgameeditor Fix drive letter in the project: ZDesigner.dproj line 67: <DCC_DcuOutput>t:\temp\zge</DCC_DcuO...
by Ats
Mon Apr 29, 2024 5:32 pm
Forum: Feature requests
Topic: Triple mouse-click to select entire line of text
Replies: 5
Views: 51

Triple mouse-click to select entire line of text

The double-click to select an entire word is already implemented. Is it possible to add a triple-click to select an entire paragraph? I'm not sure if this requires custom programming or if it's an option in the ZDesigner project settings. I'll take a look at the source code. In the meantime, we can ...
by Ats
Wed Apr 24, 2024 10:13 am
Forum: General discussion
Topic: Glow shader ES2/GL3
Replies: 1
Views: 84

Glow shader ES2/GL3

Hello. I'm still trying to make "simple" shaders from time to time :lol: So today I'm trying to port that one to ZGE: https://stackoverflow.com/questions/8166384/how-to-get-a-glow-shader-effect-in-opengl-es-2-0 Since I'm not using textures, I was trying to do that directly with the vertex ...
by Ats
Sun Apr 21, 2024 9:36 pm
Forum: General discussion
Topic: Color effect
Replies: 5
Views: 9113

Re: Color effect

All right, I managed to convert the dither example to ES2/GL3: <?xml version="1.0" encoding="iso-8859-1" ?> <ZApplication Name="App" Caption="ZGameEditor application" GLBase="1" LightPosition="0.25 1 0.5" FileVersion="2"> <OnLoade...
by Ats
Sat Apr 20, 2024 6:42 am
Forum: Bug reports
Topic: Flickering issues in release mode
Replies: 12
Views: 357

Re: Flickering issues in release mode

And just to show that even with 24-bit you need to keep your clipping range in check :wink: Thanks for the heads-up, Kjell! I always wondered why the planets with rings had severe z-order problems (but not on NVIDIA video cards). Turns out that the camera filming them is ranging from ClipNear 0.1 t...