Einzelnen Beitrag anzeigen

alf.stefan

Registriert seit: 11. Apr 2003
88 Beiträge
 
Delphi 7 Professional
 
#7

Re: DLL Funktion(en) von openCV einbinden

  Alt 17. Feb 2010, 10:06
Hier sind mal die definitionen der verwendeten Datentypen

Delphi-Quellcode:
  type

     PCvSeqBlock = ^CvSeqBlock;
     CvSeqBlock = record
          prev : PCvSeqBlock;
          next : PCvSeqBlock;
          start_index : longint;
          count : longint;
          data : Pchar;
       end;

     PCvSeq = ^CvSeq;
     CvSeq = record
          flags : longint;
          header_size : longint;
          h_prev : PCvSeq;
          h_next : PCvSeq;
          v_prev : PCvSeq;
          v_next : PCvSeq;
          total : longint;
          elem_size : longint;
          block_max : Pchar;
          ptr : Pchar;
          delta_elems : longint;
          storage : PCvMemStorage;
          free_blocks : PCvSeqBlock;
          first : PCvSeqBlock;
       end;
Type
  PCvMemStorage = ^TCvMemStorage;
  P2PCvMemStorage = ^PCvMemStorage;
  CvMemStorage = Record
                   signature : integer;
                   bottom : PCvMemBlock; //* first allocated block */
                   top : PCvMemBlock; //* current memory block - top of the stack */
                   parent : PCvMemStorage; //* borrows new blocks from */
                   block_size: integer; //* block size */
                   free_space: integer; //* free space in the current block */
end;
type
  CvPoint2D32f = record
                    x : Single;
                    y : Single;
                 end;
  TCvPoint2D32f = CvPoint2D32f;
  PCvPoint2D32f = ^TCvPoint2D32f;
end;
welche Datentypen soll ich noch posten?



cvArr, cvMat/cvSeq, iplImage bauen alle aufeinander auf bei vielen funktionen die ein pIplImage erwarten steht in der deklaration auch "nur" ein pCvArr, deshalb denke ich dass es so richtig ist, aber ganz sicher bin ich mir nicht!

das mit der line ist uU ein folgeproblem das aber denke ich noch nicht zum tragen kommt. Wenn ein string übergeben werden muss hat es immer ganz gut funktioniert wenn ich @myStr[0] statt pChar übergeben habe deshalb habe ich es analog dazu so gemacht @line[0] als pointer auf das erste element.
  Mit Zitat antworten Zitat