*/}}

ourpaint.c 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. #include "ourpaint.h"
  2. extern LA MAIN;
  3. extern tnsMain* T;
  4. extern OurPaint *Our;
  5. int main(int argc, char *argv[]){
  6. laGetReady();
  7. if(!ourInit()){ laShutoff(); return -1; }
  8. laRefreshUDFRegistries();
  9. laEnsureUserPreferences();
  10. for(int i=1;i<argc;i++){
  11. char* file=argv[i];
  12. laManagedUDF* m; laUDF* udf = laOpenUDF(file, 1, 0, &m);
  13. if(udf){ laExtractUDF(udf,m,LA_UDF_MODE_APPEND,0); laCloseUDF(udf); }
  14. }
  15. //laAddRootDBInst("la.input_mapping");
  16. //laAddRootDBInst("la.drivers");
  17. //laAddRootDBInst("our.tools");
  18. laWindow* w = laDesignWindow(-1,-1,600,600);
  19. laLayout* l = laDesignLayout(w, "Our Paint");
  20. laBlock* b = l->FirstBlock;
  21. laSplitBlockHorizon(b,0.7);
  22. laCreatePanel(b->B1, "panel_canvas");
  23. laBlock* br=b->B2;
  24. laSplitBlockVertical(br,0.6);
  25. laCreatePanel(br->B1, "panel_color");
  26. laCreatePanel(br->B1, "panel_tools");
  27. laCreatePanel(br->B1, "panel_brushes");
  28. laCreatePanel(br->B2, "panel_layers");
  29. laStartWindow(w);
  30. laMainLoop();
  31. }