1. We have added a Gift Upgrades feature that allows you to gift an account upgrade to another member, just in time for the holiday season. You can see the gift option when going to the Account Upgrades screen, or on any user profile screen.
    Dismiss Notice

Screenshot app - development and testing

Discussion in 'Team CivFanatics' started by tobiasn, Jun 8, 2012.

  1. Aivoturso

    Aivoturso King

    Joined:
    Mar 12, 2010
    Messages:
    655
    Cool! I checked the app with Firefox and IE on Windows 7. Seems to run smoothly but I did not do thorough testing. Anything specific you'd like to be tested with IE?

    I think the app will definitely make turn reporting much easier task. I have a few questions and improvement ideas, if you have time and enthusiasm to develop app further:
    1. App does seem to play nicely only with default zoom level of the browser.
    2. How does the app behave when there are more folders than can fit nicely in the list?
    3. Thumbnails for the pics in the folder would be nice. (Might take quite a lot work though.)
    4. Any plans to use the dropbox/app method for updating demographics data too?

    BTW, I love the image-not-found pic. :goodjob:

    @Bowsling, I suppose you don't have dropbox access yet? The images are upside down in the folder too, so the app posts them correctly:)
     
  2. tobiasn

    tobiasn Warlord

    Joined:
    Nov 24, 2003
    Messages:
    265
    Location:
    Norway
    Thanks for the feedback! :) Yeah the pix are upside down. iPhoto/Finder turns them around automatically, so I don't always catch it. PHP does nothing with the pix, just display them directly (or via a script in the "recent pictures" thing).

    Well.. if you resize the browser window BEFORE you click one of the turn links, I do scale the images (with javascript) to fit inside the window - whatever size or zoom level it might be.. (At least it works on Chrome, and on iPhone). My script is a little clutter-y atm, when I split it into more functions, it will be easier to retrigger the function on window.resize.

    But - if you can test this in IE or FF - reload the page, zoom in (or out) a few levels, and then click one of the turn links. If it doesn't look good, there's a bug. If you can put a screenshot in a new turnfolder, I'll check it. :)

    The turnfolders/links just continue down the page. I might make the header sticky. Or not. Is just scrolls normally. The overlay is position:fixed, so it will always stick to the edges of the viewport.


    Not a lot of work, no, it's quick to do it with GD/PHP. But it's def not a priority. I at least need to get the app on a real server first.

    Yeah we could do that, but I think those kinds of data would be easier to enter in a Google Docs spreadsheet? If we have it there, it's fairly straightforward to generate some graphs based on that spreadsheet. Lots of cool stuff we can do with stuff like Raphaël JS, for example :)

    Btw, does anyone know a good reference on bbcode? It would be nice if I could tweak the embed code to make the embedded pix not force-break the forum width. I can just wrap the IMG tags in URL tags, so we can click for full resolution?
     
  3. Aivoturso

    Aivoturso King

    Joined:
    Mar 12, 2010
    Messages:
    655
    Works with at least FF. As long as you resize the page or zoom before opening a folder, site is rescaled appropriately, so not a bug.
    From turn logging point of view, I think it would be nice to just post everything in single place. Of course, if different persons at time are responsible for screenies and demo logging, the point is kind of moot. This Raphaël seems really nice. Definitely a lot of stuff that can be done with it :) No need to re-invent the wheel.
     
  4. tobiasn

    tobiasn Warlord

    Joined:
    Nov 24, 2003
    Messages:
    265
    Location:
    Norway
    TBH I have no idea what kind of data we are collecting or how it should be presented to make most sense. Do you have any examples from previous games?
     
  5. YossarianLives

    YossarianLives Deity

    Joined:
    May 26, 2012
    Messages:
    2,097
    Location:
    Los Angeles, CA
    Check out AMAZON's turn log in the last demogame for an example of the types of images they were posting there: http://forums.civfanatics.com/showthread.php?t=360357

    I haven't read any of the other threads to see what other teams did.

    If we can get screenshots of the demos and graphs each turn, along with closely following civstats, we should be able to analyze a lot of what the other teams are doing (builds, techs, in some cases which tiles are being worked, etc.)
     
  6. tobiasn

    tobiasn Warlord

    Joined:
    Nov 24, 2003
    Messages:
    265
    Location:
    Norway
    Ah. OK. I see how you've split it up.
    Yeah it would probably be a good idea to do it like this. It's very easy to just make a "demographics" folder in the Dropbox, with turn-subfolders, and I can duplicate like 90% of the code.

    Btw - I see that none of you have tested the functionality, really. It would be nice if you could test putting some pictures in a folder, making a new folder, etc - both for you, so you get familiar with it, and for me, so I know it's working like it should.
     
  7. 2metraninja

    2metraninja Defender of Nabaxica

    Joined:
    Sep 19, 2007
    Messages:
    5,663
    Location:
    Plovdiv, BG
    Hmm, I can do that, can you remind me what was the Dropbox for it? (I am registered but never tried my dropbox, so I will need to get used to Dropbox itself.
     
  8. tobiasn

    tobiasn Warlord

    Joined:
    Nov 24, 2003
    Messages:
    265
    Location:
    Norway
    When you install Dropbox you get a Dropbox folder. Inside that folder there's a folder called "TheFastWorker" where there are a turn folder, and inside that a folder for each turn.

    You have to log in to dropbox.com to accept my share request before it will show up on your machine.

    Also, the Dropbox deamon needs to be running on your machine :)


    But-- did I get your email, the one you used when you signed up for dropbox? You can PM me that if you want.
     
  9. 2metraninja

    2metraninja Defender of Nabaxica

    Joined:
    Sep 19, 2007
    Messages:
    5,663
    Location:
    Plovdiv, BG
    Worked just fine for me. Uploaded few pics and they show up fine.
     
  10. DaveShack

    DaveShack Inventor Retired Moderator

    Joined:
    Feb 2, 2003
    Messages:
    13,108
    Location:
    Arizona, USA (it's a dry heat)
    I don't have a share request showing on the dropbox website, nor a fast worker folder.
     
  11. tobiasn

    tobiasn Warlord

    Joined:
    Nov 24, 2003
    Messages:
    265
    Location:
    Norway
    Try now, Dave? I must've got the address wrong the first time..
     
  12. Bowsling

    Bowsling Deity

    Joined:
    Nov 14, 2008
    Messages:
    5,000
    Location:
    Ontario, Canada
    Just noticed that I posted "Wow, great" three times in this thread. :lol:

    Anyways, I created my Dropbox account (using the link you provided), and uploaded a picture of my dog and a picture of some tourtière that I made a while back. Both are showing up fine in the app (although the one of the dog seems to have funny proportions). Awesome! :thumbsup:
     
  13. 2metraninja

    2metraninja Defender of Nabaxica

    Joined:
    Sep 19, 2007
    Messages:
    5,663
    Location:
    Plovdiv, BG
    Bowsling, is the dog picture rotated originally like this? As I see it rotated 90 degrees.

    My uploads were some bicycle rims and the factory where the bikes are produced. BTW, just today I saw a paparazi picture of Madonna riding one of our bikes ;)
     
  14. Bowsling

    Bowsling Deity

    Joined:
    Nov 14, 2008
    Messages:
    5,000
    Location:
    Ontario, Canada
    No - it should be a properly rotated portrait picture.

    It's probably a really terrible example though. It was taken on my iPhone, which has funny dimensions to start with, and god knows what Apple does to pictures if they aren't displayed on an Apple product. Most screenshots will be much more straight forward than these.
     
  15. tobiasn

    tobiasn Warlord

    Joined:
    Nov 24, 2003
    Messages:
    265
    Location:
    Norway
    Great :) Thanks Bowsling. I see some food and an un-rotated dog. I think he suffers from the same disease as my upside-down landscapes. Awesome.

    I did some testing yesterday. As I'm not sanitizing anything in the app, weird names can have some weird results. Anything with spaces does not work. But we can call the folders anything straight alphanumeric. So like 003 and 003b is just fine.

    If you want, you can split demographics like that. Or I can just make a seperate folder for those pix. Up to you really.
     
  16. Bowsling

    Bowsling Deity

    Joined:
    Nov 14, 2008
    Messages:
    5,000
    Location:
    Ontario, Canada
    I was reading that Dropbox has native support for Microsoft Word and Excel files. Is this at all transferable? Is it possible to "borrow" the API to make the Fast Worker able to show us spreadsheets and word documents?
     
  17. Aivoturso

    Aivoturso King

    Joined:
    Mar 12, 2010
    Messages:
    655
    How about one in bbcode.org: http://www.bbcode.org/reference.php

    I don't think that helps much, though. I tried to resize the image with the tags given in the reference to no avail. Could be that bbcode implementation CFC is using does not support image resizing. I can think of two ways to deal with this.

    Simplest workaround would be to just wrapping the images within spoiler tags. Crude, but kind of works. Even though the images still force-break the forum width, they do it only when viewed so the readability of the thread will still be maintained.

    Second option is to add resizing functionality to the app.
     
  18. Aivoturso

    Aivoturso King

    Joined:
    Mar 12, 2010
    Messages:
    655
    Screeshot autoupdate testing...

    Spoiler :



     
  19. Aivoturso

    Aivoturso King

    Joined:
    Mar 12, 2010
    Messages:
    655
    I poked around with the app a bit. Autoupdate of the links seems to be working fine. Adding a new folder and a pic to the folder works just fine. Link to the pic updates correctly with FF and IE (Win7). However, there seems to be a small bug in the app when using IE:

    When I added a new folder in dropbox, app frontpage did not update after refresh (i.e. Turn 004 folder was not available). Re-navigating to webpage did not help either. Only closing IE and starting it again did the trick. With FF update worked just fine with browser refresh.


    BTW, do we rely completely on security by obscurity? Or is there any plans to add a simple password query or such to the app frontpage?

    Offtopic: Kudos to anyone who knows the game my test screenie is from ;)
     
  20. tobiasn

    tobiasn Warlord

    Joined:
    Nov 24, 2003
    Messages:
    265
    Location:
    Norway
    Hehe nice :) Dunno the game. Illustration style reminds me of Pizza Tychoon though. Man did I waste hours on that.

    Re the IE thing - did you test there first? It takes some time for the pic to get to the server. (only folders with valid image files show up in the list.) But it's very likely browser caching of the ajax request that gets the pic info. I'll look into it.

    I'm not a big fan of security by obscurity ;) Yeah I'll safeguard it a little bit when we start the game.

    Btw: cool to see that your previous post is updated now too :D
     

Share This Page