how do i use both of these together. i get a crash when either pollevent or waitevent are called for the gui events.
here is a clip of what im trying to do, i just chopped up my code into the parts that show whats going on.
here is a clip of what im trying to do, i just chopped up my code into the parts that show whats going on.
mainwin = CreateWindow:TGadget("EOL Geometry Tool "+version$,50,50,GadgetWidth(Desktop())-100,GadgetHeight(Desktop())-100,Desktop()) view1 = CreateCanvas((GadgetWidth(mainwin)/4),0,(GadgetWidth(mainwin)-(GadgetWidth(mainwin)/4))/2,(GadgetHeight(mainwin)/2)-50,mainwin) SetGadgetLayout( view1,EDGE_ALIGNED,EDGE_RELATIVE,EDGE_ALIGNED,EDGE_RELATIVE ) view2 = CreateCanvas((GadgetWidth(mainwin)/4)+GadgetWidth(view1),0,GadgetWidth(mainwin)-((GadgetWidth(mainwin)/4)+GadgetWidth(view1)),(GadgetHeight(mainwin)/2)-50,mainwin) SetGadgetLayout( view2,EDGE_RELATIVE,EDGE_ALIGNED,EDGE_ALIGNED,EDGE_RELATIVE ) view3 = CreateCanvas((GadgetWidth(mainwin)/4),GadgetY(view1)+GadgetHeight(view1),(GadgetWidth(mainwin)-(GadgetWidth(mainwin)/4))/2,(GadgetHeight(mainwin)/2)-50,mainwin) SetGadgetLayout( view3,EDGE_ALIGNED,EDGE_RELATIVE,EDGE_RELATIVE,EDGE_ALIGNED ) '3d view view4 = CreatePanel(GadgetX(view3)+GadgetWidth(view3),GadgetY(view2)+GadgetHeight(view2),GadgetWidth(mainwin)-((GadgetWidth(mainwin)/4)+GadgetWidth(view1)),(GadgetHeight(mainwin)/2)-50,mainwin) SetGadgetLayout( view4,EDGE_RELATIVE,EDGE_ALIGNED,EDGE_RELATIVE,EDGE_ALIGNED ) hwnd=QueryGadget(view4,QUERY_HWND) w=ClientWidth(Desktop()) h=ClientHeight(Desktop()) bbSetBlitz3DHWND(hwnd) bbSetBlitz3DEventCallback(Int Byte Ptr BBEventHandler) bbBeginBlitz3D bbGraphics3D w,h,0,2 maincam=bbCreateCamera() bbPositionEntity maincam,0,0,-10 bbCameraClsColor maincam,100,100,100 EnablePolledinput While True 'crashes at pollevent or waitevent pollevent() Wend Function BBEventHandler(hwnd,msg,wp,lp) "win32" bbSystemEmitOSEvent hwnd,msg,wp,lp,Null Return -1 End Function