{"action":"created","issue":{"url":"https://api.github.com/repos/AnalyticalGraphicsInc/cesium/issues/2632","labels_url":"https://api.github.com/repos/AnalyticalGraphicsInc/cesium/issues/2632/labels{/name}","comments_url":"https://api.github.com/repos/AnalyticalGraphicsInc/cesium/issues/2632/comments","events_url":"https://api.github.com/repos/AnalyticalGraphicsInc/cesium/issues/2632/events","html_url":"https://github.com/AnalyticalGraphicsInc/cesium/pull/2632","id":68156555,"number":2632,"title":"PointPrimitive and PointPrimitiveCollection","user":{"login":"emackey","id":1235080,"avatar_url":"https://avatars.githubusercontent.com/u/1235080?v=3","gravatar_id":"","url":"https://api.github.com/users/emackey","html_url":"https://github.com/emackey","followers_url":"https://api.github.com/users/emackey/followers","following_url":"https://api.github.com/users/emackey/following{/other_user}","gists_url":"https://api.github.com/users/emackey/gists{/gist_id}","starred_url":"https://api.github.com/users/emackey/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/emackey/subscriptions","organizations_url":"https://api.github.com/users/emackey/orgs","repos_url":"https://api.github.com/users/emackey/repos","events_url":"https://api.github.com/users/emackey/events{/privacy}","received_events_url":"https://api.github.com/users/emackey/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":12,"created_at":"2015-04-13T17:54:14Z","updated_at":"2015-05-04T22:52:11Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/AnalyticalGraphicsInc/cesium/pulls/2632","html_url":"https://github.com/AnalyticalGraphicsInc/cesium/pull/2632","diff_url":"https://github.com/AnalyticalGraphicsInc/cesium/pull/2632.diff","patch_url":"https://github.com/AnalyticalGraphicsInc/cesium/pull/2632.patch"},"body":"This PR adds two new classes `PointPrimitive` and `PointPrimitiveCollection`.  It does *not* make any changes to the `Entity.point` API, however the back end of `Entity.point` is now connected to the new `PointPrimitive` system instead of billboards.  This means that existing Entity and CZML points will automatically make use of the new system, with no changes.\r\n\r\n`PointPrimitive` and its collection are similar to `Billboard` and its collection, with the following differences:\r\n\r\n* `PointPrimitive` uses `glPointSize` instead of textured quads (for 1/4th the vertices and no indicies).\r\n* `PointPrimitive` does not have any image or texture atlas system at all.\r\n* `PointPrimitive` does not support `EyeOffset`, `PixelOffset`, or `PixelOffsetScaleByDistance`.\r\n* `PointPrimitive` directly supports concepts from `Entity.point`, such as outline color/width.\r\n* `PointPrimitiveCollection` uses a single draw call, as opposed to `BillboardCollection`'s 16k billboards per draw due to 16-bit indicies (64k verts per draw, at 4 verts per billboard).\r\n* `PointPrimitiveCollection` does not suffer from a `scale` value being mismatched with a raster image of a circle of the wrong size.\r\n* The point's edges and outlines are visually clearer.\r\n\r\nThat last claim is perhaps subjective, so I'll attach some screenshots of a CZML file from [SatelliteViewer](http://apps.agi.com/SatelliteViewer/).  Here it is in master, with Billboards, followed by the same with PointPrimitives from this PR:\r\n\r\n![points2viabillboards](https://cloud.githubusercontent.com/assets/1235080/7121360/0df5a2c8-e1e2-11e4-9aa1-611523782ea8.png)\r\n\r\n![points2viaprimitives](https://cloud.githubusercontent.com/assets/1235080/7121366/14039346-e1e2-11e4-8620-78dfd5fd9efa.png)\r\n\r\nAdditional performance testing of this branch is most welcome.  The biggest gains seen thus far are mostly in the creation of points, although the rendering does appear to yield a small percentage gain in FPS as well.\r\n\r\n[Here is a Gist](https://gist.github.com/emackey/7a4096d8535c835372f8) of a Sandcastle demo that will create arbitrary numbers of PointPrimitives or Billboards, based on a number and a flag at the top of the file.  Generally I find that creating PointPrimitives is an order of magnitude or so faster than creating the same number of Billboards.  My machine will crash a Chrome tab if I ask for more than about 400k Billboards, but will let me render about 800k PointPrimitives at the high end."},"comment":{"url":"https://api.github.com/repos/AnalyticalGraphicsInc/cesium/issues/comments/98879287","html_url":"https://github.com/AnalyticalGraphicsInc/cesium/pull/2632#issuecomment-98879287","issue_url":"https://api.github.com/repos/AnalyticalGraphicsInc/cesium/issues/2632","id":98879287,"user":{"login":"pjcozzi","id":782098,"avatar_url":"https://avatars.githubusercontent.com/u/782098?v=3","gravatar_id":"","url":"https://api.github.com/users/pjcozzi","html_url":"https://github.com/pjcozzi","followers_url":"https://api.github.com/users/pjcozzi/followers","following_url":"https://api.github.com/users/pjcozzi/following{/other_user}","gists_url":"https://api.github.com/users/pjcozzi/gists{/gist_id}","starred_url":"https://api.github.com/users/pjcozzi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pjcozzi/subscriptions","organizations_url":"https://api.github.com/users/pjcozzi/orgs","repos_url":"https://api.github.com/users/pjcozzi/repos","events_url":"https://api.github.com/users/pjcozzi/events{/privacy}","received_events_url":"https://api.github.com/users/pjcozzi/received_events","type":"User","site_admin":false},"created_at":"2015-05-04T22:52:11Z","updated_at":"2015-05-04T22:52:11Z","body":"@emackey what is test coverage for `PointPrimitive` and `PointPrimitiveCollection`?  I imagine they are high."}}