![]() |
|
Wavey Words - Printable Version +- QB64 Phoenix Edition (https://qb64phoenix.com/forum) +-- Forum: QB64 Rising (https://qb64phoenix.com/forum/forumdisplay.php?fid=1) +--- Forum: Code and Stuff (https://qb64phoenix.com/forum/forumdisplay.php?fid=3) +---- Forum: Programs (https://qb64phoenix.com/forum/forumdisplay.php?fid=7) +---- Thread: Wavey Words (/showthread.php?tid=3985) Pages:
1
2
|
Wavey Words - SierraKen - 10-08-2025 I found this original code on the Basic Programming Language FB group page. I modded it to say QB64 Phoenix Edition and also made it wavey. This is from around 40 years ago (I removed the line numbers). Notice the old "Print String$(N, 32)". I had to look that up, it was used to move a string different spaces, like LOCATE does now. But it still works! 32 is the ASCII number for a space. The person that posted this said this: "It got published on the back of Remarks magazine, the club letter of the Dutch TRS-80 User Group." His version slanted down in one direction and didn't make waves. Press Esc to end. Code: (Select All)
RE: Wavey Words - SMcNeill - 10-08-2025 Wavy Words -- Steve Edition: Code: (Select All)
RE: Wavey Words - SierraKen - 10-08-2025 LOL Amazing Steve! It's so simple too, I'm stunned. lol I will have to use some of this code on wavey pictures or graphics, etc. And the use of fonts, I didn't know it was so easy. lol RE: Wavey Words - SMcNeill - 10-08-2025 (10-08-2025, 06:36 PM)SierraKen Wrote: LOL Amazing Steve! It's so simple too, I'm stunned. lol I will have to use some of this code on wavey pictures or graphics, etc. And the use of fonts, I didn't know it was so easy. lol You can honestly take out about half of it. I'm making it a hardware only screen there, just cause I was using a lot of CPU juice on my laptop and that chugs a lot of the processing into the GPU. On my laptop, running it as it is here, it uses all of 0% CPU... So less than 0.4% I suppose, which gets rounded down to nothing. All we're basically doing is just a simple sine wave here to generate the waving motions. It really is quite a simple process. Adjust the math a little for bigger waves or longer waves or whatnot, as desired. ![]() But run it and see what the CPU usage is for you. It should be almost nothing, since the vast majority of the work here is going to the hardware screen instead of anything software rendered. RE: Wavey Words - SierraKen - 10-08-2025 I just modded yours to make different words appear from DATA lines. Took me awhile to figure out how to center any word$. It works, but when I do CTRL+ALT+DEL to see CPU usage, the program completely shuts down. So I tried it without the _DISPLAYORDER HARDWARE line and it still does the same thing. It's possible it's because nowadays I'm using a Mini-PC that doesn't have a video card. Intel made it so the video RAM is taken from the regular RAM. But feel free to try it. Otherwise it's fine. I also tested CTRL+ALT+DEL with other programs (with and without SCREEN) and it comes up fine those times. I'm guessing it has to do with the very high LIMIT number on here. Code: (Select All)
RE: Wavey Words - SMcNeill - 10-08-2025 Maybe try starting task manager first, then run it, then swap to task manager for cpu usage? RE: Wavey Words - SierraKen - 10-08-2025 Thanks, that works. I got around 1 to 3% CPU usage on it and 64.5 MB RAM. Which is odd because this CPU usage is very small compared to usual programs. RE: Wavey Words - SMcNeill - 10-08-2025 (10-08-2025, 08:44 PM)SierraKen Wrote: Thanks, that works. I got around 1 to 3% CPU usage on it and 64.5 MB RAM. Which is odd because this CPU usage is very small compared to usual programs. No software screen, no software rendering. It's all hardware images.
RE: Wavey Words - bplus - 10-09-2025 Here is another way Code: (Select All) _Title "Wavy Words, press escape to quit..." 'bplus mod 2025-10-08RE: Wavey Words - SierraKen - 10-09-2025 Incredible Bplus. Yours doesn't even capture the screen and moves perfectly. |