Results 1 to 10 of 10

Thread: scrolling an image

  1. #1

    Thread Starter
    Member
    Join Date
    Jul 2002
    Location
    Singapore
    Posts
    32

    scrolling an image

    supposing i have a really big image.... whats the best way to allow the user to scrool around it?
    C you, C me

  2. #2
    Fanatic Member riis's Avatar
    Join Date
    Nov 2001
    Posts
    551
    I prefer dragging the image much over using scrollbars. (Probably because there's much more room to click than in the narrow scrollbars, and over all because you can "scroll" diagonally.) I have no idea how others think about it.
    (For performance issues you might want to only register the mousedown- and mouseup-events, and not dynamically drag the image in the mousemove-event.)

  3. #3
    Member anjulpa's Avatar
    Join Date
    Aug 2001
    Location
    india
    Posts
    43
    maybe he's talking abt how to handle such a large image in memory and to load the right parts at the right events.

    ppl saw this
    Die, ***** Die !

  4. #4
    Fanatic Member riis's Avatar
    Join Date
    Nov 2001
    Posts
    551
    I don't know, he didn't make it clear.

  5. #5

    Thread Starter
    Member
    Join Date
    Jul 2002
    Location
    Singapore
    Posts
    32
    Originally posted by riis
    I prefer dragging the image much over using scrollbars. (Probably because there's much more room to click than in the narrow scrollbars, and over all because you can "scroll" diagonally.) I have no idea how others think about it.
    (For performance issues you might want to only register the mousedown- and mouseup-events, and not dynamically drag the image in the mousemove-event.)
    that's what i want to do drag the picture around, but how do i go about doing it?
    C you, C me

  6. #6
    Member anjulpa's Avatar
    Join Date
    Aug 2001
    Location
    india
    Posts
    43
    maybe u should make it real time if you want to make it fast enuf for gaming. If you specify the right purpose then maybe you could get some help

    ppl saw this
    Die, ***** Die !

  7. #7

    Thread Starter
    Member
    Join Date
    Jul 2002
    Location
    Singapore
    Posts
    32
    ok, what i have is this really large image of a technology tree. I just want to be able to allow the user to scroll around the picture by dragging the mouse. What i have in palce now uses scrollbars.

    It doesn't need to be *very* fast
    C you, C me

  8. #8
    Good Ol' Platypus Sastraxi's Avatar
    Join Date
    Jan 2000
    Location
    Ontario, Canada
    Posts
    5,134
    Don't have a large image if it's all text. Generate it at run-time and you'll simply be able to offset the individual X and Y positions of the text, pictures, and/or controls you use.
    All contents of the above post that aren't somebody elses are mine, not the property of some media corporation.
    (Just a heads-up)

  9. #9

    Thread Starter
    Member
    Join Date
    Jul 2002
    Location
    Singapore
    Posts
    32
    Originally posted by Sastraxi
    Don't have a large image if it's all text. Generate it at run-time and you'll simply be able to offset the individual X and Y positions of the text, pictures, and/or controls you use.
    its not all text, there are icons as well
    C you, C me

  10. #10
    Member anjulpa's Avatar
    Join Date
    Aug 2001
    Location
    india
    Posts
    43
    i think sastraxi is right abt the run-time thing. Even if there are icons, you can hold certain of them in memory and display appropriate ones at the right positions, would be a hell lot faster.

    ppl saw this
    Die, ***** Die !

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