Results 1 to 15 of 15

Thread: Beacon, animated gif tutorial

  1. #1
    Jethro
    Guest

    Wink Beacon, animated gif tutorial

    Ok the first one has the tutorial and the actual control.
    Attached Files Attached Files

  2. #2
    Jethro
    Guest
    And the second one has the worlds simplest vb example of it working, drop into any directory and run.
    Attached Files Attached Files

  3. #3
    PowerPoster Beacon's Avatar
    Join Date
    Jan 2001
    Location
    Pub Floor
    Posts
    3,188
    Noice very Noice!

    Send me a copy of those pics too!

    Title: How To Store Your Pornography!

  4. #4
    Jethro
    Guest

    Wink Forgot to add....

    I didn't write the actual control. Comes from some dude in California, who is no longer at the email address he gives. See the about thing in the property box.

  5. #5
    PowerPoster Beacon's Avatar
    Join Date
    Jan 2001
    Location
    Pub Floor
    Posts
    3,188
    ssshhh i thought i heard you say u didnt write the control!

    nah but the tutorials cool. We need a tutorial page!
    Have ya given this one to john?
    I even get a mention

  6. #6
    Jethro
    Guest
    Naw, thought l would leave it to Karl to knock something up. Apparently he is quite good at knocking things up

  7. #7
    PowerPoster Beacon's Avatar
    Join Date
    Jan 2001
    Location
    Pub Floor
    Posts
    3,188

    The lone soldier!
    heheh Knock up the lone soldier.
    Who'd he knock up this time?

  8. #8
    Jethro
    Guest
    Well James is noticably by his absence

  9. #9
    Registered User Nucleus's Avatar
    Join Date
    Apr 2001
    Location
    So that's what you are up to ;)
    Posts
    2,530
    Frans C pointed out a problem with this control,

    See here:

    http://161.58.186.97/showthread.php?s=&threadid=80497

    Cander's example is good once you get it working.

  10. #10
    Jethro
    Guest
    Is the problem with the registration? go to windows\system and execute regsvr32 as explained in the tutorial. WIll check out Candor's answer though.

  11. #11
    Registered User Nucleus's Avatar
    Join Date
    Apr 2001
    Location
    So that's what you are up to ;)
    Posts
    2,530
    No I think there is a problem displaying modern animated gifs. You would have to email Frans for the details, but I have no reason to doubt it, he usually has good info.

  12. #12
    Jethro
    Guest
    Haven't run accross a "modern" gif it can't display. But maybe the ones we use are in older format or something. We email Frans for problem.

  13. #13
    Jethro
    Guest
    Still haven't run across the problem

  14. #14
    Registered User Nucleus's Avatar
    Join Date
    Apr 2001
    Location
    So that's what you are up to ;)
    Posts
    2,530
    Hey Jello, cause of all the pesky problems I have with poxy gif controls, this is how I do it now and it works well.

    Just extract all the frames from the gif using something like animation shop or you can download IrfanView from cnet for free.

    Then just load the images into a imagelist and then add this code, courtesy of Aaron and it even works with transparent background gifs.

    no external dependency + simple and easy to implement + you can control the speed of the animation at will via code + you can start and stop it at will.

    VB Code:
    1. Option Explicit
    2.  
    3. Private Sub Form_Load()
    4.     ' Set the MaskColor to Black, because you're using Transparent GIF's
    5.     ImageList1.MaskColor = vbBlack
    6. End Sub
    7.  
    8. Private Sub Timer1_Timer()
    9.     Static lFrame As Long
    10.    
    11.     Picture1.AutoRedraw = True
    12.     Picture1.Cls ' Or Redraw BackGround
    13.     ImageList1.ListImages(lFrame + 1).Draw Picture1.hDC, 0, 0, imlTransparent
    14.     Picture1.AutoRedraw = False
    15.    
    16.     lFrame = (lFrame + 1) Mod ImageList1.ListImages.Count
    17. End Sub

  15. #15
    Jethro
    Guest
    Cool code....


    The purpose of the tutorial is not to provide the world's best gif control, but too point out using third party controls, and how to get them on board a vb project....else would settle on the Blt thingy which am still mucking around with...


    Cheers...

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