va3c / viewer

3D Model Viewer with Three.js
http://va3c.github.io/viewer/
183 stars 118 forks source link

vA3C_viewer clean out, rewrite #9

Closed bhowes-tt closed 9 years ago

bhowes-tt commented 9 years ago

I've been working on a fork of this repo for the past few months with our team over here in the CORE studio, and am finally ready to submit this big pull request. The goal of the effort was to cut viewer functionality to the bone while improving the legibility of the code base and the cleanliness of the repo.

You can see the new full page viewer app running here: http://tt-acm.github.io/vA3C_viewer/

Examples of how users can embed viewers in their own web pages (and easily enable chunks of application logic) are here: http://tt-acm.github.io/vA3C_viewer/examples/embeddedViewer001/ http://tt-acm.github.io/vA3C_viewer/examples/embeddedViewer002/ http://tt-acm.github.io/vA3C_viewer/examples/embeddedViewer003/ http://tt-acm.github.io/vA3C_viewer/examples/embeddedViewer004/ http://tt-acm.github.io/vA3C_viewer/examples/embeddedViewer005/

Please let me know what you think! Cheers,

Ben

theo-armour commented 9 years ago

Hi Ben

http://tt-acm.github.io/vA3C_viewer/

Yay and good stuff and more!

I am really enjoying how different people can take the identical language, the identical libraries and the identical use cases and come up with such different coding paradigms.

And thank you for crediting me here and there.

The one example model is quite beautiful. It would be fun to see the equation that generated it/

And even more fun would be to see more examples - especially ones using your layers and views features

And examples from both Grasshopper and Revit would be even better - hint, hint - if anybody out there is listening. ;-)

In general, the code looks like it has had a lot of time spent on it and it all looks well-crafted and smooth-flowing.

The extensive, informative commenting is a bonus feature.

I also will have a bunch of suggestions and comments - such as why use rawgit.com when you don't really need to - but these can wait until another time.

In the mean time, thank you for keeping going with this work. You are only just beginning to scratch the surface as to what is doable

Theo

On Wed, Mar 25, 2015 at 3:07 PM, Ben Howes notifications@github.com wrote:

I've been working on a fork of this repo for the past few months with our team over here in the CORE studio, and am finally ready to submit this big pull request. The goal of the effort was to cut viewer functionality to the bone while improving the legibility of the code base and the cleanliness of the repo.

You can see the new full page viewer app running here: http://tt-acm.github.io/vA3C_viewer/

Examples of how users can embed viewers in their own web pages (and easily enable chunks of application logic) are here: http://tt-acm.github.io/vA3C_viewer/examples/embeddedViewer001/ http://tt-acm.github.io/vA3C_viewer/examples/embeddedViewer002/ http://tt-acm.github.io/vA3C_viewer/examples/embeddedViewer003/ http://tt-acm.github.io/vA3C_viewer/examples/embeddedViewer004/ http://tt-acm.github.io/vA3C_viewer/examples/embeddedViewer005/

Please let me know what you think! Cheers,

Ben

You can view, comment on, or merge this pull request online at:

https://github.com/va3c/viewer/pull/9 Commit Summary

  • first commit on minimal branch
  • attributes and selection working
  • refactored attributes and selection
  • improved attributes and selection
  • started lighting rig setup
  • lighting rig and UI improvements
  • Merge remote-tracking branch 'origin/BH_r9_Minimal' into gh-pages
  • massive purge
  • first commit of the minimal viewer
  • moved css files
  • edited readme
  • openLocalFile working
  • testing openUrl
  • pulled out openUrl
  • improved attributes list
  • made link properties into actual links
  • added blackout during file open
  • added loading message
  • fixed a selection bug
  • three.js r70
  • got rid of gradient background
  • implemented zoomSelected
  • small zoomSelected improvement
  • adjusted UI, experimented with fog
  • shadows sort of working
  • reshuffled UI, shadows on/off
  • swap spotlights for pointlights
  • pointlight swap part 2
  • more lighting / UI improvements
  • show / hide stats
  • revit files progress
  • Reading views from json file
  • Dynamically adding the view dropdown
  • camera working
  • upgraded dat.gui to the latest version
  • Dynamically creating the view dropdown
  • Views working
  • Layers On/Off working
  • Changing visibility of objects not transparency
  • updated visibility method to the json data structure
  • blocked out embed example 001 html
  • minimal embed example working
  • Clearing file input to be able to select the same file as before
  • clear file input and some documentation added
  • semicolon missing
  • Add the layer folder only if there user has added layers
  • Merge remote-tracking branch 'origin/cameras' into gh-pages
  • refactor for embeds - step 1
  • refactor embeds - step 2
  • refactor embeds - step 3
  • refactor embeds - step 4
  • refactor embeds - step 5
  • refactor embeds - step 6
  • refactor embeds - step 7
  • refactored zoomExtents
  • refactored views
  • refactored layers
  • fixed attributesList issue
  • embed example 001 working
  • UI responding to window size change
  • Views working
  • loading older sample file
  • pulled vA3C lib out of embed example
  • embed example 001 cleanup
  • spelling correction
  • added examples 2 and 3
  • added example 4 - layers
  • added example 5 - view and selection
  • Fixed firefox layer issue
  • Element selection improvement
  • embed example 005 working
  • added top level loadNewModel function
  • refactored style for single page app
  • handle scrolling / positioning
  • updated embed examples to allow scrolling

