December 13, 2025, 02:05:16 AM

News:

Own IWBasic 2.x ? -----> Get your free upgrade to 3.x now.........


Recent posts

Pages 1 2 3 4 ... 10
11
GUI Central / Re: Transformer Calculator
Last post by Rock Ridge Farm (Larry) - December 21, 2024, 06:28:17 AM
I will test it with the new compiler today - I hope.
Can you send me a screen capture with the output on your windoz box.

Larry
12
GUI Central / Transformer Calculator
Last post by Brian - December 21, 2024, 04:47:52 AM
Well, to be honest, I thought a Transformer was a sci-fi character! I was looking at this program by Aurel, written about 16 years ago, converted it for use with IWB, and as I was messing, realised it only catered for 50 Hertz. I understand 60 Hertz is the norm in the US and Canada, so I added some radiobuttons to allow you to change the Hertz value. I also added a suitable icon

I don't know anything about Transformers, so I am guessing that the figures produced are correct. If not, see Aurel!

Brian
13
General Questions / Re: Graphics problem
Last post by basicgames - December 06, 2024, 01:50:25 PM
Quote from: Brian on December 06, 2024, 05:31:13 AMbasicgames,

Here's a little example I dashed off this morning before going out for a Christmas lunch this afternoon. I've even included a text file showing all the BitBlt constants and meanings. Hope this helps you somewhat

Just put the IWB program and bitmap image in the same folder, and compile

Brian

Perfect demonstration. Just had to modify the waituntil to win = 0 for EB.

The gradient is helpful to understand how the colors change. I also tried replacing the gradient with solid colors and tried all of the constants.

The results are pretty much what I expected, but this way it makes sense.

That text file you made is great because I haven't seen that information compiled anywhere else. If anyone is looking to use bitblt with SHOWIMAGE, this is the thread to look at.

I appreciate you taking the time to share this. Hope you had a good lunch.

Quote from: Egil on December 06, 2024, 03:51:22 AMNever used BitBlt myself, but the best place to find information on how to use the various APIs can be found at Microsoft,
and here is a link to their explanation of BitBlt: https://learn.microsoft.com/en-us/windows/win32/api/wingdi/nf-wingdi-bitblt .

A slightly different approach can be found here: https://vbden.tripod.com/articles/invmask.htm


Good luck!

Egil

I had seen the microsoft link, but not the tripod one. It seems that after seeing Brian's example, it is clear that importing bltblt is the way to go for more complex graphics. Thanks for sharing.




My intention is to take some of the game engines I am designing in Blitz Basic using directx and port them to EB (which should be easy to port to IWB) without using any directx.

I am developing an Isometric and a 2.5d engine for role playing games and want to remove the directx dependency.

Long story short, I want to make quality games that are compatible between a 386 with Windws 95 all the way to Ryzen with Windows 11. This is due to the recent discovery that EB runs and compiles well on the 386/95 setup. Why? I got one of those new Pocket 386 machines from China and am absolutely tickled by it.

As a side note, I bet IWB would run on a 386 too. That's a mighty impressive range of compatibility. 95 to 11. 386 to Ryzen.
14
General Questions / Re: Graphics problem
Last post by Brian - December 06, 2024, 05:31:13 AM
basicgames,

Here's a little example I dashed off this morning before going out for a Christmas lunch this afternoon. I've even included a text file showing all the BitBlt constants and meanings. Hope this helps you somewhat

Just put the IWB program and bitmap image in the same folder, and compile

Brian
15
General Questions / Re: Graphics problem
Last post by Egil - December 06, 2024, 03:51:22 AM
Never used BitBlt myself, but the best place to find information on how to use the various APIs can be found at Microsoft,
and here is a link to their explanation of BitBlt: https://learn.microsoft.com/en-us/windows/win32/api/wingdi/nf-wingdi-bitblt .

A slightly different approach can be found here: https://vbden.tripod.com/articles/invmask.htm


Good luck!

Egil
16
General Questions / Re: Graphics problem
Last post by basicgames - December 05, 2024, 10:29:31 AM
Thank you, Brian.

That makes sense to me, but I'm having trouble figuring out how you got it to mask the white. What does the hex 0x00BB0226 represent? Is that a raster code?

Either way, it looks like I'd best import bitblt as a function. Still, if you get a chance, could you please provide an example of how you masked the white?

I'm not sure about IWB documentation, but in EB there's virtually nothing other than a mention of bitblit flags in SHOWIMAGE. The only other source I could find was this thread.
17
General Questions / Re: Graphics problem
Last post by Brian - December 05, 2024, 03:30:52 AM
basicgames,

Bitmaps (and JPGs) do not support transparent pixels. My bitmap image in that line of code was of some black text surrounded by white, and the BitBlt flag was to mask the white out

If you need transparent pixels in IWB, use a GIF image

Brian
18
General Questions / Re: Graphics problem
Last post by basicgames - December 04, 2024, 11:19:40 PM
I am having no luck getting SHOWIMAGE to work with bitblt flags as you show above. What else is needed? May you please provide an example or elaborate?

In other words, how do I display a bitmap with a transparent color using SHOWIMAGE?
19
User Offerings / Re: League Tables program
Last post by Brian - October 01, 2024, 04:54:24 AM
I recently re-visited this program, thinking that my last version ran okay. I was surprised to find that it wasn't saving a table correctly, and was falling over when saving

I was using a method where the opened table filename was being injected into the Save edit control. I have re-jigged that part, using different code, and it seems to work okay now

Brian
20
Games and Graphics / Re: Marblez game
Last post by Brian - September 21, 2024, 06:22:25 AM
OK, I think I have cracked it - seems to work for me, anyway

It is now a Project, which means the icon, bitmaps and wave files are embedded into the exe, so the program is self contained. I've also added a Ctrl+N to play a new game, rather than use the menu item

Brian
Pages 1 2 3 4 ... 10