AGB  ·  Datenschutz  ·  Impressum  







Anmelden
Nützliche Links
Registrieren
Zurück Delphi-PRAXiS Sprachen und Entwicklungsumgebungen Object-Pascal / Delphi-Language Delphi How elimitnate flicker of Form on resizing?
Thema durchsuchen
Ansicht
Themen-Optionen

How elimitnate flicker of Form on resizing?

Ein Thema von flashcoder · begonnen am 6. Feb 2018 · letzter Beitrag vom 9. Feb 2018
Antwort Antwort
Seite 2 von 2     12   
EWeiss
(Gast)

n/a Beiträge
 
#11

AW: How elimitnate flicker of Form on resizing?

  Alt 8. Feb 2018, 01:11
i can not see any resize Event in your example
after create the form in Fullscreen

so i not understand what your do.

greets
  Mit Zitat antworten Zitat
flashcoder

Registriert seit: 10. Nov 2013
83 Beiträge
 
#12

AW: How elimitnate flicker of Form on resizing?

  Alt 8. Feb 2018, 01:22
i can not see any resize Event in your example
after create the form in Fullscreen

so i not understand what your do.

greets
The Form is resized inside of TakeScreenshot procedure.
Relative to my last answer, what component (in my case) i can apply custom DubleBuffer function?
Ex: the parameters received are of my Form? could give a example about where apply this function?

Geändert von flashcoder ( 8. Feb 2018 um 01:26 Uhr)
  Mit Zitat antworten Zitat
EWeiss
(Gast)

n/a Beiträge
 
#13

AW: How elimitnate flicker of Form on resizing?

  Alt 8. Feb 2018, 01:24
i can not see any resize Event in your example
after create the form in Fullscreen

so i not understand what your do.

greets
The Form is resized inside of TakeScreenshot procedure.
yes and then?
i see a Fullscreen without drawing any and after can't resize the form.
not understand how your see the flicker.. nothing is draw to the Fullscreen Window

sorry for my bad english.

Zitat:
Ex: the parameters received are of my Form? could give a example about where apply this function?
how?
if nothing paint on the fullcreen and i can not resize it.
and you has a example see my Starwars Scrolltext, please compare

if understand your code correctly then you create a CompatibleDC here.

DesktopCanvas := TCanvas.Create; that should be
DesktopCanvas := DoubleBuffer(Form1.Canvas.Handle, rc.Right, rc.Bottom, CreateBuffer);
now draw to DesktopCanvas
..
then use
DoubleBuffer(0, 0, 0, DestroyBuffer);
which bitblt your result to the Target window and free the ressources.


greets

Geändert von EWeiss ( 8. Feb 2018 um 01:59 Uhr)
  Mit Zitat antworten Zitat
flashcoder

Registriert seit: 10. Nov 2013
83 Beiträge
 
#14

AW: How elimitnate flicker of Form on resizing?

  Alt 8. Feb 2018, 02:08
Unfortunately i not understood your custom DoubleBuffer function.
Probably this can work to remove flicker when Form is resized in TakeScreenshot method, but i'm totally lost about how implement on my code
  Mit Zitat antworten Zitat
EWeiss
(Gast)

n/a Beiträge
 
#15

AW: How elimitnate flicker of Form on resizing?

  Alt 8. Feb 2018, 03:45
Unfortunately i not understood your custom DoubleBuffer function.
Probably this can work to remove flicker when Form is resized in TakeScreenshot method, but i'm totally lost about how implement on my code
Delphi-Quellcode:
  if DoSnapShot then
  begin
    DoSnapShot := False;

    DesktopHwnd := GetDesktopWindow;
    DesktopDC := GetDC(DesktopHwnd);

    DesktopCanvas := DoubleBuffer(Canvas.Handle, ScreenRect.Right, ScreenRect.Bottom, CreateBuffer);
    BitBlt(DesktopCanvas, 0, 0, ScreenRect.Right, ScreenRect.Bottom, DesktopDC, 0, 0, SRCCOPY);
    DoubleBuffer(0, 0, 0, DestroyBuffer);

    ReleaseDc(DesktopHwnd, DesktopDC);
  end;
check this works by me..

EDIT:
Your problem is not the flickering but the setting of the height and width to 0
and then back to the old Position (Fullscreen)
Rethink your approach

using.. "Hide, Show" or "minimize, maximize" or create a Container for the Capture.
just a Suggestion.

greets

Geändert von EWeiss ( 8. Feb 2018 um 05:58 Uhr)
  Mit Zitat antworten Zitat
flashcoder

Registriert seit: 10. Nov 2013
83 Beiträge
 
#16

AW: How elimitnate flicker of Form on resizing?

  Alt 8. Feb 2018, 16:15

EDIT:
Your problem is not the flickering but the setting of the height and width to 0
and then back to the old Position (Fullscreen)
Rethink your approach

using.. "Hide, Show" or "minimize, maximize" or create a Container for the Capture.
just a Suggestion.

greets
@EWeiss,

this idea of container seems more appropiated for me, but my form still will appear on screenshot?
I not want hide/show or minimoze/maximize, this not is good. Remember that background of Form must be erased before capture the screen.
This container could be a TImage or what?

Geändert von flashcoder ( 8. Feb 2018 um 16:17 Uhr)
  Mit Zitat antworten Zitat
EWeiss
(Gast)

n/a Beiträge
 
#17

AW: How elimitnate flicker of Form on resizing?

  Alt 9. Feb 2018, 00:07
Zitat:
but my form still will appear on screenshot?
yes..

You change the size on every call that is wrong. (So you have to live with your current Situation)
You do not want to hide that windows, that's wrong. (so the form is still appear)

Unfortunately I can't help you anymore.. find your own way

greets

Geändert von EWeiss ( 9. Feb 2018 um 00:10 Uhr)
  Mit Zitat antworten Zitat
flashcoder

Registriert seit: 10. Nov 2013
83 Beiträge
 
#18

AW: How elimitnate flicker of Form on resizing?

  Alt 9. Feb 2018, 00:54
Zitat:
but my form still will appear on screenshot?
yes..

You change the size on every call that is wrong. (So you have to live with your current Situation)
You do not want to hide that windows, that's wrong. (so the form is still appear)

Unfortunately I can't help you anymore.. find your own way

greets
Ok, thank you very much by all your answers
  Mit Zitat antworten Zitat
EWeiss
(Gast)

n/a Beiträge
 
#19

AW: How elimitnate flicker of Form on resizing?

  Alt 9. Feb 2018, 01:16
that works..
with my own way so you can see i have give you all required Information.
bye.

Anhang gelöscht.

greets

Geändert von EWeiss ( 9. Feb 2018 um 23:50 Uhr)
  Mit Zitat antworten Zitat
Antwort Antwort
Seite 2 von 2     12   


Forumregeln

Es ist dir nicht erlaubt, neue Themen zu verfassen.
Es ist dir nicht erlaubt, auf Beiträge zu antworten.
Es ist dir nicht erlaubt, Anhänge hochzuladen.
Es ist dir nicht erlaubt, deine Beiträge zu bearbeiten.

BB-Code ist an.
Smileys sind an.
[IMG] Code ist an.
HTML-Code ist aus.
Trackbacks are an
Pingbacks are an
Refbacks are aus

Gehe zu:

Impressum · AGB · Datenschutz · Nach oben
Alle Zeitangaben in WEZ +1. Es ist jetzt 06:10 Uhr.
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz