Search found 76 matches

by Didaktik
Wed Nov 01, 2017 9:08 pm
Forum: Coding Questions
Topic: Hot to WindowedScreen AutoStetch sharpen quality? off smooth
Replies: 2
Views: 1027

Hot to WindowedScreen AutoStetch sharpen quality? off smooth

My friend create game. This similar ZX Spectrum graphics.
Have screen 256x192. And use AutoStretch to resize screen X2 or X3.
But seems very smooth, not pixel perfect.

Is it possible to do some kind of trick for Windows so that the picture is not blurred?

https://pp.userapi.com/c824204 ...
by Didaktik
Mon Oct 10, 2016 4:20 am
Forum: Coding Questions
Topic: Immediate Mode Graphical User interface
Replies: 6
Views: 4373

Immediate Mode Graphical User interface

I found quite interesting and powerful library. I think it could become a viable alternative to conventional GUI in PB.
In mode Full Screen and WindowedScreen.

https://github.com/ocornut/imgui

And it is not just a library. This entire GUI creation paradigm.

http://www.johno.se/book/imgui.html ...
by Didaktik
Thu Oct 06, 2016 9:22 pm
Forum: Coding Questions
Topic: AddTimer not work...
Replies: 15
Views: 4649

Re: AddTimer not work...

Marc56us wrote: Put animation on a Window and splashscreen on another window (over)
Uses StickyWindow(#Win_Splash, #True) to keep splash windows on top.

:wink:
and you joker :D
I animation is created in real time.
by Didaktik
Thu Oct 06, 2016 5:04 pm
Forum: Coding Questions
Topic: AddTimer not work...
Replies: 15
Views: 4649

Re: AddTimer not work...

Marc56us wrote:Without thread version

:wink:
Thx!
But... loading have animation.
Like ZX Spectrum screen loading. :)

Image
by Didaktik
Thu Oct 06, 2016 4:42 pm
Forum: Coding Questions
Topic: AddTimer not work...
Replies: 15
Views: 4649

Re: AddTimer not work...

Hi,


EnableExplicit


Enumeration #PB_Event_FirstCustomValue
#Own_Event_InitFinished
EndEnumeration



Ok, but now I need to do ThreadSafe application. A ThreadSafe programs run slower than usual. It turns due SplahScreen entire program will then run slowly ...
by Didaktik
Thu Oct 06, 2016 3:34 pm
Forum: Coding Questions
Topic: AddTimer not work...
Replies: 15
Views: 4649

Re: AddTimer not work...

I try to formulate the task:

I have a program, opens a window will ship a lot of files, creates a lot of gedgets etc.
It lasts about 5 seconds.

While this is happening, I wanted to open a small window and display it loading animation.
by Didaktik
Thu Oct 06, 2016 3:09 pm
Forum: Coding Questions
Topic: AddTimer not work...
Replies: 15
Views: 4649

Re: AddTimer not work...

By the way. How can I do waitevent if this window is used to display during loading and initializing the main program.
by Didaktik
Thu Oct 06, 2016 3:05 pm
Forum: Coding Questions
Topic: AddTimer not work...
Replies: 15
Views: 4649

Re: AddTimer not work...

I have a block with WaitEvent.

But how would I have wanted to isolate the creation and closing of windows in a separate procedure?

I do not want to have a bunch of messy code in the main body.
How to be?
by Didaktik
Thu Oct 06, 2016 1:43 pm
Forum: Coding Questions
Topic: AddTimer not work...
Replies: 15
Views: 4649

AddTimer not work...

The timer never triggered. I can not understand why!



#loading_window = 0

Procedure Loading()

CallDebugger
Static img, Dim border.l(1)

If img = 0

img = LoadImage(#PB_Any, "loading.png")
border(0) = RGB(0,0,160)
border(1) = RGB(160,160,0)

EndIf

StartDrawing( WindowOutput ...
by Didaktik
Wed Oct 05, 2016 1:58 pm
Forum: Coding Questions
Topic: Create Image 36000px width
Replies: 6
Views: 2057

Re: Create Image 36000px width

Yes, printer has a resolution of 720dpi, and as I print Pixelart, I decided to multiple zoom 6 times.
And I was able to fit in 8192x8192. )

resultal: https://dl.dropboxusercontent.com/u/6439155/huge.png :P

(Atari, Amiga, C64, ZX Spectrum gfx)
by Didaktik
Wed Oct 05, 2016 12:36 pm
Forum: Coding Questions
Topic: Create Image 36000px width
Replies: 6
Views: 2057

Create Image 36000px width

I want to order printing on wide-format printers.
I have a lot of pictures of which I want to create one. The size of the final image obtained 36,000 pixels wide (1.3 meters).
Purebasic can create 8192px only.

How can I solve this?
by Didaktik
Tue Oct 04, 2016 10:46 am
Forum: Coding Questions
Topic: Code optimisation or translate to assembly?
Replies: 18
Views: 4892

Re: Code optimisation or translate to assembly?

A few more thoughts ...
- If the Atom supports AVX, that might be a way to increase the speed some more of the module I posted.
- It's also possible to add two additional procedures that output directly to 25 or 50% size if you need smaller images.
- Did you use SSE2 for the mixing also ? If not ...
by Didaktik
Mon Oct 03, 2016 8:57 pm
Forum: Coding Questions
Topic: Code optimisation or translate to assembly?
Replies: 18
Views: 4892

Re: Code optimisation or translate to assembly?

I'm in real time converts 7 images. My version hesitate about 50-55 fps. Your version gives 62-64fps.
It's at least a few more frames per second. :wink:
Are these fps for a complete Spectrum emulator or just the screen conversion ?
If the procedure itself I created can only execute about 62 times ...
by Didaktik
Mon Oct 03, 2016 7:18 pm
Forum: Coding Questions
Topic: Code optimisation or translate to assembly?
Replies: 18
Views: 4892

Re: Code optimisation or translate to assembly?

I tried a SSE2 version since I like old 8 bit computers.
Please let me know how it performs compared to the original code.

#FlipY and #SwapRB can be used to configure the output.
The colors were taken from the javascript source of a spectrum emulator.
You can change these as you like.


Thank you ...
by Didaktik
Sun Oct 02, 2016 5:22 pm
Forum: Coding Questions
Topic: Code optimisation or translate to assembly?
Replies: 18
Views: 4892

Re: Code optimisation or translate to assembly?

perhaps it makes sense to use sse2 instructions?
If you do that it's best to decode one 8x8 pixel block after the other so you don't have to load the attributes so often.
But using SSE2 only makes sense if you always need to output to a 32 bit buffer.

It helps to know what your goal exactly is ...