Results 1 to 3 of 3

Thread: texturebrush

  1. #1

    Thread Starter
    Fanatic Member
    Join Date
    May 2001
    Posts
    837

    texturebrush

    im having trouble getting a picture to display where i want it to

    i use this to load the bitmaps
    VB Code:
    1. For i = 0 To 4
    2.     TB(i) = New TextureBrush(New Bitmap("chip " & ChipValues(i) & " big.bmp"), New Rectangle(0, 0, 698, 698))
    3.     TB(i).ScaleTransform(75 / 698, 30 / 698)
    4. Next

    and this to draw it
    VB Code:
    1. For i = 0 To 4
    2.     m_DC.FillEllipse(TB(i), New Rectangle(75 * i + 10, 700, 80, 30))
    3. Next

    and the chip ends up tiling inside the ellipse instead of being centered, i even tried doing TB(i).TranslateTransform(10, 15) and it wouldn't move the chips. Anyone know the proper way to do this?
    The human brain cannot hold all of the knowledge that exists in this world, but it can hold pointers to that knowledge.

  2. #2
    l33t! MrPolite's Avatar
    Join Date
    Sep 2001
    Posts
    4,428
    posting more code would help
    rate my posts if they help ya!
    Extract thumbnail without reading the whole image file: (C# - VB)
    Apply texture to bitmaps: (C# - VB)
    Extended console library: (VB)
    Save JPEG with a certain quality (image compression): (C# - VB )
    VB.NET to C# conversion tips!!

  3. #3

    Thread Starter
    Fanatic Member
    Join Date
    May 2001
    Posts
    837
    those are the only lines of code that go with this, its just a test setup for me to figure out how to do this and i can't seem to get it right
    The human brain cannot hold all of the knowledge that exists in this world, but it can hold pointers to that knowledge.

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