Search found 42 matches: globalfree

Return to advanced search

Re: *** Curso de C para programadores Harbour.

Hola Otto modifica esto:

GlobalAllocPtr -> GlobalAlloc
GlobalFreePtr -> GlobalFree

Por otro lado he investigado un poco el tema y creo que he visto algo en el propio Harbour.
by xmanuel
Thu Jul 15, 2021 1:11 pm
 
Forum: FiveWin para Harbour/xHarbour
Topic: *** Curso de C para programadores Harbour.
Replies: 141
Views: 18234

Re: reduce an image to a fixed size

local hBmp
local hDib := DibFromBitmap( hBmp := ResizeBitmap( hBitmap, nWidth, nHeight ) )

DibWrite( cFileName, hDib )
GloBalFree( hDib )
DeleteObject( hBmp )
by Antonio Linares
Sat Oct 17, 2020 8:50 am
 
Forum: FiveWin for Harbour/xHarbour
Topic: reduce an image to a fixed size
Replies: 9
Views: 988

Re: Ayuda DLL

Antonio buenos dias, gracias por la ayuda Agrego la VM.LIB (xharbour), y me manda estos errorres :( :( Proyecto: Kept5, Entorno: BorlandDLL: [1]:Harbour.Exe Source\Tseguro.prg /m /n /es2 /ki /iP:\32bits\xharbour\include;P:\32bits\FWH\INCLUDE /i /oObj\Tseguro.c xHarbour Compiler build 1.2.1 (SimpLex)...
by ricardog
Thu Aug 31, 2017 2:56 pm
 
Forum: FiveWin para Harbour/xHarbour
Topic: Ayuda DLL
Replies: 24
Views: 6328

Re: Save all the Screen to BMP

function save_scr()
LOCAL hBmp, hDib,h,cFile := "screen.bmp"
h:=getdesktopwindow()
hBmp := WndBitmap(h)
hDib := DibFromBitmap( hBmp )
DibWrite( cFile, hDib )
GloBalFree( hDib )
DeleteObject( hBmp )
RETURN nil
*

* Now i'm tring to convert the BMP file to JPG file....any help ?

by Romeo
Tue Oct 13, 2015 9:16 am
 
Forum: FiveWin for Harbour/xHarbour
Topic: Save all the Screen to BMP
Replies: 13
Views: 1836

Re: How to create remote desktop viewver within network ?

... := WndBitmap( ::hWnd )   local hDib := DibFromBitmap( hBmp )   DibWrite( cBmpFile, hDib )   GloBalFree( hDib )   DeleteObject( hBmp )return ( File( cBmpFile ) ) If you want to save the entire desktop ...
by Antonio Linares
Tue Aug 26, 2014 7:54 am
 
Forum: FiveWin for Harbour/xHarbour
Topic: How to create remote desktop viewver within network ?
Replies: 3
Views: 723

Re: oGraph- how to save into bmp in silent mode

... LOCAL hBmp, hDib DEFAULT cFile := "TGraph.Bmp" hBmp := WndBitmap( Self:hWnd ) hDib := DibFromBitmap( hBmp ) DibWrite( cFile, hDib ) GloBalFree( hDib ) DeleteObject( hBmp ) RETURN ( FILE( cFile ) ) Best regards, Robb
by rhlawek
Sat Aug 16, 2014 12:17 am
 
Forum: FiveWin for Harbour/xHarbour
Topic: oGraph- how to save into bmp in silent mode
Replies: 7
Views: 2029

Re: How to keep a existing alpha-channel, saving a bitmap ?

... hDib := DibFromBitmap( ::hBitmap, ::hPalette ) local cTempFile := cTempFile() local lSaved, lAlpha := ::HasAlpha() DibWrite( cTempFile, hDib ) GloBalFree( hDib ) lSaved = FIConvertImageFile( cTempFile, cFile, nFormat, nQuality, lAlpha ) FErase( cTempFile ) return lSaved //---------- function ...
by ukoenig
Mon Jun 23, 2014 10:56 am
 
Forum: FiveWin for Harbour/xHarbour
Topic: How to keep a alpha-channel, save and resize a bitmap
Replies: 5
Views: 1869

Re: "Snap" for Clipper

... GETWNDDEFAULT()        (function  in WINDOW.PRG)    WINDOW.PRG     3224! 3425  3426 GETWNDRECT()           (function  in ?)    WINDOW.PRG     1707 GLOBALFREE()           (function  in ?)    WINDOW.PRG     2017 GLOBALGETATOMNAME()    (function  in ?)    WINDOW.PRG     1456  1457 GODOWN()         ...
by Antonio Linares
Sat Oct 26, 2013 9:44 am
 
Forum: Off Topic / Otros temas
Topic: "Snap" for Clipper
Replies: 7
Views: 6688

Re: Crear un Objeto

... a DIB de esta forma: hDib = DibFromBitmap( hBmp ) lo escribimos en un fichero: DibWrite( cNombreFichero, hDib ) Liberamos la memoria del DIB: GlobalFree( hDib ) y liberamos la memoria del bitmap: DeleteObject( hBmp )
by Antonio Linares
Tue Sep 17, 2013 1:27 pm
 
Forum: FiveWin para Harbour/xHarbour
Topic: Crear un Objeto
Replies: 19
Views: 2753

Re: oPrinter:SayBitmap/ GlobalAlloc-GlobalFree ¿fuga de memoria?

Antonio,

Me alegro de que el asunto quede resuelto :-)
by Antonio Linares
Fri Dec 16, 2011 12:11 pm
 
Forum: FiveWin para Harbour/xHarbour
Topic: oPrinter:SayBitmap/ GlobalAlloc-GlobalFree ¿fuga de memoria?
Replies: 15
Views: 4083

Re: oPrinter:SayBitmap/ GlobalAlloc-GlobalFree ¿fuga de memoria?

Antonio, Encontrado el problema; resulta que yo utilizo una RPreview modificada por algun compañero del foro, siento no recordar el nombre; es una RPreview que lleva una TListView con las miniaturas de las paginas. Pues bien, he puesto la preview original de fwh y YA NO HAY CONSUMO DE MEMORIA !! Muc...
by A.Martinez
Fri Dec 16, 2011 8:20 am
 
Forum: FiveWin para Harbour/xHarbour
Topic: oPrinter:SayBitmap/ GlobalAlloc-GlobalFree ¿fuga de memoria?
Replies: 15
Views: 4083

Re: oPrinter:SayBitmap/ GlobalAlloc-GlobalFree ¿fuga de memoria?

Antonio, RESPUESTA 1: Pues siento decirte que creo que NO es la StretchDIBits() porque si modifico lo que me has mandado y pongo: ...//        if( ( wWidth == 0 ) || ( wHeight == 0 ) )        if( 1 )           SetDIBitsToDevice( hDC, wCol, wRow, lpBmp->biWidth,                        ...
by A.Martinez
Thu Dec 15, 2011 7:54 pm
 
Forum: FiveWin para Harbour/xHarbour
Topic: oPrinter:SayBitmap/ GlobalAlloc-GlobalFree ¿fuga de memoria?
Replies: 15
Views: 4083

Re: oPrinter:SayBitmap/ GlobalAlloc-GlobalFree ¿fuga de memoria?

Antonio,

Si no haces el PREVIEW (quitando esa clausula), se produce la misma pérdida ?

gracias por tus pruebas,
by Antonio Linares
Thu Dec 15, 2011 7:41 pm
 
Forum: FiveWin para Harbour/xHarbour
Topic: oPrinter:SayBitmap/ GlobalAlloc-GlobalFree ¿fuga de memoria?
Replies: 15
Views: 4083

Re: oPrinter:SayBitmap/ GlobalAlloc-GlobalFree ¿fuga de memoria?

Buscando en google veo que otros programadores (en otros lenguajes) han tenido problemas tambien con esta función:

http://stackoverflow.com/questions/8036855/how-to-handle-gdi-resource-leak

Quizá eso nos de una pista de por donde buscar...
by Antonio Linares
Thu Dec 15, 2011 7:37 pm
 
Forum: FiveWin para Harbour/xHarbour
Topic: oPrinter:SayBitmap/ GlobalAlloc-GlobalFree ¿fuga de memoria?
Replies: 15
Views: 4083

Re: oPrinter:SayBitmap/ GlobalAlloc-GlobalFree ¿fuga de memoria?

Antonio, Bueno, lo importante es que ya sabemos de donde viene el problema: función StretchDIBits(). Ahora pensemos una estrategia... Miremos por ejemplo el código que use Wine para la función StretchDIBits(): http://cvs.winehq.org/cvsweb/wine/dlls/gdi/Attic/dib.c?rev=1.22&co...
by Antonio Linares
Thu Dec 15, 2011 7:29 pm
 
Forum: FiveWin para Harbour/xHarbour
Topic: oPrinter:SayBitmap/ GlobalAlloc-GlobalFree ¿fuga de memoria?
Replies: 15
Views: 4083
Next

Return to advanced search