dispalying/accessing image data from memory
-
i i had problem in accessing data from memory.i had used two method to read image file from disk one is 1.reading byte by byte or structure but this method is slow as i had to read the whole image byte by byte and it will take lot of time. 2.Through second method i m reading the whole image once not like byte by byte as method 1. i.e file.read(buffer,filesize);//reading the whole image at once. now i m displaying data from from both method method 1 give good results but when i try to display data readed in memory through second method it did not worked it show dummy data. Both these exe are seperate application.When i save the data readed through second method in file then it save and work fine.the only problem is displaying/accessing The purpose of reading from memory n displaying was that i want to confirm that bitmaps is correctaly copied in memory, and purpose of displaying through cout<< was that i m varified that both outputs are same, and if i perform the operations like changing its bits from memory then get the correct bits to change.
Tasleem Arif
-
i i had problem in accessing data from memory.i had used two method to read image file from disk one is 1.reading byte by byte or structure but this method is slow as i had to read the whole image byte by byte and it will take lot of time. 2.Through second method i m reading the whole image once not like byte by byte as method 1. i.e file.read(buffer,filesize);//reading the whole image at once. now i m displaying data from from both method method 1 give good results but when i try to display data readed in memory through second method it did not worked it show dummy data. Both these exe are seperate application.When i save the data readed through second method in file then it save and work fine.the only problem is displaying/accessing The purpose of reading from memory n displaying was that i want to confirm that bitmaps is correctaly copied in memory, and purpose of displaying through cout<< was that i m varified that both outputs are same, and if i perform the operations like changing its bits from memory then get the correct bits to change.
Tasleem Arif
I thinks that read function has limit in term of number of bytes, so don't read whole image at once, but read in size of 10000-20000 bytes file.read(buffer,size) buffer=buffer+size use this way and let me know wht happens Subhash jain (Sundyne Technologies pvt. ltd.- 604,B wing,Trade world Lower parel Mumbai)