[<<] [<] Page 1 of 1 [>] [>>] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
Drawing Iamge from buffer
From: "Sheetal Kumar" ####@####.#### Date: 30 Dec 2002 09:53:21 -0000 Message-Id: <se106406.085@LTS1> Dear all, I written code to draw an image ,reading data from memory. I used following code , but it not worked. Image size is [512 * 512] W * H in pixels. ////////// code //////////////// int* ImageData; int nCount=0; ImageData = (int*)malloc(sizeof(int)*(512*512)); // to show black image i filled allocated mem with // zero // this not worked GrDrawImageFromBuffer(rawwidgetid,rawwidgetgc,0,0,512,512,ImageData,512,0); if any one knows answer to this please mail me. Thanking You, Sheetalkumar. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
Re: [nanogui] Drawing Iamge from buffer
From: Jordan Crouse ####@####.#### Date: 31 Dec 2002 22:56:02 -0000 Message-Id: <20021231154157.0805cf88.jordanc@censoft.com> > GrDrawImageFromBuffer(rawwidgetid,rawwidgetgc,0,0,512,512,ImageData,512,0); Its the 8th argument that got you. 'size' should be the size of the buffer (in your case, thats 512 * 512 * sizeof(int)). Jordan On > Mon, 30 Dec 2002 15:19:06 +0530 "Sheetal Kumar" ####@####.#### wrote: > Dear all, > I written code to draw an image ,reading data from > memory. I used following code , but it not worked. > Image size is [512 * 512] W * H in pixels. > > ////////// code //////////////// > > int* ImageData; > int nCount=0; > > ImageData = (int*)malloc(sizeof(int)*(512*512)); > > // to show black image i filled allocated mem with // zero > // this not worked > > GrDrawImageFromBuffer(rawwidgetid,rawwidgetgc,0,0,512,512,ImageData,512,0); > > if any one knows answer to this please mail me. > Thanking You, > Sheetalkumar. > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: ####@####.#### > For additional commands, e-mail: ####@####.#### > > | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
[<<] [<] Page 1 of 1 [>] [>>] |