text: [{"Owner":"aaronmck","Date":"2016-08-28T16:35:48Z","Content":"_lt_div class_eq__qt_mages_qt__gt_\n\t\t\t\n_lt_p_gt_\n\tHi all_co_\n_lt_/p_gt_\n\n_lt_p_gt_\n\tSo I_t_m working on a project where I need to be able to click on a mesh and have information about that mesh appear on the screen.\n_lt_/p_gt_\n\n_lt_p_gt_\n\tI was told I should use Canvas2D but I_t_m still pretty new with this and it is simply going above my head_co_ I haven_t_t a clue where to start with this. \n_lt_/p_gt_\n\n_lt_p_gt_\n\tCould anyone be kind enough to help me with this?\n_lt_/p_gt_\n\n_lt_p_gt_\n\tI have attached a playground with what I_t_m looking to do.\n_lt_/p_gt_\n\n_lt_p_gt_\n\tBasically I will have multiple meshes on screen and when I click / double click on one of the meshes it will display info for that particular mesh. \n_lt_/p_gt_\n\n_lt_p_gt_\n\t_lt_a href_eq__qt_http_dd_//babylonjs-playground.com/#BPV7F_qt_ rel_eq__qt_external nofollow_qt__gt_http_dd_//babylonjs-playground.com/#BPV7F_lt_/a_gt_\n_lt_/p_gt_\n\n_lt_p_gt_\n\tThanks in advance!\n_lt_/p_gt_\n\n\n\t\t\t\n\t\t_lt_/div_gt_\n\n\t\t_lt_div class_eq__qt_ipsI_qt__gt__lt_/div_gt__lt_/div_gt_"},{"Owner":"Sebavan","Date":"2016-08-28T17:38:39Z","Content":"_lt_div class_eq__qt_mages_qt__gt_\n\t\t\t\n_lt_p_gt_\n\tHello_co_\n_lt_/p_gt_\n\n_lt_p_gt_\n\tYou first need to attach the control to the canvas (html one not the 2d feature)_co_ but this was probably throwing due to name conflict (the canvas2d was also named canvas in your scene).\n_lt_/p_gt_\n\n_lt_p_gt_\n\tOnce done the controls are working_co_ then you can use the action manager to reference an action when the mesh is clicked.\n_lt_/p_gt_\n\n_lt_p_gt_\n\tThis action happens on pick and set the property _qt_text_qt_ of the text2d element to the chosen text... (agree it is a lot of texts and canvases...) You can check the code here_dd_\n_lt_/p_gt_\n\n_lt_p_gt_\n\t_lt_a href_eq__qt_http_dd_//babylonjs-playground.com/#BPV7F%239_qt_ rel_eq__qt_external nofollow_qt__gt_http_dd_//babylonjs-playground.com/#BPV7F#9_lt_/a_gt_\n_lt_/p_gt_\n\n_lt_p_gt_\n\tThe easiest would be to read the doc for the action manager and the other pg samples_dd_\n_lt_/p_gt_\n\n_lt_p_gt_\n\t_lt_a href_eq__qt_https_dd_//doc.babylonjs.com/tutorials/How_to_use_Actions_qt_ rel_eq__qt_external nofollow_qt__gt_https_dd_//doc.babylonjs.com/tutorials/How_to_use_Actions_lt_/a_gt_\n_lt_/p_gt_\n\n_lt_p_gt_\n\t \n_lt_/p_gt_\n\n\n\t\t\t\n\t\t_lt_/div_gt_\n\n\t\t_lt_div class_eq__qt_ipsI_qt__gt__lt_/div_gt__lt_/div_gt_"},{"Owner":"aaronmck","Date":"2016-08-29T13:00:08Z","Content":"_lt_div class_eq__qt_mages_qt__gt_\n\t\t\t\n_lt_p_gt_\n\tHey _lt_a contenteditable_eq__qt_false_qt_ data-ipshover_eq__qt__qt_ data-ipshover-target_eq__qt_http_dd_//www.html5gamedevs.com/profile/20193-sebavan/?do_eq_hovercard_qt_ data-mentionid_eq__qt_20193_qt_ href_eq__qt_http_dd_//www.html5gamedevs.com/profile/20193-sebavan/_qt_ rel_eq__qt__qt__gt_@Sebavan_lt_/a_gt_\n_lt_/p_gt_\n\n_lt_p_gt_\n\tThis is great_co_ very helpful.\n_lt_/p_gt_\n\n_lt_p_gt_\n\tJust one issue. I have some of my models load on a button click and others that do not. \n_lt_/p_gt_\n\n_lt_p_gt_\n\tThe canvas 2d panel works on the models that don_t_t load on button click but doesn_t_t work on the models that do load on button click.\n_lt_/p_gt_\n\n_lt_p_gt_\n\tDo you know why this is?\n_lt_/p_gt_\n\n_lt_p_gt_\n\tThanks!\n_lt_/p_gt_\n\n\n\t\t\t\n\t\t_lt_/div_gt_\n\n\t\t_lt_div class_eq__qt_ipsI_qt__gt__lt_/div_gt__lt_/div_gt_"},{"Owner":"Sebavan","Date":"2016-08-29T16:02:41Z","Content":"_lt_div class_eq__qt_mages_qt__gt_\n\t\t\t_lt_p_gt_\n\tI would bet on the function not being attached correctly_co_ could you share a PG with a repro please ?\n_lt_/p_gt_\n\n\t\t\t\n\t\t_lt_/div_gt_\n\n\t\t_lt_div class_eq__qt_ipsI_qt__gt__lt_/div_gt__lt_/div_gt_"},{"Owner":"aaronmck","Date":"2016-08-29T17:52:31Z","Content":"_lt_div class_eq__qt_mages_qt__gt_\n\t\t\t\n_lt_p_gt_\n\t_lt_a contenteditable_eq__qt_false_qt_ data-ipshover_eq__qt__qt_ data-ipshover-target_eq__qt_http_dd_//www.html5gamedevs.com/profile/20193-sebavan/?do_eq_hovercard_qt_ data-mentionid_eq__qt_20193_qt_ href_eq__qt_http_dd_//www.html5gamedevs.com/profile/20193-sebavan/_qt_ rel_eq__qt__qt__gt_@Sebavan_lt_/a_gt_ Here you go_co_ a basic example of my code i_t_m using\n_lt_/p_gt_\n\n_lt_p_gt_\n\t_lt_a href_eq__qt_http_dd_//babylonjs-playground.com/#JFMP_qt_ rel_eq__qt_external nofollow_qt__gt_http_dd_//babylonjs-playground.com/#JFMP_lt_/a_gt_\n_lt_/p_gt_\n\n_lt_p_gt_\n\tFor some reason it isn_t_t working on either of the models in that PG\n_lt_/p_gt_\n\n\n\t\t\t\n\t\t_lt_/div_gt_\n\n\t\t_lt_div class_eq__qt_ipsI_qt__gt__lt_/div_gt__lt_/div_gt_"},{"Owner":"Sebavan","Date":"2016-08-29T18:29:33Z","Content":"_lt_div class_eq__qt_mages_qt__gt_\n\t\t\t\n_lt_p_gt_\n\tHello_co_\n_lt_/p_gt_\n\n_lt_p_gt_\n\tHere is a fix_dd_ _lt_a href_eq__qt_http_dd_//babylonjs-playground.com/#JFMP%2316_qt_ rel_eq__qt_external nofollow_qt__gt_http_dd_//babylonjs-playground.com/#JFMP#16_lt_/a_gt_\n_lt_/p_gt_\n\n_lt_p_gt_\n\tYou need to make your meshes pickable (all the loaded one) and also your button did not work_co_ so I put the click to load the second element on the fps label.\n_lt_/p_gt_\n\n_lt_p_gt_\n\tI did not fix the rest of your code _dd_-) only the BJS part (not that much time today).\n_lt_/p_gt_\n\n_lt_p_gt_\n\tCU_co_\n_lt_/p_gt_\n\n_lt_p_gt_\n\t \n_lt_/p_gt_\n\n\n\t\t\t\n\t\t_lt_/div_gt_\n\n\t\t_lt_div class_eq__qt_ipsI_qt__gt__lt_/div_gt__lt_/div_gt_"},{"Owner":"aaronmck","Date":"2016-08-29T18:34:59Z","Content":"_lt_div class_eq__qt_mages_qt__gt_\n\t\t\t\n_lt_p_gt_\n\tHey_co_\n_lt_/p_gt_\n\n_lt_p_gt_\n\tThis is perfect_co_ I got it working in my code so thanks very much_co_ greatly appreciated!\n_lt_/p_gt_\n\n\n\t\t\t\n\t\t_lt_/div_gt_\n\n\t\t_lt_div class_eq__qt_ipsI_qt__gt__lt_/div_gt__lt_/div_gt_"}]