|
Pavan Tiruveedhula wrote: Is there any simple way of reading JPEG and TIFF images without using all those big libraries??
I read your message as decoding an image format into raw RGB values. If you for example take uncompressed TIFF files (see Google), it's a rather simple parsing of file header and reading binary data. For a more complex format like JPEG you would need to implement the complete algorithm for decompressing/transforming... or just use a free library.
Btw, Windows GDI allows you to draw JPEG/PNG image data without manual decoding, see SetDIBitsToDevice. Easy peasy.
Hope it helps.
|
|
|
|
|
|
Pavan Tiruveedhula wrote: Is there any simple way of reading JPEG and TIFF images without using all those big libraries??
GDI+ is the easiest option here. But, the point of libraries is to MAKE it easy, by stopping you from having to write the code yourself.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
You're going to need a big library if you want to draw TIFF images because there is no code built into MFC or Windows to load TIFF images. I recommend FreeImage. It has all the best features, and even works on mobile devices. You can (with a little programming ability) even reduce the "big library" down to the absolute minimum that only supports the image types you intend to load.
"Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997 ----- "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001
|
|
|
|
|
Is there a C/C++ function that will tell how many bytes are valid in a buffer?
|
|
|
|
|
not in general.
if it was allocated with GlobalAlloc/HeapAlloc, you can get the size with GlobalSize/HeapSize.
|
|
|
|
|
kani98 wrote: Is there a C/C++ function that will tell how many bytes are valid in a buffer?
Of course not. That can only be determined by the code that placed those bytes in the buffer to begin with.
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
Yes
What's a "buffer"?
led mike
|
|
|
|
|
|
what npos means?
i want to make a while( string.Find() )
which will be terminate (the while) when there isnt any foundation
|
|
|
|
|
Immunity18 wrote: what npos means?
It's a member of basic_string .
npos
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
|
I created a new dialog window that includes a number of push-buttons and radio-buttons. When I open ClassWizard I see all my IDs in the "Object IDs" list on the "Message Maps" tab. However on the "Member Variables" tab, some of the IDs are not showing in the "Control IDs" list.
I have other dialog windows that are set up the same way and I don't have this problem.
What can cause this?
I am using MS VC6.
Thanks!
jpyp
|
|
|
|
|
jpyp wrote: However on the "Member Variables" tab, some of the IDs are not showing in the "Control IDs" list.
Because those controls do not have the WS_GROUP style.
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
Thanks that did the trick.
However I don't understand why all my push-buttons IDs on that window are showing on the "Member Variables" tab as none of them except one has this property set. Furthermore my radio-buttons in my other windows do not have the WS_GROUP property set, and they are all showing on the "Member Variables" tab. Both windows have the same properties and are created the same way.
Something else seems to be going here. Any idea?
Thanks!
jpyp
|
|
|
|
|
What is the significance of heap, stack and TLS and how do they differ wrt each other. An explanation or some links would be highly appreciated.
|
|
|
|
|
tom groezer wrote: What is the significance of heap, stack and TLS...
Heap
Stack
TLS
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
hello bro...i am new to java and i want to learn this language..from where should i start? i want to make one programme for my work...plz help me..okay...hoping for your favaourable response......your's faithfully......
|
|
|
|
|
confid3nce wrote: i want to learn this language
Java or C++?
confid3nce wrote: from where should i start?
At the beginning.
confid3nce wrote: i want to make one programme for my work
That's it? Just one?
confid3nce wrote: hoping for your favaourable response
Lot's o' luck!
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
DavidCrow wrote: At the beginning.
|
|
|
|
|
My user community would like me to use the MS Access Table view GUI to edit the contents of an internal table that is a copy of a database table. The table is to manipulated in a modeless dialog. Obviously, it would be most productive to embed parts of the MS Access code in my code. My questions are:
1. Possible?
2. Feasible?
3. If feasible, some pointers on how to do this so that changes are immediately available to the C++ program would be appreciated.
Thanks in advance.
TedWagstaff
|
|
|
|
|
TedWagstaff wrote: Obviously, it would be most productive to embed parts of the MS Access code...
Are you referring to Excel's COM interface? If so, search for Excel Automation.
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
Thanks for the pointer. It has opened some doors. Not quite the way I was thinking but that is why the post.
TedWagstaff
|
|
|
|
|
hey folks,
i know how to create a window using create and giving it a rectangle region:
<br />
Create(NULL, "Windows Application", WS_OVERLAPPEDWINDOW,<br />
CRect(120, 100, 700, 480), NULL);<br />
but how do I change the rectangle region...
I mean clicking on a button and resizing the window to half or stuff (better to a Rectangle I calculate)???
I know it's simple but couldn't find a link
thx in advance
zqueezy
|
|
|
|
|
well now I Found
MoveWindow
to SetThatRegion but all I get is a "Debug Assertion Failed!"...
I actually wanted to to resize a subelement of my DialogClass. So I did a movewindow in my Dialog::OnSize(...) method.
I guess the error comes from the initialization where there isn't any SubElement (although it's initialized but maybe not visible?)
because
GetWindowRect also fails with the same assertion failed
|
|
|
|