AGB  ·  Datenschutz  ·  Impressum  







Anmelden
Nützliche Links
Registrieren
Thema durchsuchen
Ansicht
Themen-Optionen

C++ Übersetzung nach Delphi

Ein Thema von Johnny_W · begonnen am 15. Feb 2008 · letzter Beitrag vom 18. Feb 2008
 
Muetze1
(Gast)

n/a Beiträge
 
#5

Re: C++ Übersetzung nach Delphi

  Alt 16. Feb 2008, 15:10
Mal in Theorie getippt:

Delphi-Quellcode:
function SaveBitmapFile(filename : PChar, image : PByte,width : DWord, height : dword): integer;
var
  p : array of byte;
  x,y : integer;
  bitm : TBitmap;
  lDest, lSource: PByte;
begin
  lSource := Image; // damit wir Image nicht verändern

  bitm := TBitmap.Create;
  try
    bitm.PixelFormat := pf32bit;
    bitm.Width := Width;
    bitm.Height := Height;

    for y:= 0 to heigth-1 do
    begin
      lDest := bitm.Scanline[y];

      Move(lSource^, lDest^, Width * 4);
  
      Inc(lSource, Width*4);
    end;
  finally
    bitm.Free;
  end;
end;
  Mit Zitat antworten Zitat
 


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 07:01 Uhr.
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024-2025 by Thomas Breitkreuz