This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static Vector3d[] getAABBAxes( Vector3d[] vertices ) { | |
Vector3d[] axes = new Vector3d[ 6 ]; | |
// get vertices | |
Vector3d p0 = vertices[ 0 ]; | |
Vector3d p1 = vertices[ 1 ]; | |
Vector3d p2 = vertices[ 2 ]; | |
Vector3d p3 = vertices[ 3 ]; | |
Vector3d p4 = vertices[ 4 ]; | |
Vector3d p5 = vertices[ 5 ]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static Projection project( Vector3d[] vertices, Vector3d axis ) { | |
double min = axis.dot( vertices[ 0 ] ); | |
double max = min; | |
for (int i = 1; i < vertices.length; i++) { | |
// NOTE: the axis must be normalized to get accurate projections | |
double p = axis.dot( vertices[ i ] ); | |
if ( p < min ) { | |
min = p; | |
} else if ( p > max ) { | |
max = p; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
toggleMapSize: function () { | |
this.set("isFullWidth", !this.get("isVisible")) | |
}.observes("isVisible") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git pull origin master | |
# merge or what not here.. | |
bundle | |
bundle exec rake db:migrate | |
bundle exec rake assets:precompile | |
touch tmp/restart.txt | |
# Debugging | |
http://guides.rubyonrails.org/debugging_rails_applications.html |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
App.MapSearchRoute = Ember.Route.extend({ | |
renderTemplate: function() { | |
this.render({ | |
into: "sidebar", | |
outlet: "sidebar" | |
}); | |
} | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
App.Router.map(function () { | |
this.route("index", { path: "/" }); | |
this.resource("map", function () { | |
this.route("search"); | |
this.route("overlay"); | |
this.route("contact"); | |
}); | |
this.resource("surveys", { path: "/survey" }, function () { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
App.CustomSelectView = Ember.View.extend({ | |
templateName: "customSelect", | |
tagName: "ul", | |
classNames: ["custom-select"], | |
title: "Custom Select", | |
selected: null, | |
options: null, | |
click: function (event) { | |
console.dir(event.target); | |
}, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jQuery191023943386389873922_1370972233957 ( | |
{ | |
"displayFieldName": "ANCHORNAME", | |
"fieldAliases": { | |
"CAIID": "CAIID", | |
"CAICAT": "Category", | |
"ANCHORNAME": "ANCHOR NAME", | |
"ADDRESS": "ADDRESS", | |
"BLDGNBR": "Building Number", | |
"CITY": "CITY", |
OlderNewer