CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 6 of 6

Thread: apply texture

  1. #1
    Join Date
    Mar 2008
    Posts
    142

    apply texture

    applying texture
    i m trying to apply texture on the image
    but problem is that texture is not being applied on the picture
    i m loading pictures from the database
    i have three forms
    form1 for managing pictures in the database
    form2 for displaying pictures in the picturebox
    frmTexture for applying texture
    i use texture form to apply the texture on the form,once the texture is applied over
    the picture in the texture form then i press Ok button to apply this texture to back to the
    form2 picture box but problem is that this texture is not applied to the picture
    my code is for OK button as follow
    Code:
    Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
            Form2.pb.Image = Me.picTextured.Image 'apply textured bitmap to form2 picture box
            Form2.pb.Refresh() 'refresh the from2 picture box
            Me.Close()	'close the texture form
        End Sub
    if i open picture from disk directly then texture is applied.
    now i m worry how to handle this situation
    same is the case for other dialogs like applying emboss effect on the picture.
    i m sending this project along database files...i m using sql server 2000 for storing pictures into the database
    can any body provide me help....thanks
    Attached Files Attached Files

  2. #2
    Join Date
    Jan 2006
    Location
    Fox Lake, IL
    Posts
    15,007

    Re: apply texture

    I'd make a new copy of the db image, and apply the texture and show that instead.
    David

    CodeGuru Article: Bound Controls are Evil-VB6
    2013 Samples: MS CODE Samples

    CodeGuru Reviewer
    2006 Dell CSP
    2006, 2007 & 2008 MVP Visual Basic
    If your question has been answered satisfactorily, and it has been helpful, then, please, Rate this Post!

  3. #3
    Join Date
    Mar 2008
    Posts
    142

    Re: apply texture

    i can't what u have asked me
    can u expalin me
    how can i solve this problem

  4. #4
    Join Date
    Jan 2006
    Location
    Fox Lake, IL
    Posts
    15,007

    Re: apply texture

    Like this:

    Code:
    dim im as image = new Form2.pb.Image
    then process IM instead of the original image
    David

    CodeGuru Article: Bound Controls are Evil-VB6
    2013 Samples: MS CODE Samples

    CodeGuru Reviewer
    2006 Dell CSP
    2006, 2007 & 2008 MVP Visual Basic
    If your question has been answered satisfactorily, and it has been helpful, then, please, Rate this Post!

  5. #5
    Join Date
    Mar 2008
    Posts
    142

    Re: apply texture

    hello where i have to write this line??
    Code:
    dim im as image=new Form2.pb.Image
    i don't know how to do it
    whether i have to write in ok button event or when i load texture dialog.
    kindly explain me

  6. #6
    Join Date
    Mar 2008
    Posts
    142

    Re: apply texture

    hello
    give me reply why texture is not applied
    i m still waiting
    first u reply me and then u do not relpy...why??
    thanks

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