{"action":"created","issue":{"url":"https://api.github.com/repos/raptor/clip2tri/issues/5","repository_url":"https://api.github.com/repos/raptor/clip2tri","labels_url":"https://api.github.com/repos/raptor/clip2tri/issues/5/labels{/name}","comments_url":"https://api.github.com/repos/raptor/clip2tri/issues/5/comments","events_url":"https://api.github.com/repos/raptor/clip2tri/issues/5/events","html_url":"https://github.com/raptor/clip2tri/issues/5","id":191341041,"number":5,"title":"clip2tri class design issue.","user":{"login":"Talkless","id":292191,"avatar_url":"https://avatars.githubusercontent.com/u/292191?v=3","gravatar_id":"","url":"https://api.github.com/users/Talkless","html_url":"https://github.com/Talkless","followers_url":"https://api.github.com/users/Talkless/followers","following_url":"https://api.github.com/users/Talkless/following{/other_user}","gists_url":"https://api.github.com/users/Talkless/gists{/gist_id}","starred_url":"https://api.github.com/users/Talkless/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Talkless/subscriptions","organizations_url":"https://api.github.com/users/Talkless/orgs","repos_url":"https://api.github.com/users/Talkless/repos","events_url":"https://api.github.com/users/Talkless/events{/privacy}","received_events_url":"https://api.github.com/users/Talkless/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2016-11-23T17:51:41Z","updated_at":"2016-11-24T06:33:45Z","closed_at":null,"body":"Hi,\r\n\r\nIt seems that [c2t::clip2tri::triangulate](https://github.com/raptor/clip2tri/blob/5a11e66fef454c33ddfc080c17a9b2b03f7b642b/clip2tri/clip2tri.h#L61) could be marked as static, because it does not use any class member variables.\r\n\r\nIn fact, there are no member variables in `clip2tri` at all, so maybe `c2t::clip2tri::triangulate()` should be simply become a free function `c2t::triangulate()`, and all private `clip2tri` member functions used in implementation hidden inside `.cpp` file.\r\n\r\nIt seems that `clip2tri` class existence produces some misunderstanding, as I've seen new'ing `clip2tri` object in Qt source code [qdeclarativepolygonmapitem.cpp line 288](https://code.qt.io/cgit/qt/qtlocation.git/tree/src/imports/location/qdeclarativepolygonmapitem.cpp?h=5.7#n288). There is no object needed as `clip2tri` has no member variables."},"comment":{"url":"https://api.github.com/repos/raptor/clip2tri/issues/comments/262700811","html_url":"https://github.com/raptor/clip2tri/issues/5#issuecomment-262700811","issue_url":"https://api.github.com/repos/raptor/clip2tri/issues/5","id":262700811,"user":{"login":"Talkless","id":292191,"avatar_url":"https://avatars.githubusercontent.com/u/292191?v=3","gravatar_id":"","url":"https://api.github.com/users/Talkless","html_url":"https://github.com/Talkless","followers_url":"https://api.github.com/users/Talkless/followers","following_url":"https://api.github.com/users/Talkless/following{/other_user}","gists_url":"https://api.github.com/users/Talkless/gists{/gist_id}","starred_url":"https://api.github.com/users/Talkless/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Talkless/subscriptions","organizations_url":"https://api.github.com/users/Talkless/orgs","repos_url":"https://api.github.com/users/Talkless/repos","events_url":"https://api.github.com/users/Talkless/events{/privacy}","received_events_url":"https://api.github.com/users/Talkless/received_events","type":"User","site_admin":false},"created_at":"2016-11-24T06:33:45Z","updated_at":"2016-11-24T06:33:45Z","body":"Well, at least marking `triangulate()` method as static could work, as guarantee/documentation that no object creation is needed for this particular algorithm, if removing whole class seems too much breaking change."}}
{"actor":{"display_login":"Talkless"}}