CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Page 3 of 4 FirstFirst 1234 LastLast
Results 31 to 45 of 46
  1. #31
    Join Date
    Apr 2008
    Posts
    214

    Re: C++ bitmap - why?

    bmp.palette is being set to the bitmapinfo.bmiColors (the palette in the structure) address space, so when we read in the palette from the file, it reads into that address space and then because bitmapinfo is used to draw the image, it has everything needed? Just say yes, so we can leave.

    Code:
    if(!(bmp.palette = (RGBQUAD*) ((BYTE*)bmp.bitmapInfo + sizeof(BITMAPINFOHEADER))))
    if(!fread(bmp.palette, sizeof(RGBQUAD), bmp.nColors, file))

  2. #32
    Join Date
    Feb 2005
    Posts
    2,160

    Re: [RESOLVED] C++ bitmap - why?

    Yes.

  3. #33
    Join Date
    Apr 2004
    Location
    England, Europe
    Posts
    2,492

    Re: [RESOLVED] C++ bitmap - why?

    To put it another way, you are passing pbmi to the SetDIBitsToDevice and pbmi contains a pointer to the palette, so it looks like the palette is being used by SetDIBitsToDevice.
    My hobby projects:
    www.rclsoftware.org.uk

  4. #34
    Join Date
    May 2002
    Location
    Lindenhurst, NY
    Posts
    867

    Re: [RESOLVED] C++ bitmap - why?

    Why someone like this gets any help at all after such temper tantrum outbursts is beyond me.

    Zaryk needs help with programming....then insults the people trying to help.

    Personally, even if I weren't offended by this ***, I wouldn't waste time trying to teach programming to someone who is so stupid that they insult the people they're asking for help from. Its like trying to teach an ape how to play piano--a waste of time.

  5. #35
    VictorN's Avatar
    VictorN is offline Super Moderator Power Poster
    Join Date
    Jan 2003
    Location
    Hanover Germany
    Posts
    20,430

    Re: [RESOLVED] C++ bitmap - why?

    Quote Originally Posted by Martin O View Post
    Why someone like this gets any help at all after such temper tantrum outbursts is beyond me.

    Zaryk needs help with programming....then insults the people trying to help.
    Well, I could agree with you...
    But perhaps, OP would be able (after so long discussion) to understand, that he was wrong with his attacks to the people trying to help him...
    At least, it is what I hope...
    Victor Nijegorodov

  6. #36
    Join Date
    May 2002
    Location
    Lindenhurst, NY
    Posts
    867

    Re: [RESOLVED] C++ bitmap - why?

    Quote Originally Posted by VictorN View Post
    But perhaps, OP would be able (after so long discussion) to understand, that he was wrong with his attacks to the people trying to help him...
    At least, it is what I hope...
    I doubt it. I remembered his name from a year or 2 ago. He pulled the same 'how dare you ask me to clarify myself, you must be stupid' BS then & still does it now. The stench of entitlement coming from him is overpowering. He's one of those simultaneously arrogant & incompetent individuals that I've seen too much of in IT. He's an extreme example of that.

  7. #37
    VictorN's Avatar
    VictorN is offline Super Moderator Power Poster
    Join Date
    Jan 2003
    Location
    Hanover Germany
    Posts
    20,430

    Re: [RESOLVED] C++ bitmap - why?

    Quote Originally Posted by Martin O View Post
    I doubt it. I remembered his name from a year or 2 ago. He pulled the same 'how dare you ask me to clarify myself, you must be stupid' BS then & still does it now...
    Ok, Thanks for the info.
    I'll keep it in mind...
    Victor Nijegorodov

  8. #38
    Join Date
    Apr 1999
    Posts
    27,449

    Re: [RESOLVED] C++ bitmap - why?

    Quote Originally Posted by Martin O View Post
    I doubt it. I remembered his name from a year or 2 ago. He pulled the same 'how dare you ask me to clarify myself, you must be stupid' BS then & still does it now. The stench of entitlement coming from him is overpowering. He's one of those simultaneously arrogant & incompetent individuals that I've seen too much of in IT. He's an extreme example of that.
    Going by the previous posting history, the schtick is to ask a question with hardly any info, and then when simply asked for more info, insults are directed to the ones asking for more info.

    One thread had to be shut down by Andreas because of this tactic.

    Regards,

    Paul McKenzie

  9. #39
    Join Date
    Apr 2008
    Posts
    214

    Re: [RESOLVED] C++ bitmap - why?

    Lucky for me, I don't feel bad for my outbursts. All it took to answer the question was the explanation of why those two lines worked, and everyone decided to go stupid, because most of the time they get people asking questions that require more detail. It could have been over in 1 reply, like most of my questions I have posted here. It's sad really.

    I didn't gain anything from this, like most of my posts, except to pass the time while I was at work; I already had the answer when I asked. I like being argumentative and annoying. What makes all the much better, is that no one knows who I am. Plus, I have multiple personality disorder,....so I don't even know who I am.

    I asked my 21 yr old brother, has a few years of experience, the same question, same detail, same 2 lines; and he answered on his 1st reply. But, then again, I understand why. Our father actually taught us to think before talking; use critical intelligence and observation; analyze everything.

    I don't really care if you believe me or not. Honestly, I don't care if I get kicked off codeguru, there will always be someone to annoy as long as they let it get to them. Makes it fun, for me at least. Cheers.

  10. #40
    Join Date
    May 2002
    Location
    Lindenhurst, NY
    Posts
    867

    Re: [RESOLVED] C++ bitmap - why?

    Quote Originally Posted by zaryk View Post
    Plus, I have multiple personality disorder
    I remember him mentioning this a few years ago--I don't think he's kidding.

  11. #41
    Join Date
    Feb 2002
    Posts
    4,640

    Re: [RESOLVED] C++ bitmap - why?

    Quote Originally Posted by zaryk View Post
    I didn't gain anything from this, like most of my posts, except to pass the time while I was at work; I already had the answer when I asked. I like being argumentative and annoying.
    Nice. Try this in a bar, or on the street, and see how long you last...

    Viggy

  12. #42
    Join Date
    Apr 2004
    Location
    England, Europe
    Posts
    2,492

    Re: [RESOLVED] C++ bitmap - why?

    Quote Originally Posted by zaryk View Post
    I didn't gain anything from this, like most of my posts, except to pass the time while I was at work; I already had the answer when I asked. I like being argumentative and annoying.
    That's the first post of yours which makes sense. I'll link to it the next time you ask a question.
    My hobby projects:
    www.rclsoftware.org.uk

  13. #43
    VictorN's Avatar
    VictorN is offline Super Moderator Power Poster
    Join Date
    Jan 2003
    Location
    Hanover Germany
    Posts
    20,430

    Re: [RESOLVED] C++ bitmap - why?

    Quote Originally Posted by Zaccheus View Post
    That's the first post of yours which makes sense. I'll link to it the next time you ask a question.
    I'm not an admin but IMHO, the posts like the last OP's one is a very good reason for ban...
    Victor Nijegorodov

  14. #44
    Join Date
    Apr 2004
    Location
    England, Europe
    Posts
    2,492

    Re: [RESOLVED] C++ bitmap - why?

    I often wonder how many of the dumb questions we get are just trolls out for a laugh.
    My hobby projects:
    www.rclsoftware.org.uk

  15. #45
    Join Date
    Oct 2010
    Location
    Australia
    Posts
    98

    Thumbs down Re: [RESOLVED] C++ bitmap - why?

    Quote Originally Posted by Zaccheus View Post
    I often wonder how many of the dumb questions we get are just trolls out for a laugh.
    Very few I'd imagine - the OP is just making excuses for ignorance and frustration. When someone asks a question and is faced with a question of their own, he simply could not handle the idea that his knowledge was insufficient to process the nature of getting help requires effort, not just indolence.

    A final note though - LET THIS THREAD DIE!

Page 3 of 4 FirstFirst 1234 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured