Delphi-PRAXiS
Seite 2 von 2     12   

Delphi-PRAXiS (https://www.delphipraxis.net/forum.php)
-   Programmieren allgemein (https://www.delphipraxis.net/40-programmieren-allgemein/)
-   -   Farbe wird verändert (https://www.delphipraxis.net/192643-farbe-wird-veraendert.html)

Blup 17. Mai 2017 08:34

AW: Farbe wird verändert
 
Was war dann die Ursache und wie hast du das Problem gelöst?

EWeiss 17. Mai 2017 17:13

AW: Farbe wird verändert
 
Zitat:

Zitat von Blup (Beitrag 1371717)
Was war dann die Ursache und wie hast du das Problem gelöst?

Mit der geänderten Function von Amateurprofi und angehängten stdcall
stdcall wirkt manchmal wunder. (vor allem dann wenn diese Function sich in einer DLL befindet.)

Delphi-Quellcode:
function RGBtoGray(Value: COLORREF):COLORREF; stdcall;
asm
       movzx  edx,al
       imul   edx,19595  // Red
       movzx  ecx,ah
       imul   ecx,38470  // Greean
       shr    eax,16
       imul   eax,7471   // Blue
       add    eax,ecx
       add    eax,edx
       shr    eax,16
       mov    ah,al
       shl    eax,8
       mov    al,ah
 end;
gruss


Alle Zeitangaben in WEZ +1. Es ist jetzt 01:42 Uhr.
Seite 2 von 2     12   

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