Autor Beitrag
Hack Gott
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Beiträge: 409

Windows Vista
Delphi 2005 Personal, Delphi 7
BeitragVerfasst: Fr 04.01.08 22:47 
Hallo,
ich hab hier und bei schon bei Google verzweifelt gesucht. Und zwar: ich will eine TImage sehr schnell auf und ab bewegen, und zawr so dass es flüssig ist. (bz. nach links und nach rechts). In dem TImage ist ein png Bild (denke aber mal dass das nichts ändert). Das ganze sollte so ablaufen, dass währenddesen, nicht das ganze Programm abstürtzt sondern einfach weiterarbeitet (wie bei einem Timer). Ein Timer macht den ganzen Spaß aber zu langsam. Auch DoubleBufferd hilft nicht weiter. Selbst mit der schnellsten Geschwinidigkeit bei einem Timer erzielt es nicht den gewünschten Effekt. Gibt es noch eine andere Möglichkeit.

Einen schönen Abend noch und ein schönes Woschende
Hack Gott

_________________
"Je mehr Käse, desto mehr Löcher; Je mehr Löcher, desto weniger Käse. Daraus folgt: Je mehr Käse desto weniger Käse!"
Fabian E.
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 554

Windows 7 Ultimate
Visual Studio 2008 Pro, Visual Studion 2010 Ultimate
BeitragVerfasst: Fr 04.01.08 22:53 
also erst mal würde ich dir davon abraten ein TImage zu nutzn...
das ist an sich schon recht langsam. villicht wär es für dich besser wen du direkt auf das canvas deinr form zeichnest.
das ist wesntlich performanter.

ansosten könntest du eine schleife nehmen in die Application.ProcessMesagesdrinne is.

gruß
Hack Gott Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Beiträge: 409

Windows Vista
Delphi 2005 Personal, Delphi 7
BeitragVerfasst: Sa 05.01.08 13:47 
dank schonmal...

ok, und wie kann ich den ein png in canvas laden?

_________________
"Je mehr Käse, desto mehr Löcher; Je mehr Löcher, desto weniger Käse. Daraus folgt: Je mehr Käse desto weniger Käse!"
Andreas Pfau
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 997



BeitragVerfasst: So 06.01.08 01:13 
Genauso wie du es in ein TImage lädst ;)

Zugegeben, ich verwende Delphi7, anscheinend unterstützen neuere Delphi-Versionen PNGs in TImages. Aber demnach gibt es unter Image.Picture eine Klasse, welche PNGs lädt. Die müsstest du dazu wohl suchen und verwenden. Und ich bin mir ganz sicher dass Canvas.Draw() auch diese Klasse unterstützt.

_________________
Life is a bad adventure, but the graphic is really good!
Narses
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Administrator
Beiträge: 10185
Erhaltene Danke: 1261

W11x64
TP3 .. D7pro .. D10.2CE
BeitragVerfasst: So 06.01.08 01:17 
Moin!

user profile iconHack Gott hat folgendes geschrieben:
ok, und wie kann ich den ein png in canvas laden?

Schau mal nach Suche in: Delphi-Forum, Delphi-Library TPNGIMAGE, damit solltest du weiter kommen. ;)

cu
Narses

_________________
There are 10 types of people - those who understand binary and those who don´t.