nanogui: What's wrong with GdBitmap?


Previous by date: 9 Oct 2000 18:56:23 -0000 [patch] wintern.h enhancements for VxWorks, Brent Thompson
Next by date: 9 Oct 2000 18:56:23 -0000 [patch] windef.h enhancements for VxWorks, Brent Thompson
Previous in thread:
Next in thread:

Subject: What's wrong with GdBitmap?
From: tuan ####@####.####
Date: 9 Oct 2000 18:56:23 -0000
Message-Id: <39E21A19.4E554ED9@topiaventures.com>

Hi All,


I did the following that try to draw an bitmap that was create in the
new buffer, but my bit map draw on the screen was not correct. What's
wrong? Is the way that I use GdBitmap is corrected.

Tuan


	MWIMAGEBITS  *hbitmap;
	int nWidth, nHeight;
	int size, linelen;
	nWidth = 200;
	nHeight = 200;
	GdFillRect(psd,0,0,500,500);
	PSD newPSD = psd->AllocateMemGC(psd);
	GdCalcMemGCAlloc(psd, nWidth, nHeight, 1, 2, &size, &linelen);
	hbitmap = new MWIMAGEBITS[size];
	MWBOOL result = psd->MapMemGC(newPSD,200,200,1,2,linelen , size
,hbitmap);

        GdSetForeground(blue);
        GdEllipse(newPSD,50,50,50,50, TRUE);

        GdLine(newPSD, 0, 0, 100,100, TRUE);
	GdBitmap(psd,100,100,200, 200,hbitmap) ;

Previous by date: 9 Oct 2000 18:56:23 -0000 [patch] wintern.h enhancements for VxWorks, Brent Thompson
Next by date: 9 Oct 2000 18:56:23 -0000 [patch] windef.h enhancements for VxWorks, Brent Thompson
Previous in thread:
Next in thread:


Powered by ezmlm-browse 0.20.