123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769 |
- /*
- * LaGUI: A graphical application framework.
- * Copyright (C) 2022-2023 Wu Yiming
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program. If not, see <http://www.gnu.org/licenses/>.
- */
- #pragma once
- #ifdef LAGUI_ANDROID
- #include <GLES3/gl32.h>
- #include <EGL/egl.h>
- #include <android/input.h>
- #include <android/keycodes.h>
- #else
- #ifdef LA_USE_GLES
- #include <EGL/egl.h>
- #include <GL/gl.h>
- #else
- #include <GL/glew.h>
- #include <GL/gl.h>
- #endif
- #endif
- #ifdef __linux__
- #ifndef LAGUI_ANDROID
- #include <X11/Xlib.h>
- #include <X11/Xutil.h>
- #include <X11/Xresource.h>
- #include <X11/Xlocale.h>
- #include <X11/XKBlib.h>
- #include <X11/Xatom.h>
- #include <GL/glx.h>
- #include <GL/glext.h>
- #endif
- #endif
- #ifdef _WIN32
- #include <GL/wglew.h>
- #endif
- #include "la_5.h"
- #include "la_data.h"
- //#include "llvm-c/Analysis.h"
- //#include "llvm-c/BitWriter.h"
- //#include "llvm-c/Core.h"
- //#include "llvm-c/ExecutionEngine.h"
- //#include "llvm-c/Target.h"
- //#include <Windows.h>
- #define LA_VERSION_MAIN 5
- #define LA_VERSION_SUB 3
- #define LA_ACTUATOR_CAPABILITY_MAIN 5
- #define LA_ACTUATOR_CAPABILITY_SUB 0
- #define LA_NODE_MAIN_MODULE_NAME "LA_NODE_MAIN_MODULE"
- #define LA_GUI_WNDCLASS_NAME "LA_WINDOW_CLASS"
- #define LA_ARROW 0
- #define LA_CROSS 1
- #define LA_LEFT_AND_RIGHT 2
- #define LA_UP_AND_DOWN 3
- #define LA_HAND 4
- #define LA_MOVE 5
- #define LA_CORNER 6
- #define EVT_WND_MOVE -1
- #define EVT_WND_SIZE_BEGIN -2
- #define EVT_WND_SIZE_FINISH -3
- #define EVT_WND_SIZE -4
- #define EVT_WND_SHOW -5
- #define EVT_FEEDBACK 8192
- #define LA_KEYBOARD_EVENT (1<<0)
- #define LA_MOUSE_EVENT (1<<1)
- #define LA_STATE_MOVE (1<<2)
- #define LA_STATE_DOWN (1<<3)
- #define LA_STATE_UP (1<<4)
- #define LA_TIME_EVENT (1<<5)
- #define LA_TIME_IDLE (LA_TIME_EVENT|(1<<6))
- #define LA_TIME_DELAY (LA_TIME_EVENT|(1<<7))
- #define LA_KEY_MOUSE_LEFT (1<<8)
- #define LA_KEY_MOUSE_MIDDLE (1<<9)
- #define LA_KEY_MOUSE_RIGHT (1<<10)
- #define LA_KEY_MOUSE_SCROLL (1<<11)
- #define LA_KEY_BACKSPACE (1<<12)
- #define LA_KEY_ESCAPE (1<<13)
- #define LA_KEY_ENTER (1<<14)
- #define LA_INPUT (1<<15)
- #define LA_KEY_ARRLEFT (1<<16)
- #define LA_KEY_ARRRIGHT (1<<17)
- #define LA_KEY_ARRUP (1<<18)
- #define LA_KEY_ARRDOWN (1<<19)
- #define LA_KEY_SHIFT (1<<20)
- #define LA_KEY_CTRL (1<<21)
- #define LA_KEY_ALT (1<<22)
- #define LA_KEY_DELETE (1<<23)
- #define LA_KEY_TAB (1<<24)
- #define LA_KEY_EXTRA (1<<25)
- #define LA_KEY_NUM1 (LA_KEY_EXTRA+1)
- #define LA_KEY_NUM2 (LA_KEY_EXTRA+2)
- #define LA_KEY_NUM3 (LA_KEY_EXTRA+3)
- #define LA_KEY_NUM4 (LA_KEY_EXTRA+4)
- #define LA_KEY_NUM5 (LA_KEY_EXTRA+5)
- #define LA_KEY_NUM6 (LA_KEY_EXTRA+6)
- #define LA_KEY_NUM7 (LA_KEY_EXTRA+7)
- #define LA_KEY_NUM8 (LA_KEY_EXTRA+8)
- #define LA_KEY_NUM9 (LA_KEY_EXTRA+9)
- #define LA_KEY_NUM0 (LA_KEY_EXTRA+10)
- #define LA_KEY_NUMPLUS (LA_KEY_EXTRA+11)
- #define LA_KEY_NUMMINUS (LA_KEY_EXTRA+12)
- #define LA_KEY_NUMMULT (LA_KEY_EXTRA+13)
- #define LA_KEY_NUMDIVIDE (LA_KEY_EXTRA+14)
- #define LA_KEY_NUMDOT (LA_KEY_EXTRA+15)
- #define LA_KEY_NUMENTER (LA_KEY_EXTRA+16)
- #define LA_KEY_PANNING (1<<26)
- #define LA_SIGNAL_EVENT (1<<31)
- #ifdef _WIN32
- #define XK_F1 1
- #define XK_F2 2
- #define XK_F3 3
- #define XK_F4 4
- #define XK_F5 5
- #define XK_F6 6
- #define XK_F7 7
- #define XK_F8 8
- #define XK_F9 9
- #define XK_F10 10
- #define XK_F11 11
- #define XK_F12 12
- #endif
- #if defined(LA_LINUX) || defined(_WIN32)
- #define LA_KEY_F1 XK_F1
- #define LA_KEY_F2 XK_F2
- #define LA_KEY_F3 XK_F3
- #define LA_KEY_F4 XK_F4
- #define LA_KEY_F5 XK_F5
- #define LA_KEY_F6 XK_F6
- #define LA_KEY_F7 XK_F7
- #define LA_KEY_F8 XK_F8
- #define LA_KEY_F9 XK_F9
- #define LA_KEY_F10 XK_F10
- #define LA_KEY_F11 XK_F11
- #define LA_KEY_F12 XK_F12
- #endif
- #ifdef LAGUI_ANDROID
- #define LA_KEY_F1 AKEYCODE_F1
- #define LA_KEY_F2 AKEYCODE_F2
- #define LA_KEY_F3 AKEYCODE_F3
- #define LA_KEY_F4 AKEYCODE_F4
- #define LA_KEY_F5 AKEYCODE_F5
- #define LA_KEY_F6 AKEYCODE_F6
- #define LA_KEY_F7 AKEYCODE_F7
- #define LA_KEY_F8 AKEYCODE_F8
- #define LA_KEY_F9 AKEYCODE_F9
- #define LA_KEY_F10 AKEYCODE_F10
- #define LA_KEY_F11 AKEYCODE_F11
- #define LA_KEY_F12 AKEYCODE_F12
- #endif
- #define LA_KEY_SPECIALS (LA_KEY_CTRL|LA_KEY_SHIFT|LA_KEY_ALT)
- #define LA_MOUSEMOVE (LA_MOUSE_EVENT | LA_STATE_MOVE)
- #define LA_EMPTY LA_MOUSEMOVE
- #define LA_MOUSEDOWN (LA_MOUSE_EVENT | LA_STATE_DOWN)
- #define LA_MOUSEUP (LA_MOUSE_EVENT | LA_STATE_UP)
- #define LA_WHEEL (LA_MOUSE_EVENT | LA_KEY_MOUSE_SCROLL)
- #define LA_L_MOUSE_DOWN (LA_MOUSE_EVENT | LA_STATE_DOWN | LA_KEY_MOUSE_LEFT)
- #define LA_L_MOUSE_UP (LA_MOUSE_EVENT | LA_STATE_UP | LA_KEY_MOUSE_LEFT)
- #define LA_M_MOUSE_DOWN (LA_MOUSE_EVENT | LA_STATE_DOWN | LA_KEY_MOUSE_MIDDLE)
- #define LA_M_MOUSE_UP (LA_MOUSE_EVENT | LA_STATE_UP | LA_KEY_MOUSE_MIDDLE)
- #define LA_R_MOUSE_DOWN (LA_MOUSE_EVENT | LA_STATE_DOWN | LA_KEY_MOUSE_RIGHT)
- #define LA_R_MOUSE_UP (LA_MOUSE_EVENT | LA_STATE_UP | LA_KEY_MOUSE_RIGHT)
- #define LA_MOUSE_WHEEL_DOWN (LA_MOUSE_EVENT | LA_STATE_DOWN | LA_KEY_MOUSE_SCROLL)
- #define LA_MOUSE_WHEEL_UP (LA_MOUSE_EVENT | LA_STATE_UP | LA_KEY_MOUSE_SCROLL)
- #define LA_KEY_DOWN (LA_KEYBOARD_EVENT | LA_STATE_DOWN)
- #define LA_KEY_UP (LA_KEYBOARD_EVENT | LA_STATE_UP)
- #define LA_PANNING_LEFT (LA_KEYBOARD_EVENT | LA_KEY_PANNING | LA_KEY_ARRLEFT)
- #define LA_PANNING_RIGHT (LA_KEYBOARD_EVENT | LA_KEY_PANNING | LA_KEY_ARRRIGHT)
- #define LA_PANNING_UP (LA_KEYBOARD_EVENT | LA_KEY_PANNING | LA_KEY_ARRUP)
- #define LA_PANNING_DOWN (LA_KEYBOARD_EVENT | LA_KEY_PANNING | LA_KEY_ARRDOWN)
- #define LA_LEFT_DOWN (LA_KEYBOARD_EVENT | LA_KEY_ARRLEFT | LA_STATE_DOWN)
- #define LA_RIGHT_DOWN (LA_KEYBOARD_EVENT | LA_KEY_ARRRIGHT | LA_STATE_DOWN)
- #define LA_UP_DOWN (LA_KEYBOARD_EVENT | LA_KEY_ARRUP | LA_STATE_DOWN)
- #define LA_DOWN_DOWN (LA_KEYBOARD_EVENT | LA_KEY_ARRDOWN | LA_STATE_DOWN)
- #define LA_LEFT_UP (LA_KEYBOARD_EVENT | LA_KEY_ARRLEFT | LA_STATE_UP)
- #define LA_RIGHT_UP (LA_KEYBOARD_EVENT | LA_KEY_ARRRIGHT | LA_STATE_UP)
- #define LA_UP_UP (LA_KEYBOARD_EVENT | LA_KEY_ARRUP | LA_STATE_UP)
- #define LA_DOWN_UP (LA_KEYBOARD_EVENT | LA_KEY_ARRDOWN | LA_STATE_UP)
- #define LA_BACKSPACE_DOWN (LA_KEYBOARD_EVENT | LA_KEY_BACKSPACE | LA_STATE_DOWN)
- #define LA_BACKSPACE_UP (LA_KEYBOARD_EVENT | LA_KEY_BACKSPACE | LA_STATE_UP)
- #define LA_ESCAPE_DOWN (LA_KEYBOARD_EVENT | LA_KEY_ESCAPE | LA_STATE_DOWN)
- #define LA_ESCAPE_UP (LA_KEYBOARD_EVENT | LA_KEY_ESCAPE | LA_STATE_UP)
- #define LA_ENTER_DOWN (LA_KEYBOARD_EVENT | LA_KEY_ENTER | LA_STATE_DOWN)
- #define LA_ENTER_UP (LA_KEYBOARD_EVENT | LA_KEY_ENTER | LA_STATE_UP)
- #define LA_ONLY_BITS_AND(orig, yours) \
- ((orig & yours) == yours)
- NEED_STRUCTURE(laUiList);
- NEED_STRUCTURE(laUiItem);
- NEED_STRUCTURE(laColumn);
- typedef void (*laUiDrawFunc)(void *, int); //Instance,Theme
- typedef void (*laPanelDrawFunc)(void *, void *, void *); //SYSWINDOW,Instance,Theme
- //typedef void(*laUiDefineFunc)(laUiList*,laPropPack*,laPropPack*,laColumn*);//uil,collection inst+"This" inst,actuator inst,Extra column list.
- typedef void (*laOperatorArgumentParserFunc)(laStringSplitor *, uint32_t *, char *); //icon id,display string buf
- typedef int (*laUiGetHeightFunc)(laUiItem *);
- typedef int (*laUiGetMinWidthFunc)(laUiItem *);
- typedef int (*laUiConditionFunc)(laPropPack *); //maybe inst+actuator,replaceInst
- typedef void (*laUiDestroyFunc)(laUiItem *);
- typedef void (*laUiInitFunc)(laUiItem *);
- typedef void (*laUiRefreshFunc)(laUiItem *);
- typedef void (*laLayoutBkgDrawFunc)(void *, void *l);
- typedef void (*laPreFrameF)();
- typedef void (*laPreDrawF)();
- typedef void (*laPostFrameF)();
- typedef void (*laCleanupF)();
- STRUCTURE(laEvent){
- laListItem Item;
- laWindow* window;
- int type;
- int state;
- int x, y;
- int key;
- int SpecialKeyBit;
- int p1, p2;
- uint32_t Input;
- int GoodPressure,IsEraser,HasTwist;
- real Pressure,Orientation,Deviation,Twist,Hover;
- void *Localized;
- };
- typedef int (*laInputProcessF)(laEvent* e);
- NEED_STRUCTURE(laWindow)
- NEED_STRUCTURE(laRoot)
- NEED_STRUCTURE(laPanel)
- NEED_STRUCTURE(laUiItem)
- NEED_STRUCTURE(laUiList)
- NEED_STRUCTURE(laAnimationAction)
- NEED_STRUCTURE(laUiDescriptor)
- NEED_STRUCTURE(laUiConditionNode)
- STRUCTURE(laSharedTypeItem){
- laListItem Item;
- char ID[64];
- void *Pointer;
- };
- NEED_STRUCTURE(laTranslation);
- NEED_STRUCTURE(laTheme);
- STRUCTURE(laKeyMapper){
- laListItem Item;//unused;
- laListHandle Items;
- };
- STRUCTURE(laLogEntry){
- laListItem Item;
- laSafeString* Content;
- int Type;
- };
- NEED_STRUCTURE(laManagedUDF);
- STRUCTURE(laNodeOutSocket){
- void* Data;
- void* Parent;
- laSafeString* Label;
- int DataType, ArrLen;
- int RuntimeX, RuntimeY, RuntimePX, RuntimePY;
- void* Duplicated;
- };
- STRUCTURE(laNodeInSocket){
- laNodeOutSocket* Source;
- laSafeString* Label;
- int DataType, ArrLen; int ColorId;
- int RuntimeX, RuntimeY, RuntimePX, RuntimePY;
- };
- NEED_STRUCTURE(laBaseNodeType);
- NEED_STRUCTURE(laRackPage);
- NEED_STRUCTURE(laNodeCategory);
- STRUCTURE(laRackPageCollection){
- laRackPage* CurrentPage;
- laListHandle Pages;
- };
- typedef laBaseNodeType* (*laGetBaseNodeTypeF)(char* str);
- NEED_STRUCTURE(laConfirmData);
- STRUCTURE(laExtraPreferencePage){
- laListItem Item;
- const char* Name;
- laUiDefineFunc Func;
- };
- STRUCTURE(laProgressDisplay){
- char String[256];
- SYSWINDOW w;
- #ifdef LA_LINUX
- GC gc;
- XGCValues gc_values;
- #endif
- #ifdef _WIN32
- HBRUSH brush_bg;
- HBRUSH brush_fg;
- HPEN pen_fg;
- HDC hdc;
- #endif
- laTimeRecorder TimeCalled;
- real p1,p2;
- int Called,Shown;
- };
- STRUCTURE(laInitArguments){
- int GLMajor,GLMinor,BufferSamples;
- int GLESMajor,GLESMinor;
- int UseColorManagement;
- int HasWorldObjects;
- int HasAction;
- int HasTextureInspector;
- int HasHistories;
- int HasTerminal;
- int HasAudio;
- int GLDebug;
- int EnableLogStdOut;
- };
- NEED_STRUCTURE(laAnimation);
- NEED_STRUCTURE(laAudio);
- NEED_STRUCTURE(laInputMappingBundle);
- STRUCTURE(LA){
- laListItem Hyper;
- laListHandle Logs;
- real PerfCounter[32][32];
- laSafeString* PerfLogs[32];
- int NextPerfCounter,NextPerfGroup,ShowPerf;
- laTimeRecorder FrameStartTime, FrameEndTime;
- char* TerminalInput[512];
- laListHandle TerminalHistories;
- int TerminalIncomplete;
- int IsTerminalEnter;
- #ifdef LA_WITH_LUAJIT
- lua_State *L;
- #endif
- laListHandle Controllers; int NextControllerID;
- u8bit LastControllerKey, LastControllerKeyDevice, ControllerHasNewKey;
- u8bit LastControllerAxis, LastControllerAxisDevice, ControllerHasNewAxis;
- laEvent* CurrentInputEvent;
- laInputProcessF InputProcess;
- laListHandle Windows;
- laListHandle WastedPanels;
- laListHandle Screens;
- int AutoSwitchColorSpace;
- laConfirmData *InvokeConfirmData;
-
- laPreFrameF PreFrame;
- laPreDrawF PreDraw;
- laPostFrameF PostFrame;
- laCleanupF Cleanup;
- real IdleStart, DelayStart;
- int DelayTriggered;
- int IdleTriggered;
- int ReTriggerOperators;
- laPanel* DockingPanel;
- char SysFontDir[512];
- laInitArguments InitArgs;
- char *InputBuf; int InputBufNext, InputBufMax;
- int32_t *InputBufU; int InputBufUNext, InputBufUMax;
- #ifdef LA_LINUX
- Atom MsgDelWindow;
- Atom bufid;
- Atom fmtid;
- Atom propid;
- Atom incrid;
- Atom targets_atom;
- Atom text_atom;
- Atom UTF8;
- Atom selection;
- Atom wmstate,wmfullscr,wmfullscroff;
- #endif
- laSafeString* CopyPending;
- int GLMajor,GLMinor,GLESMajor,GLESMinor,BufferSamples;
- GLuint TempVAO;
- SYSTEMDISPLAY* dpy;
- SYSGLCONTEXT glc;
- #ifdef _WIN32
- HINSTANCE hinstance;
- HDC hdc;
- int WinTabAvailable, WinTabOpened, WinTabMaxPenPressure, WinTabMaxEraserPressure, WinTabMaxHover;
- #endif
- #ifdef LA_LINUX
- Window* win;
- XVisualInfo* xvi;
- #ifdef LA_USE_GLES
- EGLConfig BestFBC;
- EGLDisplay egl_dpy;
- #else
- GLXFBConfig BestFBC;
- #endif
- Colormap cmap;
- XIM im;
- XIC ic;
- int xi_opcode;
- #endif
- #ifdef LAGUI_ANDROID
- SYSWINDOW* win;
- EGLConfig BestFBC;
- EGLDisplay egl_dpy;
- EGLSurface egl_surf;
- struct android_app* app;
- struct android_poll_source *event_source;
- int AppWidth,AppHeight;
- int AppReady,AppEnabled;
- int ContextRebindRequired;
- AAssetManager *AssetManager;
- char *InternalDataPath;
- char *ExternalDataPath;
- #endif
- int InkOrWinTab;
- int WacomDeviceStylus; real StylusPressure, StylusOrientation, StylusDeviation, StylusMaxPressure;
- int WacomDeviceEraser; real EraserPressure, EraserOrientation, EraserDeviation, EraserMaxPressure;
- int StylusHasTwist; real StylusTwist; real StylusHover;
- int PointerIsEraser,IsPen;
- int evLastX,evLastY;
- int EnableColorManagement;
- int EnableLogStdOut;
- int EnableGLDebug;
- int GLDebugSync;
- int GLDebugLevel;
- int GLDebugNeedsUpdate;
- int CurrentCursor;
- laWindow *CurrentWindow;
- laPanel *CurrentPanel;
- laListHandle DeferredRedrawList;
- laProgressDisplay Progress;
- laAudio* Audio;
- int InitDone;
- int IsReadingUDF;
- int SavePreferenceOnExit;
- laKeyMapper KeyMap;
- laHash256 OperatorTypeHash;
- //laHash256 CustomCommandHash;
- laSafeString* SignalFilter;
- laListHandle CustomSignals;
- laSafeString* ThumbnailProp;
- laListHandle ExtraExtensions;
- laListHandle ExtraPreferencePaths;
- laListHandle ExtraPreferencePages;
- laUiDefineFunc PreferencePageDisplay;
- laUiDefineFunc PreferencePageInput;
- laUiDefineFunc PreferencePageResource;
- laUiDefineFunc PreferencePageTheme;
- laPropContainer *GeneralIntSub;
- laPropContainer *GeneralFloatSub;
- laPropContainer *GeneralEnumSub;
- laPropContainer *GeneralIntArraySub;
- laPropContainer *GeneralFloatArraySub;
- laPropContainer *GeneralEnumArraySub;
- laPropContainer *GeneralStringSub;
- laPropContainer *GeneralOperatorSub;
- laPropContainer *GeneralCollectionSub;
- laPropContainer *GeneralRawSub;
- laPropContainer *ContainerInt;
- laPropContainer *ContainerFloat;
- laPropContainer *ContainerEnum;
- laPropContainer *ContainerString;
- laPropContainer *ContainerOperator;
- laPropContainer *ContainerCollection;
- laPropContainer *_CONTAINER_SETTING;
- laProp *_PROP_SETTING;
- laPropContainer *_CONTAINER_SETTING_PROPAGATE_TO;
- void *_CONTAINER_SETTING_INSTANCE;
- laListHandle PropContainers;
- laRoot DataRoot;
- laPanel *PropMatcherContextP;
- laPanel* PendingSplash;
- laTheme* CurrentTheme;
- laListHandle Themes;
- laListHandle UiTypes;
-
- laListHandle InitPanelTemplates;
- laListHandle PanelTemplates;
- laListHandle View2DTemplates;
- laUiDefineFunc MenuButtons;
- laUiDefineFunc MenuExtras;
- laUiDefineFunc AboutContent;
- laUiDefineFunc AboutVersion;
- laUiDefineFunc AboutAuthor;
- const char* MenuProgramName;
- SYSLOCK MemLock;
- SYSLOCK OpsLock;
- laHash256 GlobalMemPool;
- int ByteCount;
- int TotalByteCount;
- laHash65536* DBInstMemLeft;// list item pointers
- laHash65536 DBInst2;
- laHash65536 DBInst1;
- laHash65536 PtrSync;
- laListHandle PtrSyncAddressCommands;
- laListHandle PtrSyncHyper2Commands;
- laListHandle PostReadNodes;
- laListHandle RenewHyper2s;
- laListHandle SharedTypePointerSync;
- laListHandle PendingResourceRequests;
- laListHandle ResourceFolders;
- laListHandle ResourceRegistries;
- laListHandle UDFResources;
- laListHandle ManagedUDFs;
- laListHandle ManagedSaveProps;
- laManagedUDF* DummyManageUDF;
- laManagedUDF* DummyManageUDFSingle;
- laManagedUDF* DummyManageUDFSingleForce;
- int ManagerDefaultView;
- int SetUDFPending;
- laPropContainer* SaverDummyContainer;
- laListHandle DBInstPendingAcquireDBP;
- laListHandle DBInstPendingAcquireDiffCMD;
- laListHandle DiffTouched;
- laListHandle Differences;
- laDiff* HeadDifference;
- laDBInst RootDBInst;
- laListHandle DBRecordedProps;
- laHash65536* DBInstLink;
- laDiffPushEverythingF PushEverything;
- laPreSaveF PreSave;
- laPostSaveF PostSave;
- laAnimation* Animation;
- real FontSize;
- real MarginSize;
- int UiRowHeight;
- int ScaledUiRowHeight;
- real UiScale;
- void *ToPanel;
- int NextX, NextY, NextW, NextH;
- laNodeInSocket* tNodeIn;
- laNodeOutSocket* tNodeOut;
- laAuthorInfo Author;
- laListHandle ExternalAuthors;
- laSafeString *WorkingDirectory;
- //SYSLOCK csNotifier;
- laListHandle ThreadNotifiers;
- //preference:
- laInputMappingBundle* InputMapping;
- //color
- real ColorPickerGamma;
- real ViewportHalftoneFactor;
- real ViewportHalftoneSize;
- int NextWireColor, WireColorSlices;
- real WireThickness;
- real WireSaggyness;
- real* WireColorCache;
- //user interactions:
- int TopFramerate;
- int ValuatorThreshold;
- int ScrollingSpeed;
- int TooltipCloseDistance;
- real ZoomSpeed2D;
- real IdleTime;
- real DelayTime;
- //translations:
- laTranslation Translation;
- //display:
- real FloatingAlpha;
- int SolidShadowLength;
- int EnableAnimation;
- real AnimationSpeed;
- real PanelAnimationSpeed;
- int PanelMultisample;
- real LastFrameTime;
- real TimeAccum;
-
- //animation:
- int DefaultKeyFrameMode;
- //laThemeColor *ConditionStackColors[6];
- laListHandle MediaFiles;
- int GraphNeedsRebuild; // current mechanism only allows global.
- int InputNeedsEval;
-
- laListHandle NodeCategories;
- laNodeCategory* CurrentNodeCategory;
- int FilterNodeCategory;
- laBaseNodeType** NodeTypes; int NodeTypeNext, NodeTypeMax;
- laUiDefineFunc ExtraAddInputNodes;
- laUiDefineFunc ExtraAddDriverNodes;
- laGetBaseNodeTypeF ExtraGetInputNodeType;
- laGetBaseNodeTypeF ExtraGetDriverNodeType;
- //laHash256 RootNodes;
- //LLVMContextRef llvmContext;
- //LLVMModuleRef llvmModule;
- //SYSLOCK csMediaPlay;
- int DetachedViewSwitch;
- int example_int;
- laSafeString* example_string;
- };
- #define LA_KM_SEL_UI_EXTRA 1
- #define LA_KM_SEL_PANEL 2
- STRUCTURE(laKeyMapItem){
- laListItem Item;
- int SpecialKeyBits;
- int EventType;
- int Key;
- char SelectBase;
- laPropPack Base;
- laPropPack Action;
- laSafeString *Operation;
- laSafeString *Instructions;
- };
- STRUCTURE(laScreen){
- laListItem Item;
- laSafeString* Name;
- laSafeString* Description;
- int RoughDPI;
- int ColorSpace;
- int x,y,w,h;
- };
- NEED_STRUCTURE(laLayout);
- NEED_STRUCTURE(laBlock);
- NEED_STRUCTURE(laPanel);
- NEED_STRUCTURE(laUiItem);
- STRUCTURE(laWindow){
- laListItem Item;
- SYSWINDOW* win;
- SYSGLCONTEXT glc;
- #if defined(LA_USE_GLES) && !defined(LAGUI_ANDROID)
- EGLSurface egl_surf;
- #endif
- int GLDebugNeedsUpdate;
- GLuint vao;
- struct NVGcontext* nvg;
- #ifdef _WIN32
- HDC hdc;
- #endif
- int X,Y,W,H;
- int CW,CH;
- int Activated;
- int Shown;
- int IsDocking;
- int OutputColorSpace;
- int OutputShowStripes;
- int UseComposing; real ComposingGamma,ComposingBlackpoint;
- int IsFullScreen;
- int Redraw;
- int RedrawTouched;
- laPropPack PP;
- laPropStep FakePS;
- laSafeString *Title;
- laWindow* DockingFrom;
- laListHandle EventList;
- laSafeString *OperatorHints;
- laListHandle Layouts;
- laLayout *CurrentLayout;
- laBlock *MaximizedBlock;
- laPanel *MaximizedUiPanel;
- laUiItem *MaximizedUi;
- laListHandle Panels;
- laListHandle FadingPanels;
- laListHandle Operators;
- laListHandle PendingOperators;
- laUiDrawFunc Draw;
- };
- STRUCTURE(laBlock){
- int X, Y, W, H;
- laBlock *B1;
- laBlock *B2;
- laBlock *parent;
- laPanel *CurrentPanel;
- laListHandle Panels;
- int Vertical;
- int Folded;
- real SplitRatio; // From Left/Top;
- laPropPack PP;
- laPropPack FakePS;
- int OnButton;
- };
- #define LA_BLOCK_DROP_LOCATION_L 1
- #define LA_BLOCK_DROP_LOCATION_R 2
- #define LA_BLOCK_DROP_LOCATION_U 3
- #define LA_BLOCK_DROP_LOCATION_B 4
- STRUCTURE(laLayout){
- laListItem Item;
- laBlock *OperatingBlock;
- laBlock *FirstBlock;
- laBlock *MovingBlock;
- int IsMoving;
- laPanel *ClickedPanel;
- laBlock *DropToBlock;
- laBlock *OnBlockSeperator;
- char DropLocation;
- laSafeString *ID;
- laLayoutBkgDrawFunc Draw;
- };
- STRUCTURE(laUiList){
- laListItem Item;
- int L, R, U, B;
- int TL, TR, TU, TB;
- real PanX, PanY; //Pan Up/Left Is Positive
- laListHandle UiItems;
- laListHandle Columns;
- laListHandle *ShareColumns;
- laSafeString *TabName;
- char *Instance;
- short HeightCoeff;
- char ScrollerShownV;
- char ScrollerShownH;
- uint32_t IconID;
- int AllowScale;
- real Scale; real SaveScale;
- };
- STRUCTURE(laUiListRecord){
- laListItem Item;
- laUiList* uil;
- laUiItem* pui;
- };
- STRUCTURE(laColumn){
- laListItem Item;
- real PreWidth;
- real SP;
- int IL, IR;
- laColumn *Top;
- int MaxW;
- int B;
- laColumn *LS, *RS;
- laColumn *CopyRef;
- };
- STRUCTURE(laUiListDraw){
- laListHandle Items;
- laListHandle SocketRecord;
- laUiList* WiresContainer;
- };
- STRUCTURE(laUiListDrawItem){
- laListItem Item;
- laUiList *Target;
- int L, R, U, B, XP, YP, DifX, DifY;
- int ExtraPanX;
- real Scale;
- };
- STRUCTURE(laBoxedTheme){
- laListItem Item;
- laSafeString *Name;
- real NormalY, Normal[4], Inactive[4];
- real ActiveY, Active[4];
- real BorderY, Border[4];
- real TextY, Text[4];
- real TextActiveY, TextActive[4], TextInactive[4];
- real Alpha;
- int TextAlign;
- int Margins[4];
- int Paddings[4];
- //Don't change order
- int LM, RM, TM, BM;
- int LP, RP, TP, BP;
- laBoxedTheme **BackRef;
- laTheme* Parent;
- };
- STRUCTURE(laSocketRecord){
- laListItem Item;
- laNodeInSocket* In;
- laNodeOutSocket* Out;
- };
- extern laPropContainer* LA_PC_SOCKET_IN;
- extern laPropContainer* LA_PC_SOCKET_OUT;
- extern laPropContainer* LA_PC_MAPPER;
- extern laPropContainer* LA_PROP_SOCKET_SOURCE;
- extern laPropContainer* LA_PROP_SOCKET_OUT;
- extern laPropContainer* LA_PC_RACK_PAGE;
- extern laProp* LA_PROP_CONTROLLER;
- #define LA_UI_NORMAL 0
- #define LA_UI_ACTIVE (1<<0)
- #define LA_UI_EDITING (1<<1)
- #define LA_UI_DISABLED (1<<30)
- #define LA_BT_NORMAL LA_UI_NORMAL
- #define LA_BT_ACTIVE LA_UI_ACTIVE
- #define LA_BT_BORDER (1<<6)
- #define LA_BT_TEXT (1<<7)
- #define LA_BT_TEXT_NORMAL (LA_BT_TEXT|LA_UI_NORMAL)
- #define LA_BT_TEXT_ACTIVE (LA_BT_TEXT|LA_UI_ACTIVE)
- #define LA_BT_DISABLED LA_UI_DISABLED
- #define LA_BT_VERTEX (1<<8)
- #define LA_BT_EDGE (1<<9)
- #define LA_BT_FACE (1<<10)
- #define LA_BT_SELECTED (1<<11)
- #define LA_BT_SVERTEX (LA_BT_VERTEX|LA_BT_SELECTED)
- #define LA_BT_SEDGE (LA_BT_EDGE|LA_BT_SELECTED)
- #define LA_BT_SFACE (LA_BT_FACE|LA_BT_SELECTED)
- #define LA_BT_WARNING (1<<12)
- #define LA_UI_WARNING LA_BT_WARNING
- #define LA_BT_SHADOW (1<<13)
- #define LA_UI_TAG_IS_OFFSCREEN (1<<0)
- #define LA_UI_TAG_CAVANS_SCALED (1<<1)
- #define LA_UI_TAG_NEED_REBUILD (LA_UI_TAG_IS_OFFSCREEN | LA_UI_TAG_CAVANS_SCALED)
- #define LA_UI_TAG_SCISSOR (1<<2)
- STRUCTURE(laTheme){
- laListItem Item;
- laSafeString *Name;
- laSafeString *Author;
- laListHandle Colors;
- laListHandle BoxedThemes;
- int abc;
- //
- real ColorBkg[4];
- real Color[4];
- real AccentColor[4];
- real WarningColor[4];
- real SelectionColor[4];
- real CursorColor[4];
- real InactiveMix;
- real InactiveSaturation;
- real CursorAlpha;
- real SelectionAlpha;
- real WireSaturation;
- real WireTransparency;
- real WireBrightness;
- real VertexColor[4];
- real EdgeColor[4];
- real SVertexColor[4];
- real SEdgeColor[4];
- real SFaceColor[4];
- real ShadowColor[4];
- real EdgeBrightness, EdgeTransparency;
- real VertexBrightness, VertexTransparency;
- real SelectedVertexTransparency;
- real SelectedEdgeTransparency;
- real SelectedFaceTransparency;
- };
- NEED_STRUCTURE(laOperatorType);
- STRUCTURE(laUiType){
- laListItem Item;
- const char *Identifier;
- int ForType;
- const char *TargetSub;
- //laPropStep FakePs;
- laSubProp* FakeProp;
- laPropContainer* ExtraProps;
- laBoxedTheme **Theme;
- laUiDrawFunc Draw;
- const char *OperatorID;
- laOperatorType *OperatorType;
- laUiGetMinWidthFunc GetMinWidth;
- laUiGetHeightFunc GetHeight;
- laUiDestroyFunc Destroy;
- laUiInitFunc Init;
- laKeyMapper KeyMapper;
- int Tag;
- };
- NEED_STRUCTURE(laUiItem);
- STRUCTURE(laGeneralUiExtraData){
- int LastX, LastY;
- int TargetIndexVali;
- real TargetIndexValf;
- int On; //On:Modifying
- int Dragging;
- laStringEdit *Edit;
- void *Ptr1;
- void *Ptr2;
- int HeightCoeff;
- laUiItem* ui;
- };
- STRUCTURE(laMultiStringExtra){
- laGeneralUiExtraData* general;
- int PanX, PanY;
- };
- NEED_STRUCTURE(laCanvasExtra);
- STRUCTURE(la3DObjectDrawExtra){
- int DisplayMode;
- int MeshEditType;
- tnsMatrix44d mViewProj;
- int W,H,Is3D;
- real PointScale;
- };
- typedef void(*laCanvasDrawFunc)(laBoxedTheme* bt, void* DataInstance, laCanvasExtra* Extra);
- typedef int (*laModalFunc)(laOperator *, laEvent *);
- STRUCTURE(laCanvasTemplate){
- laListItem Item;
- laSafeString *Identifier;
- laCanvasDrawFunc Draw;
- laUiDrawFunc SecondDraw;
- laKeyMapper KeyMapper;
- char *TargetContainerID;
- laPropContainer *TargetContainer;
- laPropContainer *ExtraProps;
- laSubProp *FakeProp;
- laModalFunc ExtraModal;
- //float LimitYScale;
- laUiInitFunc Init;
- laUiDestroyFunc Destroy;
- };
- #define LA_CANVAS_CURSOR_CROSS 1
- #define LA_CANVAS_CURSOR_BOX 2
- #define LA_CANVAS_CURSOR_ARROW 3
- #define LA_CANVAS_CURSOR_X 4
- #define LA_CANVAS_CURSOR_Y 5
- #define LA_CANVAS_SELECT_MODE_VERTS 0
- #define LA_CANVAS_SELECT_MODE_EDGES 1
- //#define LA_CANVAS_SELECT_MODE_FACES 2
- #define LA_CANVAS_SELECT_MODE_KNIFE 3
- #define LA_CANVAS_SELECT_THROUGH_OFF 0
- #define LA_CANVAS_SELECT_THROUGH_ON 1
- #define LA_CANVAS_DISPLAY_SOLID 0
- #define LA_CANVAS_DISPLAY_MATERIAL 1
- #ifdef LAGUI_ANDROID
- #define LA_PANEL_DEFAULT_GL_FORMAT GL_RGBA4
- #else
- #define LA_PANEL_DEFAULT_GL_FORMAT GL_RGBA
- #endif
- void la_CanvasDefaultOverlay(laUiItem* ui, int h);
- void la_CanvasDrawOverlay(laUiItem *ui, int h);
- void la_CanvasInit(laUiItem *ui);
- void la_CanvasDestroy(laUiItem *ui);
- STRUCTURE(laCanvasExtra){
- laListItem Item;
- tnsOffscreen *OffScr;
- tnsOffscreen *DeferredOffScr;
- laUiItem *ParentUi;
- real ZoomX,ZoomY;
- real PanX,PanY;
- int DrawCursor;
- real OnX, TargetX;
- real OnY, TargetY;
- real ClickedX,ClickedY;
- int LW,ShowLegend,UiMode;
- int HeightCoeff;
- int ShowDetails;
- int ImageDrawAlpha;
- int ImageDrawBorder;
- int AdaptiveLineWidth;
- int LineWidthWarning;
- int ClearBackground;
- int SelectMode;
- int SelectThrough;
- int EditCenter;
- int DeltaMode;
- real BL, BR, BU, BB;
- int Dragging;
- int TargetIndexVali;
- //3d==========
- tnsOffscreen *OffScrShadow;
- tnsCamera *ViewingCamera; //Always create this one;
- tnsCamera *UsingCamera;
- int Layers[20];
- int AsPlayer;
- int ShowFloorGrid;
- int ShowAxis[3];
- int DisplayMode;
- };
- NEED_STRUCTURE(laUiConditionNode);
- STRUCTURE(laConditionUiExtraData){
- int a;
- laUiItem *EndUi;
- laUiItem *ElseUi;
- laUiConditionNode *Expression;
- //char Remove;
- char IsTrue;
- };
- STRUCTURE(laUiTemplate){
- laListItem Item;
- laSafeString *Title;
- laSafeString *Identifier;
- laSafeString *CategoryName;
- laUiDefineFunc Define;
- laUiDefineFunc Header;
- laPanelDetachedPropFunc PropFunc;
- int DefaultGLFormat;
- int DefaultW_RH,DefaultH_RH;
- laKeyMapper KeyMap;
- };
- #define LA_SLOT_MARKER_1 0
- #define LA_SLOT_MARKER_2 1
- #define LA_SLOT_MARKER_3 2
- #define LA_SLOT_MARKER_4 3
- STRUCTURE(laCompoundPP){
- laListItem Item;
- int Slot;
- laPropPack PP;
- };
- STRUCTURE(laUiItem){
- laListItem Item;
- laColumn *C;
- int L, R, U, B;
- int TL, TR, TU, TB;
- int AnimationDistinguish;
- int State; int Flags; // expand and even (in row control ui)
- laPropPack ExtraPP;
- laPropStep FakePs;
- laGeneralUiExtraData *Extra;
- short Expand;
- short SymbolID;
- laPropPack PP;
- laListHandle CompoundPPs;
- laSafeString *Display;
- laSafeString *ExtraInstructions;
- laUiType *Type;
- laCanvasTemplate *CanvasTemplate;
- laUiList *Page; // reuse as row begin ref
- laOperatorType *AT; //Probably share in the future;
- laStringSplitor *Instructions;
- laListHandle Subs;
- laUiDefineFunc Template;
- int TemplateContext;
- laListHandle SubPanels;
- };
- STRUCTURE(laWidget){
- laUiType* Type;
- int Flags;
- };
- #define LA_UI_FLAGS_TRANSPOSE (1<<0)
- #define LA_UI_FLAGS_EXPAND (1<<1)
- #define LA_UI_FLAGS_ICON (1<<2)
- #define LA_UI_FLAGS_CYCLE (1<<3)
- #define LA_UI_FLAGS_NO_DECAL (1<<4)
- #define LA_UI_FLAGS_NO_EVENT (1<<5)
- #define LA_UI_FLAGS_NO_CONFIRM (1<<6)
- #define LA_TEXT_ALIGN_LEFT (1<<7)
- #define LA_TEXT_ALIGN_RIGHT (1<<8)
- #define LA_TEXT_ALIGN_CENTER (1<<9)
- #define LA_TEXT_ALIGN_AUTO (1<<10)
- #define LA_TEXT_USE_NEWLINE (1<<11)
- #define LA_TEXT_LINE_WRAP (1<<12)
- #define LA_TEXT_REVERT_Y (1<<13)
- #define LA_TEXT_MONO (1<<14)
- #define LA_UI_FLAGS_PREFER_BOTTOM (1<<15)
- #define LA_UI_FLAGS_NO_GAP (1<<16)
- #define LA_UI_FLAGS_UNDERNEATH (1<<17)
- #define LA_UI_FLAGS_NO_HEIGHT (LA_UI_FLAGS_NO_GAP|LA_UI_FLAGS_NO_DECAL|LA_UI_FLAGS_UNDERNEATH)
- #define LA_UI_FLAGS_NO_OVERLAY (1<<18)
- #define LA_TEXT_OVERFLOW_ARROW (1<<19)
- #define LA_UI_FLAGS_DISABLED (1<<20)
- #define LA_UI_FLAGS_HIGHLIGHT (1<<21)
- #define LA_UI_FLAGS_NODE_CONTAINER (1<<22)
- #define LA_UI_COLLECTION_NO_HIGHLIGHT LA_TEXT_ALIGN_LEFT
- #define LA_TEXT_ONE_LINE (1<<23)
- #define LA_UI_FLAGS_NO_SCROLL_INACTIVE (1<<24)
- #define LA_UI_FLAGS_COLOR_SPACE_CLAY (1<<25)
- #define LA_UI_FLAGS_COLOR_SPACE_D65_P3 LA_UI_FLAGS_NO_SCROLL_INACTIVE
- #define LA_UI_FLAGS_EXIT_WHEN_TRIGGERED LA_UI_FLAGS_COLOR_SPACE_CLAY
- #define LA_TEXT_LCD_16 (1<<27)
- #define LA_TEXT_LCD_7 (1<<28)
- #define LA_UI_FLAGS_NO_TOOLTIP LA_UI_FLAGS_PREFER_BOTTOM
- #define LA_UI_IMAGE_FULL_W LA_TEXT_MONO
- #define LA_UI_MIN_WIDTH LA_UI_FLAGS_COLOR_SPACE_CLAY
- #define LA_UI_FLAGS_NO_LABEL (1<<29)
- #define LA_UI_COLLECTION_SIMPLE_SELECTOR LA_UI_FLAGS_CYCLE
- #define LA_UI_FLAGS_WARNING (LA_UI_FLAGS_CYCLE)
- #define LA_TEXT_SHADOW LA_UI_FLAGS_NO_OVERLAY
- #define LA_UI_FLAGS_INT_ICON (LA_UI_FLAGS_NO_DECAL|LA_UI_FLAGS_NO_EVENT|LA_UI_FLAGS_ICON)
- #define LA_UI_FLAGS_PLAIN (LA_UI_FLAGS_NO_DECAL|LA_UI_FLAGS_NO_EVENT)
- #define LA_TEXT_ALIGN (LA_TEXT_ALIGN_LEFT|LA_TEXT_ALIGN_CENTER|LA_TEXT_ALIGN_RIGHT|LA_TEXT_ALIGN_AUTO)
- #define LA_UI_FLAGS_COLORFUL LA_UI_FLAGS_ICON
- #define LA_UI_FLAGS_TERMINAL_INPUT LA_UI_FLAGS_COLOR_SPACE_CLAY
- #define LA_UI_FLAGS_IMMEDIATE_INPUT LA_UI_FLAGS_CYCLE
- #define LA_UI_FLAGS_MOMENTARY (LA_UI_FLAGS_CYCLE|LA_UI_FLAGS_NODE_CONTAINER)
- #define LA_UI_FLAGS_KNOB LA_UI_FLAGS_NODE_CONTAINER
- #define LA_UI_FLAGS_VALUE_METER LA_UI_FLAGS_CYCLE
- #define LA_UI_SOCKET_LABEL_N LA_TEXT_ALIGN_LEFT
- #define LA_UI_SOCKET_LABEL_S LA_TEXT_ALIGN_RIGHT
- #define LA_UI_SOCKET_LABEL_W LA_TEXT_ALIGN_CENTER
- #define LA_UI_SOCKET_LABEL_E LA_TEXT_ALIGN_AUTO
- extern laWidget* LA_WIDGET_FIXED_GROUP;
- extern laWidget* LA_WIDGET_TAB;
- extern laWidget* LA_WIDGET_COLLECTION;
- extern laWidget* LA_WIDGET_COLLECTION_ITEM;
- extern laWidget* LA_WIDGET_COLLECTION_SELECTOR;
- extern laWidget* LA_WIDGET_COLLECTION_SINGLE;
- extern laWidget* LA_WIDGET_CONDITION_TOGGLE;
- extern laWidget* LA_WIDGET_COLUMN_ADJUSTER;
- extern laWidget* LA_WIDGET_COLUMN_VIEWER;
- extern laWidget* LA_WIDGET_BUTTON;
- extern laWidget* LA_WIDGET_BUTTON_NO_CONFIRM;
- extern laWidget* LA_WIDGET_LABEL;
- extern laWidget* LA_WIDGET_INT;
- extern laWidget* LA_WIDGET_INT_PLAIN;
- extern laWidget* LA_WIDGET_INT_PLAIN_ICON;
- extern laWidget* LA_WIDGET_METER_TYPE1;
- extern laWidget* LA_WIDGET_METER_TYPE2;
- extern laWidget* LA_WIDGET_VALUE_METER_2D;
- extern laWidget* LA_WIDGET_FLOAT;
- extern laWidget* LA_WIDGET_FLOAT_PLAIN;
- extern laWidget* LA_WIDGET_FLOAT_COLOR;
- extern laWidget* LA_WIDGET_FLOAT_COLOR_HCY;
- extern laWidget* LA_WIDGET_ENUM_SELECTOR;
- extern laWidget* LA_WIDGET_ENUM_SELECTOR_ICON;
- extern laWidget* LA_WIDGET_ENUM_CYCLE;
- extern laWidget* LA_WIDGET_ENUM_CYCLE_ICON;
- extern laWidget* LA_WIDGET_ENUM_ICON_PLAIN;
- extern laWidget *LA_WIDGET_ENUM_HIGHLIGHT;
- extern laWidget* LA_WIDGET_STRING;
- extern laWidget* LA_WIDGET_STRING_PLAIN;
- extern laWidget* LA_WIDGET_STRING_MULTI;
- extern laWidget *LA_WIDGET_STRING_MONO_PLAIN;
- extern laWidget* LA_WIDGET_MENU_ROOT;
- extern laWidget* LA_WIDGET_ALIGN;
- extern laWidget* LA_WIDGET_3D_VIEW;
- extern laWidget* LA_WIDGET_2D_VIEW;
- extern laWidget* LA_WIDGET_SYMBOL;
- extern laWidget *LA_WIDGET_NODE_SOCKET;
- extern laWidget *LA_WIDGET_HEIGHT_ADJUSTER;
- extern laWidget *LA_WIDGET_RAW;
- extern laWidget *LA_WIDGET_MAPPER;
- extern laWidget *LA_WIDGET_IMAGE;
- extern laWidget *LA_WIDGET_SCOPE;
- extern laWidget *LA_WIDGET_KNOB;
- #define LA_CONDITION_TRUE 1
- #define LA_CONDITION_FALSE 2
- #define LA_CONDITION_GE 3
- #define LA_CONDITION_GT 4
- #define LA_CONDITION_EQ 5
- #define LA_CONDITION_LT 6
- #define LA_CONDITION_LE 7
- #define LA_CONDITION_AND 8
- #define LA_CONDITION_OR 9
- #define LA_CONDITION_NOT 10
- #define LA_CONDITION_INT 11
- #define LA_CONDITION_FLOAT 12
- #define LA_CONDITION_STRING 13
- #define LA_CONDITION_PROP 14
- STRUCTURE(laUiConditionNode){
- char a;
- int Type;
- laUiConditionNode *Expression1; // As Int Value
- laUiConditionNode *Expression2;
- laUiDescriptor *Base;
- char IsExtra;
- int IntValue;
- real FloatValue;
- laSafeString *String; //used as prop path in template
- laPropPack PP;
- };
- #define LA_PANEL_NORMAL 0
- #define LA_PANEL_FLOATING_PASSIVE 2
- #define LA_PANEL_FLOATING_TOP 3
- #define LA_PANEL_NO_PARENT_MENU 4
- #define LA_TAG_REDRAW 1
- #define LA_TAG_RECALC 2
- #define LA_TAG_ANIMATION 4
- #define LA_TAG_RECALC_SCROLLER 8
- #define LA_PANEL_ANIMATION_DROP_DOWN 1
- #define LA_PANEL_ANIMATION_EXPAND 2
- #define LA_PANEL_ANIMATION_DISSOVE 3
- #define LA_PANEL_ANIMATION_COLLAPSE 4
- #define LA_PANEL_ANIMATION_MINIMIZE 5
- #define LA_PANEL_ANIMATION_FLASH 126
- #define LA_PANEL_ANIMATION_DESTROY 127
- NEED_STRUCTURE(laOperator);
- NEED_STRUCTURE(laOperator);
- STRUCTURE(laPanel){
- laListItem Item;
- int __SAFE__;
- int X, Y, W, H;
- int MaxW, MaxH, MinW, MinH;
- int TX, TY, TW, TH;
- int TitleWidth;
- char AnimationMode;
- real AnimationRatio;
- //int PanX, PanY;
- int Show;
- short Refresh;
- short ShowCorner;
- unsigned int FrameDistinguish;
- char BoundUi;
- char IsMenuPanel;
- char LaterDestroy;
- char CloseWhenMovedOut;
- int Mode;
- int NoConfirm;
- int LiveEditing;
- laUiItem *EditingUi;
- laUiItem *FocusingUi;
- void *SFPNode;
- int SL, SR, ST, SB; //Snap To Edge
- laSafeString *Title;
- laUiTemplate *PanelTemplate;
- laPropPack PP;
- laPropStep FakePS;
- laPropContainer* PropLinkContainer;
- laSubProp* PropLinkFakeProp;
- laPropPack PropLinkPP;
- laPropStep PropLinkFakePS;
- laKeyMapper KeyMap;
- laPanelDrawFunc Draw;
- laBoxedTheme **BT;
- tnsOffscreen *OffScr;
- laUiList UI;
- laUiList TitleBar;
- laUiList *MenuRefer;
- laUiDefineFunc UiDefine;
- laListHandle SubPanels;
- laPanel *Parent;
- laBlock *Block;
- laOperator *ParentOperator;
- u64bit Tag;
- //64 Main Types are useable,with 31 subtypes avainable each.
- //Main Type 0~63(some are occupied by LA internal)
- //Sub Type 0~31
- //Main (Low) 0| 1| 2| 3|...
- //[---32bits---][---32bits---][---32bits---][---32bits---]...
- };
- STRUCTURE(laPanelMessage){
- laListItem Item;
- laSafeString *Message;
- };
- STRUCTURE(laPanelMessageList){
- laListHandle Msg;
- };
- NEED_STRUCTURE(laOperator);
- typedef int (*laInitFunc)(laOperator *);
- typedef int (*laRefreshFunc)(laOperator *);
- typedef int (*laCheckFunc)(laPropPack *, laStringSplitor *); //this, ui->instructions amd ap->instructions
- typedef void (*laExitFunc)(laOperator *, int); //true means Quit, false means Cancel
- typedef int (*laInvokeFunc)(laOperator *, laEvent *);
- typedef int (*laModalFunc)(laOperator *, laEvent *);
- typedef int (*laSystemFunc)(laOperator *, laEvent *);
- #define LA_CANCEL 0
- #define LA_PASS_ON (1<<10)
- #define LA_BLOCK (1<<11)
- #define LA_FINISH (1<<12)
- #define LA_CONFIRM (1<<13)
- #define LA_CANCELED 0
- //#define LA_PRE_INVOKE 16384
- #define LA_FINISHED (LA_FINISH | LA_BLOCK)
- #define LA_FINISHED_PASS (LA_FINISH | LA_PASS_ON)
- #define LA_RUNNING LA_BLOCK
- #define LA_RUNNING_PASS (LA_BLOCK | LA_PASS_ON)
- #define LA_OPERATOR_CALLS_SHUTOFF (LA_FINISHED|(1<<5))
- #define LA_EXTRA_TO_PANEL 1
- #define LA_EXTRA_CONFIRM 2
- #define LA_ACTUATOR_SYSTEM 4
- #define LA_ACTUATOR_HIDDEN 8
- #define LA_CONFIRM_OK (1<<10)
- #define LA_CONFIRM_CANCEL (1<<11)
- #define LA_CONFIRM_IGNORE (1<<12)
- #define LA_CONFIRM_DATA (1<<13)
- #define LA_CONFIRM_CUSTOM_STRING (1<<14)
- STRUCTURE(laOperatorType){
- laListItem Item;
- const char *Identifier;
- const char *Name;
- const char *Description;
- const char *ExtraInstructions;
- laInitFunc Init;
- laExitFunc Exit;
- laInvokeFunc Invoke;
- laModalFunc Modal;
- laCheckFunc Check;
- uint32_t IconID;
- laPropContainer* PC;
- laUiDefineFunc UiDefine;
- laOperatorArgumentParserFunc ParseArgs;
- laListHandle Properties;
- int ExtraMark;
- };
- typedef void (*laConfirmDataDestroyFunc)(void *);
- STRUCTURE(laConfirmData){
- int Mode;
- int IData;
- real FData;
- void *CustomData;
- char *StrData;
- void* PointerData;
- laPropContainer* PointerType;
- laConfirmDataDestroyFunc Destroy;
- };
- STRUCTURE(laOperator){
- laListItem Item;
- int State;
- void *Instance;
- void *CustomData;
- const char *ExtraInstructions;
- laStringSplitor *ExtraInstructionsP;
- laPropPack PP;
- laPropPack *This;
- laConfirmData *ConfirmData;
- laConfirmData *NextConfirmData;
- laOperator *Child;
- laListHandle PropertyStorage;
- laOperatorType *Type;
- laPropPack *CreatedThis;
- int Using;
- int StopNow;
- int ModalOver;
- laPanel *ToPanel;
- laPanel *OperatorPanel;
- laListHandle LocalUiLists;
- laSafeString* RuntimeHint;
- };
- #define LA_INPUT_DEVICE_KEYBOARD 0
- #define LA_INPUT_DEVICE_JOYSTICK 1
- STRUCTURE(laInputMapping){
- laListItem Item;
- laSafeString* Name;
- laListHandle Entries;
- };
- STRUCTURE(laInputMappingEntry){
- laListItem Item;
- laInputMapping* Parent;
- int DeviceType;
- int JoystickDevice; int Axis, Button;
- laSafeString* Key; int KeyValue;
- int SpecialKeyBits;
- laSafeString* Signal; int SignalValue;
- };
- STRUCTURE(laInputMappingBundle){
- void* _pad;
- laListHandle InputMappings;
- laInputMapping* CurrentInputMapping;
- };
- #define LA_SIGNAL_NEW 10000
- #define LA_SIGNAL_DELETE 10001
- #define LA_SIGNAL_CONFIRM 10002
- #define LA_SIGNAL_UNDO 10003
- #define LA_SIGNAL_REDO 10004
- #define LA_SIGNAL_OPEN 10005
- #define LA_SIGNAL_SAVE 10006
- #define LA_SIGNAL_SAVE_AS 10007
- #define LA_SIGNAL_LAYOUT_NEXT 10008
- #define LA_SIGNAL_LAYOUT_PREV 10009
- #define LA_SIGNAL_FULLSCREEN 10010
- STRUCTURE(laCustomSignal){
- laListItem Item;
- //laListItem Item2;
- laSafeString* Name;
- int Signal;
- };
- #define LA_JS_MAX_AXES 64
- #define LA_JS_MAX_BUTTONS 128
- STRUCTURE(laController){
- laListItem Item;
- laSafeString* Name;
- laSafeString* Path;
- int fd; //device;
- int NumButtons; int NumAxes; int UserAssignedID; int Error;
- int InternalType; // used to identify models and use specific props.
- int16_t AxisValues[LA_JS_MAX_AXES],SaveAxisValues[LA_JS_MAX_AXES];
- int AxisMaxes[LA_JS_MAX_AXES];
- int AxisMins[LA_JS_MAX_AXES];
- int16_t AxisLimitMaxes[LA_JS_MAX_AXES]; // calibrated max;
- int16_t AxisLimitMins[LA_JS_MAX_AXES];
- int16_t AxisCenterMaxes[LA_JS_MAX_AXES]; // calibrated center;
- int16_t AxisCenterMins[LA_JS_MAX_AXES];
- char ButtonValues[LA_JS_MAX_BUTTONS];
- u8bit ButtonsMap[LA_JS_MAX_BUTTONS];
- u8bit AxisMap[LA_JS_MAX_AXES];
- laSafeString* ButtonNames[LA_JS_MAX_BUTTONS];
- laSafeString* AxisNames[LA_JS_MAX_AXES];
- };
- void la_RefreshControllers();
- void la_InitControllers();
- void la_RemoveDuplicatedControllers();
- void la_UpdateControllerStatus();
- void la_RegisterControllerProps();
- laPropContainer* laget_ControllerType(laController* c);
- laController* la_FindControllerWithID(int id);
- char* laControllerIDGetAxisName(int id, int axis);
- char* laControllerIDGetButtonName(int id, int button);
- int laControllerIDGetAxis(int id, char* name);
- int laControllerIDGetButton(int id, char* name);
- void la_RegisterBasicNodes();
- #define LA_DAG_FLAG_ERR 0
- #define LA_DAG_FLAG_TEMP 1
- #define LA_DAG_FLAG_PERM 2
- int laRebuildPageEval(laRackPage* rp);
- int laRunPage(laRackPage* rp, uint64_t mask);
- void laGraphRequestRebuild();
- int la_RunDrivers();
- void lapost_Node(laBaseNode *bn);
- laBaseNode* la_CreateDriverNode(laNodeRack* ir, laBaseNodeType* NodeType);
- void* laget_InstanceSelf(void* instace);
- laPropContainer* laget_BaseNodeType(laBaseNode* bn);
- void laRegisterNode(laBaseNodeType* type, laPropContainer* pc,
- laBaseNodeInitF init, laBaseNodeDestroyF destroy, laBaseNodeVisitF visit, laBaseNodeEvalF eval, laBaseNodeCopyF copy,
- int nodesize, char* udf_string, char* type_string, char* UiText, int icon);
- void latouched_NodeInSocket(void* unused, int hint);
- #define LA_BASE_NODE_HEADER(uil,c,This) \
- {laSplitColumn(uil,c,0.2);laColumn*c1=laLeftColumn(c,1);c=laRightColumn(c,0);\
- laShowHeightAdjuster(uil,c1,This,"base.__gap",0);}
- #define LA_IDN_REGISTER(uitext,icon,a,pc,funcname,type) \
- laRegisterNode(&a,pc,funcname##Init,funcname##Destroy,funcname##Visit,funcname##Eval,funcname##Copy,sizeof(type),"UDFRES_" #type, #type, uitext,icon);
- #define LA_SRC_AND_PARENT(socket) \
- ((socket)->Source && (socket)->Source->Parent)
- #define LA_VISIT_NODE(node,vi) \
- {if(node){int result=node->Type->Visit(node,vi); if(result!=LA_DAG_FLAG_PERM) return LA_DAG_FLAG_ERR;} }
- #define LA_GUARD_THIS_NODE(n,vi) \
- {uint64_t br=vi->Branch; if((n->Base.Branch&br)==br) return LA_DAG_FLAG_PERM; if((n->Base.BranchTemp&br)==br) return LA_DAG_FLAG_ERR; n->Base.BranchTemp|=br; }
- #define LA_ADD_THIS_NODE(n,vi) \
- {uint64_t br=vi->Branch; if(!n->Base.Branch){ lstAppendPointer(vi->l,n); } n->Base.Branch|=br; n->Base.BranchTemp&=(~br); }
- #define LA_GET_SRC_AS_VALUE(var, socket) \
- {if(socket->Source&&socket->Source->DataType&LA_PROP_FLOAT) var=*((real*)socket->Source->Data);\
- if(socket->Source&&socket->Source->DataType&(LA_PROP_INT|LA_PROP_ENUM)) var=*((int*)socket->Source->Data);}
- #define LA_IDN_OLD_DUPL(socket) \
- old->socket->Duplicated=new->socket;
- #define LA_IDN_NEW_LINK(socket) \
- { memAssignRef(new->socket,&new->socket->Source,old->socket->Source?old->socket->Source->Duplicated:0); new->socket->ColorId=old->socket->ColorId; }
- extern laBaseNodeType LA_IDN_KEYBOARD;
- extern laBaseNodeType LA_IDN_MOUSE;
- extern laBaseNodeType LA_IDN_CONTROLLER;
- extern laBaseNodeType LA_IDN_VISUALIZER;
- extern laBaseNodeType LA_IDN_SPLIT;
- extern laBaseNodeType LA_IDN_SWITCH;
- extern laBaseNodeType LA_IDN_COMBINE;
- extern laBaseNodeType LA_IDN_VALUES;
- extern laBaseNodeType LA_IDN_MATRIX;
- extern laBaseNodeType LA_IDN_MATH;
- extern laBaseNodeType TNS_IDN_TRANSFORM;
- extern laBaseNodeType TNS_IDN_MAKE_TRANSFORM;
- extern laNodeCategory* LA_NODE_CATEGORY_INPUT;
- extern laNodeCategory* LA_NODE_CATEGORY_MATH;
- extern laNodeCategory* LA_NODE_CATEGORY_ROUTE;
- extern laNodeCategory* LA_NODE_CATEGORY_DRIVER;
- extern laNodeCategory* LA_NODE_CATEGORY_AUX;
- extern laNodeCategory* LA_NODE_CATEGORY_COLOR;
- #define LA_VALUES_NODE_FLOAT 0
- #define LA_VALUES_NODE_INT 1
- #define LA_VALUES_NODE_ENUM 2
- #define LA_MATRIX_NODE_OP_MUL 0
- #define LA_MATRIX_NODE_OP_INV 1
- #define LA_MATH_NODE_OP_ADD 0
- #define LA_MATH_NODE_OP_SUB 1
- #define LA_MATH_NODE_OP_MUL 2
- #define LA_MATH_NODE_OP_DIV 3
- #define LA_MATH_NODE_OP_POW 4
- #define LA_MATH_NODE_OP_LOG 5
- #define LA_MATH_NODE_OP_SIN 6
- #define LA_MATH_NODE_OP_COS 7
- #define LA_MATH_NODE_OP_TAN 8
- #define LA_MATH_NODE_OP_ASIN 9
- #define LA_MATH_NODE_OP_ACOS 10
- #define LA_MATH_NODE_OP_ATAN 11
- #define LA_MATH_NODE_OP_ATAN2 12
- #define LA_MATH_NODE_OP_MOD 13
- #define LA_VECTOR_MATH_OP_ADD 0
- #define LA_VECTOR_MATH_OP_SUB 1
- #define LA_VECTOR_MATH_OP_MUL 2
- #define LA_VECTOR_MATH_OP_DIV 3
- #define LA_VECTOR_MATH_OP_POW 4
- #define LA_VECTOR_MATH_OP_LOG 5
- #define LA_VECTOR_MATH_OP_DOT 6
- #define LA_VECTOR_MATH_OP_CROSS 7
- #define LA_VECTOR_MATH_OP_LEN 8
- #define LA_VECTOR_MATH_OP_NORMALIZE 9
- NEED_STRUCTURE(tnsObject)
- STRUCTURE(laRackPage){
- laListItem Item;
- laSafeString* Name;
- laListHandle Racks;
- laListHandle Eval;
- laListHandle AlwaysBranchers;
- laSafeString* Script;
- tnsObject* ParentObject;
- int RackType;
- int TriggerMode;
- int UseScript;
- };
- #define LA_RACK_TYPE_INPUT (1<<0)
- #define LA_RACK_TYPE_DRIVER (1<<1)
- #define LA_RACK_TYPE_ALL 0xfffffff
- STRUCTURE(laNodeRack){
- laListItem Item;
- laSafeString* Name;
- laListHandle Nodes;
- laRackPage* ParentPage;
- int RackType;
- laNodeRack* Duplicated;
- };
- STRUCTURE(laKeyboardNode){
- laBaseNode Base;
- laNodeOutSocket* IsKey; int iIsKey;
- laNodeOutSocket* KeyDown; int iKeyDown;
- laNodeOutSocket* Key; int iKey;
- };
- NEED_STRUCTURE(laInputControllerNode);
- STRUCTURE(laInputControllerNodeSocket){
- laInputControllerNode* Parent;
- laSafeString* Which;
- laNodeOutSocket* Out;
- int Offset;
- int IntVal[8]; real RealVal[8];
- };
- STRUCTURE(laInputControllerNode){
- laBaseNode Base;
- laInputControllerNodeSocket Sockets[8];
- int UserID;
- int Mode;// btn/axis;
- };
- STRUCTURE(laInputVisualizerNode){
- laBaseNode Base;
- laNodeInSocket* In;
- int IntVal[8]; real RealVal[8];
- };
- STRUCTURE(laSplitNodeOutSocket){
- laNodeOutSocket* Out;
- };
- STRUCTURE(laSplitNode){
- laBaseNode Base;
- laNodeInSocket* In;
- laSplitNodeOutSocket Out[8];
- int IntVal[8]; real RealVal[8];
- int ArrLen;
- };
- STRUCTURE(laSwitchNodeInSocket){
- laNodeInSocket* In;
- };
- STRUCTURE(laSwitchNode){
- laBaseNode Base;
- laSwitchNodeInSocket In[8];
- laNodeOutSocket* Out;
- laNodeInSocket* SwitchIn;
- real TempVal;
- int Switch;
- int MaxUsed;
- laRackPage* Page;
- uint64_t BranchSW;
- };
- STRUCTURE(laCombineNode){
- laBaseNode Base;
- laSwitchNodeInSocket In[8];
- laNodeOutSocket* Out;
- laNodeOutSocket* OutInt;
- laNodeOutSocket* OutEnum;
- real Values[8]; int ValuesI[8];
- };
- STRUCTURE(laValuesNode){
- laBaseNode Base;
- laSplitNodeOutSocket Out[8];
- real Values[8]; int ValuesI[8], ValuesE[8];
- int Modes[8];
- };
- STRUCTURE(laMatrixNode){
- laBaseNode Base;
- laNodeInSocket *InL,*InR;
- laNodeOutSocket* Out;
- tnsMatrix44d Mat;
- int Operation;
- };
- STRUCTURE(laMathNode){
- laBaseNode Base;
- laNodeInSocket *InL,*InR;
- laNodeOutSocket* Out,*OutInt;
- real Value; int ValueI;
- real ValueL, ValueR;
- int Operation;
- };
- STRUCTURE(laValueMapperPoint){
- laListItem Item;
- real x,y;
- };
- STRUCTURE(laValueMapper){
- real pad;
- laListHandle Points;
- real InRange[2],OutRange[2];
- };
- STRUCTURE(laMapperNode){
- laBaseNode Base;
- laNodeInSocket *In, *InMin, *InMax, *OutMin, *OutMax;
- laNodeOutSocket* Out;
- real rIn,rOut;
- laValueMapper* Mapper;
- int ClampInput, ClampOutput;
- };
- STRUCTURE(laRandomNode){
- laBaseNode Base;
- laNodeOutSocket* Out; real rOut;
- laNodeInSocket *InMin, *InMax;
- real Min,Max;
- };
- STRUCTURE(laVectorMathNode){
- laBaseNode Base;
- laNodeInSocket *InL,*InR;
- laNodeOutSocket* Out;
- real rOut[4];
- int Operation;
- };
- STRUCTURE(laCommentNode){
- laBaseNode Base;
- laSafeString* Content;
- };
- STRUCTURE(laRGB2OKHSLNode){
- laBaseNode Base;
- laNodeInSocket *In;
- laNodeOutSocket* OutH;
- laNodeOutSocket* OutS;
- laNodeOutSocket* OutL;
- real RGB[3];
- real rOut[3];
- };
- STRUCTURE(laOKHSL2RGBNode){
- laBaseNode Base;
- laNodeInSocket *InH;
- laNodeInSocket *InS;
- laNodeInSocket *InL;
- laNodeOutSocket* Out;
- real rOut[3];
- };
- STRUCTURE(laLoopNode){
- laBaseNode Base;
- laNodeInSocket *InIndex;
- laNodeInSocket *InIterations;
- laNodeInSocket *Branch;
- laNodeInSocket *Prev;
- laNodeOutSocket* Next;
- int Iterations;
- laRackPage* Page;
- uint64_t BranchControl;
- };
- STRUCTURE(laLoopIndexNode){
- laBaseNode Base;
- laNodeOutSocket* Out;
- int Iteration;
- };
- STRUCTURE(laNodeCategory){
- laListItem Item;
- laSafeString* Name;
- laListHandle NodeTypes;//lip
- laUiDefineFunc Ui;
- int For;
- };
- #define LA_RACK_TYPE_AUDIO (1<<2)
- #define LA_SYNTH_PLEN 512
- extern laPropContainer* LA_PC_SYNTH;
- STRUCTURE(laSynth){
- laListItem Item;
- laSafeString* Name;
- laRackPage* Page;
- real Length;
- u16bit Poly,MaxPoly;
- SYSLOCK Lock;
- int Playing;
- real EvalTime;
- int EvalSamples;
- int PolyCount;
- laListHandle PolyphonicInstances;
- };
- STRUCTURE(laSynthNodeInput){
- laBaseNode Base;
- laNodeOutSocket* OutTime;
- laNodeOutSocket* OutTrigger;
- laNodeOutSocket* OutL;
- laNodeOutSocket* OutR;
- real* rTime;
- real* rTrigger;
- real* rSamplesL;
- real* rSamplesR;
- };
- STRUCTURE(laSynthNodePulse){
- laBaseNode Base;
- laNodeInSocket* InTrigger; int iTrigger;
- laNodeInSocket* InWidth; real rWidth,rInfluence;
- laNodeInSocket* InGate; real rGate;
- laNodeOutSocket* Out; real *rOut;
- int Triggered; real EvalSamples;
- };
- STRUCTURE(laSynthNodeFM){
- laBaseNode Base;
- int Slow;
- real Frequency,rInfluence;
- laNodeInSocket* InFrequency;
- laNodeOutSocket* Out;
- //runtime
- real Phase;
- real* OutSamples;
- };
- STRUCTURE(laSynthNodeNoise){
- laBaseNode Base;
- laNodeOutSocket* OutWhite;
- laNodeOutSocket* OutPink;
- real* OutWhiteSamples;
- real* OutPinkSamples;
- //runtime
- real PinkStates[3];
- real PinkA[3],PinkP[3];
- };
- STRUCTURE(laSynthNodeVCA){
- laBaseNode Base;
- real Amp, rInfluence;
- laNodeInSocket* In;
- laNodeInSocket* InAmp;
- laNodeOutSocket* Out;
- real* OutSamples;
- };
- STRUCTURE(laSynthNodeScope){
- laBaseNode Base;
- int Time;
- int Gain1,Gain2;
- real Offset1,Offset2;
- real Brightness1,Brightness2;
- laNodeInSocket* In1;
- laNodeInSocket* In2;
- real *Display1,*Display2; // each PLEN*2, upper/lower bounds.
- int NextSample;
- SYSLOCK Lock;
- laSynth* FromSynth;
- };
- NEED_STRUCTURE(laAudioChannel);
- STRUCTURE(laSynthNodeOutput){
- laBaseNode Base;
- laNodeInSocket* InL,*InR; int IsMono;
- laSafeString* SendName;
- /* Runtime */
- laAudioChannel* Send;
- };
- STRUCTURE(laSynthNodeEnvelope){
- laBaseNode Base;
- laNodeInSocket* Trigger,*Gate; real rGate; int bTrigger; int Triggered;
- laNodeInSocket* Restart;
- laNodeInSocket* Attack; real rAttack,iAttack;
- laNodeInSocket* Delay; real rDelay,iDelay;
- laNodeInSocket* Sustain; real rSustain,iSustain;
- laNodeInSocket* Release; real rRelease,iRelease;
- laNodeOutSocket* Out; real* OutSamples;
- real Time,ReleaseTime,AtLevel;
- };
- STRUCTURE(laSynthNodeQuantize){
- laBaseNode Base;
- laNodeInSocket* In;
- laNodeOutSocket* Out;
- real* OutSamples;
- int EnabledBits[12];
- };
- STRUCTURE(laSynthNodeDriver){
- laBaseNode Base;
- laNodeInSocket* Prev; laNodeOutSocket* Next;
- laNodeInSocket* InTransport; int iTransport;
- laNodeInSocket* InReset; int iReset,AlreadyReset; // on rising edge
- laSynth* Target;
- };
- STRUCTURE(laSynthNodeTrigger){
- laBaseNode Base;
- laNodeInSocket* Prev; laNodeOutSocket* Next;
- laNodeInSocket* InTrigger; int Triggered,TriggerEdge,iTrigger;
- laSynth* Target;
- };
- #include "miniaudio.h"
- STRUCTURE(laAudioChannel){
- laListItem Item;
- laSafeString* Name;
- real Volume;
- laSafeString* OutputChannel;
- real SamplesL[LA_SYNTH_PLEN];
- real SamplesR[LA_SYNTH_PLEN];
- int IsMono;
- };
- STRUCTURE(laAudioDevice){
- laListItem Item;
- int MiniAudioID;
- laSafeString Name;
- };
- typedef int (*laAudioCallbackF)(int Paused, float* input, float* output, uint32_t framecount);
- STRUCTURE(laAudio){
- int Paused;
-
- laListHandle Synths;
- laSynth* CurrentSynth;
- laListHandle Channels;
- laListHandle PolyLaterTrigger;
- SYSLOCK AudioStatusLock;
- ma_backend MiniAudioBackend;
- ma_context MiniAudioContext;
- ma_device AudioDevice;
- laAudioDevice* UsingDevice;
- laListHandle AudioDevices;
- laSynth* AudioEvalSynth;
- real AudioFrameInterval;
- real* InputSamplesL,*InputSamplesR;
- real *OutputSamplesL,*OutputSamplesR;
- int NextAudioSample,AudioSampleRate;//,NextInputSample;
-
- laAudioCallbackF Callback;
- };
- void laSetAudioCallback(laAudioCallbackF Callback);
- int laget_SynthPlaying(laSynth* ss);
- void* laget_FirstAudioDevice(void* unused1,void* unused2);
- void* laget_FirstSynth(void* unused1,void* unused2);
- void laset_CurrentSynth(laAudio* a,laSynth* s);
- void laset_CurrentAudioDevice(laAudio* a,laAudioDevice* ad);
- void laRemoveAudioChannel(laAudioChannel* ac);
- laAudioChannel* laNewAudioChannel(char* Name);
- laAudioChannel* laGetAudioChannel(char* Name);
- void la_AudioPreFrame();
- void laset_MiniAudioBackend(void* unused, int backend);
- void laRebuildSynthGraphs(int current_only);
- void laInitAudio();
- void laDeinitAudio();
- void laStartAudio();
- void laPauseAudio();
- void laStopAudio();
- void laResetAudio();
- laSynth* laFindSynth(const char* Name);
- void la_SynthAddPolyInstance(laSynth* s);
- void la_SynthRemovePolyInstance(laSynth* s, laSynth* inst);
- void laSynthTriggerNew(laSynth* s);
- void laSynthTriggerLater(laSynth* s);
- #define LA_INPUT_CONTROLLER_NODE_MODE_BTN 0
- #define LA_INPUT_CONTROLLER_NODE_MODE_AXIS 1
- laValueMapper* laValueMapperInit();
- laValueMapper* laValueMapperDestroy(laValueMapper* vm);
- laValueMapper* laValueMapperCopy(laValueMapper* new_optional, laValueMapper* vm);
- real laValueMapperEvaluate(laValueMapper* vm, real x, real* force_InMin, real* force_InMax, real* force_OutMin, real* force_OutMax, int ClampIn, int ClampOut);
- void laShowProgress(real p1, real p2);
- void laHideProgress();
- void logPrintT(int Type, char* format, ...);
- void logPrint(char* format, ...);
- void logPrintNew(char* format, ...);
- void logClear();
- void laPerfRecordV(char* format, va_list v);
- void laPerfRecord(char* format, ...);
- #ifdef _WIN32
- LRESULT CALLBACK LA_WindowProc(HWND hwnd, UINT message, WPARAM wparam, LPARAM lparam);
- LRESULT CALLBACK LA_ProgressWindowProc(HWND hwnd, UINT message, WPARAM wparam, LPARAM lparam);
- #endif
- void la_RegisterMainOperators();
- void la_RegisterUiOperatorsBasic();
- void la_RegisterViewerOperators();
- void la_RegisterBuiltinOperators();
- void la_RegisterModellingOperators();
- void la_RegisterUiTypesBasic();
- void la_RegisterUiTypesViewerWidgets();
- void la_RegisterBuiltinTemplates();
- void la_RegisterWindowKeys();
- void la_RegisterGeneralProps();
- void la_RegisterInternalProps();
- void la_RegisterDefaultSignals();
- void la_RegisterAnimationResources();
- void la_RegenerateWireColors();
- void laui_IntPropInfo(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *ExtraColumns, int context);
- void laui_FloatPropInfo(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *ExtraColumns, int context);
- void laui_RackPage(laUiList *uil, laPropPack *This, laPropPack *Extra, laColumn *UNUSED, int context);
- void laui_DefaultPropDetails(laUiList *uil, laPropPack *This, laPropPack *Extra, laColumn *UNUSED, int context);
- void laui_DefaultNodeOperationsPropUiDefine(laUiList *uil, laPropPack *This, laPropPack *OperatorProps, laColumn *UNUSED, int context);
- void laui_DefaultPropUiDefine(laUiList *uil, laPropPack *This, laPropPack *OperatorProps, laColumn *UNUSED, int context);
- void laui_StringPropUiDefine(laUiList *uil, laPropPack *This, laPropPack *Extra, laColumn *UNUSED, int context);
- void laui_IdentifierOnly(laUiList *uil, laPropPack *This, laPropPack *OP_UNUSED, laColumn *Extra, int context);
- void laui_SubPropInfoDefault(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
- void laui_SubPropSelection(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
- void laui_LinkerSelectionProp(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
- void laui_LinkerSelectionInstance(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
- void laui_DefaultOperatorPanelTitleBar(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
- void laui_ColumnItem(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *UNUSED_Colums, int context);
- void laui_DefaultMenuButtonsFileEntries(laUiList *uil, laPropPack *pp, laPropPack *actinst, laColumn *extracol, int context);
- void laui_DefaultMenuButtonsEditEntries(laUiList *uil, laPropPack *pp, laPropPack *actinst, laColumn *extracol, int context);
- void laui_DefaultMenuButtonsOptionEntries(laUiList *uil, laPropPack *pp, laPropPack *actinst, laColumn *extracol, int context);
- void laui_DefaultMenuButtons(laUiList *uil, laPropPack *pp, laPropPack *actinst, laColumn *extracol, int context);
- void laui_DefaultMenuExtras(laUiList *uil, laPropPack *pp, laPropPack *actinst, laColumn *extracol, int context);
- void laui_DefaultMenuBarActual(laUiList *uil, laPropPack *pp, laPropPack *actinst, laColumn *extracol, int context);
- void laui_DefaultSubWindowMenuBarActual(laUiList *uil, laPropPack *pp, laPropPack *actinst, laColumn *extracol, int context);
- void laui_ThemeListItem(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *UNUSED_Colums, int context);
- void laui_Theme(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *UNUSED_Colums, int context);
- void laui_BoxedThemeItem(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *UNUSED_Colums, int context);
- void laui_PropertyContainerList(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *UNUSED_Colums, int context);
- void laui_WindowListItem(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *UNUSED_Colums, int context);
- void laui_LayoutListItem(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *UNUSED_Colums, int context);
- void laui_PanelListItem(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *UNUSED_Colums, int context);
- void laui_InputSocketItem(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *UNUSED_Colums, int context);
- void laui_OutputSocketItem(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *UNUSED_Colums, int context);
- void laui_FileBrowserFileItem(laUiList *uil, laPropPack *This, laPropPack *OP_UNUSED, laColumn *Extra, int context);
- void laui_FileBrowserDiskItem(laUiList *uil, laPropPack *This, laPropPack *OP_UNUSED, laColumn *Extra, int context);
- void laui_LinkerPanel(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
- void laui_ManagedUDFItem(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
- void laui_ManagedUDFOps(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
- void laui_ManagedProp(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
- void laui_ManagedSavePanel(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
- void laui_ManagedUDFPanel(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
- void laui_FileBrowserFileList(laUiList *uil, laPropPack *THIS_UNUSED, laPropPack *Operator, laColumn *UNUSED, int context);
- void laui_DataRestorePage(laUiList *uil, laPropPack *THIS_UNUSED, laPropPack *Operator, laColumn *UNUSED, int context);
- void laui_ResourceFolderItem(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
- void laui_LogItem(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
- void laui_NodeCategory(laUiList *uil, laPropPack *This, laPropPack *Extra, laColumn *UNUSED, int context);
- void tnsui_CameraObjectProperties(laUiList *uil, laPropPack *This, laPropPack *UNUSED_Extra, laColumn *UNUSED_Colums, int context);
- void tnsui_LightObjectProperties(laUiList *uil, laPropPack *This, laPropPack *UNUSED_Extra, laColumn *UNUSED_Colums, int context);
- void tnsui_MeshObjectProperties(laUiList *uil, laPropPack *This, laPropPack *UNUSED_Extra, laColumn *UNUSED_Colums, int context);
- void tnsui_ShapeObjectProperties(laUiList *uil, laPropPack *This, laPropPack *UNUSED_Extra, laColumn *UNUSED_Colums, int context);
- void tnsui_InstancerObjectProperties(laUiList *uil, laPropPack *This, laPropPack *UNUSED_Extra, laColumn *UNUSED_Colums, int context);
- void tnsui_BaseObjectProperties(laUiList *uil, laPropPack *This, laPropPack *UNUSED_Extra, laColumn *UNUSED_Colums, int context);
- void tnsui_RootObjectProperties(laUiList *uil, laPropPack *This, laPropPack *UNUSED_Extra, laColumn *UNUSED_Colums, int context);
- void tnsui_RootObjectMenuUi(laUiList *uil, laPropPack *This, laPropPack *OperatorProps, laColumn *UNUSED, int context);
- int OPINV_UiItem(laOperator *a, laEvent *e);
- int OPEXT_UiItem(laOperator *a, int ExitCode);
- int la_ArrayGetHeight(laUiItem *ui);
- int la_ValueGetHeight(laUiItem*ui);
- int la_3DViewGetHeight(laUiItem *ui);
- int la_CanvasGetHeight(laUiItem *ui);
- int la_EnumGetHeight(laUiItem *ui);
- int la_ColorPickerGetHeight(laUiItem *ui);
- int la_SymbolGetHeight(laUiItem *ui);
- int la_GroupGetHeight(laUiItem *ui);
- laPanel *la_FindFreePanelByTemplate(laWindow *w, const laUiTemplate *uit);
- laUiItem *la_FindUiWithMark(laUiList *uil, char *mark);
- laUiList *la_FindSubListWithInstance(laUiItem *ui, void *Instance);
- void* laget_CurrentRackPage(laRackPageCollection* c);
- void laset_CurrentRackPage(laRackPageCollection* c,laRackPage* rp);
- void la_BeginNVG(struct NVGcontext* vg,laCanvasExtra* e,int W,int H, int Is2D);
- void la_SetCanvasOrtho(laCanvasExtra* e,int W, int H);
- #define LA_FILETYPE_UNKNOWN 0
- #define LA_FILETYPE_UDF 1
- #define LA_FILETYPE_DOCUMENT 2
- #define LA_FILETYPE_IMAGE 3
- #define LA_FILETYPE_AUDIO 4
- #define LA_FILETYPE_VIDEO 5
- #define LA_FILETYPE_COMPRESSED 6
- #define LA_FILETYPE_FONT 7
- #define LA_FILETYPE_VECTOR 8
- #define LA_FILETYPE_WEBPAGE 9
- #define LA_FILETYPE_META 10
- #define LA_FILETYPE_BLEND 11
- #define LA_FILETYPE_PDF 13
- #define LA_FILETYPE_EXEC 14
- #define LA_FILETYPE_SYS 15
- #define LA_FILETYPE_FOLDER 16
- #define LA_FILETYPE_LASDEXCHANGE 17
- #define LA_FILE_SELECT_FILE 0
- #define LA_FILE_SELECT_FOLDER 1
- STRUCTURE(laExtensionType){
- laListItem Item;
- int FileType;
- const char* Extension;
- };
- STRUCTURE(laFileItem){
- laListItem Hyper;
- int IsFolder;
- char Name[1024];
- int Size;
- uint64_t Timestamp;
- laTimeInfo TimeModified;
- int Type;
- };
- STRUCTURE(laDiskItem){
- laListItem Hyper;
- char ID;
- real Total_GB;
- real Free_GB;
- };
- STRUCTURE(laBookmarkedFolder){
- laListItem Item;
- char Name[128];
- char Path[1024];
- };
- #define LA_FILE_SORT_NAME 0
- #define LA_FILE_SORT_NAME_REV 1
- #define LA_FILE_SORT_TIME 2
- #define LA_FILE_SORT_TIME_REV 3
- #define LA_FILE_SORT_SIZE 4
- #define LA_FILE_SORT_SIZE_REV 5
- STRUCTURE(laFileBrowser){
- laListItem Hyper;
- char Path[2048];
- char FileName[512];
- char TempStr[512];
- char MD5[128];
- char FilterName[512];
- tnsImage* Thumbnail;
- laDiskItem *RootDisk;
- laFileItem *Active;
- laListHandle FileList;
- laListHandle Bookmarks;
- laListHandle Disks;
- int SelectFolder;
- int WarnFileExists;
- int StatusWaitingWarning;
- char UseExtension[64];
- int UseType;
- int FilterType;
- int ShowBackups;
- int ShowThumbnail;
- int SortBy;
- laStringSplitor* ss_filter_extensions;
- };
- STRUCTURE(laUDFPreviewExtra){
- laUDF *UDF;
- int Opened;
- int Append;
- };
- STRUCTURE(laManagedSaveExtra){
- int ShowPage;
- int OnExit;
- };
- #define LA_UDF_SHARE_POINTER(id) \
- la_UDFAppendSharedTypePointer("" #id, id)
- void la_MakeTranslations_zh_hans();
- void la_MakeTranslations_es_ES();
- laCanvasTemplate *la_GetCanvasTemplate(char *TargetContainerID, char* TemplateID);
- laPropContainer* laUiHasExtraProps(laUiType *ut, int size, int Hyper);
- laPropContainer* laCanvasHasExtraProps(laCanvasTemplate *ct, int size, int Hyper);
- laUiType *la_RegisterUiType(const char *Identifer, int ForType, const char *UseOperator, laBoxedTheme **bt, laUiDrawFunc *Draw, laUiGetHeightFunc GetHeight, laUiInitFunc Init, laUiDestroyFunc Destroy);
- void la_NotifyGLDebugChanges();
- void laSetWindowCursor(int id);
- void laRenameWindow(laWindow* wnd, char* name);
- #ifdef LA_LINUX
- int la_GetDPI(Window* root_win);
- void la_ScanWacomDevices(SYSTEMDISPLAY *display, int deviceid);
- #endif
- #ifdef _WIN32
- int la_GetDPI(HWND win);
- void la_OpenWacomWinTab(HWND hwnd);
- #endif
- void laSetFontFolderPath(char* absolute);
- void laSetDefaultInitArguments(laInitArguments* ia);
- void laSetCompleteInitArguments(laInitArguments* ia);
- void laProcessInitArguments(int argc, char* argv[],laInitArguments* ia);
- int laGetReady();
- int laGetReadyWith(laInitArguments* ia);
- void laShutoff(int SavePreferences);
- int laRestoreFactorySettings();
- void laSaveUserPreferences();
- void laEnsureUserPreferences();
- void laAddExtraExtension(int FileType, ...);
- void laAddExtraPreferencePath(const char* path);
- void laAddExtraPreferencePage(const char* name, laUiDefineFunc Func);
- void laSetFrameCallbacks(laPreFrameF PreFrame, laPreDrawF PreDraw, laPostFrameF PostFrame);
- void laSetCleanupCallback(laCleanupF Cleanup);
- void laSetInputProcessCallback(laInputProcessF InputProcess);
- void laSetMenuBarTemplates(laUiDefineFunc MenuButtons, laUiDefineFunc MenuExtras, const char* ProgramName);
- void laSetAboutTemplates(laUiDefineFunc AboutContent, laUiDefineFunc AboutVersion, laUiDefineFunc AboutAuthor);
- void laSetPreferenceTemplates(laUiDefineFunc PreferencePageDisplay, laUiDefineFunc PreferencePageInput, laUiDefineFunc PreferencePageResource, laUiDefineFunc PreferencePageTheme);
- void la_InputMappingGetKeyName(int key, int special, char* name);
- int la_InputMappingGetKeyFromName(char* name, int* special);
- laCustomSignal* laFindSignal(char* Name);
- laCustomSignal* laFindSignalByID(int ID);
- void laInputMappingUpdateSignal(laInputMappingEntry* ime);
- laInputMapping* laNewInputMapping(char* Name);
- laInputMappingEntry* laNewInputMappingEntry(laInputMapping* im, int DeviceType, int JoystickDevice, char* Key, int SpecialKeyBit, char* Signal);
- laInputMappingEntry* laNewInputMappingEntryP(laInputMapping* im, int DeviceType, int JoystickDevice, char* Key, int SpecialKeyBit, int Signal);
- void laRemoveInputMappingEntry(laInputMapping* im, laInputMappingEntry* e);
- void laRemoveInputMapping(laInputMapping* im);
- laCustomSignal* laNewCustomSignal(char* Name, int Signal);
- void laRemoveCustomSignal(laCustomSignal* cs);
- void la_RemoveScreen(laScreen*s);
- laScreen* laGetWindowScreen(laWindow* w);
- laWindow *laDesignWindow(int X, int Y, int W, int H);
- laLayout *laDesignLayout(laWindow *w, char *Title);
- void laDestroyLayout(laWindow *w, laLayout* l);
- void laFoldBlockTitle(laBlock* b);
- void laUnfoldBlockTitle(laBlock* b);
- void laMaximizeBlock(laBlock* b);
- void laRestoreToLayout();
- void laMaximizeCanvasUI(laUiItem* ui, laPanel* UiParentPanel);
- void laRestoreCanvasUI();
- void laHideMenuBar();
- void laShowMenuBar();
- void laSplitBlockHorizon(laBlock *b, real Percentage);
- void laSplitBlockVertical(laBlock *b, real Percentage);
- void laCombineChildBlocks(laBlock *b);
- laBlock *laBlock1(laBlock *b);
- laBlock *laBlock2(laBlock *b);
- laBlock *laSwapSubBlocks(laBlock *b);
- void laDestroyBlocksRecursive(laBlock *Root);
- laPanel* laTearOffPanel(laBlock* b, laPanel* p_if_set);
- void laDockPanel(laWindow* from, laBlock* b, laPanel* p);
- laPanel *laCreatePanel(laBlock *b, char *template_id);
- laPanel *laCreateTopPanel(laWindow *w, char *template_id, int X, int Y, int W, int H, int MaxW, int MaxH, int MinW, int MinH, int SnapL, int SnapR, int SnapT, int SnapB);
- void laShowPanel(laPanel *p);
- void laShowPanelWithDropDownEffect(laPanel *p);
- void laShowPanelWithExpandEffect(laPanel *p);
- void laHidePanel(laPanel *p);
- void laHidePanelWithDissoveEffect(laPanel *p);
- void laActivatePanel(char* TemplateID, int x, int y);
- void laPanPanel(laPanel *p, int DeltaX, int DeltaY);
- int laPanUiListFree(laUiList *uil, int X, int Y);
- int laPanUiList(laUiList *uil, int X, int Y, int L, int R, int U, int B);
- int laPanUiListAuto(laUiList *uil, int X, int Y, int L, int R, int U, int B);
- int laScaleUiList(laUiList *uil, real factor, int L, int R, int U, int B);
- laPanel *laDesignPropPanel(char *Title, int X, int Y, int W, int H,
- laUiDefineFunc Define, laPropPack *This, laPropPack *OperatorProps);
- laPanel *laDesignOperatorPanel(char *Title, int X, int Y, int W, int H, int MaxW, int MaxH, int MinW, int MinH, int SnapL, int SnapR, int SnapT, int SnapB,
- laUiDefineFunc Define, laPropPack *This, laPropPack *OperatorProps);
- void laDeferedDestroyPanel(laPanel *p);
- void laDestroySinglePanel(laPanel *p, int immediate);
- void laEnsurePanelInBound(laPanel *p,laUiList* uil);
- int laEnclosePanelContent(laPanel *p, laUiList *uil);
- laPanel *laEnableIdlePanel(laPanel *Attachment, laOperator *a, laPropPack *OperatorProps, laUiDefineFunc ReplaceUiDefine, laPropPack *This,
- int L, int R, int B, int MaxGH, int MaxW, laEvent *e);
- laPanel *laEnableSplashPanel(laUiDefineFunc ReplaceUiDefine, int L, int R, int B, int MaxGH, int MaxW, laEvent* e);
- laPanel *laEnablePropertyPanel(laPanel *Attachment, laOperator *a, laPropPack *OperatorProps, laUiDefineFunc ReplaceUiDefine, laUiDefineFunc FallBackUiDefine, laPropPack *This,
- int L, int R, int B, int MaxGH, int MaxW, laEvent *e);
- laPanel *laEnableEmptyPropertyPanel(laPanel *Attachment, laOperator *a, int L, int R, int U, int MaxGH, laEvent *e);
- laPanel *laEnableMenuPanel(laPanel *Attachment, laOperator *a, laUiList *MenuRefer, laPropPack *This,
- int L, int R, int B, int MaxGH, int MaxW, laEvent *e);
- laPanel *laDefineAndEnableMenuPanel(laPanel *Attachment, laOperator *a, laPropPack *This,
- int L, int B, int MaxGH, int MaxW, laEvent *e);
- laPanel *laEnableOperatorPanel(laOperator *For, laPropPack *This, int X, int Y, int W, int H, int MaxW, int MaxH, int MinW, int MinH, int SnapL, int SnapR, int SnapT, int SnapB, laEvent *e);
- laPanel *laEnableYesNoPanel(laOperator *a, laPanel *Attachment, char *Title, char *Message, int X, int Y, int W, laEvent *e);
- laPanel *laEnableMessagePanel(laOperator *a, laPanel *Attachment, char *Title, char *Message, int X, int Y, int W, laEvent *e);
- void laOperatorModalOver(laOperator* For);
- void la_PropPanelUserRemover(void* This, laItemUserLinker* iul);
- void la_EnsurePanelExtras(laPanel *p);
- void laDeferredRedraw(laPanel* p);
- void laRedrawAllWindows();
- void laRefreshWindow();
- void laRedrawCurrentWindow();
- void laRedrawPanel(laPanel* p);
- void laRecalcPanel(laPanel* p);
- void laRedrawCurrentPanel();
- void laRecalcCurrentPanel();
- void laRecalcPanelImmediate(laPanel *p);
- void laRecalcCurrentPanelImmediate();
- int laNonFixedPanelExists(laPanel *p);
- int laIsInPanel(laPanel *p, int PanelX, int PanelY);
- int laIsCloseToPanel(laPanel *p, int PanelX, int PanelY);
- void laPopPanel(laPanel *p);
- int laPanelOverlappingEachOther(laPanel *p1, laPanel *p2);
- void laUnlinkSharedPanel(laPanel *p);
- int laIsPanelCovered(laPanel *p);
- int laIsTopPanel(laPanel *p);
- laPanel *laDetectPanel(int X, int Y);
- void laWindowToLocal(laOperator *a, laPanel *p, int *x, int *y);
- void laPanelToLocal(laOperator *a, int *x, int *y);
- void laLocalToWindow(laOperator *a, laPanel *p, int *x, int *y);
- void laLocalToPanel(laOperator *a, int *x, int *y);
- void laSetNextMenuPos(int X, int Y, int W, int H);
- int laIsInBlock(laBlock *b, int X, int Y);
- int laIsInBlockHeader(laBlock *b, int X, int Y);
- int laIsInBlockBotton1(laBlock *b, int X, int Y);
- int laIsInBlockBotton2(laBlock *b, int X, int Y);
- laBlock *laClearBlockButtonRecursive(laBlock *b, laBlock *except);
- laBlock *laDetectBlockRecursive(laBlock *b, int X, int Y);
- void la_DoUiScissor(laUiItem* ui, int* savex, int* savey, int* savew, int* saveh,
- int* savel, int* saver, int* saveu, int* saveb);
- laUiList *laPrepareUi(laPanel *p);
- laColumn *laFirstColumn(laUiList *uil);
- laColumn *laSplitColumn(laUiList *uil, laColumn *c, real Percent);
- laColumn *laSplitColumnDescriptor(laUiDescriptor *ud, laColumn *c, real Percent);
- laColumn *laLeftColumn(laColumn *c, int MaxWidth);
- laColumn *laRightColumn(laColumn *c, int MaxWidth);
- int laCheckAndMergeSubColumnsUiList(laUiList *TopUil, laColumn *c, int DoMerge);
- int laCheckAndMergeSubColumnsDescriptor(laUiDescriptor *TopDescriptor, laColumn *c, int DoMerge);
- laUiConditionNode *laTrue();
- laUiConditionNode *laFalse();
- laUiConditionNode *laPropExpression(laPropPack *Base, char *Prop);
- laUiConditionNode *laIntExpression(int Value);
- laUiConditionNode *laFloatExpression(real Value);
- laUiConditionNode *laStringExpression(char *Content);
- laUiConditionNode *laAnd(laUiConditionNode *Expression1, laUiConditionNode *Expression2);
- laUiConditionNode *laOr(laUiConditionNode *Expression1, laUiConditionNode *Expression2);
- laUiConditionNode *laNot(laUiConditionNode *Expression1);
- laUiConditionNode *laEqual(laUiConditionNode *Expression1, laUiConditionNode *Expression2);
- laUiConditionNode *laGreaterThan(laUiConditionNode *Expression1, laUiConditionNode *Expression2);
- laUiConditionNode *laLessThan(laUiConditionNode *Expression1, laUiConditionNode *Expression2);
- laUiConditionNode *laGreaterEqual(laUiConditionNode *Expression1, laUiConditionNode *Expression2);
- laUiConditionNode *laLessEqual(laUiConditionNode *Expression1, laUiConditionNode *Expression2);
- laUiItem *laShowLabel(laUiList *uil, laColumn *c, const char *Content, laUiDefineFunc Template, laWidget* Widget);
- laUiItem *laShowLabelDynamic(laUiList *uil, laColumn *c, const char *Content, laUiDefineFunc Template, laWidget* Widget);
- laUiItem *laShowIcon(laUiList *uil, laColumn *c, laPropPack *Base, const char *Path, laWidget* Widget);
- laUiItem *laShowInvisibleItem(laUiList *uil, laColumn *c, laPropPack *Base, const char *Path);
- laUiItem *laShowItem(laUiList *uil, laColumn *c, laPropPack *Base, const char *Path);
- laUiItem *laShowItemFull(laUiList *uil, laColumn *c, laPropPack *Base, const char *Path, laWidget* Widget, char* instructions, laUiDefineFunc Template, int TemplateContext);
- laUiItem *laShowImage(laUiList *uil, laColumn *c, tnsImage* Image, int Height);
- laUiItem *laShowNodeSocket(laUiList *uil, laColumn *c, laPropPack *Base, const char *Path, char* instructions);
- laUiItem *laShowHeightAdjuster(laUiList *uil, laColumn *c, laPropPack *Base, const char *Path, char* instructions);
- laUiItem *laShowDetachedItem(laPanel *p, laUiList *uil, laColumn *c, laPropPack *Base, const char *Path, const char *Rename, laUiDefineFunc Template, laWidget* Widget);
- laUiItem *laShowCanvas(laUiList *uil, laColumn *c, laPropPack *Base, const char *Path, const char *id2DTemplate, int Height);
- laUiItem *laShow3DCanvasCombo(laUiList *uil, laColumn *c, laPropPack *Base, const char *Path, int Height, laPropPack* Detached);
- laUiItem *laShow2DContainerItem(laUiList *uil, laColumn *c, laPropPack *Base, const char *Path, int Height);
- void laDefault3DViewOverlay(laUiItem *ui);
- void laDefault2DViewOverlayRight(laUiItem *ui);
- laUiItem *laShowColumnAdjuster(laUiList *uil, laColumn *c);
- laUiItem *laShowSymbol(laUiList *uil, laColumn *c, int SymbolID, int Height);
- laPropPack* laShowCompoundValue(laUiItem* ui, int slot, laPropPack *Base, const char *Path);
- laUiItem *laBeginRow(laUiList *uil, laColumn *c, int Expand, int Even);
- laUiItem *laEndRow(laUiList *uil, laUiItem* Begin);
- laUiItem *laMakeGroup(laUiList *uil, laColumn *c, const char *Name, laWidget* Widget);
- laUiItem *laMakeFoldableGroup(laUiList *uil, laColumn *c, const char *Name, laWidget* Widget, int DefaultFolded, int ButtonFlags);
- laUiItem *laMakeEmptyGroup(laUiList *uil, laColumn *c, const char *Name, laWidget* Widget);
- void laEndFoldableGroup(laUiList *sub, laUiItem *group);
- laUiItem *laMakeTab(laUiList *uil, laColumn *c, laWidget* Widget);
- laUiList *laAddTabPage(laUiItem *ui, const char *Name);
- laUiItem *laOnConditionThat(laUiList *uil, laColumn *c, laUiConditionNode *Expression);
- laUiItem *laOnConditionToggle(laUiList *uil, laColumn *col, laUiDefineFunc define, int Remove, laPropPack *ExtraBase, laPropPack *ExtraThis, laWidget* Widget);
- laUiItem *laEndCondition(laUiList *uil, laUiItem *Beginner);
- laUiItem *laElse(laUiList *uil, laUiItem *Beginner);
- laUiList* laMakeMenuPageEx(laUiList* uil, laColumn* c, const char* Title, int flags);
- laUiList *laMakeMenuPage(laUiList *uil, laColumn *c, const char *Title);
- laUiItem *laShowSeparator(laUiList *uil, laColumn *widest);
- void laFixHeight(laUiList *uil, short Rows);
- void la_ConditionerInit(laUiItem *ui, laUiConditionNode *Expression);
- void laMakeExtraColumns(laUiItem *ui, u8bit HowMany, ...);
- int la_UiInBoundEx(laUiItem *ui, laUiListDraw *uild);
- void la_DestroyUiRange(laUiList *uil, laUiItem *Begin, laUiItem *End);
- void la_ClearUiSpecificData(laUiItem *ui);
- laUiItem *la_UpdatePropDisplay(laUiItem *ui, laPropPack *Base, const char *Path, laUiDefineFunc Template, laWidget* Widget, char* instructions);
- laUiItem *la_UpdateLabelDisplay(laUiItem *ui, laUiDefineFunc Template, char *Content);
- laUiItem *la_ShowGeneralPropItem(laUiList *uil, laColumn *c, laPropPack *Base, laProp *GeneralProp, laProp *p, laUiDefineFunc Template, laWidget* Widget);
- void laFinalizeUiTemplates();
- laUiTemplate *laFindUiTemplate(char *Identifier);
- void la_DestroyUiTemplate(laUiTemplate* uit);
- void la_DestroyCanvasTemplate(laCanvasTemplate* uit);
- laUiTemplate *laRegisterUiTemplate(char *Identifier, char* Title, laUiDefineFunc func,laPanelDetachedPropFunc PropFunc, laUiDefineFunc header, char* NewCategory, int DefaultGLFormat, int DefaultW_RH, int DefaultH_RH);
- laCanvasTemplate *laRegisterCanvasTemplate(char *Identifier, char *ForContainer, laModalFunc ExtraModal, laCanvasDrawFunc Func, laUiDrawFunc SecondDraw, laUiInitFunc CustomInit, laUiDestroyFunc CustomDestroy);
- void la_DestroyTheme(laTheme* t);
- laTheme *laDesignTheme(const char *Name, const char *AuthorName);
- laBoxedTheme *laDesignBoxedTheme(laTheme *t, const char *Name, laBoxedTheme** BackRef,
- real NormalY,real ActiveY,real BorderY,real TextY,real TextActiveY, real Alpha,
- real TopMargin, real LeftMargin, real RightMargin, real BottomMargin,
- real TopPadding, real LeftPadding, real RightPadding, real BottomPadding);
- laTheme *laGetTheme(const char *ThemeName);
- laBoxedTheme *laGetBoxedTheme(const char *ThemeName, const char *BoxName);
- real* laThemeColor(laBoxedTheme* bt, int which);
- real* laAccentColor(int which);
- void la_RefreshBoxedThemeColor(laBoxedTheme* bt);
- void la_RefreshThemeColorSelf(laTheme* th);
- void la_RefreshThemeColor(laTheme* th);
- #define LA_COLOR4(c) (c)[0], (c)[1], (c)[2], (c)[3]
- #define LA_COLOR3(c) (c)[0], (c)[1], (c)[2]
- #define LA_VEC2(c) (c)[0], (c)[1]
- #define LA_SET3(c, a1,a2,a3) { (c)[0]=a1; (c)[1]=a2; (c)[2]=a3; }
- #define LA_COLOR3_TO_HEX(c) (((int)((c)[0]*255)<<16)|((int)((c)[1]*255)<<8)|((int)((c)[2]*255)<<0))
- #define LA_COLOR3_TO_RGB(c) (RGB((int)((c)[0]*255),(int)((c)[1]*255),(int)((c)[2]*255)))
- int laIsInUiItem(laUiItem *ui, int x, int y);
- int laIsInBound(int x, int y, int l, int r, int u, int b);
- laUiItem *la_DetectUiItemRecursive(laUiList *uil, int x, int y, int LimB, laListHandle *LocalBuf, int Deep);
- laUiItem *la_DetectSocketRecursive(laUiList* uil, int x, int y, int LimB, laPropContainer* PCInOrOut);
- laUiList *la_DetectUiListRecursive(laUiList *uil, int x, int y, int LimH,
- laUiItem **ParentUi, laUiList **ScrollUil, laUiList **ContainerParent, int InToContainerUI, laUiItem *Exception);
- laUiList *la_DetectUiListRecursiveDeep(laUiList *uil, int x, int y, int LimH, laUiItem **ParentUi, laUiList **ScrollUil,
- laUiList **ContainerParent, int InToContainerUI, laUiItem *Exception, laListHandle* levels);
- int laStartWindow(laWindow *w);
- void laMainLoop();
- void la_DestroyOperatorType(laOperatorType* at);
- laOperatorType *laCreateOperatorType(const char *ID, const char *Name, const char *Description,
- laCheckFunc Check, laInitFunc Init, laExitFunc Exit, laInvokeFunc Invoke, laModalFunc Modal,
- uint32_t IconID, int ExtraMark);
- laPropContainer* laDefineOperatorProps(laOperatorType* ot, int HyperLevel);
- #define LA_VERIFY_THIS_TYPE(this,pc,pc_identifier) \
- ((this)&&(this)->EndInstance&& \
- (this)->LastPs->p->PropertyType==LA_PROP_SUB&& \
- ((pc)=la_EnsureSubTarget((this)->LastPs->p,(this)->EndInstance))&&strSame((pc)->Identifier,pc_identifier))
- laNodeOutSocket* laCreateOutSocket(void* NodeParentOptional, char* label, int DataType);
- laNodeInSocket* laCreateInSocket(char* label, int DataType);
- void laDestroyInSocket(laNodeInSocket* s);
- void laDestroyOutSocket(laNodeOutSocket* s);
- laNodeCategory* laEnsureNodeCategory(char* Name,laUiDefineFunc* Ui,int ForRackTypes);
- void laNodeCategoryAddNodeTypes(laNodeCategory* nc, ...);
- void laDestroyRack(laNodeRack* rr);
- laRackPage* laDuplicateRackPage(laRackPage* new_optional, laRackPage* from);
- void laFreeKeyMapItem(laKeyMapItem* kmi);
- laKeyMapItem *laAssignNewKey(laKeyMapper *km, char *Path, char *Operation, char SelectBase, int SpecialKeyBits, int EventType, int Key, char *ExtraInstructions);
- int laKeyMapExecuteEvent(laOperator *from, laKeyMapper *km, laEvent *e);
- int laKeyMapExecuteEventEx(laOperator *from, laPropPack *UiExtra, laKeyMapper *km, laEvent *e);
- laOperatorType *laGetOperatorType(const char *ID);
- void laSetOperatorLocalizer(void *ToPanel);
- int laOperatorAvailable(char *ID, laPropPack *This, laStringSplitor *Instructions);
- int laOperatorAvailableP(laOperatorType *at, laPropPack *This, laStringSplitor *Instructions);
- int laOperatorAvailableSafe(char *ID, laPropPack *This, void *Real_FromInstance, laStringSplitor *Instructions);
- int laOperatorAvailablePSafe(laOperatorType *at, laPropPack *This, void *Real_FromInstance, laStringSplitor *Instructions);
- void laSendOperatorTriggerEvent();
- void laRetriggerOperators();
- int la_GenericTopPanelProcessing(laOperator* a, laEvent* e);
- int OPMOD_FinishOnData(laOperator* a, laEvent* e);
- void OPEXT_FreeUserData(laOperator* a, int mark_unused);
- void laHideCursor();
- void laShowCursor();
- int la_UiOperatorExists(void *inst);
- int laOperatorExistsT(laOperatorType* at);
- int laOperatorExists(const char* ID);
- int laInvokeUi(laOperator *From, char *ID, laEvent *e, void *inst, laListHandle *Locals, int IgnoreLocals);
- int laInvokeUiP(laOperator *From, laOperatorType *at, laEvent *e, void *inst, laListHandle *Locals, int IgnoreLocals);
- int laInvoke(laOperator *From, char *ID, laEvent *e, laPropPack *This, char *args, char *args2);
- int laInvokeP(laOperator *From, laOperatorType *at, laEvent *e, laPropPack *This, char *args, char *args2);
- int laInvokePCreateThis(laOperator *From, laOperatorType *at, laEvent *e, laPropPack *OrigionalThis, void *FromInstance, char *args, char *args2);
- void laRequestDelayEvent(real Seconds);
- int la_UiStillInService(void *UiInstance);
- void la_StopUiOperatorService(void *UiInstance);
- void la_StopAllOperators();
- int la_ProcessTextEdit(laEvent *e, laStringEdit *se, laUiItem* ui);
- void laConfirmPointer(laOperator *a, void* Data,laPropContainer* PointerType, int mode);
- void laConfirmInt(laOperator *a, int Data, int mode);
- void laConfirmFloat(laOperator *a, real Data, int mode);
- void laConfirmString(laOperator *a, char *Str, int mode);
- int laConfirmSameDataIfAny(laOperator *a);
- void laConfirmUserData(laOperator *a, void *UserData, laConfirmDataDestroyFunc Destroy, int mode);
- int laGetConfirmInt(laOperator *a);
- real laGetConfirmFloat(laOperator *a);
- void laGetConfirmString(laOperator *a, char *buf);
- void *laGetConfirmUserData(laOperator *a);
- //int laInvokeSub(laProp* From, char * ID, laEvent* e, void* inst);
- void la_DisplayKeyboard(bool pShow);
- void la_HideNavBar();
- void laFinalizeOperators();
- int laWaitFor(laOperator *Who, int State);
- void la_PrintOperatorStack();
- void laui_DefaultPanelTitleBar(laUiList *uil, laPropPack *Base, laPropPack *Extra, laUiDefineFunc header);
- void laui_DefaultOperatorPanelTitleBar(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);;
- void laui_DefaultSubWindowMenuBarActual(laUiList *uil, laPropPack *pp, laPropPack *actinst, laColumn *extracol, int context);;
- void laui_DefaultMenuBarActual(laUiList *uil, laPropPack *pp, laPropPack *actinst, laColumn *extracol, int context);;
- void laui_DefaultMenuBar(laWindow *w);
- void laui_DefaultSubWindowMenuBar(laWindow *w);
- void laui_DefaultPropUiDefine(laUiList *uil, laPropPack *This, laPropPack *OperatorProps, laColumn *UNUSED, int context);;
- void laui_PropOperatorUiDefine(laUiList *uil, laPropPack *This, laPropPack *Unused, laColumn *UNUSED, int context);
- int laCopyToClipboard(unsigned char * text);
- extern laUiType *_LA_UI_FIXED_GROUP;
- extern laUiType *_LA_UI_TAB;
- extern laUiType _LA_UI_CONDITION; //NO PTR
- extern laUiType _LA_UI_CONDITION_END; //NO PTR
- extern laUiType _LA_UI_CONDITION_ELSE; //NO PTR
- extern laUiType _LA_UI_ROW_BEGIN; //NO PTR
- extern laUiType _LA_UI_ROW_END; //NO PTR
- extern laUiType _LA_UI_INVISIBLE; //NO PTR
- extern laUiType *_LA_UI_COLLECTION;
- extern laUiType *_LA_UI_COLLECTION_ITEM;
- extern laUiType *_LA_UI_COLLECTION_SELECTOR;
- extern laUiType *_LA_UI_COLLECTION_SINGLE;
- extern laUiType *_LA_UI_BUTTON;
- extern laUiType *_LA_UI_LABEL;
- extern laUiType *_LA_UI_INT;
- extern laUiType *_LA_UI_METER_TYPE1;
- extern laUiType *_LA_UI_METER_TYPE2;
- extern laUiType *_LA_UI_VALUE_METER_2D;
- extern laUiType *_LA_UI_FLOAT;
- extern laUiType *_LA_UI_FLOAT_COLOR;
- extern laUiType *_LA_UI_FLOAT_COLOR_HCY;
- extern laUiType *_LA_UI_ENUM_SELECTOR;
- extern laUiType *_LA_UI_MENU_ROOT;
- extern laUiType *_LA_UI_CONDITION_TOGGLE;
- extern laUiType *_LA_UI_STRING;
- extern laUiType *_LA_UI_STRING_MULTI;
- extern laUiType *_LA_UI_ALIGN;
- extern laUiType *_LA_UI_CANVAS;
- extern laUiType *_LA_UI_COLUMN_ADJUSTER;
- extern laUiType *_LA_UI_SYMBOL;
- extern laUiType *_LA_UI_COLUMN_VIEWER;
- extern laUiType *_LA_UI_NODE_SOCKET;
- extern laUiType *_LA_UI_HEIGHT_ADJUSTER;
- extern laUiType *_LA_UI_RAW;
- extern laUiType *_LA_UI_MAPPER;
- extern laUiType *_LA_UI_IMAGE;
- extern laUiType *_LA_UI_SCOPE;
-
- extern laUiDescriptor _LA_UI_DESCRIPTOR_REF_UI;
- extern laUiDescriptor _LA_UI_DESCRIPTOR_REF_UIE;
- extern laUiDescriptor _LA_UI_DESCRIPTOR_REF_P;
- extern laUiDescriptor _LA_UI_DESCRIPTOR_REF_PE;
- extern laUiDescriptor _LA_UI_DESCRIPTOR_REF_BASE;
- extern laUiDescriptor _LA_UI_DESCRIPTOR_REF_ACT;
- extern laUiDefineFunc _LA_SUBPROP_DONT_CARE;
-
- extern laBoxedTheme *_LA_THEME_PANEL;
- extern laBoxedTheme *_LA_THEME_VALUATOR;
- extern laBoxedTheme *_LA_THEME_BUTTON;
- extern laBoxedTheme *_LA_THEME_STRING;
- extern laBoxedTheme *_LA_THEME_SELECTOR;
- extern laBoxedTheme *_LA_THEME_COLLECTION_SELECTOR;
- extern laBoxedTheme *_LA_THEME_LABEL;
- extern laBoxedTheme *_LA_THEME_TAB;
- extern laBoxedTheme *_LA_THEME_COLLECTION_GROUP;
- extern laBoxedTheme *_LA_THEME_COLLECTION_ITEM;
- extern laBoxedTheme *_LA_THEME_FLOATING_PANEL;
- extern laBoxedTheme *_LA_THEME_3D_VIEW;
- extern laBoxedTheme *_LA_THEME_2D_VIEW;
- extern laBoxedTheme *_LA_THEME_SOCKET;
- extern laProp *_LA_PROP_PANEL;
- extern laProp *_LA_PROP_BLOCK;
- extern laProp *_LA_PROP_WINDOW;
- extern laProp *_LA_PROP_UI_ITEM;
- extern laProp *_LA_PROP_FAILED_ITEM;
- extern laProp *_LA_PROP_TRASH_ITEM;
- extern laProp *_LA_PROP_NODE_GRAPH;
- extern laPropContainer *_LA_PROP_3D_EXTRA;
- extern laPropContainer *_LA_PROP_2D_EXTRA;
- extern laPropContainer *_LA_PROP_FILE_BROWSER;
-
- extern laProp _P_LA_USE_INSTANCE_ONLY;
- #define _LA_USE_INSTANCE_ONLY (&_P_LA_USE_INSTANCE_ONLY)
- #define LA_RH0 (MAIN.UiRowHeight)
- #define LA_RH (MAIN.ScaledUiRowHeight)
- #define LA_2RH (MAIN.ScaledUiRowHeight*2)
- #define LA_RH2 ((int)(MAIN.ScaledUiRowHeight/2))
- #define LA_SCROLL_W ((int)(MAIN.ScaledUiRowHeight * 0.67))
- #define LA_SEAM_W ((int)(MAIN.ScaledUiRowHeight * 0.15))
|