Click here to Skip to main content
15,890,123 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
Questionhow to restricted browser Pin
vc-programmer-29-Nov-04 21:43
vc-programmer-29-Nov-04 21:43 
AnswerRe: how to restricted browser Pin
ThatsAlok30-Nov-04 0:58
ThatsAlok30-Nov-04 0:58 
Questionwhat the hell is this grammar all about Pin
LiYS29-Nov-04 21:20
LiYS29-Nov-04 21:20 
AnswerRe: what the hell is this grammar all about Pin
Steve S29-Nov-04 21:34
Steve S29-Nov-04 21:34 
GeneralRe: what the hell is this grammar all about Pin
LiYS29-Nov-04 21:45
LiYS29-Nov-04 21:45 
GeneralRe: what the hell is this grammar all about Pin
benjymous29-Nov-04 22:38
benjymous29-Nov-04 22:38 
GeneralRe: what the hell is this grammar all about Pin
LiYS29-Nov-04 22:53
LiYS29-Nov-04 22:53 
GeneralRe: what the hell is this grammar all about Pin
benjymous29-Nov-04 22:59
benjymous29-Nov-04 22:59 
Yup - basically if you type unsigned int nDay; you're saying "I want an int called nDay" and the compiler will likely allocate 32 bits for it.

If you have unsigned int nDay:5; you're saying "I only need 5 bits for this variable" - whether the compiler allocates 5 bits, or gives you a full 32 bits is up to the compiler, but if it works properly it'll let you save memory.

So in other words, 9 times out of 10 you'll probably never use it.

In the example you gave, it looks like it's something to do with parsing the data in an MP3 file - this is quite a common use of bitfields, since it lets you quickly read in an abstract binary file into sensible variables



--
Help me! I'm turning into a grapefruit!
Phoenix Paint - back from DPaint's ashes!

GeneralRe: what the hell is this grammar all about Pin
LiYS29-Nov-04 23:08
LiYS29-Nov-04 23:08 
AnswerRe: what the hell is this grammar all about Pin
David Crow30-Nov-04 3:09
David Crow30-Nov-04 3:09 
Generalhighlighting a portion of a bitmap Pin
Arrun29-Nov-04 19:57
Arrun29-Nov-04 19:57 
QuestionFunction Parameters in a C DLL? Pin
Arsalan Malik29-Nov-04 19:41
Arsalan Malik29-Nov-04 19:41 
AnswerRe: Function Parameters in a C DLL? Pin
basementman30-Nov-04 4:45
basementman30-Nov-04 4:45 
GeneralRe: Function Parameters in a C DLL? Pin
Arsalan Malik30-Nov-04 16:53
Arsalan Malik30-Nov-04 16:53 
GeneralOLE2ANSI issue in VS.Net 2003 Pin
sajpt29-Nov-04 19:36
sajpt29-Nov-04 19:36 
GeneralRe: OLE2ANSI issue in VS.Net 2003 Pin
El'Cachubrey29-Nov-04 20:25
El'Cachubrey29-Nov-04 20:25 
GeneralRe: OLE2ANSI issue in VS.Net 2003 Pin
sajpt29-Nov-04 20:48
sajpt29-Nov-04 20:48 
GeneralRe: OLE2ANSI issue in VS.Net 2003 Pin
sajpt29-Nov-04 23:22
sajpt29-Nov-04 23:22 
GeneralReading function signature from DLL... Pin
Orkun GEDiK29-Nov-04 18:50
Orkun GEDiK29-Nov-04 18:50 
GeneralRe: Reading function signature from DLL... Pin
ThatsAlok29-Nov-04 19:00
ThatsAlok29-Nov-04 19:00 
GeneralRe: Reading function signature from DLL... Pin
Orkun GEDiK29-Nov-04 20:43
Orkun GEDiK29-Nov-04 20:43 
GeneralRe: Reading function signature from DLL... Pin
ThatsAlok30-Nov-04 1:11
ThatsAlok30-Nov-04 1:11 
GeneralCopy Screen Pin
Timothy Grabrian29-Nov-04 18:09
professionalTimothy Grabrian29-Nov-04 18:09 
GeneralRe: Copy Screen Pin
ThatsAlok29-Nov-04 19:23
ThatsAlok29-Nov-04 19:23 
GeneralRe: Copy Screen Pin
David Crow30-Nov-04 5:42
David Crow30-Nov-04 5:42 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.