Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
A faster way to scale images?
#11
(02-16-2023, 08:28 AM)johannhowitzer Wrote: I tried some more tests, commenting various things out, moving stuff around, adding in extra calls,
and the mystery only gets weirder.

- When I added SOFTWARE to the DISPLAYORDER at the start and commented out the others - or just
commented out every DISPLAYORDER and went with default - I got everything to show up, but it was
twice as slow.

- When I commented out the running frame counter display during the simulation, the ending result
display afterward flickered once and went black.

- When I added a DISPLAY statement before the simulation, the ending result stayed visible.
I also noticed that without it, the window size did not change after leaving the editor (which
operates at 1:1), until the simulation was done.  It seems SCREEN does not resize the window
by itself, if you are not in AUTODISPLAY; you have to use a DISPLAY statement to get it to realize
the window size should change.  I understand how this would update the window size, but still have
no idea why this prevents the flicker, or rather, why neglecting it causes the flicker in the
first place!


And still no clue why PUTIMAGE is sending to the SCREEN handle and ignoring the subsequent DEST.
Do hardware images just ignore DEST and place straight to whatever's SCREEN at the time?


Since adding hardware images, I had not run through other parts of the program, just the level
editor and the frame counter on simulation.  Upon trying to start the game from the title screen,
there were several other sticking points where I ran into black screens when it seemed like I
shouldn't.  Putting a DISPLAY in a few spots did seem to smooth them over, but now I'm going to
have to go through everything and comb for black screens and figure out how to prevent them.
Hardware images apparently behave very strangely with regard to DISPLAY, SCREEN, and DEST.
It will take me some time to test things, and figure out how the behavior works in detail, enough
to use hardware images confidently.  There are some really unusual quirks.

I hear ya. I've played around with hardware images in the past and wow are they fast. However, every single time I've tried implementing them into one of my software projects I've run across the same quirkiness you are describing. I'm working on a project now that would benefit greatly from hardware images so I'm going to give it another go.

I may end up writing a new tutorial topic on just hardware images to help get everything straight in my own mind and have documentation on how exactly to implement them.
New to QB64pe? Visit the QB64 tutorial to get started.
QB64 Tutorial
Reply


Messages In This Thread
A faster way to scale images? - by johannhowitzer - 01-31-2023, 02:14 PM
RE: A faster way to scale images? - by SMcNeill - 01-31-2023, 02:46 PM
RE: A faster way to scale images? - by SMcNeill - 02-01-2023, 02:07 PM
RE: A faster way to scale images? - by SMcNeill - 02-13-2023, 01:30 PM
RE: A faster way to scale images? - by SMcNeill - 02-15-2023, 05:27 PM
RE: A faster way to scale images? - by TerryRitchie - 02-16-2023, 06:00 PM
RE: A faster way to scale images? - by SMcNeill - 02-16-2023, 07:39 PM



Users browsing this thread: 1 Guest(s)