syt123450 / giojs Goto Github PK
View Code? Open in Web Editor NEW๐ A Declarative 3D Globe Data Visualization Library built with Three.js
Home Page: https://giojs.org
License: Apache License 2.0
๐ A Declarative 3D Globe Data Visualization Library built with Three.js
Home Page: https://giojs.org
License: Apache License 2.0
There are some APIs implemented in Gio.js, but haven't been exposed to developer, test, expose, and add more documentation for them!
In utils.js, around line 51 and 77.
while ( current !== null ) {
actualLeft += current.offsetLeft;
current = current.offsetParent;
}
current !== null
should be change to current !== undefined
, otherwise it gives an error.
Our source can not be used directly with npm, we need to use rollup to package all react source code for npm publish.
As gio.js can switch between different countries, Gio.js 2.0 would support continents control, so the developers could configure the continent in Json format.
Use design like Chain of Responsibilities to process data by separate processors.
Make moving particle responsive.
Implement APIs to expose three.js object for developers. Gio.js will be more flexible with these kind of APIs.
Our code now is based on old Three.js version, we need to test which function is deprecated or not support by the latest three.js version, and changed our source code.
The mouse wheel function to let globe zoom in or out can not work in Firefox.
var replica = JSON.parse( JSON.stringify( data ) );
replica.sort( function ( a, b ) {
return a[ valueKey ] - b[ valueKey ];
} );
var min = replica[ 0 ][ valueKey ];
var max = replica[ replica.length - 1 ][ valueKey ];
In the code snippet above, sort() is used to get min/max, which lead to time complexity of O(N*log N). Instead, using a for loop for achieve the same goal for time of O(N):
if (data === undefined || data.length === 0)
return;
var min = data[0][ valueKey ];
var max = data[0][ valueKey ];
data.forEach(function(country) {
if (country[ valueKey ] < min)
min = country[ valueKey ];
else if (country[ valueKey ] > max)
max = country[ valueKey ];
});
See examples in three.js website.
Currently the ranges are defined as private variables in SurfaceHandler, it makes some user cases difficult since there's no way to get those ranges via GIO.Controller
The halo can not be removed before init() function of controller is called.
When the div which will hold Gio globe have offset in Safari, the click function can not work.
The offset problem still exist if the div has several wrappers parent node between , it seems that can be solved by change the the calculate method of scrollTop.
I noticed that the website is having a long latency on page loading (e.g. Document page), which is caused by some huge size images (e.g. A 1.5MB image just for 500 * 300 actual display size) and the arrangement of resource tags, etc.
In general, now that the demo is done, performance is the next step.
Cheers!
We need to explore how to use our library after download from npm, and how to combine it with Threejs.
For example, it's hard to tell the difference between the two instances in 09_API_adjustMentionedBrightness.html
Tried "npm install giojs --save", says "can't find module three"
Hi!
When i tried to connect it with youtube stats, I had some issues with countrycode. I notice some missing countries from your singleton object :
I only found it for now but I will post update if there are more of them.
Thanks for the lib anyway !
The library now can not work well in some browser, especially Safari, we may need to fix it.
Currently, brightness won't be updated immediately after calling controller.adjustOceanBrightness, controller.adjustMentionedBrightness, or controller.adjustRelatedBrightness
We need to add several document for the project:
Review the docs in the wiki and move them to master branch, it can be download by developers.
List of variables names, function names and parameter names to be renamed.
(new ideas come up now and then)
Add API in controller for users to set the earth surface color as they like.
Users may use hex color to set the color, the API may like setSurfaceColor(), and user can use it like:
setSurfaceColor("#54ce60")
Now gio.js can only assign a specific for selected countries, Gio.js 2.0 will support assign specific color for all countries. The developers can assign color for countries like this:
controller.setCountryColor("US", 0xffffff);
We can add a data processor manager to register data processors according to the current settings.
The background is white in Safari 11 while it should be black, and this issue do not happen in Safari 10.
Separate repo and transfer repo to organization.
When Stats is enabled, the user should be able to customize its style, a possible solution is to give that element a unique id so that they can use CSS to adjust its styles.
We need to establish a website to introduce the library to developer.
Add more examples for each api, so that developer can easily know how to use the library.
The examples should follow the example format defined in examples folder, and cover as much API as possible.
We need to create a big data set for demo to show get great visual experience.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.