File Changes

Patch Links:

— Reply to this email directly or view it on GitHub https://github.com/va3c/viewer/pull/9.

bhowes-tt commented 9 years ago

Thanks for the feedback, @theo-armour ! I'm very glad to hear you dig on the new viewer's code structure.

Yes there are still some things to improve (quality and diversity of examples, local libs vs hosted, etc) and as always, I look forward to all of the low level feedback once things settle in a bit more.

So. Unless I hear any other major objections, I'm going to try to merge in this pull request - likely early next week (family in town this weekend! :heart: ).

Also - @va3c/owners, keep your eyes peeled for an email to the google group about this latest round of work, how we (CORE studio) are using vA3C in practice, and some ideas that come up over the past few months for the future of the project (including a proposal for a re-branding effort).

theo-armour commented 9 years ago

Hi Ben

Pull Request I don't always understand Git so forgive me if I am wrong, but looking at the file changes in the pull request, it looks to me like all changes in the https://github.com/va3c/viewer since December or so - messy as they are

What about starting a new repo? Would that help us not write all over each other? And perhaps even with a e-branding effort?

Use of DAT.GUI DAT.GUI has not been updated since 2011. As far as I know. Mr.doob only keeps it around to support old example code and has not used it in any recent code.

So I am wondering what you think is so special about DAT.GUI - especially since you are using jQuery/jQueryUI which provide access to a much broader range of UI widgets?


Will keep my eyes peeled for latest events. ;-)

Theo

On Fri, Mar 27, 2015 at 10:55 AM, Ben Howes notifications@github.com wrote:

Thanks for the feedback, @theo-armour https://github.com/theo-armour ! I'm very glad to hear you dig on the new viewer's code structure.

Yes there are still some things to improve (quality and diversity of examples, local libs vs hosted, etc) and as always, I look forward to all of the low level feedback once things settle in a bit more.

So. Unless I hear any other major objections, I'm going to try to merge in this pull request - likely early next week (family in town this weekend! [image: :heart:] ).

Also - @va3c/owners https://github.com/orgs/va3c/teams/owners, keep your eyes peeled for an email to the google group about this latest round of work, how we ((CORE studio)[http://core.thorntontomasetti.com/]) are using vA3C in practice, and some ideas that come up over the past few months for the future of the project (including a proposal for a re-branding effort).

— Reply to this email directly or view it on GitHub https://github.com/va3c/viewer/pull/9#issuecomment-87033915.

bhowes-tt commented 9 years ago

Hi Theo,

You are correct sir. I'm pretty new to the whole pull request thing too, but yes, the acceptance of this pull would replace the existing code base with this new one. Of course all of the old work would still be in the repo's history, but going forward I am hoping to keep the viewer repo a bit more structured (a single page web app at the root, a javascript library that can be used by anyone as-is, and a set of examples).

We already have a repo going that was forked off of this one - https://github.com/tt-acm/vA3C_viewer - and we could certainly just keep the development of this new code base going in that repo. Same goes for the grasshopper and revit exporters. We have been submitting pull requests from those repos too, and some of those have made it back into the parent repos.

Our intent with all of these pulls is to make sure we are sharing the progress we are making in the CORE studio back with the original vA3C crew. Because we are considering a rebranding effort (and planning on much more development in the future), it might make more sense to do so using our existing forks. We discussed this quite a bit on our side, and I wanted to be sure that we discussed this with the vA3C crew before making any rash moves with our forks. @va3c/owners and @theo-armour --- Let me know what you think - I'm leaning towards rebranding our repos and moving forward with those, and crediting the original vA3C effort in all of our documentation going forward. Of course all of our forks will remain open source.

Re: dat.gui. It is a stepping stone - at some point we'll need to leave it behind I suppose. I like it because it is easy to work with and has a tiny code footprint. If someone can do more with less and keep it legible, I'd be pumped to fold that work into the viewer.

jeremytammik commented 9 years ago

i would love the main vA3C project to be as simple as possible.

everything else makes it harder for newbies to understand and use.

all confusing experiments should be elsewhere, imho.

and clearly documented!

mille grazie to any and all for any simplification you can provide!

theo-armour commented 9 years ago

Hi Ben

It's great that you are wanting to move the vA3C project forward. A project like this needs active professionals involved if it is to succeed.

Some observations:

One of the sad things about having been young in the pre-digital era is that so little of one's work is available or accessible. Such things no longer need happen.

One of the things I called for during our Hackathon was a GitHub presence that listed every participant in the team and their details. That data - and all the code we produced - remains as-is and completely intact and when I last checked it still worked.

I recommend that the entire hackathon effort should remain accessible via a URL in perpetuity. That being said, I can see some moving about with renaming of repose, folders and files - but all remaining searchable via Google or whatever.

As for the other repos added or updated since the Hackathon I think it's up to the various people involved to decide. For the Grasshopper that would mean you , Jonatan et al, for Revit it's Jeremy and for the viewer additions it's mostly up to me.

Regarding the viewer work, I am way behind in updating what's been going on. Here's a fun one - a viewer for Open Studio files:

http://va3c.github.io/projects/

In general, I am moving very much in the direction of very small cookbook projects. This can continue at vA3C or it could move over to my Jaanga efforts.

Hope this helps...

Theo

On Mon, Mar 30, 2015 at 7:55 AM, Jeremy Tammik notifications@github.com wrote:

i would love the main vA3C project to be as simple as possible.

everything else makes it harder for newbies to understand and use.

all confusing experiments should be elsewhere, imho.

and clearly documented!

mille grazie to any and all for any simplification you can provide!

  • KISS
  • Simplicity is the ultimate sophistication – Leonardo da Vinci
  • There is no greatness where there is no simplicity – Leo Tolstoy
  • Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away – Antoine de Saint-Exupéry

— Reply to this email directly or view it on GitHub https://github.com/va3c/viewer/pull/9#issuecomment-87711457.

bhowes-tt commented 9 years ago

@jeremytammik @theo-armour - thanks so much for the feedback!

Theo,

I hear you and I totally agree with your point about accessibility. I think your recommendation to keep the hackathon effort intact and accessible via a consistent URL makes sense - let's do that.

We discussed this a bit more on our side too. Under the circumstances, we think it makes sense for us to drop this pull request and continue to develop our own forks of the vA3C repos. It's likely that we will re-brand our forked projects at some point, but they will all remain open source and pointing back to the parent vA3C repos in this organization.

I'm hopeful that this approach allows us to further develop the viewer and Revit and Grasshopper exporters ( hopefully with the help of some of the original vA3C'ers! ) while maintaining the original hackathon effort in perpetuity in this organization.

Thanks so much for your input Theo - I'm glad we were able to find a solution that works for everyone.

Best regards and cheers from NYC, Ben

theo-armour commented 9 years ago

Hi Ben

We discussed this a bit more on our side too. Under the circumstances, we think it makes sense for us to drop this pull request and continue to develop our own forks of the vA3C repos.

Did you talk about creating a repository in the vA3C organization such as 'view'? This would then have the URL http://va3C.github.io/view.

You could then acquire the domain name, say, vA3C.io and point it to that repo as the home page.

In other words, there are many fun ways we can work together without stomping each other and keeping the history alive.

And if you want to truly be open source, it is probably more appropriate to do this under the aegis of a GitHub organization - such as vA3C rather than under a corporate sponsor.

So feel free to keep the discussion open...

Theo

On Thu, Apr 2, 2015 at 2:16 PM, Ben Howes notifications@github.com wrote:

Closed #9 https://github.com/va3c/viewer/pull/9.

— Reply to this email directly or view it on GitHub https://github.com/va3c/viewer/pull/9#event-272116569.