{"id":578,"date":"2011-03-29T13:47:00","date_gmt":"2011-03-29T13:47:00","guid":{"rendered":"http:\/\/pycheung.com\/weblog\/?p=578"},"modified":"2012-12-10T17:29:29","modified_gmt":"2012-12-10T17:29:29","slug":"hex-grid","status":"publish","type":"post","link":"https:\/\/www.pycheung.com\/weblog\/post\/578","title":{"rendered":"hex grid"},"content":{"rendered":"<p>          <a href=\"http:\/\/www.pycheung.com\/weblog\/wp-content\/uploads\/hex7.jpg\" title=\"hex7.jpg\">            <img loading=\"lazy\" src=\"http:\/\/www.pycheung.com\/weblog\/wp-content\/uploads\/zrtn_002p6e482c2_tn.jpg\" style=\"BORDER-BOTTOM: #000000 1px; BORDER-LEFT: #000000 1px; BORDER-TOP: #000000 1px; BORDER-RIGHT: #000000 1px\" height=\"369\" width=\"800\" alt=\"hex7.jpg\" border=\"0\"\/>          <\/a> <br \/>Building hex grid by staggering stardard grid <\/p>\n<p>Characteristics: <br \/>same distance between each cell&#8217;s center and neighbor center <br \/>6 immediate neighbor with shared edge <\/p>\n<p>Issues: <br \/>Extra run time required to convert global point to hex coordinate <br \/>horizontal\/vertical orthographic trace lines have different length i.e. 0,2 to 0,0 comparing to 0,0 to 2,0         <\/p>\n<p>          <a href=\"http:\/\/www.pycheung.com\/weblog\/wp-content\/uploads\/hex3_0001.jpg\" title=\"hex3.jpg\">            <img loading=\"lazy\" src=\"http:\/\/www.pycheung.com\/weblog\/wp-content\/uploads\/zrtn_006n1e95d7af_tn.jpg\" style=\"BORDER-BOTTOM: #000000 1px; BORDER-LEFT: #000000 1px; BORDER-TOP: #000000 1px; BORDER-RIGHT: #000000 1px\" height=\"115\" width=\"250\" alt=\"hex3.jpg\" border=\"0\"\/>          <\/a> <a href=\"http:\/\/www.pycheung.com\/weblog\/wp-content\/uploads\/hex8.jpg\" title=\"hex8.jpg\">            <img loading=\"lazy\" src=\"http:\/\/www.pycheung.com\/weblog\/wp-content\/uploads\/zrtn_007n4a721d3b_tn.jpg\" style=\"BORDER-BOTTOM: #000000 1px; BORDER-LEFT: #000000 1px; BORDER-TOP: #000000 1px; BORDER-RIGHT: #000000 1px\" height=\"115\" width=\"250\" alt=\"hex8.jpg\" border=\"0\"\/>          <\/a>        <\/p>\n<p>Convert global point to hex coordinate <br \/>1. convert point to nearest rectangular cell <br \/>2. check for point in hex, apply different x,y for the 4 corners and even\/odd rows<\/p>\n<p>        <\/p>\n","protected":false},"excerpt":{"rendered":"<p>Building hex grid by staggering stardard grid Characteristics: same distance between each cell&#8217;s center and neighbor center 6 immediate neighbor with shared edge Issues: Extra run time required to convert&#8230;<\/p>\n<div class=\"royalwp-readmore-wrap\"><a href=\"https:\/\/www.pycheung.com\/weblog\/post\/578\" class=\"royalwp-readmore\">Explore more <i class=\"far fa-hand-point-right\"><\/i><\/a><\/div>\n","protected":false},"author":2,"featured_media":1140,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[153],"tags":[47,48,60,90],"_links":{"self":[{"href":"https:\/\/www.pycheung.com\/weblog\/wp-json\/wp\/v2\/posts\/578"}],"collection":[{"href":"https:\/\/www.pycheung.com\/weblog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.pycheung.com\/weblog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.pycheung.com\/weblog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.pycheung.com\/weblog\/wp-json\/wp\/v2\/comments?post=578"}],"version-history":[{"count":1,"href":"https:\/\/www.pycheung.com\/weblog\/wp-json\/wp\/v2\/posts\/578\/revisions"}],"predecessor-version":[{"id":1008,"href":"https:\/\/www.pycheung.com\/weblog\/wp-json\/wp\/v2\/posts\/578\/revisions\/1008"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.pycheung.com\/weblog\/wp-json\/wp\/v2\/media\/1140"}],"wp:attachment":[{"href":"https:\/\/www.pycheung.com\/weblog\/wp-json\/wp\/v2\/media?parent=578"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.pycheung.com\/weblog\/wp-json\/wp\/v2\/categories?post=578"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.pycheung.com\/weblog\/wp-json\/wp\/v2\/tags?post=578"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}