{"action":"created","issue":{"url":"https://api.github.com/repos/vasturiano/react-force-graph/issues/38","repository_url":"https://api.github.com/repos/vasturiano/react-force-graph","labels_url":"https://api.github.com/repos/vasturiano/react-force-graph/issues/38/labels{/name}","comments_url":"https://api.github.com/repos/vasturiano/react-force-graph/issues/38/comments","events_url":"https://api.github.com/repos/vasturiano/react-force-graph/issues/38/events","html_url":"https://github.com/vasturiano/react-force-graph/issues/38","id":357417862,"node_id":"MDU6SXNzdWUzNTc0MTc4NjI=","number":38,"title":"How to represent irregular polygon as sprite?","user":{"login":"wadehenning","id":10761087,"node_id":"MDQ6VXNlcjEwNzYxMDg3","avatar_url":"https://avatars3.githubusercontent.com/u/10761087?v=4","gravatar_id":"","url":"https://api.github.com/users/wadehenning","html_url":"https://github.com/wadehenning","followers_url":"https://api.github.com/users/wadehenning/followers","following_url":"https://api.github.com/users/wadehenning/following{/other_user}","gists_url":"https://api.github.com/users/wadehenning/gists{/gist_id}","starred_url":"https://api.github.com/users/wadehenning/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wadehenning/subscriptions","organizations_url":"https://api.github.com/users/wadehenning/orgs","repos_url":"https://api.github.com/users/wadehenning/repos","events_url":"https://api.github.com/users/wadehenning/events{/privacy}","received_events_url":"https://api.github.com/users/wadehenning/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":9,"created_at":"2018-09-05T21:51:38Z","updated_at":"2018-10-20T00:55:54Z","closed_at":null,"author_association":"NONE","body":"Thank you for this beautiful repo.  How do I replace the 3D Text nodes with irregular shapes?  For example, my shapes might look something California in this example.\r\nhttps://threejs.org/examples/#webgl_geometry_shapes"},"comment":{"url":"https://api.github.com/repos/vasturiano/react-force-graph/issues/comments/431535328","html_url":"https://github.com/vasturiano/react-force-graph/issues/38#issuecomment-431535328","issue_url":"https://api.github.com/repos/vasturiano/react-force-graph/issues/38","id":431535328,"node_id":"MDEyOklzc3VlQ29tbWVudDQzMTUzNTMyOA==","user":{"login":"vasturiano","id":6784226,"node_id":"MDQ6VXNlcjY3ODQyMjY=","avatar_url":"https://avatars1.githubusercontent.com/u/6784226?v=4","gravatar_id":"","url":"https://api.github.com/users/vasturiano","html_url":"https://github.com/vasturiano","followers_url":"https://api.github.com/users/vasturiano/followers","following_url":"https://api.github.com/users/vasturiano/following{/other_user}","gists_url":"https://api.github.com/users/vasturiano/gists{/gist_id}","starred_url":"https://api.github.com/users/vasturiano/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vasturiano/subscriptions","organizations_url":"https://api.github.com/users/vasturiano/orgs","repos_url":"https://api.github.com/users/vasturiano/repos","events_url":"https://api.github.com/users/vasturiano/events{/privacy}","received_events_url":"https://api.github.com/users/vasturiano/received_events","type":"User","site_admin":false},"created_at":"2018-10-20T00:55:54Z","updated_at":"2018-10-20T00:55:54Z","author_association":"OWNER","body":"@wadehenning the signature of `nodeCanvasObject` is\r\n```\r\n.nodeCanvasObject((<nodeData>, <canvas context>, <current global scale>) => { /* ... do something with the context for representing this node */ })\r\n```\r\n\r\nIn your code above, you're not unpacking the function signature correctly, it should be `(node, ctx) => {...}`.\r\n\r\nAlso you should do some drawing operations on the context, otherwise `ctx.fill()` has nothing to fill.\r\n\r\nHere's an example of using the `nodeCanvasObject` that may be of help:\r\nhttps://github.com/vasturiano/force-graph/blob/master/example/custom-node-shape/index.html\r\n"}}
{"actor":{"display_login":"vasturiano"}}