sokol_debugtext.h 268 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175317631773178317931803181318231833184318531863187318831893190319131923193319431953196319731983199320032013202320332043205320632073208320932103211321232133214321532163217321832193220322132223223322432253226322732283229323032313232323332343235323632373238323932403241324232433244324532463247324832493250325132523253325432553256325732583259326032613262326332643265326632673268326932703271327232733274327532763277327832793280328132823283328432853286328732883289329032913292329332943295329632973298329933003301330233033304330533063307330833093310331133123313331433153316331733183319332033213322332333243325332633273328332933303331333233333334333533363337333833393340334133423343334433453346334733483349335033513352335333543355335633573358335933603361336233633364336533663367336833693370337133723373337433753376337733783379338033813382338333843385338633873388338933903391339233933394339533963397339833993400340134023403340434053406340734083409341034113412341334143415341634173418341934203421342234233424342534263427342834293430343134323433343434353436343734383439344034413442344334443445344634473448344934503451345234533454345534563457345834593460346134623463346434653466346734683469347034713472347334743475347634773478347934803481348234833484348534863487348834893490349134923493349434953496349734983499350035013502350335043505350635073508350935103511351235133514351535163517351835193520352135223523352435253526352735283529353035313532353335343535353635373538353935403541354235433544354535463547354835493550355135523553355435553556355735583559356035613562356335643565356635673568356935703571357235733574357535763577357835793580358135823583358435853586358735883589359035913592359335943595359635973598359936003601360236033604360536063607360836093610361136123613361436153616361736183619362036213622362336243625362636273628362936303631363236333634363536363637363836393640364136423643364436453646364736483649365036513652365336543655365636573658365936603661366236633664366536663667366836693670367136723673367436753676367736783679368036813682368336843685368636873688368936903691369236933694369536963697369836993700370137023703370437053706370737083709371037113712371337143715371637173718371937203721372237233724372537263727372837293730373137323733373437353736373737383739374037413742374337443745374637473748374937503751375237533754375537563757375837593760376137623763376437653766376737683769377037713772377337743775377637773778377937803781378237833784378537863787378837893790379137923793379437953796379737983799380038013802380338043805380638073808380938103811381238133814381538163817381838193820382138223823382438253826382738283829383038313832383338343835383638373838383938403841384238433844384538463847384838493850385138523853385438553856385738583859386038613862386338643865386638673868386938703871387238733874387538763877387838793880388138823883388438853886388738883889389038913892389338943895389638973898389939003901390239033904390539063907390839093910391139123913391439153916391739183919392039213922392339243925392639273928392939303931393239333934393539363937393839393940394139423943394439453946394739483949395039513952395339543955395639573958395939603961396239633964396539663967396839693970397139723973397439753976397739783979398039813982398339843985398639873988398939903991399239933994399539963997399839994000400140024003400440054006400740084009401040114012401340144015401640174018401940204021402240234024402540264027402840294030403140324033403440354036403740384039404040414042404340444045404640474048404940504051405240534054405540564057405840594060406140624063406440654066406740684069407040714072407340744075407640774078407940804081408240834084408540864087408840894090409140924093409440954096409740984099410041014102410341044105410641074108410941104111411241134114411541164117411841194120412141224123412441254126412741284129413041314132413341344135413641374138413941404141414241434144414541464147414841494150415141524153415441554156415741584159416041614162416341644165416641674168416941704171417241734174417541764177417841794180418141824183418441854186418741884189419041914192419341944195419641974198419942004201420242034204420542064207420842094210421142124213421442154216421742184219422042214222422342244225422642274228422942304231423242334234423542364237423842394240424142424243424442454246424742484249425042514252425342544255425642574258425942604261426242634264426542664267426842694270427142724273427442754276427742784279428042814282428342844285428642874288428942904291429242934294429542964297429842994300430143024303430443054306430743084309431043114312431343144315431643174318431943204321432243234324432543264327432843294330433143324333433443354336433743384339434043414342434343444345434643474348434943504351435243534354435543564357435843594360436143624363436443654366436743684369437043714372437343744375437643774378437943804381438243834384438543864387438843894390439143924393439443954396439743984399440044014402440344044405440644074408440944104411441244134414441544164417441844194420442144224423442444254426442744284429443044314432443344344435443644374438443944404441444244434444444544464447444844494450445144524453445444554456445744584459446044614462446344644465446644674468446944704471447244734474447544764477447844794480448144824483448444854486448744884489449044914492449344944495449644974498449945004501450245034504450545064507450845094510451145124513451445154516451745184519452045214522452345244525452645274528452945304531453245334534453545364537453845394540454145424543454445454546454745484549455045514552455345544555455645574558455945604561456245634564456545664567456845694570457145724573457445754576457745784579458045814582458345844585458645874588458945904591459245934594459545964597459845994600460146024603460446054606460746084609461046114612461346144615461646174618461946204621462246234624462546264627462846294630463146324633463446354636463746384639464046414642464346444645464646474648464946504651465246534654465546564657465846594660466146624663466446654666466746684669467046714672467346744675467646774678467946804681468246834684468546864687468846894690469146924693469446954696469746984699470047014702470347044705470647074708470947104711471247134714471547164717471847194720472147224723472447254726472747284729473047314732473347344735473647374738473947404741474247434744474547464747474847494750475147524753475447554756475747584759476047614762476347644765476647674768476947704771477247734774477547764777477847794780478147824783478447854786478747884789479047914792479347944795479647974798479948004801480248034804480548064807480848094810481148124813481448154816481748184819482048214822482348244825482648274828482948304831483248334834483548364837483848394840484148424843484448454846484748484849485048514852485348544855485648574858485948604861486248634864486548664867486848694870487148724873487448754876487748784879488048814882488348844885488648874888488948904891489248934894489548964897489848994900490149024903490449054906490749084909491049114912491349144915491649174918491949204921492249234924492549264927492849294930493149324933493449354936493749384939494049414942494349444945494649474948494949504951495249534954495549564957495849594960496149624963496449654966496749684969497049714972497349744975497649774978497949804981498249834984498549864987498849894990499149924993499449954996499749984999500050015002500350045005500650075008500950105011501250135014501550165017501850195020502150225023502450255026502750285029503050315032503350345035503650375038503950405041504250435044504550465047504850495050505150525053505450555056505750585059506050615062506350645065506650675068506950705071507250735074507550765077507850795080508150825083508450855086508750885089509050915092509350945095509650975098509951005101510251035104510551065107510851095110511151125113511451155116511751185119512051215122512351245125512651275128512951305131513251335134513551365137513851395140514151425143514451455146514751485149515051515152515351545155515651575158515951605161516251635164516551665167516851695170517151725173
  1. #if defined(SOKOL_IMPL) && !defined(SOKOL_DEBUGTEXT_IMPL)
  2. #define SOKOL_DEBUGTEXT_IMPL
  3. #endif
  4. #ifndef SOKOL_DEBUGTEXT_INCLUDED
  5. /*
  6. sokol_debugtext.h - simple ASCII debug text rendering on top of sokol_gfx.h
  7. Project URL: https://github.com/floooh/sokol
  8. Do this:
  9. #define SOKOL_IMPL or
  10. #define SOKOL_DEBUGTEXT_IMPL
  11. before you include this file in *one* C or C++ file to create the
  12. implementation.
  13. The following defines are used by the implementation to select the
  14. platform-specific embedded shader code (these are the same defines as
  15. used by sokol_gfx.h and sokol_app.h):
  16. SOKOL_GLCORE
  17. SOKOL_GLES3
  18. SOKOL_D3D11
  19. SOKOL_METAL
  20. SOKOL_WGPU
  21. SOKOL_VULKAN
  22. ...optionally provide the following macros to override defaults:
  23. SOKOL_VSNPRINTF - the function name of an alternative vsnprintf() function (default: vsnprintf)
  24. SOKOL_ASSERT(c) - your own assert macro (default: assert(c))
  25. SOKOL_DEBUGTEXT_API_DECL - public function declaration prefix (default: extern)
  26. SOKOL_API_DECL - same as SOKOL_DEBUGTEXT_API_DECL
  27. SOKOL_API_IMPL - public function implementation prefix (default: -)
  28. SOKOL_UNREACHABLE() - a guard macro for unreachable code (default: assert(false))
  29. If sokol_debugtext.h is compiled as a DLL, define the following before
  30. including the declaration or implementation:
  31. SOKOL_DLL
  32. On Windows, SOKOL_DLL will define SOKOL_DEBUGTEXT_API_DECL as __declspec(dllexport)
  33. or __declspec(dllimport) as needed.
  34. Include the following headers before including sokol_debugtext.h:
  35. sokol_gfx.h
  36. FEATURES AND CONCEPTS
  37. =====================
  38. - renders 8-bit ASCII text as fixed-size 8x8 pixel characters
  39. - comes with 6 embedded 8-bit home computer fonts (each taking up 2 KBytes)
  40. - easily plug in your own fonts
  41. - create multiple contexts for rendering text in different layers or render passes
  42. STEP BY STEP
  43. ============
  44. --- to initialize sokol-debugtext, call sdtx_setup() *after* initializing
  45. sokol-gfx:
  46. sdtx_setup(&(sdtx_desc_t){ ... });
  47. To see any warnings and errors, you should always install a logging callback.
  48. The easiest way is via sokol_log.h:
  49. #include "sokol_log.h"
  50. sdtx_setup(&(sdtx_desc_t){
  51. .logger.func = slog_func,
  52. });
  53. --- configure sokol-debugtext by populating the sdtx_desc_t struct:
  54. .context_pool_size (default: 8)
  55. The max number of text contexts that can be created.
  56. .printf_buf_size (default: 4096)
  57. The size of the internal text formatting buffer used by
  58. sdtx_printf() and sdtx_vprintf().
  59. .fonts (default: none)
  60. An array of sdtx_font_desc_t structs used to configure the
  61. fonts that can be used for rendering. To use all builtin
  62. fonts call sdtx_setup() like this (in C99):
  63. sdtx_setup(&(sdtx_desc_t){
  64. .fonts = {
  65. [0] = sdtx_font_kc853(),
  66. [1] = sdtx_font_kc854(),
  67. [2] = sdtx_font_z1013(),
  68. [3] = sdtx_font_cpc(),
  69. [4] = sdtx_font_c64(),
  70. [5] = sdtx_font_oric()
  71. }
  72. });
  73. For documentation on how to use you own font data, search
  74. below for "USING YOUR OWN FONT DATA".
  75. .context
  76. The setup parameters for the default text context. This will
  77. be active right after sdtx_setup(), or when calling
  78. sdtx_set_context(SDTX_DEFAULT_CONTEXT):
  79. .max_commands (default: 4096)
  80. The max number of render commands that can be recorded
  81. into the internal command buffer. This directly translates
  82. to the number of render layer changes in a single frame.
  83. .char_buf_size (default: 4096)
  84. The number of characters that can be rendered per frame in this
  85. context, defines the size of an internal fixed-size vertex
  86. buffer. Any additional characters will be silently ignored.
  87. .canvas_width (default: 640)
  88. .canvas_height (default: 480)
  89. The 'virtual canvas size' in pixels. This defines how big
  90. characters will be rendered relative to the default framebuffer
  91. dimensions. Each character occupies a grid of 8x8 'virtual canvas
  92. pixels' (so a virtual canvas size of 640x480 means that 80x60 characters
  93. fit on the screen). For rendering in a resizeable window, you
  94. should dynamically update the canvas size in each frame by
  95. calling sdtx_canvas(w, h).
  96. .tab_width (default: 4)
  97. The width of a tab character in number of character cells.
  98. .color_format (default: 0)
  99. .depth_format (default: 0)
  100. .sample_count (default: 0)
  101. The pixel format description for the default context needed
  102. for creating the context's sg_pipeline object. When
  103. rendering to the default framebuffer you can leave those
  104. zero-initialized, in this case the proper values will be
  105. filled in by sokol-gfx. You only need to provide non-default
  106. values here when rendering to render targets with different
  107. pixel format attributes than the default framebuffer.
  108. --- Before starting to render text, optionally call sdtx_canvas() to
  109. dynamically resize the virtual canvas. This is recommended when
  110. rendering to a resizeable window. The virtual canvas size can
  111. also be used to scale text in relation to the display resolution.
  112. Examples when using sokol-app:
  113. - to render characters at 8x8 'physical pixels':
  114. sdtx_canvas(sapp_width(), sapp_height());
  115. - to render characters at 16x16 physical pixels:
  116. sdtx_canvas(sapp_width()/2.0f, sapp_height()/2.0f);
  117. Do *not* use integer math here, since this will not look nice
  118. when the render target size isn't divisible by 2.
  119. --- Optionally define the origin for the character grid with:
  120. sdtx_origin(x, y);
  121. The provided coordinates are in character grid cells, not in
  122. virtual canvas pixels. E.g. to set the origin to 2 character tiles
  123. from the left and top border:
  124. sdtx_origin(2, 2);
  125. You can define fractions, e.g. to start rendering half
  126. a character tile from the top-left corner:
  127. sdtx_origin(0.5f, 0.5f);
  128. --- Optionally set a different font by calling:
  129. sdtx_font(font_index)
  130. sokol-debugtext provides 8 font slots which can be populated
  131. with the builtin fonts or with user-provided font data, so
  132. 'font_index' must be a number from 0 to 7.
  133. --- Position the text cursor with one of the following calls. All arguments
  134. are in character grid cells as floats and relative to the
  135. origin defined with sdtx_origin():
  136. sdtx_pos(x, y) - sets absolute cursor position
  137. sdtx_pos_x(x) - only set absolute x cursor position
  138. sdtx_pos_y(y) - only set absolute y cursor position
  139. sdtx_move(x, y) - move cursor relative in x and y direction
  140. sdtx_move_x(x) - move cursor relative only in x direction
  141. sdtx_move_y(y) - move cursor relative only in y direction
  142. sdtx_crlf() - set cursor to beginning of next line
  143. (same as sdtx_pos_x(0) + sdtx_move_y(1))
  144. sdtx_home() - resets the cursor to the origin
  145. (same as sdtx_pos(0, 0))
  146. --- Set a new text color with any of the following functions:
  147. sdtx_color3b(r, g, b) - RGB 0..255, A=255
  148. sdtx_color3f(r, g, b) - RGB 0.0f..1.0f, A=1.0f
  149. sdtx_color4b(r, g, b, a) - RGBA 0..255
  150. sdtx_color4f(r, g, b, a) - RGBA 0.0f..1.0f
  151. sdtx_color1i(uint32_t rgba) - ABGR (0xAABBGGRR)
  152. --- Output 8-bit ASCII text with the following functions:
  153. sdtx_putc(c) - output a single character
  154. sdtx_puts(str) - output a null-terminated C string, note that
  155. this will *not* append a newline (so it behaves
  156. differently than the CRT's puts() function)
  157. sdtx_putr(str, len) - 'put range' output the first 'len' characters of
  158. a C string or until the zero character is encountered
  159. sdtx_printf(fmt, ...) - output with printf-formatting, note that you
  160. can inject your own printf-compatible function
  161. by overriding the SOKOL_VSNPRINTF define before
  162. including the implementation
  163. sdtx_vprintf(fmt, args) - same as sdtx_printf() but with the arguments
  164. provided in a va_list
  165. - Note that the text will not yet be rendered, only recorded for rendering
  166. at a later time, the actual rendering happens when sdtx_draw() is called
  167. inside a sokol-gfx render pass.
  168. - This means also you can output text anywhere in the frame, it doesn't
  169. have to be inside a render pass.
  170. - Note that character codes <32 are reserved as control characters
  171. and won't render anything. Currently only the following control
  172. characters are implemented:
  173. \r - carriage return (same as sdtx_pos_x(0))
  174. \n - carriage return + line feed (same as stdx_crlf())
  175. \t - a tab character
  176. --- You can 'record' text into render layers, this allows to mix/interleave
  177. sokol-debugtext rendering with other rendering operations inside
  178. sokol-gfx render passes. To start recording text into a different render
  179. layer, call:
  180. sdtx_layer(int layer_id)
  181. ...outside a sokol-gfx render pass.
  182. --- finally, from within a sokol-gfx render pass, call:
  183. sdtx_draw()
  184. ...for non-layered rendering, or to draw a specific layer:
  185. sdtx_draw_layer(int layer_id)
  186. NOTE that sdtx_draw() is equivalent to:
  187. sdtx_draw_layer(0)
  188. ...so sdtx_draw() will *NOT* render all text layers, instead it will
  189. only render the 'default layer' 0.
  190. --- at the end of a frame (defined by the call to sg_commit()), sokol-debugtext
  191. will rewind all contexts:
  192. - the internal vertex index is set to 0
  193. - the internal command index is set to 0
  194. - the current layer id is set to 0
  195. - the current font is set to 0
  196. - the cursor position is reset
  197. RENDERING WITH MULTIPLE CONTEXTS
  198. ================================
  199. Use multiple text contexts if you need to render debug text in different
  200. sokol-gfx render passes, or want to render text to different layers
  201. in the same render pass, each with its own set of parameters.
  202. To create a new text context call:
  203. sdtx_context ctx = sdtx_make_context(&(sdtx_context_desc_t){ ... });
  204. The creation parameters in the sdtx_context_desc_t struct are the same
  205. as already described above in the sdtx_setup() function:
  206. .char_buf_size -- max number of characters rendered in one frame, default: 4096
  207. .canvas_width -- the initial virtual canvas width, default: 640
  208. .canvas_height -- the initial virtual canvas height, default: 400
  209. .tab_width -- tab width in number of characters, default: 4
  210. .color_format -- color pixel format of target render pass
  211. .depth_format -- depth pixel format of target render pass
  212. .sample_count -- MSAA sample count of target render pass
  213. To make a new context the active context, call:
  214. sdtx_set_context(ctx)
  215. ...and after that call the text output functions as described above, and
  216. finally, inside a sokol-gfx render pass, call sdtx_draw() to actually
  217. render the text for this context.
  218. A context keeps track of the following parameters:
  219. - the active font
  220. - the virtual canvas size
  221. - the origin position
  222. - the current cursor position
  223. - the current tab width
  224. - the current color
  225. - and the current layer-id
  226. You can get the currently active context with:
  227. sdtx_get_context()
  228. To make the default context current, call sdtx_set_context() with the
  229. special SDTX_DEFAULT_CONTEXT handle:
  230. sdtx_set_context(SDTX_DEFAULT_CONTEXT)
  231. Alternatively, use the function sdtx_default_context() to get the default
  232. context handle:
  233. sdtx_set_context(sdtx_default_context());
  234. To destroy a context, call:
  235. sdtx_destroy_context(ctx)
  236. If a context is set as active that no longer exists, all sokol-debugtext
  237. functions that require an active context will silently fail.
  238. You can directly draw the recorded text in a specific context without
  239. setting the active context:
  240. sdtx_context_draw(ctx)
  241. sdtx_context_draw_layer(ctx, layer_id)
  242. USING YOUR OWN FONT DATA
  243. ========================
  244. Instead of the built-in fonts you can also plug your own font data
  245. into sokol-debugtext by providing one or several sdtx_font_desc_t
  246. structures in the sdtx_setup call.
  247. For instance to use a built-in font at slot 0, and a user-font at
  248. font slot 1, the sdtx_setup() call might look like this:
  249. sdtx_setup(&sdtx_desc_t){
  250. .fonts = {
  251. [0] = sdtx_font_kc853(),
  252. [1] = {
  253. .data = {
  254. .ptr = my_font_data,
  255. .size = sizeof(my_font_data)
  256. },
  257. .first_char = ...,
  258. .last_char = ...
  259. }
  260. }
  261. });
  262. Where 'my_font_data' is a byte array where every character is described
  263. by 8 bytes arranged like this:
  264. bits
  265. 7 6 5 4 3 2 1 0
  266. . . . X X . . . byte 0: 0x18
  267. . . X X X X . . byte 1: 0x3C
  268. . X X . . X X . byte 2: 0x66
  269. . X X . . X X . byte 3: 0x66
  270. . X X X X X X . byte 4: 0x7E
  271. . X X . . X X . byte 5: 0x66
  272. . X X . . X X . byte 6: 0x66
  273. . . . . . . . . byte 7: 0x00
  274. A complete font consists of 256 characters, resulting in 2048 bytes for
  275. the font data array (but note that the character codes 0..31 will never
  276. be rendered).
  277. If you provide such a complete font data array, you can drop the .first_char
  278. and .last_char initialization parameters since those default to 0 and 255,
  279. note that you can also use the SDTX_RANGE() helper macro to build the
  280. .data item:
  281. sdtx_setup(&sdtx_desc_t){
  282. .fonts = {
  283. [0] = sdtx_font_kc853(),
  284. [1] = {
  285. .data = SDTX_RANGE(my_font_data)
  286. }
  287. }
  288. });
  289. If the font doesn't define all 256 character tiles, or you don't need an
  290. entire 256-character font and want to save a couple of bytes, use the
  291. .first_char and .last_char initialization parameters to define a sub-range.
  292. For instance if the font only contains the characters between the Space
  293. (ASCII code 32) and uppercase character 'Z' (ASCII code 90):
  294. sdtx_setup(&sdtx_desc_t){
  295. .fonts = {
  296. [0] = sdtx_font_kc853(),
  297. [1] = {
  298. .data = SDTX_RANGE(my_font_data),
  299. .first_char = 32, // could also write ' '
  300. .last_char = 90 // could also write 'Z'
  301. }
  302. }
  303. });
  304. Character tiles that haven't been defined in the font will be rendered
  305. as a solid 8x8 quad.
  306. MEMORY ALLOCATION OVERRIDE
  307. ==========================
  308. You can override the memory allocation functions at initialization time
  309. like this:
  310. void* my_alloc(size_t size, void* user_data) {
  311. return malloc(size);
  312. }
  313. void my_free(void* ptr, void* user_data) {
  314. free(ptr);
  315. }
  316. ...
  317. sdtx_setup(&(sdtx_desc_t){
  318. // ...
  319. .allocator = {
  320. .alloc_fn = my_alloc,
  321. .free_fn = my_free,
  322. .user_data = ...;
  323. }
  324. });
  325. ...
  326. If no overrides are provided, malloc and free will be used.
  327. ERROR REPORTING AND LOGGING
  328. ===========================
  329. To get any logging information at all you need to provide a logging callback in the setup call,
  330. the easiest way is to use sokol_log.h:
  331. #include "sokol_log.h"
  332. sdtx_setup(&(sdtx_desc_t){
  333. // ...
  334. .logger.func = slog_func
  335. });
  336. To override logging with your own callback, first write a logging function like this:
  337. void my_log(const char* tag, // e.g. 'sdtx'
  338. uint32_t log_level, // 0=panic, 1=error, 2=warn, 3=info
  339. uint32_t log_item_id, // SDTX_LOGITEM_*
  340. const char* message_or_null, // a message string, may be nullptr in release mode
  341. uint32_t line_nr, // line number in sokol_debugtext.h
  342. const char* filename_or_null, // source filename, may be nullptr in release mode
  343. void* user_data)
  344. {
  345. ...
  346. }
  347. ...and then setup sokol-debugtext like this:
  348. sdtx_setup(&(sdtx_desc_t){
  349. .logger = {
  350. .func = my_log,
  351. .user_data = my_user_data,
  352. }
  353. });
  354. The provided logging function must be reentrant (e.g. be callable from
  355. different threads).
  356. If you don't want to provide your own custom logger it is highly recommended to use
  357. the standard logger in sokol_log.h instead, otherwise you won't see any warnings or
  358. errors.
  359. LICENSE
  360. =======
  361. zlib/libpng license
  362. Copyright (c) 2020 Andre Weissflog
  363. This software is provided 'as-is', without any express or implied warranty.
  364. In no event will the authors be held liable for any damages arising from the
  365. use of this software.
  366. Permission is granted to anyone to use this software for any purpose,
  367. including commercial applications, and to alter it and redistribute it
  368. freely, subject to the following restrictions:
  369. 1. The origin of this software must not be misrepresented; you must not
  370. claim that you wrote the original software. If you use this software in a
  371. product, an acknowledgment in the product documentation would be
  372. appreciated but is not required.
  373. 2. Altered source versions must be plainly marked as such, and must not
  374. be misrepresented as being the original software.
  375. 3. This notice may not be removed or altered from any source
  376. distribution.
  377. */
  378. #define SOKOL_DEBUGTEXT_INCLUDED (1)
  379. #include <stdint.h>
  380. #include <stdbool.h>
  381. #include <stddef.h> // size_t
  382. #include <stdarg.h> // va_list
  383. #if !defined(SOKOL_GFX_INCLUDED)
  384. #error "Please include sokol_gfx.h before sokol_debugtext.h"
  385. #endif
  386. #if defined(SOKOL_API_DECL) && !defined(SOKOL_DEBUGTEXT_API_DECL)
  387. #define SOKOL_DEBUGTEXT_API_DECL SOKOL_API_DECL
  388. #endif
  389. #ifndef SOKOL_DEBUGTEXT_API_DECL
  390. #if defined(_WIN32) && defined(SOKOL_DLL) && defined(SOKOL_DEBUGTEXT_IMPL)
  391. #define SOKOL_DEBUGTEXT_API_DECL __declspec(dllexport)
  392. #elif defined(_WIN32) && defined(SOKOL_DLL)
  393. #define SOKOL_DEBUGTEXT_API_DECL __declspec(dllimport)
  394. #else
  395. #define SOKOL_DEBUGTEXT_API_DECL extern
  396. #endif
  397. #endif
  398. #if defined(__GNUC__)
  399. #define SOKOL_DEBUGTEXT_PRINTF_ATTR __attribute__((format(printf, 1, 2)))
  400. #else
  401. #define SOKOL_DEBUGTEXT_PRINTF_ATTR
  402. #endif
  403. #ifdef __cplusplus
  404. extern "C" {
  405. #endif
  406. /*
  407. sdtx_log_item_t
  408. Log items are defined via X-Macros, and expanded to an
  409. enum 'sdtx_log_item' - and in debug mode only - corresponding strings.
  410. Used as parameter in the logging callback.
  411. */
  412. #define _SDTX_LOG_ITEMS \
  413. _SDTX_LOGITEM_XMACRO(OK, "Ok") \
  414. _SDTX_LOGITEM_XMACRO(MALLOC_FAILED, "memory allocation failed") \
  415. _SDTX_LOGITEM_XMACRO(ADD_COMMIT_LISTENER_FAILED, "sg_add_commit_listener() failed") \
  416. _SDTX_LOGITEM_XMACRO(COMMAND_BUFFER_FULL, "command buffer full (adjust via sdtx_context_desc_t.max_commands)") \
  417. _SDTX_LOGITEM_XMACRO(CONTEXT_POOL_EXHAUSTED, "context pool exhausted (adjust via sdtx_desc_t.context_pool_size)") \
  418. _SDTX_LOGITEM_XMACRO(CANNOT_DESTROY_DEFAULT_CONTEXT, "cannot destroy default context") \
  419. #define _SDTX_LOGITEM_XMACRO(item,msg) SDTX_LOGITEM_##item,
  420. typedef enum sdtx_log_item_t {
  421. _SDTX_LOG_ITEMS
  422. } sdtx_log_item_t;
  423. #undef _SDTX_LOGITEM_XMACRO
  424. /*
  425. sdtx_logger_t
  426. Used in sdtx_desc_t to provide a custom logging and error reporting
  427. callback to sokol-debugtext.
  428. */
  429. typedef struct sdtx_logger_t {
  430. void (*func)(
  431. const char* tag, // always "sdtx"
  432. uint32_t log_level, // 0=panic, 1=error, 2=warning, 3=info
  433. uint32_t log_item_id, // SDTX_LOGITEM_*
  434. const char* message_or_null, // a message string, may be nullptr in release mode
  435. uint32_t line_nr, // line number in sokol_debugtext.h
  436. const char* filename_or_null, // source filename, may be nullptr in release mode
  437. void* user_data);
  438. void* user_data;
  439. } sdtx_logger_t;
  440. /* a rendering context handle */
  441. typedef struct sdtx_context { uint32_t id; } sdtx_context;
  442. /* the default context handle */
  443. static const sdtx_context SDTX_DEFAULT_CONTEXT = { 0x00010001 };
  444. /*
  445. sdtx_range is a pointer-size-pair struct used to pass memory
  446. blobs into sokol-debugtext. When initialized from a value type
  447. (array or struct), use the SDTX_RANGE() macro to build
  448. an sdtx_range struct.
  449. */
  450. typedef struct sdtx_range {
  451. const void* ptr;
  452. size_t size;
  453. } sdtx_range;
  454. // disabling this for every includer isn't great, but the warning is also quite pointless
  455. #if defined(_MSC_VER)
  456. #pragma warning(disable:4221) /* /W4 only: nonstandard extension used: 'x': cannot be initialized using address of automatic variable 'y' */
  457. #pragma warning(disable:4204) /* VS2015: nonstandard extension used: non-constant aggregate initializer */
  458. #endif
  459. #if defined(__cplusplus)
  460. #define SDTX_RANGE(x) sdtx_range{ &x, sizeof(x) }
  461. #else
  462. #define SDTX_RANGE(x) (sdtx_range){ &x, sizeof(x) }
  463. #endif
  464. /*
  465. sdtx_font_desc_t
  466. Describes the pixel data of a font. A font consists of up to
  467. 256 8x8 character tiles, where each character tile is described
  468. by 8 consecutive bytes, each byte describing 8 pixels.
  469. For instance the character 'A' could look like this (this is also
  470. how most home computers used to describe their fonts in ROM):
  471. bits
  472. 7 6 5 4 3 2 1 0
  473. . . . X X . . . byte 0: 0x18
  474. . . X X X X . . byte 1: 0x3C
  475. . X X . . X X . byte 2: 0x66
  476. . X X . . X X . byte 3: 0x66
  477. . X X X X X X . byte 4: 0x7E
  478. . X X . . X X . byte 5: 0x66
  479. . X X . . X X . byte 6: 0x66
  480. . . . . . . . . byte 7: 0x00
  481. */
  482. #define SDTX_MAX_FONTS (8)
  483. typedef struct sdtx_font_desc_t {
  484. sdtx_range data; // pointer to and size of font pixel data
  485. uint8_t first_char; // first character index in font pixel data
  486. uint8_t last_char; // last character index in font pixel data, inclusive (default: 255)
  487. } sdtx_font_desc_t;
  488. /*
  489. sdtx_context_desc_t
  490. Describes the initialization parameters of a rendering context. Creating
  491. additional rendering contexts is useful if you want to render in
  492. different sokol-gfx rendering passes, or when rendering several layers
  493. of text.
  494. */
  495. typedef struct sdtx_context_desc_t {
  496. int max_commands; // max number of draw commands, each layer transition counts as a command, default: 4096
  497. int char_buf_size; // max number of characters rendered in one frame, default: 4096
  498. float canvas_width; // the initial virtual canvas width, default: 640
  499. float canvas_height; // the initial virtual canvas height, default: 400
  500. int tab_width; // tab width in number of characters, default: 4
  501. sg_pixel_format color_format; // color pixel format of target render pass
  502. sg_pixel_format depth_format; // depth pixel format of target render pass
  503. int sample_count; // MSAA sample count of target render pass
  504. } sdtx_context_desc_t;
  505. /*
  506. sdtx_allocator_t
  507. Used in sdtx_desc_t to provide custom memory-alloc and -free functions
  508. to sokol_debugtext.h. If memory management should be overridden, both the
  509. alloc_fn and free_fn function must be provided (e.g. it's not valid to
  510. override one function but not the other).
  511. */
  512. typedef struct sdtx_allocator_t {
  513. void* (*alloc_fn)(size_t size, void* user_data);
  514. void (*free_fn)(void* ptr, void* user_data);
  515. void* user_data;
  516. } sdtx_allocator_t;
  517. /*
  518. sdtx_desc_t
  519. Describes the sokol-debugtext API initialization parameters. Passed
  520. to the sdtx_setup() function.
  521. NOTE: to populate the fonts item array with builtin fonts, use any
  522. of the following functions:
  523. sdtx_font_kc853()
  524. sdtx_font_kc854()
  525. sdtx_font_z1013()
  526. sdtx_font_cpc()
  527. sdtx_font_c64()
  528. sdtx_font_oric()
  529. */
  530. typedef struct sdtx_desc_t {
  531. int context_pool_size; // max number of rendering contexts that can be created, default: 8
  532. int printf_buf_size; // size of internal buffer for snprintf(), default: 4096
  533. sdtx_font_desc_t fonts[SDTX_MAX_FONTS]; // up to 8 fonts descriptions
  534. sdtx_context_desc_t context; // the default context creation parameters
  535. sdtx_allocator_t allocator; // optional memory allocation overrides (default: malloc/free)
  536. sdtx_logger_t logger; // optional log override function (default: NO LOGGING)
  537. } sdtx_desc_t;
  538. /* initialization/shutdown */
  539. SOKOL_DEBUGTEXT_API_DECL void sdtx_setup(const sdtx_desc_t* desc);
  540. SOKOL_DEBUGTEXT_API_DECL void sdtx_shutdown(void);
  541. /* builtin font data (use to populate sdtx_desc.font[]) */
  542. SOKOL_DEBUGTEXT_API_DECL sdtx_font_desc_t sdtx_font_kc853(void);
  543. SOKOL_DEBUGTEXT_API_DECL sdtx_font_desc_t sdtx_font_kc854(void);
  544. SOKOL_DEBUGTEXT_API_DECL sdtx_font_desc_t sdtx_font_z1013(void);
  545. SOKOL_DEBUGTEXT_API_DECL sdtx_font_desc_t sdtx_font_cpc(void);
  546. SOKOL_DEBUGTEXT_API_DECL sdtx_font_desc_t sdtx_font_c64(void);
  547. SOKOL_DEBUGTEXT_API_DECL sdtx_font_desc_t sdtx_font_oric(void);
  548. /* context functions */
  549. SOKOL_DEBUGTEXT_API_DECL sdtx_context sdtx_make_context(const sdtx_context_desc_t* desc);
  550. SOKOL_DEBUGTEXT_API_DECL void sdtx_destroy_context(sdtx_context ctx);
  551. SOKOL_DEBUGTEXT_API_DECL void sdtx_set_context(sdtx_context ctx);
  552. SOKOL_DEBUGTEXT_API_DECL sdtx_context sdtx_get_context(void);
  553. SOKOL_DEBUGTEXT_API_DECL sdtx_context sdtx_default_context(void);
  554. /* drawing functions (call inside sokol-gfx render pass) */
  555. SOKOL_DEBUGTEXT_API_DECL void sdtx_draw(void);
  556. SOKOL_DEBUGTEXT_API_DECL void sdtx_context_draw(sdtx_context ctx);
  557. SOKOL_DEBUGTEXT_API_DECL void sdtx_draw_layer(int layer_id);
  558. SOKOL_DEBUGTEXT_API_DECL void sdtx_context_draw_layer(sdtx_context ctx, int layer_id);
  559. /* switch render layer */
  560. SOKOL_DEBUGTEXT_API_DECL void sdtx_layer(int layer_id);
  561. /* switch to a different font */
  562. SOKOL_DEBUGTEXT_API_DECL void sdtx_font(int font_index);
  563. /* set a new virtual canvas size in screen pixels */
  564. SOKOL_DEBUGTEXT_API_DECL void sdtx_canvas(float w, float h);
  565. /* set a new origin in character grid coordinates */
  566. SOKOL_DEBUGTEXT_API_DECL void sdtx_origin(float x, float y);
  567. /* cursor movement functions (relative to origin in character grid coordinates) */
  568. SOKOL_DEBUGTEXT_API_DECL void sdtx_home(void);
  569. SOKOL_DEBUGTEXT_API_DECL void sdtx_pos(float x, float y);
  570. SOKOL_DEBUGTEXT_API_DECL void sdtx_pos_x(float x);
  571. SOKOL_DEBUGTEXT_API_DECL void sdtx_pos_y(float y);
  572. SOKOL_DEBUGTEXT_API_DECL void sdtx_move(float dx, float dy);
  573. SOKOL_DEBUGTEXT_API_DECL void sdtx_move_x(float dx);
  574. SOKOL_DEBUGTEXT_API_DECL void sdtx_move_y(float dy);
  575. SOKOL_DEBUGTEXT_API_DECL void sdtx_crlf(void);
  576. /* set the current text color */
  577. SOKOL_DEBUGTEXT_API_DECL void sdtx_color3b(uint8_t r, uint8_t g, uint8_t b); // RGB 0..255, A=255
  578. SOKOL_DEBUGTEXT_API_DECL void sdtx_color3f(float r, float g, float b); // RGB 0.0f..1.0f, A=1.0f
  579. SOKOL_DEBUGTEXT_API_DECL void sdtx_color4b(uint8_t r, uint8_t g, uint8_t b, uint8_t a); // RGBA 0..255
  580. SOKOL_DEBUGTEXT_API_DECL void sdtx_color4f(float r, float g, float b, float a); // RGBA 0.0f..1.0f
  581. SOKOL_DEBUGTEXT_API_DECL void sdtx_color1i(uint32_t rgba); // ABGR 0xAABBGGRR
  582. /* text rendering */
  583. SOKOL_DEBUGTEXT_API_DECL void sdtx_putc(char c);
  584. SOKOL_DEBUGTEXT_API_DECL void sdtx_puts(const char* str); // does NOT append newline!
  585. SOKOL_DEBUGTEXT_API_DECL void sdtx_putr(const char* str, int len); // 'put range', also stops at zero-char
  586. SOKOL_DEBUGTEXT_API_DECL int sdtx_printf(const char* fmt, ...) SOKOL_DEBUGTEXT_PRINTF_ATTR;
  587. SOKOL_DEBUGTEXT_API_DECL int sdtx_vprintf(const char* fmt, va_list args);
  588. /* language bindings helper: get the internal printf format buffer */
  589. SOKOL_DEBUGTEXT_API_DECL sdtx_range sdtx_get_cleared_fmt_buffer(void);
  590. #ifdef __cplusplus
  591. } /* extern "C" */
  592. /* C++ const-ref wrappers */
  593. inline void sdtx_setup(const sdtx_desc_t& desc) { return sdtx_setup(&desc); }
  594. inline sdtx_context sdtx_make_context(const sdtx_context_desc_t& desc) { return sdtx_make_context(&desc); }
  595. #endif
  596. #endif /* SOKOL_DEBUGTEXT_INCLUDED */
  597. // ██ ███ ███ ██████ ██ ███████ ███ ███ ███████ ███ ██ ████████ █████ ████████ ██ ██████ ███ ██
  598. // ██ ████ ████ ██ ██ ██ ██ ████ ████ ██ ████ ██ ██ ██ ██ ██ ██ ██ ██ ████ ██
  599. // ██ ██ ████ ██ ██████ ██ █████ ██ ████ ██ █████ ██ ██ ██ ██ ███████ ██ ██ ██ ██ ██ ██ ██
  600. // ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██
  601. // ██ ██ ██ ██ ███████ ███████ ██ ██ ███████ ██ ████ ██ ██ ██ ██ ██ ██████ ██ ████
  602. //
  603. // >>implementation
  604. #ifdef SOKOL_DEBUGTEXT_IMPL
  605. #define SOKOL_DEBUGTEXT_IMPL_INCLUDED (1)
  606. #if defined(SOKOL_MALLOC) || defined(SOKOL_CALLOC) || defined(SOKOL_FREE)
  607. #error "SOKOL_MALLOC/CALLOC/FREE macros are no longer supported, please use sdtx_desc_t.allocator to override memory allocation functions"
  608. #endif
  609. #include <string.h> // memset
  610. #include <math.h> // fmodf
  611. #include <stdarg.h> // for vsnprintf
  612. #include <stdlib.h> // malloc/free
  613. #ifndef SOKOL_API_IMPL
  614. #define SOKOL_API_IMPL
  615. #endif
  616. #ifndef SOKOL_DEBUG
  617. #ifndef NDEBUG
  618. #define SOKOL_DEBUG
  619. #endif
  620. #endif
  621. #ifndef SOKOL_ASSERT
  622. #include <assert.h>
  623. #define SOKOL_ASSERT(c) assert(c)
  624. #endif
  625. #ifndef SOKOL_UNREACHABLE
  626. #define SOKOL_UNREACHABLE SOKOL_ASSERT(false)
  627. #endif
  628. #ifndef _SOKOL_UNUSED
  629. #define _SOKOL_UNUSED(x) (void)(x)
  630. #endif
  631. #ifndef SOKOL_VSNPRINTF
  632. #include <stdio.h>
  633. #define SOKOL_VSNPRINTF vsnprintf
  634. #endif
  635. #define _sdtx_def(val, def) (((val) == 0) ? (def) : (val))
  636. #define _SDTX_INIT_COOKIE (0xACBAABCA)
  637. #define _SDTX_DEFAULT_MAX_COMMANDS (4096)
  638. #define _SDTX_DEFAULT_CONTEXT_POOL_SIZE (8)
  639. #define _SDTX_DEFAULT_CHAR_BUF_SIZE (4096)
  640. #define _SDTX_DEFAULT_PRINTF_BUF_SIZE (4096)
  641. #define _SDTX_DEFAULT_CANVAS_WIDTH (640)
  642. #define _SDTX_DEFAULT_CANVAS_HEIGHT (480)
  643. #define _SDTX_DEFAULT_TAB_WIDTH (4)
  644. #define _SDTX_DEFAULT_COLOR (0xFF00FFFF)
  645. #define _SDTX_INVALID_SLOT_INDEX (0)
  646. #define _SDTX_SLOT_SHIFT (16)
  647. #define _SDTX_MAX_POOL_SIZE (1<<_SDTX_SLOT_SHIFT)
  648. #define _SDTX_SLOT_MASK (_SDTX_MAX_POOL_SIZE-1)
  649. /* embedded font data */
  650. static const uint8_t _sdtx_font_kc853[2048] = {
  651. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x81, 0xFF, // 00
  652. 0x00, 0x00, 0x22, 0x72, 0x22, 0x3E, 0x00, 0x00, // 01
  653. 0x00, 0x00, 0x12, 0x32, 0x7E, 0x32, 0x12, 0x00, // 02
  654. 0x7E, 0x81, 0xB9, 0xA5, 0xB9, 0xA5, 0xB9, 0x81, // 03
  655. 0x55, 0xFF, 0x55, 0xFF, 0x55, 0xFF, 0x55, 0xFF, // 04
  656. 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, // 05
  657. 0xFF, 0x00, 0xFF, 0x00, 0xFF, 0x00, 0xFF, 0x00, // 06
  658. 0x00, 0x00, 0x3C, 0x42, 0x42, 0x7E, 0x00, 0x00, // 07
  659. 0x00, 0x10, 0x30, 0x7E, 0x30, 0x10, 0x00, 0x00, // 08
  660. 0x00, 0x08, 0x0C, 0x7E, 0x0C, 0x08, 0x00, 0x00, // 09
  661. 0x00, 0x10, 0x10, 0x10, 0x7C, 0x38, 0x10, 0x00, // 0A
  662. 0x08, 0x1C, 0x3E, 0x08, 0x08, 0x08, 0x08, 0x00, // 0B
  663. 0x38, 0x30, 0x28, 0x08, 0x08, 0x08, 0x3E, 0x00, // 0C
  664. 0x00, 0x00, 0x12, 0x32, 0x7E, 0x30, 0x10, 0x00, // 0D
  665. 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, // 0E
  666. 0x3E, 0x7C, 0x7C, 0x3E, 0x3E, 0x7C, 0xF8, 0xF8, // 0F
  667. 0x38, 0x30, 0x28, 0x04, 0x04, 0x04, 0x04, 0x00, // 10
  668. 0x7F, 0x08, 0x1C, 0x2A, 0x08, 0x08, 0x08, 0x00, // 11
  669. 0x00, 0x08, 0x08, 0x08, 0x2A, 0x1C, 0x08, 0x7F, // 12
  670. 0x7E, 0x81, 0x9D, 0xA1, 0xB9, 0x85, 0x85, 0xB9, // 13
  671. 0x00, 0x3C, 0x42, 0x5A, 0x5A, 0x42, 0x3C, 0x00, // 14
  672. 0x88, 0x44, 0x22, 0x11, 0x88, 0x44, 0x22, 0x11, // 15
  673. 0x00, 0x7F, 0x22, 0x72, 0x27, 0x22, 0x7F, 0x00, // 16
  674. 0x11, 0x22, 0x44, 0x88, 0x11, 0x22, 0x44, 0x88, // 17
  675. 0x00, 0x01, 0x09, 0x0D, 0x7F, 0x0D, 0x09, 0x01, // 18
  676. 0x00, 0x90, 0xB0, 0xFE, 0xB0, 0x90, 0x00, 0x00, // 19
  677. 0x00, 0x08, 0x7C, 0x06, 0x7C, 0x08, 0x00, 0x00, // 1A
  678. 0xCC, 0xCC, 0x33, 0x33, 0xCC, 0xCC, 0x33, 0x33, // 1B
  679. 0x7E, 0x81, 0xA1, 0xA1, 0xA1, 0xA1, 0xBD, 0x81, // 1C
  680. 0x7E, 0x81, 0xB9, 0xA5, 0xB9, 0xA5, 0xA5, 0x81, // 1D
  681. 0x7E, 0x81, 0x99, 0xA1, 0xA1, 0xA1, 0x99, 0x81, // 1E
  682. 0x00, 0x10, 0x3E, 0x60, 0x3E, 0x10, 0x00, 0x00, // 1F
  683. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 20
  684. 0x00, 0x18, 0x18, 0x18, 0x18, 0x00, 0x18, 0x00, // 21
  685. 0x00, 0x66, 0x66, 0xCC, 0x00, 0x00, 0x00, 0x00, // 22
  686. 0x00, 0x36, 0x7F, 0x36, 0x36, 0x7F, 0x36, 0x00, // 23
  687. 0x18, 0x3E, 0x6C, 0x3E, 0x1B, 0x1B, 0x7E, 0x18, // 24
  688. 0x00, 0x63, 0x66, 0x0C, 0x18, 0x36, 0x66, 0x00, // 25
  689. 0x18, 0x24, 0x28, 0x11, 0x2A, 0x44, 0x4A, 0x31, // 26
  690. 0x00, 0x18, 0x18, 0x30, 0x00, 0x00, 0x00, 0x00, // 27
  691. 0x00, 0x18, 0x30, 0x30, 0x30, 0x30, 0x18, 0x00, // 28
  692. 0x00, 0x18, 0x0C, 0x0C, 0x0C, 0x0C, 0x18, 0x00, // 29
  693. 0x00, 0x00, 0x24, 0x18, 0x7E, 0x18, 0x24, 0x00, // 2A
  694. 0x00, 0x00, 0x18, 0x18, 0x7E, 0x18, 0x18, 0x00, // 2B
  695. 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x30, 0x00, // 2C
  696. 0x00, 0x00, 0x00, 0x00, 0x3E, 0x00, 0x00, 0x00, // 2D
  697. 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, // 2E
  698. 0x06, 0x0C, 0x18, 0x30, 0x60, 0xC0, 0x00, 0x00, // 2F
  699. 0x00, 0x3C, 0x6E, 0x6E, 0x76, 0x76, 0x3C, 0x00, // 30
  700. 0x00, 0x1C, 0x3C, 0x0C, 0x0C, 0x0C, 0x3E, 0x00, // 31
  701. 0x00, 0x3C, 0x66, 0x06, 0x3C, 0x60, 0x7E, 0x00, // 32
  702. 0x00, 0x3C, 0x66, 0x0C, 0x06, 0x66, 0x3C, 0x00, // 33
  703. 0x00, 0x3C, 0x6C, 0xCC, 0xFE, 0x0C, 0x0C, 0x00, // 34
  704. 0x00, 0x7E, 0x60, 0x7C, 0x06, 0x66, 0x3C, 0x00, // 35
  705. 0x00, 0x3C, 0x60, 0x7C, 0x66, 0x66, 0x3C, 0x00, // 36
  706. 0x00, 0x7E, 0x06, 0x0C, 0x18, 0x30, 0x60, 0x00, // 37
  707. 0x00, 0x3C, 0x66, 0x3C, 0x66, 0x66, 0x3C, 0x00, // 38
  708. 0x00, 0x3C, 0x66, 0x66, 0x3E, 0x06, 0x3C, 0x00, // 39
  709. 0x00, 0x00, 0x18, 0x18, 0x00, 0x18, 0x18, 0x00, // 3A
  710. 0x00, 0x00, 0x18, 0x00, 0x18, 0x18, 0x30, 0x00, // 3B
  711. 0x00, 0x00, 0x18, 0x30, 0x60, 0x30, 0x18, 0x00, // 3C
  712. 0x00, 0x00, 0x00, 0x3E, 0x00, 0x3E, 0x00, 0x00, // 3D
  713. 0x00, 0x00, 0x30, 0x18, 0x0C, 0x18, 0x30, 0x00, // 3E
  714. 0x00, 0x3C, 0x66, 0x06, 0x1C, 0x18, 0x00, 0x18, // 3F
  715. 0x3C, 0x42, 0x81, 0x35, 0x49, 0x49, 0x49, 0x36, // 40
  716. 0x00, 0x3C, 0x66, 0x66, 0x7E, 0x66, 0x66, 0x00, // 41
  717. 0x00, 0x7C, 0x66, 0x7C, 0x66, 0x66, 0x7C, 0x00, // 42
  718. 0x00, 0x3C, 0x66, 0x60, 0x60, 0x66, 0x3C, 0x00, // 43
  719. 0x00, 0x7C, 0x66, 0x66, 0x66, 0x66, 0x7C, 0x00, // 44
  720. 0x00, 0x7E, 0x60, 0x7C, 0x60, 0x60, 0x7E, 0x00, // 45
  721. 0x00, 0x7E, 0x60, 0x7C, 0x60, 0x60, 0x60, 0x00, // 46
  722. 0x00, 0x3C, 0x66, 0x60, 0x6E, 0x66, 0x3C, 0x00, // 47
  723. 0x00, 0x66, 0x66, 0x7E, 0x66, 0x66, 0x66, 0x00, // 48
  724. 0x00, 0x3C, 0x18, 0x18, 0x18, 0x18, 0x3C, 0x00, // 49
  725. 0x00, 0x1E, 0x0C, 0x0C, 0x0C, 0x6C, 0x38, 0x00, // 4A
  726. 0x00, 0x66, 0x6C, 0x78, 0x6C, 0x66, 0x63, 0x00, // 4B
  727. 0x00, 0x60, 0x60, 0x60, 0x60, 0x60, 0x7E, 0x00, // 4C
  728. 0x00, 0x63, 0x77, 0x6B, 0x63, 0x63, 0x63, 0x00, // 4D
  729. 0x00, 0x63, 0x73, 0x6B, 0x67, 0x63, 0x63, 0x00, // 4E
  730. 0x00, 0x3C, 0x66, 0x66, 0x66, 0x66, 0x3C, 0x00, // 4F
  731. 0x00, 0x7C, 0x66, 0x7C, 0x60, 0x60, 0x60, 0x00, // 50
  732. 0x00, 0x3C, 0x66, 0x66, 0x6E, 0x66, 0x3A, 0x01, // 51
  733. 0x00, 0x7C, 0x66, 0x7C, 0x6C, 0x66, 0x63, 0x00, // 52
  734. 0x00, 0x3C, 0x60, 0x3C, 0x06, 0x66, 0x3C, 0x00, // 53
  735. 0x00, 0x7E, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, // 54
  736. 0x00, 0x66, 0x66, 0x66, 0x66, 0x66, 0x3C, 0x00, // 55
  737. 0x00, 0x66, 0x66, 0x66, 0x66, 0x3C, 0x18, 0x00, // 56
  738. 0x00, 0x63, 0x63, 0x6B, 0x6B, 0x7F, 0x36, 0x00, // 57
  739. 0x00, 0x66, 0x3C, 0x18, 0x18, 0x3C, 0x66, 0x00, // 58
  740. 0x00, 0x66, 0x3C, 0x18, 0x18, 0x18, 0x18, 0x00, // 59
  741. 0x00, 0x7E, 0x0C, 0x18, 0x30, 0x60, 0x7E, 0x00, // 5A
  742. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // 5B
  743. 0x00, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, // 5C
  744. 0x00, 0x7E, 0x06, 0x06, 0x00, 0x00, 0x00, 0x00, // 5D
  745. 0x00, 0x00, 0x00, 0x08, 0x1C, 0x36, 0x00, 0x00, // 5E
  746. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, // 5F
  747. 0x7E, 0x81, 0x99, 0xA1, 0xA1, 0x99, 0x81, 0x7E, // 60
  748. 0x00, 0x00, 0x3C, 0x66, 0x66, 0x66, 0x3B, 0x00, // 61
  749. 0x00, 0x60, 0x60, 0x78, 0x6C, 0x6C, 0x78, 0x00, // 62
  750. 0x00, 0x00, 0x3C, 0x66, 0x60, 0x66, 0x3C, 0x00, // 63
  751. 0x00, 0x06, 0x06, 0x1E, 0x36, 0x36, 0x1E, 0x00, // 64
  752. 0x00, 0x00, 0x38, 0x6C, 0x7C, 0x60, 0x38, 0x00, // 65
  753. 0x00, 0x1E, 0x18, 0x7E, 0x18, 0x18, 0x18, 0x00, // 66
  754. 0x00, 0x00, 0x3C, 0x66, 0x66, 0x3F, 0x06, 0x3C, // 67
  755. 0x00, 0x60, 0x60, 0x6C, 0x76, 0x66, 0x66, 0x00, // 68
  756. 0x00, 0x18, 0x00, 0x18, 0x18, 0x18, 0x18, 0x00, // 69
  757. 0x00, 0x18, 0x00, 0x38, 0x18, 0x18, 0x18, 0x30, // 6A
  758. 0x00, 0x60, 0x66, 0x6C, 0x78, 0x6C, 0x66, 0x00, // 6B
  759. 0x00, 0x30, 0x30, 0x30, 0x30, 0x30, 0x18, 0x00, // 6C
  760. 0x00, 0x00, 0x36, 0x7F, 0x6B, 0x63, 0x63, 0x00, // 6D
  761. 0x00, 0x00, 0x7C, 0x66, 0x66, 0x66, 0x66, 0x00, // 6E
  762. 0x00, 0x00, 0x3C, 0x66, 0x66, 0x66, 0x3C, 0x00, // 6F
  763. 0x00, 0x00, 0x7C, 0x66, 0x66, 0x7C, 0x60, 0x60, // 70
  764. 0x00, 0x00, 0x3C, 0x66, 0x66, 0x3E, 0x06, 0x06, // 71
  765. 0x00, 0x00, 0x36, 0x38, 0x30, 0x30, 0x30, 0x00, // 72
  766. 0x00, 0x00, 0x1C, 0x30, 0x1C, 0x06, 0x3C, 0x00, // 73
  767. 0x00, 0x18, 0x18, 0x3C, 0x18, 0x18, 0x0C, 0x00, // 74
  768. 0x00, 0x00, 0x66, 0x66, 0x66, 0x66, 0x3C, 0x00, // 75
  769. 0x00, 0x00, 0x66, 0x66, 0x3C, 0x3C, 0x18, 0x00, // 76
  770. 0x00, 0x00, 0x63, 0x63, 0x6B, 0x7F, 0x36, 0x00, // 77
  771. 0x00, 0x00, 0x66, 0x3C, 0x18, 0x3C, 0x66, 0x00, // 78
  772. 0x00, 0x00, 0x66, 0x3C, 0x18, 0x30, 0x60, 0x00, // 79
  773. 0x00, 0x00, 0x7E, 0x0C, 0x18, 0x30, 0x7E, 0x00, // 7A
  774. 0x66, 0x00, 0x3C, 0x66, 0x66, 0x66, 0x3B, 0x00, // 7B
  775. 0x66, 0x00, 0x3C, 0x66, 0x66, 0x66, 0x3C, 0x00, // 7C
  776. 0x66, 0x00, 0x66, 0x66, 0x66, 0x66, 0x3C, 0x00, // 7D
  777. 0x00, 0x38, 0x6C, 0x78, 0x6C, 0x78, 0x60, 0x60, // 7E
  778. 0xFF, 0x81, 0x81, 0x81, 0x81, 0x81, 0x81, 0xFF, // 7F
  779. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x7E, 0x00, // 80
  780. 0xFF, 0xFF, 0xDD, 0x8D, 0xDD, 0xC1, 0xFF, 0xFF, // 81
  781. 0xFF, 0xFF, 0xED, 0xCD, 0x81, 0xCD, 0xED, 0xFF, // 82
  782. 0x81, 0x7E, 0x46, 0x5A, 0x46, 0x5A, 0x46, 0x7E, // 83
  783. 0xAA, 0x00, 0xAA, 0x00, 0xAA, 0x00, 0xAA, 0x00, // 84
  784. 0x55, 0x55, 0x55, 0x55, 0x55, 0x55, 0x55, 0x55, // 85
  785. 0x00, 0xFF, 0x00, 0xFF, 0x00, 0xFF, 0x00, 0xFF, // 86
  786. 0xFF, 0xFF, 0xC3, 0xBD, 0xBD, 0x81, 0xFF, 0xFF, // 87
  787. 0xFF, 0xEF, 0xCF, 0x81, 0xCF, 0xEF, 0xFF, 0xFF, // 88
  788. 0xFF, 0xF7, 0xF3, 0x81, 0xF3, 0xF7, 0xFF, 0xFF, // 89
  789. 0xFF, 0xEF, 0xEF, 0xEF, 0x83, 0xC7, 0xEF, 0xFF, // 8A
  790. 0xF7, 0xE3, 0xC1, 0xF7, 0xF7, 0xF7, 0xF7, 0xFF, // 8B
  791. 0xC7, 0xCF, 0xD7, 0xF7, 0xF7, 0xF7, 0xC1, 0xFF, // 8C
  792. 0xFF, 0xFF, 0xED, 0xCD, 0x81, 0xCF, 0xEF, 0xFF, // 8D
  793. 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, // 8E
  794. 0xC1, 0x83, 0x83, 0xC1, 0xC1, 0x83, 0x07, 0x07, // 8F
  795. 0xC7, 0xCF, 0xD7, 0xFB, 0xFB, 0xFB, 0xFB, 0xFF, // 90
  796. 0x80, 0xF7, 0xE3, 0xD5, 0xF7, 0xF7, 0xF7, 0xFF, // 91
  797. 0xFF, 0xF7, 0xF7, 0xF7, 0xD5, 0xE3, 0xF7, 0x80, // 92
  798. 0x81, 0x7E, 0x62, 0x5E, 0x46, 0x7A, 0x7A, 0x46, // 93
  799. 0xFF, 0xC3, 0xBD, 0xA5, 0xA5, 0xBD, 0xC3, 0xFF, // 94
  800. 0x77, 0xBB, 0xDD, 0xEE, 0x77, 0xBB, 0xDD, 0xEE, // 95
  801. 0xFF, 0x80, 0xDD, 0x8D, 0xD8, 0xDD, 0x80, 0xFF, // 96
  802. 0xEE, 0xDD, 0xBB, 0x77, 0xEE, 0xDD, 0xBB, 0x77, // 97
  803. 0xFF, 0xFE, 0xF6, 0xF2, 0x80, 0xF2, 0xF6, 0xFE, // 98
  804. 0xFF, 0x6F, 0x4F, 0x01, 0x4F, 0x6F, 0xFF, 0xFF, // 99
  805. 0xFF, 0xF7, 0x83, 0xF9, 0x83, 0xF7, 0xFF, 0xFF, // 9A
  806. 0x33, 0x33, 0xCC, 0xCC, 0x33, 0x33, 0xCC, 0xCC, // 9B
  807. 0x81, 0x7E, 0x5E, 0x5E, 0x5E, 0x5E, 0x42, 0x7E, // 9C
  808. 0x81, 0x7E, 0x46, 0x5A, 0x46, 0x5A, 0x5A, 0x7E, // 9D
  809. 0x81, 0x7E, 0x66, 0x5E, 0x5E, 0x5E, 0x66, 0x7E, // 9E
  810. 0xFF, 0xEF, 0xC1, 0x9F, 0xC1, 0xEF, 0xFF, 0xFF, // 9F
  811. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // A0
  812. 0xFF, 0xE7, 0xE7, 0xE7, 0xE7, 0xFF, 0xE7, 0xFF, // A1
  813. 0xFF, 0x99, 0x99, 0x33, 0xFF, 0xFF, 0xFF, 0xFF, // A2
  814. 0xFF, 0xC9, 0x80, 0xC9, 0xC9, 0x80, 0xC9, 0xFF, // A3
  815. 0xE7, 0xC1, 0x93, 0xC1, 0xE4, 0xE4, 0x81, 0xE7, // A4
  816. 0xFF, 0x9C, 0x99, 0xF3, 0xE7, 0xC9, 0x99, 0xFF, // A5
  817. 0xE7, 0xDB, 0xD7, 0xEE, 0xD5, 0xBB, 0xB5, 0xCE, // A6
  818. 0xFF, 0xE7, 0xE7, 0xCF, 0xFF, 0xFF, 0xFF, 0xFF, // A7
  819. 0xFF, 0xE7, 0xCF, 0xCF, 0xCF, 0xCF, 0xE7, 0xFF, // A8
  820. 0xFF, 0xE7, 0xF3, 0xF3, 0xF3, 0xF3, 0xE7, 0xFF, // A9
  821. 0xFF, 0xFF, 0xDB, 0xE7, 0x81, 0xE7, 0xDB, 0xFF, // AA
  822. 0xFF, 0xFF, 0xE7, 0xE7, 0x81, 0xE7, 0xE7, 0xFF, // AB
  823. 0xFF, 0xFF, 0xFF, 0xFF, 0xE7, 0xE7, 0xCF, 0xFF, // AC
  824. 0xFF, 0xFF, 0xFF, 0xFF, 0xC1, 0xFF, 0xFF, 0xFF, // AD
  825. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xE7, 0xE7, 0xFF, // AE
  826. 0xF9, 0xF3, 0xE7, 0xCF, 0x9F, 0x3F, 0xFF, 0xFF, // AF
  827. 0xFF, 0xC3, 0x91, 0x91, 0x89, 0x89, 0xC3, 0xFF, // B0
  828. 0xFF, 0xE3, 0xC3, 0xF3, 0xF3, 0xF3, 0xC1, 0xFF, // B1
  829. 0xFF, 0xC3, 0x99, 0xF9, 0xC3, 0x9F, 0x81, 0xFF, // B2
  830. 0xFF, 0xC3, 0x99, 0xF3, 0xF9, 0x99, 0xC3, 0xFF, // B3
  831. 0xFF, 0xC3, 0x93, 0x33, 0x01, 0xF3, 0xF3, 0xFF, // B4
  832. 0xFF, 0x81, 0x9F, 0x83, 0xF9, 0x99, 0xC3, 0xFF, // B5
  833. 0xFF, 0xC3, 0x9F, 0x83, 0x99, 0x99, 0xC3, 0xFF, // B6
  834. 0xFF, 0x81, 0xF9, 0xF3, 0xE7, 0xCF, 0x9F, 0xFF, // B7
  835. 0xFF, 0xC3, 0x99, 0xC3, 0x99, 0x99, 0xC3, 0xFF, // B8
  836. 0xFF, 0xC3, 0x99, 0x99, 0xC1, 0xF9, 0xC3, 0xFF, // B9
  837. 0xFF, 0xFF, 0xE7, 0xE7, 0xFF, 0xE7, 0xE7, 0xFF, // BA
  838. 0xFF, 0xFF, 0xE7, 0xFF, 0xE7, 0xE7, 0xCF, 0xFF, // BB
  839. 0xFF, 0xFF, 0xE7, 0xCF, 0x9F, 0xCF, 0xE7, 0xFF, // BC
  840. 0xFF, 0xFF, 0xFF, 0xC1, 0xFF, 0xC1, 0xFF, 0xFF, // BD
  841. 0xFF, 0xFF, 0xCF, 0xE7, 0xF3, 0xE7, 0xCF, 0xFF, // BE
  842. 0xFF, 0xC3, 0x99, 0xF9, 0xE3, 0xE7, 0xFF, 0xE7, // BF
  843. 0xC3, 0xBD, 0x7E, 0xCA, 0xB6, 0xB6, 0xB6, 0xC9, // C0
  844. 0xFF, 0xC3, 0x99, 0x99, 0x81, 0x99, 0x99, 0xFF, // C1
  845. 0xFF, 0x83, 0x99, 0x83, 0x99, 0x99, 0x83, 0xFF, // C2
  846. 0xFF, 0xC3, 0x99, 0x9F, 0x9F, 0x99, 0xC3, 0xFF, // C3
  847. 0xFF, 0x83, 0x99, 0x99, 0x99, 0x99, 0x83, 0xFF, // C4
  848. 0xFF, 0x81, 0x9F, 0x83, 0x9F, 0x9F, 0x81, 0xFF, // C5
  849. 0xFF, 0x81, 0x9F, 0x83, 0x9F, 0x9F, 0x9F, 0xFF, // C6
  850. 0xFF, 0xC3, 0x99, 0x9F, 0x91, 0x99, 0xC3, 0xFF, // C7
  851. 0xFF, 0x99, 0x99, 0x81, 0x99, 0x99, 0x99, 0xFF, // C8
  852. 0xFF, 0xC3, 0xE7, 0xE7, 0xE7, 0xE7, 0xC3, 0xFF, // C9
  853. 0xFF, 0xE1, 0xF3, 0xF3, 0xF3, 0x93, 0xC7, 0xFF, // CA
  854. 0xFF, 0x99, 0x93, 0x87, 0x93, 0x99, 0x9C, 0xFF, // CB
  855. 0xFF, 0x9F, 0x9F, 0x9F, 0x9F, 0x9F, 0x81, 0xFF, // CC
  856. 0xFF, 0x9C, 0x88, 0x94, 0x9C, 0x9C, 0x9C, 0xFF, // CD
  857. 0xFF, 0x9C, 0x8C, 0x94, 0x98, 0x9C, 0x9C, 0xFF, // CE
  858. 0xFF, 0xC3, 0x99, 0x99, 0x99, 0x99, 0xC3, 0xFF, // CF
  859. 0xFF, 0x83, 0x99, 0x83, 0x9F, 0x9F, 0x9F, 0xFF, // D0
  860. 0xFF, 0xC3, 0x99, 0x99, 0x91, 0x99, 0xC5, 0xFE, // D1
  861. 0xFF, 0x83, 0x99, 0x83, 0x93, 0x99, 0x9C, 0xFF, // D2
  862. 0xFF, 0xC3, 0x9F, 0xC3, 0xF9, 0x99, 0xC3, 0xFF, // D3
  863. 0xFF, 0x81, 0xE7, 0xE7, 0xE7, 0xE7, 0xE7, 0xFF, // D4
  864. 0xFF, 0x99, 0x99, 0x99, 0x99, 0x99, 0xC3, 0xFF, // D5
  865. 0xFF, 0x99, 0x99, 0x99, 0x99, 0xC3, 0xE7, 0xFF, // D6
  866. 0xFF, 0x9C, 0x9C, 0x94, 0x94, 0x80, 0xC9, 0xFF, // D7
  867. 0xFF, 0x99, 0xC3, 0xE7, 0xE7, 0xC3, 0x99, 0xFF, // D8
  868. 0xFF, 0x99, 0xC3, 0xE7, 0xE7, 0xE7, 0xE7, 0xFF, // D9
  869. 0xFF, 0x81, 0xF3, 0xE7, 0xCF, 0x9F, 0x81, 0xFF, // DA
  870. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // DB
  871. 0xFF, 0xE7, 0xE7, 0xE7, 0xE7, 0xE7, 0xE7, 0xFF, // DC
  872. 0xFF, 0x81, 0xF9, 0xF9, 0xFF, 0xFF, 0xFF, 0xFF, // DD
  873. 0xFF, 0xFF, 0xFF, 0xF7, 0xE3, 0xC9, 0xFF, 0xFF, // DE
  874. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, // DF
  875. 0x81, 0x7E, 0x66, 0x5E, 0x5E, 0x66, 0x7E, 0x81, // E0
  876. 0xFF, 0xFF, 0xC3, 0x99, 0x99, 0x99, 0xC4, 0xFF, // E1
  877. 0xFF, 0x9F, 0x9F, 0x87, 0x93, 0x93, 0x87, 0xFF, // E2
  878. 0xFF, 0xFF, 0xC3, 0x99, 0x9F, 0x99, 0xC3, 0xFF, // E3
  879. 0xFF, 0xF9, 0xF9, 0xE1, 0xC9, 0xC9, 0xE1, 0xFF, // E4
  880. 0xFF, 0xFF, 0xC7, 0x93, 0x83, 0x9F, 0xC7, 0xFF, // E5
  881. 0xFF, 0xE1, 0xE7, 0x81, 0xE7, 0xE7, 0xE7, 0xFF, // E6
  882. 0xFF, 0xFF, 0xC3, 0x99, 0x99, 0xC0, 0xF9, 0xC3, // E7
  883. 0xFF, 0x9F, 0x9F, 0x93, 0x89, 0x99, 0x99, 0xFF, // E8
  884. 0xFF, 0xE7, 0xFF, 0xE7, 0xE7, 0xE7, 0xE7, 0xFF, // E9
  885. 0xFF, 0xE7, 0xFF, 0xC7, 0xE7, 0xE7, 0xE7, 0xCF, // EA
  886. 0xFF, 0x9F, 0x99, 0x93, 0x87, 0x93, 0x99, 0xFF, // EB
  887. 0xFF, 0xCF, 0xCF, 0xCF, 0xCF, 0xCF, 0xE7, 0xFF, // EC
  888. 0xFF, 0xFF, 0xC9, 0x80, 0x94, 0x9C, 0x9C, 0xFF, // ED
  889. 0xFF, 0xFF, 0x83, 0x99, 0x99, 0x99, 0x99, 0xFF, // EE
  890. 0xFF, 0xFF, 0xC3, 0x99, 0x99, 0x99, 0xC3, 0xFF, // EF
  891. 0xFF, 0xFF, 0x83, 0x99, 0x99, 0x83, 0x9F, 0x9F, // F0
  892. 0xFF, 0xFF, 0xC3, 0x99, 0x99, 0xC1, 0xF9, 0xF9, // F1
  893. 0xFF, 0xFF, 0xC9, 0xC7, 0xCF, 0xCF, 0xCF, 0xFF, // F2
  894. 0xFF, 0xFF, 0xE3, 0xCF, 0xE3, 0xF9, 0xC3, 0xFF, // F3
  895. 0xFF, 0xE7, 0xE7, 0xC3, 0xE7, 0xE7, 0xF3, 0xFF, // F4
  896. 0xFF, 0xFF, 0x99, 0x99, 0x99, 0x99, 0xC3, 0xFF, // F5
  897. 0xFF, 0xFF, 0x99, 0x99, 0xC3, 0xC3, 0xE7, 0xFF, // F6
  898. 0xFF, 0xFF, 0x9C, 0x9C, 0x94, 0x80, 0xC9, 0xFF, // F7
  899. 0xFF, 0xFF, 0x99, 0xC3, 0xE7, 0xC3, 0x99, 0xFF, // F8
  900. 0xFF, 0xFF, 0x99, 0xC3, 0xE7, 0xCF, 0x9F, 0xFF, // F9
  901. 0xFF, 0xFF, 0x81, 0xF3, 0xE7, 0xCF, 0x81, 0xFF, // FA
  902. 0x99, 0xFF, 0xC3, 0x99, 0x99, 0x99, 0xC4, 0xFF, // FB
  903. 0x99, 0xFF, 0xC3, 0x99, 0x99, 0x99, 0xC3, 0xFF, // FC
  904. 0x99, 0xFF, 0x99, 0x99, 0x99, 0x99, 0xC3, 0xFF, // FD
  905. 0xFF, 0xC7, 0x93, 0x87, 0x93, 0x87, 0x9F, 0x9F, // FE
  906. 0x00, 0x7E, 0x7E, 0x7E, 0x7E, 0x7E, 0x7E, 0x00, // FF
  907. };
  908. static const uint8_t _sdtx_font_kc854[2048] = {
  909. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x81, 0xFF, // 00
  910. 0x00, 0x00, 0x22, 0x72, 0x22, 0x3E, 0x00, 0x00, // 01
  911. 0x00, 0x00, 0x12, 0x32, 0x7E, 0x32, 0x12, 0x00, // 02
  912. 0x7E, 0x81, 0xB9, 0xA5, 0xB9, 0xA5, 0xB9, 0x81, // 03
  913. 0x55, 0xFF, 0x55, 0xFF, 0x55, 0xFF, 0x55, 0xFF, // 04
  914. 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, // 05
  915. 0xFF, 0x00, 0xFF, 0x00, 0xFF, 0x00, 0xFF, 0x00, // 06
  916. 0x00, 0x00, 0x3C, 0x42, 0x42, 0x7E, 0x00, 0x00, // 07
  917. 0x00, 0x10, 0x30, 0x7E, 0x30, 0x10, 0x00, 0x00, // 08
  918. 0x00, 0x08, 0x0C, 0x7E, 0x0C, 0x08, 0x00, 0x00, // 09
  919. 0x00, 0x10, 0x10, 0x10, 0x7C, 0x38, 0x10, 0x00, // 0A
  920. 0x08, 0x1C, 0x3E, 0x08, 0x08, 0x08, 0x08, 0x00, // 0B
  921. 0x38, 0x30, 0x28, 0x08, 0x08, 0x08, 0x3E, 0x00, // 0C
  922. 0x00, 0x00, 0x12, 0x32, 0x7E, 0x30, 0x10, 0x00, // 0D
  923. 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, // 0E
  924. 0x3E, 0x7C, 0x7C, 0x3E, 0x3E, 0x7C, 0xF8, 0xF8, // 0F
  925. 0x38, 0x30, 0x28, 0x04, 0x04, 0x04, 0x04, 0x00, // 10
  926. 0x7F, 0x08, 0x1C, 0x2A, 0x08, 0x08, 0x08, 0x00, // 11
  927. 0x00, 0x08, 0x08, 0x08, 0x2A, 0x1C, 0x08, 0x7F, // 12
  928. 0x7E, 0x81, 0x9D, 0xA1, 0xB9, 0x85, 0x85, 0xB9, // 13
  929. 0x00, 0x3C, 0x42, 0x5A, 0x5A, 0x42, 0x3C, 0x00, // 14
  930. 0x88, 0x44, 0x22, 0x11, 0x88, 0x44, 0x22, 0x11, // 15
  931. 0x00, 0x7F, 0x22, 0x72, 0x27, 0x22, 0x7F, 0x00, // 16
  932. 0x11, 0x22, 0x44, 0x88, 0x11, 0x22, 0x44, 0x88, // 17
  933. 0x00, 0x01, 0x09, 0x0D, 0x7F, 0x0D, 0x09, 0x01, // 18
  934. 0x00, 0x90, 0xB0, 0xFE, 0xB0, 0x90, 0x00, 0x00, // 19
  935. 0x00, 0x08, 0x7C, 0x06, 0x7C, 0x08, 0x00, 0x00, // 1A
  936. 0xCC, 0xCC, 0x33, 0x33, 0xCC, 0xCC, 0x33, 0x33, // 1B
  937. 0x7E, 0x81, 0xA1, 0xA1, 0xA1, 0xA1, 0xBD, 0x81, // 1C
  938. 0x7E, 0x81, 0xB9, 0xA5, 0xB9, 0xA5, 0xA5, 0x81, // 1D
  939. 0x7E, 0x81, 0x99, 0xA1, 0xA1, 0xA1, 0x99, 0x81, // 1E
  940. 0x00, 0x10, 0x3E, 0x60, 0x3E, 0x10, 0x00, 0x00, // 1F
  941. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 20
  942. 0x30, 0x30, 0x30, 0x30, 0x30, 0x00, 0x30, 0x00, // 21
  943. 0x77, 0x33, 0x66, 0x00, 0x00, 0x00, 0x00, 0x00, // 22
  944. 0x36, 0x36, 0xFE, 0x6C, 0xFE, 0xD8, 0xD8, 0x00, // 23
  945. 0x18, 0x3E, 0x6C, 0x3E, 0x1B, 0x1B, 0x7E, 0x18, // 24
  946. 0x00, 0xC6, 0xCC, 0x18, 0x30, 0x66, 0xC6, 0x00, // 25
  947. 0x38, 0x6C, 0x38, 0x76, 0xDC, 0xCC, 0x76, 0x00, // 26
  948. 0x1C, 0x0C, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, // 27
  949. 0x18, 0x30, 0x60, 0x60, 0x60, 0x30, 0x18, 0x00, // 28
  950. 0x60, 0x30, 0x18, 0x18, 0x18, 0x30, 0x60, 0x00, // 29
  951. 0x00, 0x66, 0x3C, 0xFF, 0x3C, 0x66, 0x00, 0x00, // 2A
  952. 0x00, 0x30, 0x30, 0xFC, 0x30, 0x30, 0x00, 0x00, // 2B
  953. 0x00, 0x00, 0x00, 0x00, 0x00, 0x1C, 0x0C, 0x18, // 2C
  954. 0x00, 0x00, 0x00, 0xFE, 0x00, 0x00, 0x00, 0x00, // 2D
  955. 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x30, 0x00, // 2E
  956. 0x06, 0x0C, 0x18, 0x30, 0x60, 0xC0, 0x80, 0x00, // 2F
  957. 0x7C, 0xC6, 0xCE, 0xDE, 0xF6, 0xE6, 0x7C, 0x00, // 30
  958. 0x30, 0x70, 0x30, 0x30, 0x30, 0x30, 0xFC, 0x00, // 31
  959. 0x78, 0xCC, 0x0C, 0x38, 0x60, 0xCC, 0xFC, 0x00, // 32
  960. 0xFC, 0x18, 0x30, 0x78, 0x0C, 0xCC, 0x78, 0x00, // 33
  961. 0x1C, 0x3C, 0x6C, 0xCC, 0xFE, 0x0C, 0x1E, 0x00, // 34
  962. 0xFC, 0xC0, 0xF8, 0x0C, 0x0C, 0xCC, 0x78, 0x00, // 35
  963. 0x38, 0x60, 0xC0, 0xF8, 0xCC, 0xCC, 0x78, 0x00, // 36
  964. 0xFC, 0xCC, 0x0C, 0x18, 0x30, 0x30, 0x30, 0x00, // 37
  965. 0x78, 0xCC, 0xCC, 0x78, 0xCC, 0xCC, 0x78, 0x00, // 38
  966. 0x78, 0xCC, 0xCC, 0x7C, 0x0C, 0x18, 0x70, 0x00, // 39
  967. 0x00, 0x00, 0x30, 0x30, 0x00, 0x30, 0x30, 0x00, // 3A
  968. 0x00, 0x00, 0x30, 0x30, 0x00, 0x30, 0x30, 0x60, // 3B
  969. 0x18, 0x30, 0x60, 0xC0, 0x60, 0x30, 0x18, 0x00, // 3C
  970. 0x00, 0x00, 0xFC, 0x00, 0xFC, 0x00, 0x00, 0x00, // 3D
  971. 0x60, 0x30, 0x18, 0x0C, 0x18, 0x30, 0x60, 0x00, // 3E
  972. 0x78, 0xCC, 0x0C, 0x18, 0x30, 0x00, 0x30, 0x00, // 3F
  973. 0x7C, 0xC6, 0xDE, 0xDE, 0xDE, 0xC0, 0x78, 0x00, // 40
  974. 0x30, 0x78, 0xCC, 0xCC, 0xFC, 0xCC, 0xCC, 0x00, // 41
  975. 0xFC, 0x66, 0x66, 0x7C, 0x66, 0x66, 0xFC, 0x00, // 42
  976. 0x3C, 0x66, 0xC0, 0xC0, 0xC0, 0x66, 0x3C, 0x00, // 43
  977. 0xF8, 0x6C, 0x66, 0x66, 0x66, 0x6C, 0xF8, 0x00, // 44
  978. 0xFE, 0x62, 0x68, 0x78, 0x68, 0x62, 0xFE, 0x00, // 45
  979. 0xFE, 0x62, 0x68, 0x78, 0x68, 0x60, 0xF0, 0x00, // 46
  980. 0x3C, 0x66, 0xC0, 0xC0, 0xCE, 0x66, 0x3C, 0x00, // 47
  981. 0xCC, 0xCC, 0xCC, 0xFC, 0xCC, 0xCC, 0xCC, 0x00, // 48
  982. 0x78, 0x30, 0x30, 0x30, 0x30, 0x30, 0x78, 0x00, // 49
  983. 0x1E, 0x0C, 0x0C, 0x0C, 0xCC, 0xCC, 0x78, 0x00, // 4A
  984. 0xE6, 0x66, 0x6C, 0x70, 0x6C, 0x66, 0xE6, 0x00, // 4B
  985. 0xF0, 0x60, 0x60, 0x60, 0x62, 0x66, 0xFE, 0x00, // 4C
  986. 0xC6, 0xEE, 0xFE, 0xD6, 0xC6, 0xC6, 0xC6, 0x00, // 4D
  987. 0xC6, 0xE6, 0xF6, 0xDE, 0xCE, 0xC6, 0xC6, 0x00, // 4E
  988. 0x38, 0x6C, 0xC6, 0xC6, 0xC6, 0x6C, 0x38, 0x00, // 4F
  989. 0xFC, 0x66, 0x66, 0x7C, 0x60, 0x60, 0xF0, 0x00, // 50
  990. 0x78, 0xCC, 0xCC, 0xCC, 0xDC, 0x78, 0x1C, 0x00, // 51
  991. 0xFC, 0x66, 0x66, 0x7C, 0x6C, 0x66, 0xE6, 0x00, // 52
  992. 0x7C, 0xC6, 0xF0, 0x3C, 0x0E, 0xC6, 0x7C, 0x00, // 53
  993. 0xFC, 0xB4, 0x30, 0x30, 0x30, 0x30, 0x78, 0x00, // 54
  994. 0xCC, 0xCC, 0xCC, 0xCC, 0xCC, 0xCC, 0x78, 0x00, // 55
  995. 0xCC, 0xCC, 0xCC, 0x78, 0x78, 0x30, 0x30, 0x00, // 56
  996. 0xC6, 0xC6, 0xC6, 0xD6, 0xFE, 0xEE, 0xC6, 0x00, // 57
  997. 0xC6, 0xC6, 0x6C, 0x38, 0x6C, 0xC6, 0xC6, 0x00, // 58
  998. 0xCC, 0xCC, 0xCC, 0x78, 0x30, 0x30, 0x78, 0x00, // 59
  999. 0xFE, 0xC6, 0x8C, 0x18, 0x32, 0x66, 0xFE, 0x00, // 5A
  1000. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // 5B
  1001. 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, // 5C
  1002. 0x00, 0xFE, 0x06, 0x06, 0x00, 0x00, 0x00, 0x00, // 5D
  1003. 0x10, 0x38, 0x6C, 0xC6, 0x00, 0x00, 0x00, 0x00, // 5E
  1004. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, // 5F
  1005. 0x3C, 0x42, 0x99, 0xA1, 0xA1, 0x99, 0x42, 0x3C, // 60
  1006. 0x00, 0x00, 0x78, 0x0C, 0x7C, 0xCC, 0x76, 0x00, // 61
  1007. 0xE0, 0x60, 0x7C, 0x66, 0x66, 0x66, 0xDC, 0x00, // 62
  1008. 0x00, 0x00, 0x78, 0xCC, 0xC0, 0xCC, 0x78, 0x00, // 63
  1009. 0x1C, 0x0C, 0x7C, 0xCC, 0xCC, 0xCC, 0x76, 0x00, // 64
  1010. 0x00, 0x00, 0x78, 0xCC, 0xFC, 0xC0, 0x78, 0x00, // 65
  1011. 0x38, 0x6C, 0x60, 0xF0, 0x60, 0x60, 0xF0, 0x00, // 66
  1012. 0x00, 0x00, 0x76, 0xCC, 0xCC, 0x7C, 0x0C, 0xF8, // 67
  1013. 0xE0, 0x60, 0x6C, 0x76, 0x66, 0x66, 0xE6, 0x00, // 68
  1014. 0x30, 0x00, 0x70, 0x30, 0x30, 0x30, 0xFC, 0x00, // 69
  1015. 0x0C, 0x00, 0x1C, 0x0C, 0x0C, 0xCC, 0xCC, 0x78, // 6A
  1016. 0xE0, 0x60, 0x66, 0x6C, 0x78, 0x6C, 0xE6, 0x00, // 6B
  1017. 0x70, 0x30, 0x30, 0x30, 0x30, 0x30, 0xFC, 0x00, // 6C
  1018. 0x00, 0x00, 0xCC, 0xFE, 0xFE, 0xD6, 0xC6, 0x00, // 6D
  1019. 0x00, 0x00, 0xF8, 0xCC, 0xCC, 0xCC, 0xCC, 0x00, // 6E
  1020. 0x00, 0x00, 0x78, 0xCC, 0xCC, 0xCC, 0x78, 0x00, // 6F
  1021. 0x00, 0x00, 0xDC, 0x66, 0x66, 0x7C, 0x60, 0xF0, // 70
  1022. 0x00, 0x00, 0x76, 0xCC, 0xCC, 0x7C, 0x0C, 0x1E, // 71
  1023. 0x00, 0x00, 0xDC, 0x76, 0x66, 0x60, 0xF0, 0x00, // 72
  1024. 0x00, 0x00, 0x7C, 0xC0, 0x78, 0x0C, 0xF8, 0x00, // 73
  1025. 0x10, 0x30, 0x7C, 0x30, 0x30, 0x34, 0x18, 0x00, // 74
  1026. 0x00, 0x00, 0xCC, 0xCC, 0xCC, 0xCC, 0x76, 0x00, // 75
  1027. 0x00, 0x00, 0xCC, 0xCC, 0xCC, 0x78, 0x30, 0x00, // 76
  1028. 0x00, 0x00, 0xC6, 0xD6, 0xFE, 0xFE, 0x6C, 0x00, // 77
  1029. 0x00, 0x00, 0xC6, 0x6C, 0x38, 0x6C, 0xC6, 0x00, // 78
  1030. 0x00, 0x00, 0xCC, 0xCC, 0xCC, 0x7C, 0x0C, 0xF8, // 79
  1031. 0x00, 0x00, 0xFC, 0x98, 0x30, 0x64, 0xFC, 0x00, // 7A
  1032. 0x6C, 0x00, 0x78, 0x0C, 0x7C, 0xCC, 0x76, 0x00, // 7B
  1033. 0xCC, 0x00, 0x78, 0xCC, 0xCC, 0xCC, 0x78, 0x00, // 7C
  1034. 0xCC, 0x00, 0xCC, 0xCC, 0xCC, 0xCC, 0x76, 0x00, // 7D
  1035. 0x3C, 0x66, 0x66, 0x6C, 0x66, 0x66, 0x6C, 0xF0, // 7E
  1036. 0xFF, 0x81, 0x81, 0x81, 0x81, 0x81, 0x81, 0xFF, // 7F
  1037. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x7E, 0x00, // 80
  1038. 0xFF, 0xFF, 0xDD, 0x8D, 0xDD, 0xC1, 0xFF, 0xFF, // 81
  1039. 0xFF, 0xFF, 0xED, 0xCD, 0x81, 0xCD, 0xED, 0xFF, // 82
  1040. 0x81, 0x7E, 0x46, 0x5A, 0x46, 0x5A, 0x46, 0x7E, // 83
  1041. 0xAA, 0x00, 0xAA, 0x00, 0xAA, 0x00, 0xAA, 0x00, // 84
  1042. 0x55, 0x55, 0x55, 0x55, 0x55, 0x55, 0x55, 0x55, // 85
  1043. 0x00, 0xFF, 0x00, 0xFF, 0x00, 0xFF, 0x00, 0xFF, // 86
  1044. 0xFF, 0xFF, 0xC3, 0xBD, 0xBD, 0x81, 0xFF, 0xFF, // 87
  1045. 0xFF, 0xEF, 0xCF, 0x81, 0xCF, 0xEF, 0xFF, 0xFF, // 88
  1046. 0xFF, 0xF7, 0xF3, 0x81, 0xF3, 0xF7, 0xFF, 0xFF, // 89
  1047. 0xFF, 0xEF, 0xEF, 0xEF, 0x83, 0xC7, 0xEF, 0xFF, // 8A
  1048. 0xF7, 0xE3, 0xC1, 0xF7, 0xF7, 0xF7, 0xF7, 0xFF, // 8B
  1049. 0xC7, 0xCF, 0xD7, 0xF7, 0xF7, 0xF7, 0xC1, 0xFF, // 8C
  1050. 0xFF, 0xFF, 0xED, 0xCD, 0x81, 0xCF, 0xEF, 0xFF, // 8D
  1051. 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, // 8E
  1052. 0xC1, 0x83, 0x83, 0xC1, 0xC1, 0x83, 0x07, 0x07, // 8F
  1053. 0xC7, 0xCF, 0xD7, 0xFB, 0xFB, 0xFB, 0xFB, 0xFF, // 90
  1054. 0x80, 0xF7, 0xE3, 0xD5, 0xF7, 0xF7, 0xF7, 0xFF, // 91
  1055. 0xFF, 0xF7, 0xF7, 0xF7, 0xD5, 0xE3, 0xF7, 0x80, // 92
  1056. 0x81, 0x7E, 0x62, 0x5E, 0x46, 0x7A, 0x7A, 0x46, // 93
  1057. 0xFF, 0xC3, 0xBD, 0xA5, 0xA5, 0xBD, 0xC3, 0xFF, // 94
  1058. 0x77, 0xBB, 0xDD, 0xEE, 0x77, 0xBB, 0xDD, 0xEE, // 95
  1059. 0xFF, 0x80, 0xDD, 0x8D, 0xD8, 0xDD, 0x80, 0xFF, // 96
  1060. 0xEE, 0xDD, 0xBB, 0x77, 0xEE, 0xDD, 0xBB, 0x77, // 97
  1061. 0xFF, 0xFE, 0xF6, 0xF2, 0x80, 0xF2, 0xF6, 0xFE, // 98
  1062. 0xFF, 0x6F, 0x4F, 0x01, 0x4F, 0x6F, 0xFF, 0xFF, // 99
  1063. 0xFF, 0xF7, 0x83, 0xF9, 0x83, 0xF7, 0xFF, 0xFF, // 9A
  1064. 0x33, 0x33, 0xCC, 0xCC, 0x33, 0x33, 0xCC, 0xCC, // 9B
  1065. 0x81, 0x7E, 0x5E, 0x5E, 0x5E, 0x5E, 0x42, 0x7E, // 9C
  1066. 0x81, 0x7E, 0x46, 0x5A, 0x46, 0x5A, 0x5A, 0x7E, // 9D
  1067. 0x81, 0x7E, 0x66, 0x5E, 0x5E, 0x5E, 0x66, 0x7E, // 9E
  1068. 0xFF, 0xEF, 0xC1, 0x9F, 0xC1, 0xEF, 0xFF, 0xFF, // 9F
  1069. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // A0
  1070. 0xCF, 0xCF, 0xCF, 0xCF, 0xCF, 0xFF, 0xCF, 0xFF, // A1
  1071. 0x88, 0xCC, 0x99, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // A2
  1072. 0xC9, 0xC9, 0x01, 0x93, 0x01, 0x27, 0x27, 0xFF, // A3
  1073. 0xE7, 0xC1, 0x93, 0xC1, 0xE4, 0xE4, 0x81, 0xE7, // A4
  1074. 0xFF, 0x39, 0x33, 0xE7, 0xCF, 0x99, 0x39, 0xFF, // A5
  1075. 0xC7, 0x93, 0xC7, 0x89, 0x23, 0x33, 0x89, 0xFF, // A6
  1076. 0xE3, 0xF3, 0xE7, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // A7
  1077. 0xE7, 0xCF, 0x9F, 0x9F, 0x9F, 0xCF, 0xE7, 0xFF, // A8
  1078. 0x9F, 0xCF, 0xE7, 0xE7, 0xE7, 0xCF, 0x9F, 0xFF, // A9
  1079. 0xFF, 0x99, 0xC3, 0x00, 0xC3, 0x99, 0xFF, 0xFF, // AA
  1080. 0xFF, 0xCF, 0xCF, 0x03, 0xCF, 0xCF, 0xFF, 0xFF, // AB
  1081. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xE3, 0xF3, 0xE7, // AC
  1082. 0xFF, 0xFF, 0xFF, 0x01, 0xFF, 0xFF, 0xFF, 0xFF, // AD
  1083. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xCF, 0xCF, 0xFF, // AE
  1084. 0xF9, 0xF3, 0xE7, 0xCF, 0x9F, 0x3F, 0x7F, 0xFF, // AF
  1085. 0x83, 0x39, 0x31, 0x21, 0x09, 0x19, 0x83, 0xFF, // B0
  1086. 0xCF, 0x8F, 0xCF, 0xCF, 0xCF, 0xCF, 0x03, 0xFF, // B1
  1087. 0x87, 0x33, 0xF3, 0xC7, 0x9F, 0x33, 0x03, 0xFF, // B2
  1088. 0x03, 0xE7, 0xCF, 0x87, 0xF3, 0x33, 0x87, 0xFF, // B3
  1089. 0xE3, 0xC3, 0x93, 0x33, 0x01, 0xF3, 0xE1, 0xFF, // B4
  1090. 0x03, 0x3F, 0x07, 0xF3, 0xF3, 0x33, 0x87, 0xFF, // B5
  1091. 0xC7, 0x9F, 0x3F, 0x07, 0x33, 0x33, 0x87, 0xFF, // B6
  1092. 0x03, 0x33, 0xF3, 0xE7, 0xCF, 0xCF, 0xCF, 0xFF, // B7
  1093. 0x87, 0x33, 0x33, 0x87, 0x33, 0x33, 0x87, 0xFF, // B8
  1094. 0x87, 0x33, 0x33, 0x83, 0xF3, 0xE7, 0x8F, 0xFF, // B9
  1095. 0xFF, 0xFF, 0xCF, 0xCF, 0xFF, 0xCF, 0xCF, 0xFF, // BA
  1096. 0xFF, 0xFF, 0xCF, 0xCF, 0xFF, 0xCF, 0xCF, 0x9F, // BB
  1097. 0xE7, 0xCF, 0x9F, 0x3F, 0x9F, 0xCF, 0xE7, 0xFF, // BC
  1098. 0xFF, 0xFF, 0x03, 0xFF, 0x03, 0xFF, 0xFF, 0xFF, // BD
  1099. 0x9F, 0xCF, 0xE7, 0xF3, 0xE7, 0xCF, 0x9F, 0xFF, // BE
  1100. 0x87, 0x33, 0xF3, 0xE7, 0xCF, 0xFF, 0xCF, 0xFF, // BF
  1101. 0x83, 0x39, 0x21, 0x21, 0x21, 0x3F, 0x87, 0xFF, // C0
  1102. 0xCF, 0x87, 0x33, 0x33, 0x03, 0x33, 0x33, 0xFF, // C1
  1103. 0x03, 0x99, 0x99, 0x83, 0x99, 0x99, 0x03, 0xFF, // C2
  1104. 0xC3, 0x99, 0x3F, 0x3F, 0x3F, 0x99, 0xC3, 0xFF, // C3
  1105. 0x07, 0x93, 0x99, 0x99, 0x99, 0x93, 0x07, 0xFF, // C4
  1106. 0x01, 0x9D, 0x97, 0x87, 0x97, 0x9D, 0x01, 0xFF, // C5
  1107. 0x01, 0x9D, 0x97, 0x87, 0x97, 0x9F, 0x0F, 0xFF, // C6
  1108. 0xC3, 0x99, 0x3F, 0x3F, 0x31, 0x99, 0xC3, 0xFF, // C7
  1109. 0x33, 0x33, 0x33, 0x03, 0x33, 0x33, 0x33, 0xFF, // C8
  1110. 0x87, 0xCF, 0xCF, 0xCF, 0xCF, 0xCF, 0x87, 0xFF, // C9
  1111. 0xE1, 0xF3, 0xF3, 0xF3, 0x33, 0x33, 0x87, 0xFF, // CA
  1112. 0x19, 0x99, 0x93, 0x8F, 0x93, 0x99, 0x19, 0xFF, // CB
  1113. 0x0F, 0x9F, 0x9F, 0x9F, 0x9D, 0x99, 0x01, 0xFF, // CC
  1114. 0x39, 0x11, 0x01, 0x29, 0x39, 0x39, 0x39, 0xFF, // CD
  1115. 0x39, 0x19, 0x09, 0x21, 0x31, 0x39, 0x39, 0xFF, // CE
  1116. 0xC7, 0x93, 0x39, 0x39, 0x39, 0x93, 0xC7, 0xFF, // CF
  1117. 0x03, 0x99, 0x99, 0x83, 0x9F, 0x9F, 0x0F, 0xFF, // D0
  1118. 0x87, 0x33, 0x33, 0x33, 0x23, 0x87, 0xE3, 0xFF, // D1
  1119. 0x03, 0x99, 0x99, 0x83, 0x93, 0x99, 0x19, 0xFF, // D2
  1120. 0x83, 0x39, 0x0F, 0xC3, 0xF1, 0x39, 0x83, 0xFF, // D3
  1121. 0x03, 0x4B, 0xCF, 0xCF, 0xCF, 0xCF, 0x87, 0xFF, // D4
  1122. 0x33, 0x33, 0x33, 0x33, 0x33, 0x33, 0x87, 0xFF, // D5
  1123. 0x33, 0x33, 0x33, 0x87, 0x87, 0xCF, 0xCF, 0xFF, // D6
  1124. 0x39, 0x39, 0x39, 0x29, 0x01, 0x11, 0x39, 0xFF, // D7
  1125. 0x39, 0x39, 0x93, 0xC7, 0x93, 0x39, 0x39, 0xFF, // D8
  1126. 0x33, 0x33, 0x33, 0x87, 0xCF, 0xCF, 0x87, 0xFF, // D9
  1127. 0x01, 0x39, 0x73, 0xE7, 0xCD, 0x99, 0x01, 0xFF, // DA
  1128. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // DB
  1129. 0xE7, 0xE7, 0xE7, 0xE7, 0xE7, 0xE7, 0xE7, 0xFF, // DC
  1130. 0xFF, 0x01, 0xF9, 0xF9, 0xFF, 0xFF, 0xFF, 0xFF, // DD
  1131. 0xEF, 0xC7, 0x93, 0x39, 0xFF, 0xFF, 0xFF, 0xFF, // DE
  1132. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, // DF
  1133. 0xC3, 0xBD, 0x66, 0x5E, 0x5E, 0x66, 0xBD, 0xC3, // E0
  1134. 0xFF, 0xFF, 0x87, 0xF3, 0x83, 0x33, 0x89, 0xFF, // E1
  1135. 0x1F, 0x9F, 0x83, 0x99, 0x99, 0x99, 0x23, 0xFF, // E2
  1136. 0xFF, 0xFF, 0x87, 0x33, 0x3F, 0x33, 0x87, 0xFF, // E3
  1137. 0xE3, 0xF3, 0x83, 0x33, 0x33, 0x33, 0x89, 0xFF, // E4
  1138. 0xFF, 0xFF, 0x87, 0x33, 0x03, 0x3F, 0x87, 0xFF, // E5
  1139. 0xC7, 0x93, 0x9F, 0x0F, 0x9F, 0x9F, 0x0F, 0xFF, // E6
  1140. 0xFF, 0xFF, 0x89, 0x33, 0x33, 0x83, 0xF3, 0x07, // E7
  1141. 0x1F, 0x9F, 0x93, 0x89, 0x99, 0x99, 0x19, 0xFF, // E8
  1142. 0xCF, 0xFF, 0x8F, 0xCF, 0xCF, 0xCF, 0x03, 0xFF, // E9
  1143. 0xF3, 0xFF, 0xE3, 0xF3, 0xF3, 0x33, 0x33, 0x87, // EA
  1144. 0x1F, 0x9F, 0x99, 0x93, 0x87, 0x93, 0x19, 0xFF, // EB
  1145. 0x8F, 0xCF, 0xCF, 0xCF, 0xCF, 0xCF, 0x03, 0xFF, // EC
  1146. 0xFF, 0xFF, 0x33, 0x01, 0x01, 0x29, 0x39, 0xFF, // ED
  1147. 0xFF, 0xFF, 0x07, 0x33, 0x33, 0x33, 0x33, 0xFF, // EE
  1148. 0xFF, 0xFF, 0x87, 0x33, 0x33, 0x33, 0x87, 0xFF, // EF
  1149. 0xFF, 0xFF, 0x23, 0x99, 0x99, 0x83, 0x9F, 0x0F, // F0
  1150. 0xFF, 0xFF, 0x89, 0x33, 0x33, 0x83, 0xF3, 0xE1, // F1
  1151. 0xFF, 0xFF, 0x23, 0x89, 0x99, 0x9F, 0x0F, 0xFF, // F2
  1152. 0xFF, 0xFF, 0x83, 0x3F, 0x87, 0xF3, 0x07, 0xFF, // F3
  1153. 0xEF, 0xCF, 0x83, 0xCF, 0xCF, 0xCB, 0xE7, 0xFF, // F4
  1154. 0xFF, 0xFF, 0x33, 0x33, 0x33, 0x33, 0x89, 0xFF, // F5
  1155. 0xFF, 0xFF, 0x33, 0x33, 0x33, 0x87, 0xCF, 0xFF, // F6
  1156. 0xFF, 0xFF, 0x39, 0x29, 0x01, 0x01, 0x93, 0xFF, // F7
  1157. 0xFF, 0xFF, 0x39, 0x93, 0xC7, 0x93, 0x39, 0xFF, // F8
  1158. 0xFF, 0xFF, 0x33, 0x33, 0x33, 0x83, 0xF3, 0x07, // F9
  1159. 0xFF, 0xFF, 0x03, 0x67, 0xCF, 0x9B, 0x03, 0xFF, // FA
  1160. 0x93, 0xFF, 0x87, 0xF3, 0x83, 0x33, 0x89, 0xFF, // FB
  1161. 0x33, 0xFF, 0x87, 0x33, 0x33, 0x33, 0x87, 0xFF, // FC
  1162. 0x33, 0xFF, 0x33, 0x33, 0x33, 0x33, 0x89, 0xFF, // FD
  1163. 0xC3, 0x99, 0x99, 0x93, 0x99, 0x99, 0x93, 0x0F, // FE
  1164. 0x00, 0x7E, 0x7E, 0x7E, 0x7E, 0x7E, 0x7E, 0x00, // FF
  1165. };
  1166. static const uint8_t _sdtx_font_z1013[2048] = {
  1167. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // 00
  1168. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // 01
  1169. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // 02
  1170. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // 03
  1171. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // 04
  1172. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // 05
  1173. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // 06
  1174. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // 07
  1175. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // 08
  1176. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // 09
  1177. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // 0A
  1178. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // 0B
  1179. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // 0C
  1180. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // 0D
  1181. 0x00, 0x00, 0x18, 0x24, 0x24, 0x18, 0x24, 0x42, // 0E
  1182. 0xDB, 0xA5, 0x81, 0xFF, 0x24, 0x24, 0x24, 0x42, // 0F
  1183. 0x08, 0x34, 0x42, 0x81, 0x91, 0x69, 0x09, 0x31, // 10
  1184. 0x42, 0x7E, 0x81, 0xFF, 0x00, 0x00, 0x00, 0x00, // 11
  1185. 0x18, 0x24, 0x42, 0x99, 0xBD, 0x99, 0x42, 0x24, // 12
  1186. 0x7E, 0x42, 0x99, 0xE7, 0x00, 0x00, 0x00, 0x00, // 13
  1187. 0x18, 0xDB, 0xC3, 0x18, 0x99, 0xE7, 0x81, 0x42, // 14
  1188. 0x18, 0x24, 0x18, 0xC3, 0xBD, 0x81, 0x81, 0x42, // 15
  1189. 0x24, 0x7E, 0x81, 0xFF, 0x00, 0x00, 0x00, 0x00, // 16
  1190. 0x00, 0x00, 0x18, 0x3C, 0x3C, 0x18, 0x3C, 0x7E, // 17
  1191. 0xDB, 0xFF, 0xFF, 0xFF, 0x3C, 0x3C, 0x3C, 0x7E, // 18
  1192. 0x08, 0x3C, 0x7E, 0xFF, 0xFF, 0x6F, 0x0F, 0x3F, // 19
  1193. 0x7E, 0x7E, 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x00, // 1A
  1194. 0x18, 0x3C, 0x7E, 0xE7, 0xC3, 0xE7, 0x7E, 0x3C, // 1B
  1195. 0x7E, 0x7E, 0xFF, 0xE7, 0x00, 0x00, 0x00, 0x00, // 1C
  1196. 0x18, 0xDB, 0xC3, 0x18, 0x99, 0xFF, 0xFF, 0x7E, // 1D
  1197. 0x18, 0x3C, 0x18, 0xC3, 0xFF, 0xFF, 0xFF, 0x7E, // 1E
  1198. 0x3C, 0x3C, 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x00, // 1F
  1199. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 20
  1200. 0x10, 0x10, 0x10, 0x10, 0x00, 0x00, 0x10, 0x00, // 21
  1201. 0x28, 0x28, 0x28, 0x00, 0x00, 0x00, 0x00, 0x00, // 22
  1202. 0x24, 0x7E, 0x24, 0x24, 0x24, 0x7E, 0x24, 0x00, // 23
  1203. 0x10, 0x3C, 0x50, 0x38, 0x14, 0x78, 0x10, 0x00, // 24
  1204. 0x60, 0x64, 0x08, 0x10, 0x20, 0x4C, 0x0C, 0x00, // 25
  1205. 0x10, 0x28, 0x28, 0x30, 0x54, 0x48, 0x34, 0x00, // 26
  1206. 0x10, 0x10, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, // 27
  1207. 0x08, 0x10, 0x20, 0x20, 0x20, 0x10, 0x08, 0x00, // 28
  1208. 0x20, 0x10, 0x08, 0x08, 0x08, 0x10, 0x20, 0x00, // 29
  1209. 0x00, 0x10, 0x54, 0x38, 0x54, 0x10, 0x00, 0x00, // 2A
  1210. 0x00, 0x10, 0x10, 0x7C, 0x10, 0x10, 0x00, 0x00, // 2B
  1211. 0x00, 0x00, 0x00, 0x00, 0x10, 0x10, 0x20, 0x00, // 2C
  1212. 0x00, 0x00, 0x00, 0x7C, 0x00, 0x00, 0x00, 0x00, // 2D
  1213. 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x30, 0x00, // 2E
  1214. 0x00, 0x04, 0x08, 0x10, 0x20, 0x40, 0x00, 0x00, // 2F
  1215. 0x38, 0x44, 0x44, 0x54, 0x44, 0x44, 0x38, 0x00, // 30
  1216. 0x10, 0x30, 0x10, 0x10, 0x10, 0x10, 0x38, 0x00, // 31
  1217. 0x38, 0x44, 0x04, 0x08, 0x10, 0x20, 0x7C, 0x00, // 32
  1218. 0x7C, 0x08, 0x10, 0x08, 0x04, 0x44, 0x38, 0x00, // 33
  1219. 0x08, 0x18, 0x28, 0x48, 0x7C, 0x08, 0x08, 0x00, // 34
  1220. 0x7C, 0x40, 0x78, 0x04, 0x04, 0x44, 0x38, 0x00, // 35
  1221. 0x18, 0x20, 0x40, 0x78, 0x44, 0x44, 0x38, 0x00, // 36
  1222. 0x7C, 0x04, 0x08, 0x10, 0x20, 0x20, 0x20, 0x00, // 37
  1223. 0x38, 0x44, 0x44, 0x38, 0x44, 0x44, 0x38, 0x00, // 38
  1224. 0x38, 0x44, 0x44, 0x3C, 0x04, 0x08, 0x30, 0x00, // 39
  1225. 0x00, 0x30, 0x30, 0x00, 0x30, 0x30, 0x00, 0x00, // 3A
  1226. 0x00, 0x00, 0x10, 0x00, 0x10, 0x10, 0x20, 0x00, // 3B
  1227. 0x08, 0x10, 0x20, 0x40, 0x20, 0x10, 0x08, 0x00, // 3C
  1228. 0x00, 0x00, 0x7C, 0x00, 0x7C, 0x00, 0x00, 0x00, // 3D
  1229. 0x20, 0x10, 0x08, 0x04, 0x08, 0x10, 0x20, 0x00, // 3E
  1230. 0x38, 0x44, 0x04, 0x08, 0x10, 0x00, 0x10, 0x00, // 3F
  1231. 0x38, 0x44, 0x5C, 0x54, 0x5C, 0x40, 0x3C, 0x00, // 40
  1232. 0x38, 0x44, 0x44, 0x7C, 0x44, 0x44, 0x44, 0x00, // 41
  1233. 0x78, 0x24, 0x24, 0x38, 0x24, 0x24, 0x78, 0x00, // 42
  1234. 0x38, 0x44, 0x40, 0x40, 0x40, 0x44, 0x38, 0x00, // 43
  1235. 0x78, 0x24, 0x24, 0x24, 0x24, 0x24, 0x78, 0x00, // 44
  1236. 0x7C, 0x40, 0x40, 0x78, 0x40, 0x40, 0x7C, 0x00, // 45
  1237. 0x7C, 0x40, 0x40, 0x78, 0x40, 0x40, 0x40, 0x00, // 46
  1238. 0x38, 0x44, 0x40, 0x40, 0x4C, 0x44, 0x3C, 0x00, // 47
  1239. 0x44, 0x44, 0x44, 0x7C, 0x44, 0x44, 0x44, 0x00, // 48
  1240. 0x38, 0x10, 0x10, 0x10, 0x10, 0x10, 0x38, 0x00, // 49
  1241. 0x1C, 0x08, 0x08, 0x08, 0x08, 0x48, 0x30, 0x00, // 4A
  1242. 0x44, 0x48, 0x50, 0x60, 0x50, 0x48, 0x44, 0x00, // 4B
  1243. 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x7C, 0x00, // 4C
  1244. 0x44, 0x6C, 0x54, 0x54, 0x44, 0x44, 0x44, 0x00, // 4D
  1245. 0x44, 0x44, 0x64, 0x54, 0x4C, 0x44, 0x44, 0x00, // 4E
  1246. 0x38, 0x44, 0x44, 0x44, 0x44, 0x44, 0x38, 0x00, // 4F
  1247. 0x78, 0x44, 0x44, 0x78, 0x40, 0x40, 0x40, 0x00, // 50
  1248. 0x38, 0x44, 0x44, 0x44, 0x54, 0x48, 0x34, 0x00, // 51
  1249. 0x78, 0x44, 0x44, 0x78, 0x50, 0x48, 0x44, 0x00, // 52
  1250. 0x3C, 0x40, 0x40, 0x38, 0x04, 0x04, 0x78, 0x00, // 53
  1251. 0x7C, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x00, // 54
  1252. 0x44, 0x44, 0x44, 0x44, 0x44, 0x44, 0x38, 0x00, // 55
  1253. 0x44, 0x44, 0x44, 0x44, 0x44, 0x28, 0x10, 0x00, // 56
  1254. 0x44, 0x44, 0x44, 0x54, 0x54, 0x6C, 0x44, 0x00, // 57
  1255. 0x44, 0x44, 0x28, 0x10, 0x28, 0x44, 0x44, 0x00, // 58
  1256. 0x44, 0x44, 0x44, 0x28, 0x10, 0x10, 0x10, 0x00, // 59
  1257. 0x7C, 0x04, 0x08, 0x10, 0x20, 0x40, 0x7C, 0x00, // 5A
  1258. 0x38, 0x20, 0x20, 0x20, 0x20, 0x20, 0x38, 0x00, // 5B
  1259. 0x00, 0x40, 0x20, 0x10, 0x08, 0x04, 0x00, 0x00, // 5C
  1260. 0x38, 0x08, 0x08, 0x08, 0x08, 0x08, 0x38, 0x00, // 5D
  1261. 0x10, 0x28, 0x44, 0x00, 0x00, 0x00, 0x00, 0x00, // 5E
  1262. 0x00, 0x00, 0x00, 0x00, 0x00, 0x7C, 0x00, 0x00, // 5F
  1263. 0x00, 0x20, 0x10, 0x08, 0x00, 0x00, 0x00, 0x00, // 60
  1264. 0x00, 0x00, 0x34, 0x4C, 0x44, 0x44, 0x3A, 0x00, // 61
  1265. 0x40, 0x40, 0x58, 0x64, 0x44, 0x44, 0x78, 0x00, // 62
  1266. 0x00, 0x00, 0x38, 0x44, 0x40, 0x44, 0x38, 0x00, // 63
  1267. 0x04, 0x04, 0x34, 0x4C, 0x44, 0x44, 0x3A, 0x00, // 64
  1268. 0x00, 0x00, 0x38, 0x44, 0x7C, 0x40, 0x38, 0x00, // 65
  1269. 0x08, 0x10, 0x38, 0x10, 0x10, 0x10, 0x10, 0x00, // 66
  1270. 0x00, 0x00, 0x34, 0x4C, 0x44, 0x3C, 0x04, 0x38, // 67
  1271. 0x40, 0x40, 0x58, 0x64, 0x44, 0x44, 0x44, 0x00, // 68
  1272. 0x10, 0x00, 0x10, 0x10, 0x10, 0x10, 0x08, 0x00, // 69
  1273. 0x10, 0x00, 0x10, 0x10, 0x10, 0x10, 0x10, 0x20, // 6A
  1274. 0x40, 0x40, 0x48, 0x50, 0x70, 0x48, 0x44, 0x00, // 6B
  1275. 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x08, 0x00, // 6C
  1276. 0x00, 0x00, 0x68, 0x54, 0x54, 0x54, 0x54, 0x00, // 6D
  1277. 0x00, 0x00, 0x58, 0x64, 0x44, 0x44, 0x44, 0x00, // 6E
  1278. 0x00, 0x00, 0x38, 0x44, 0x44, 0x44, 0x38, 0x00, // 6F
  1279. 0x00, 0x00, 0x58, 0x64, 0x44, 0x78, 0x40, 0x40, // 70
  1280. 0x00, 0x00, 0x34, 0x4C, 0x44, 0x3C, 0x04, 0x04, // 71
  1281. 0x00, 0x00, 0x58, 0x64, 0x40, 0x40, 0x40, 0x00, // 72
  1282. 0x00, 0x00, 0x38, 0x40, 0x38, 0x04, 0x78, 0x00, // 73
  1283. 0x10, 0x10, 0x38, 0x10, 0x10, 0x10, 0x08, 0x00, // 74
  1284. 0x00, 0x00, 0x44, 0x44, 0x44, 0x4C, 0x34, 0x00, // 75
  1285. 0x00, 0x00, 0x44, 0x44, 0x44, 0x28, 0x10, 0x00, // 76
  1286. 0x00, 0x00, 0x54, 0x54, 0x54, 0x54, 0x28, 0x00, // 77
  1287. 0x00, 0x00, 0x44, 0x28, 0x10, 0x28, 0x44, 0x00, // 78
  1288. 0x00, 0x00, 0x44, 0x44, 0x44, 0x3C, 0x04, 0x38, // 79
  1289. 0x00, 0x00, 0x7C, 0x08, 0x10, 0x20, 0x7C, 0x00, // 7A
  1290. 0x08, 0x10, 0x10, 0x20, 0x10, 0x10, 0x08, 0x00, // 7B
  1291. 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x00, // 7C
  1292. 0x20, 0x10, 0x10, 0x08, 0x10, 0x10, 0x20, 0x00, // 7D
  1293. 0x00, 0x00, 0x00, 0x32, 0x4C, 0x00, 0x00, 0x00, // 7E
  1294. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // 7F
  1295. 0xC0, 0x20, 0x10, 0x10, 0x10, 0x10, 0x20, 0xC0, // 80
  1296. 0x03, 0x04, 0x08, 0x08, 0x08, 0x08, 0x04, 0x03, // 81
  1297. 0x81, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00, // 82
  1298. 0x00, 0x00, 0x00, 0x00, 0x3C, 0x42, 0x81, 0x81, // 83
  1299. 0x10, 0x10, 0x20, 0xC0, 0x00, 0x00, 0x00, 0x00, // 84
  1300. 0x08, 0x08, 0x04, 0x03, 0x00, 0x00, 0x00, 0x00, // 85
  1301. 0x00, 0x00, 0x00, 0x00, 0x03, 0x04, 0x08, 0x08, // 86
  1302. 0x00, 0x00, 0x00, 0x00, 0xC0, 0x20, 0x10, 0x10, // 87
  1303. 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0xFF, // 88
  1304. 0xFF, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, // 89
  1305. 0x00, 0x10, 0x28, 0x44, 0x82, 0x44, 0x28, 0x10, // 8A
  1306. 0xFF, 0xEF, 0xC7, 0x83, 0x01, 0x83, 0xC7, 0xEF, // 8B
  1307. 0x3C, 0x42, 0x81, 0x81, 0x81, 0x81, 0x42, 0x3C, // 8C
  1308. 0xC3, 0x81, 0x00, 0x00, 0x00, 0x00, 0x81, 0xC3, // 8D
  1309. 0xFF, 0xFE, 0xFC, 0xF8, 0xF0, 0xE0, 0xC0, 0x80, // 8E
  1310. 0x80, 0xC0, 0xE0, 0xF0, 0xF8, 0xFC, 0xFE, 0xFF, // 8F
  1311. 0x01, 0x02, 0x04, 0x08, 0x10, 0x20, 0x40, 0x80, // 90
  1312. 0x80, 0x40, 0x20, 0x10, 0x08, 0x04, 0x02, 0x01, // 91
  1313. 0x00, 0x00, 0x00, 0x00, 0x03, 0x0C, 0x30, 0xC0, // 92
  1314. 0x03, 0x0C, 0x30, 0xC0, 0x00, 0x00, 0x00, 0x00, // 93
  1315. 0x03, 0x0C, 0x30, 0xC0, 0xC0, 0x30, 0x0C, 0x03, // 94
  1316. 0x00, 0x00, 0x00, 0x00, 0xC0, 0x30, 0x0C, 0x03, // 95
  1317. 0xC0, 0x30, 0x0C, 0x03, 0x00, 0x00, 0x00, 0x00, // 96
  1318. 0xC0, 0x30, 0x0C, 0x03, 0x03, 0x0C, 0x30, 0xC0, // 97
  1319. 0x10, 0x10, 0x20, 0x20, 0x40, 0x40, 0x80, 0x80, // 98
  1320. 0x01, 0x01, 0x02, 0x02, 0x04, 0x04, 0x08, 0x08, // 99
  1321. 0x81, 0x81, 0x42, 0x42, 0x24, 0x24, 0x18, 0x18, // 9A
  1322. 0x80, 0x80, 0x40, 0x40, 0x20, 0x20, 0x10, 0x10, // 9B
  1323. 0x08, 0x08, 0x04, 0x04, 0x02, 0x02, 0x01, 0x01, // 9C
  1324. 0x18, 0x18, 0x24, 0x24, 0x42, 0x42, 0x81, 0x81, // 9D
  1325. 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 9E
  1326. 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, // 9F
  1327. 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x00, 0x00, 0x00, // A0
  1328. 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, // A1
  1329. 0x18, 0x18, 0x18, 0xFF, 0xFF, 0x00, 0x00, 0x00, // A2
  1330. 0x18, 0x18, 0x18, 0x1F, 0x1F, 0x18, 0x18, 0x18, // A3
  1331. 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x18, 0x18, 0x18, // A4
  1332. 0x18, 0x18, 0x18, 0xF8, 0xF8, 0x18, 0x18, 0x18, // A5
  1333. 0x18, 0x18, 0x18, 0xFF, 0xFF, 0x18, 0x18, 0x18, // A6
  1334. 0x18, 0x18, 0x18, 0x1F, 0x1F, 0x00, 0x00, 0x00, // A7
  1335. 0x00, 0x00, 0x00, 0x1F, 0x1F, 0x18, 0x18, 0x18, // A8
  1336. 0x00, 0x00, 0x00, 0xF8, 0xF8, 0x18, 0x18, 0x18, // A9
  1337. 0x18, 0x18, 0x18, 0xF8, 0xF8, 0x00, 0x00, 0x00, // AA
  1338. 0x80, 0x80, 0x80, 0x40, 0x40, 0x20, 0x18, 0x07, // AB
  1339. 0x01, 0x01, 0x01, 0x02, 0x02, 0x04, 0x18, 0xE0, // AC
  1340. 0xE0, 0x18, 0x04, 0x02, 0x02, 0x01, 0x01, 0x01, // AD
  1341. 0x07, 0x18, 0x20, 0x40, 0x40, 0x80, 0x80, 0x80, // AE
  1342. 0x81, 0x42, 0x24, 0x18, 0x18, 0x24, 0x42, 0x81, // AF
  1343. 0xF0, 0xF0, 0xF0, 0xF0, 0x00, 0x00, 0x00, 0x00, // B0
  1344. 0x0F, 0x0F, 0x0F, 0x0F, 0x00, 0x00, 0x00, 0x00, // B1
  1345. 0x00, 0x00, 0x00, 0x00, 0x0F, 0x0F, 0x0F, 0x0F, // B2
  1346. 0x00, 0x00, 0x00, 0x00, 0xF0, 0xF0, 0xF0, 0xF0, // B3
  1347. 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, // B4
  1348. 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, // B5
  1349. 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x00, // B6
  1350. 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, // B7
  1351. 0xF0, 0xF0, 0xF0, 0xF0, 0x0F, 0x0F, 0x0F, 0x0F, // B8
  1352. 0x0F, 0x0F, 0x0F, 0x0F, 0xF0, 0xF0, 0xF0, 0xF0, // B9
  1353. 0x0F, 0x0F, 0x0F, 0x0F, 0xFF, 0xFF, 0xFF, 0xFF, // BA
  1354. 0xF0, 0xF0, 0xF0, 0xF0, 0xFF, 0xFF, 0xFF, 0xFF, // BB
  1355. 0xFF, 0xFF, 0xFF, 0xFF, 0xF0, 0xF0, 0xF0, 0xF0, // BC
  1356. 0xFF, 0xFF, 0xFF, 0xFF, 0x0F, 0x0F, 0x0F, 0x0F, // BD
  1357. 0x01, 0x03, 0x07, 0x0F, 0x1F, 0x3F, 0x7F, 0xFF, // BE
  1358. 0xFF, 0x7F, 0x3F, 0x1F, 0x0F, 0x07, 0x03, 0x01, // BF
  1359. 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, // C0
  1360. 0xFF, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, // C1
  1361. 0xFF, 0x80, 0x80, 0x9C, 0x9C, 0x9C, 0x80, 0x80, // C2
  1362. 0xFF, 0xFF, 0xFF, 0xE3, 0xE3, 0xE3, 0xFF, 0xFF, // C3
  1363. 0x18, 0x3C, 0x7E, 0x3C, 0x18, 0x3C, 0x7E, 0xFF, // C4
  1364. 0xFF, 0x00, 0xFF, 0x00, 0xFF, 0x00, 0xFF, 0x00, // C5
  1365. 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, // C6
  1366. 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, // C7
  1367. 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0xFF, // C8
  1368. 0x00, 0x10, 0x38, 0x7C, 0xFE, 0x7C, 0x38, 0x10, // C9
  1369. 0x38, 0x10, 0x92, 0xFE, 0x92, 0x10, 0x38, 0x7C, // CA
  1370. 0x00, 0x6C, 0xFE, 0xFE, 0xFE, 0x7C, 0x38, 0x10, // CB
  1371. 0x10, 0x38, 0x7C, 0xFE, 0xFE, 0x7C, 0x10, 0x7C, // CC
  1372. 0xE7, 0xE7, 0x42, 0xFF, 0xFF, 0x42, 0xE7, 0xE7, // CD
  1373. 0xDB, 0xFF, 0xDB, 0x18, 0x18, 0xDB, 0xFF, 0xDB, // CE
  1374. 0x3C, 0x7E, 0xFF, 0xFF, 0xFF, 0xFF, 0x7E, 0x3C, // CF
  1375. 0xC0, 0xC0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // D0
  1376. 0x30, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // D1
  1377. 0x0C, 0x0C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // D2
  1378. 0x03, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // D3
  1379. 0x00, 0x00, 0xC0, 0xC0, 0x00, 0x00, 0x00, 0x00, // D4
  1380. 0x00, 0x00, 0x30, 0x30, 0x00, 0x00, 0x00, 0x00, // D5
  1381. 0x00, 0x00, 0x0C, 0x0C, 0x00, 0x00, 0x00, 0x00, // D6
  1382. 0x00, 0x00, 0x03, 0x03, 0x00, 0x00, 0x00, 0x00, // D7
  1383. 0x00, 0x00, 0x00, 0x00, 0xC0, 0xC0, 0x00, 0x00, // D8
  1384. 0x00, 0x00, 0x00, 0x00, 0x30, 0x30, 0x00, 0x00, // D9
  1385. 0x00, 0x00, 0x00, 0x00, 0x0C, 0x0C, 0x00, 0x00, // DA
  1386. 0x00, 0x00, 0x00, 0x00, 0x03, 0x03, 0x00, 0x00, // DB
  1387. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xC0, 0xC0, // DC
  1388. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x30, // DD
  1389. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0C, 0x0C, // DE
  1390. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x03, // DF
  1391. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0F, 0x0F, // E0
  1392. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3F, 0x3F, // E1
  1393. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, // E2
  1394. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFC, 0xFC, // E3
  1395. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF0, 0xF0, // E4
  1396. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xC0, 0xC0, // E5
  1397. 0x00, 0x00, 0x00, 0x00, 0xC0, 0xC0, 0xC0, 0xC0, // E6
  1398. 0x00, 0x00, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, // E7
  1399. 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, // E8
  1400. 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0x00, 0x00, // E9
  1401. 0xC0, 0xC0, 0xC0, 0xC0, 0x00, 0x00, 0x00, 0x00, // EA
  1402. 0xC0, 0xC0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // EB
  1403. 0xF0, 0xF0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // EC
  1404. 0xFC, 0xFC, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // ED
  1405. 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // EE
  1406. 0x3F, 0x3F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // EF
  1407. 0x0F, 0x0F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // F0
  1408. 0x03, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // F1
  1409. 0x03, 0x03, 0x03, 0x03, 0x00, 0x00, 0x00, 0x00, // F2
  1410. 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x00, 0x00, // F3
  1411. 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, // F4
  1412. 0x00, 0x00, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, // F5
  1413. 0x00, 0x00, 0x00, 0x00, 0x03, 0x03, 0x03, 0x03, // F6
  1414. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x03, // F7
  1415. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, // F8
  1416. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, // F9
  1417. 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xFF, // FA
  1418. 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, // FB
  1419. 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // FC
  1420. 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // FD
  1421. 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // FE
  1422. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // FF
  1423. };
  1424. static const uint8_t _sdtx_font_cpc[2048] = {
  1425. 0xFF, 0xC3, 0xC3, 0xC3, 0xC3, 0xC3, 0xC3, 0xFF, // 00
  1426. 0xFF, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, // 01
  1427. 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0xFF, // 02
  1428. 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0xFF, // 03
  1429. 0x0C, 0x18, 0x30, 0x7E, 0x0C, 0x18, 0x30, 0x00, // 04
  1430. 0xFF, 0xC3, 0xE7, 0xDB, 0xDB, 0xE7, 0xC3, 0xFF, // 05
  1431. 0x00, 0x01, 0x03, 0x06, 0xCC, 0x78, 0x30, 0x00, // 06
  1432. 0x3C, 0x66, 0xC3, 0xC3, 0xFF, 0x24, 0xE7, 0x00, // 07
  1433. 0x00, 0x00, 0x30, 0x60, 0xFF, 0x60, 0x30, 0x00, // 08
  1434. 0x00, 0x00, 0x0C, 0x06, 0xFF, 0x06, 0x0C, 0x00, // 09
  1435. 0x18, 0x18, 0x18, 0x18, 0xDB, 0x7E, 0x3C, 0x18, // 0A
  1436. 0x18, 0x3C, 0x7E, 0xDB, 0x18, 0x18, 0x18, 0x18, // 0B
  1437. 0x18, 0x5A, 0x3C, 0x99, 0xDB, 0x7E, 0x3C, 0x18, // 0C
  1438. 0x00, 0x03, 0x33, 0x63, 0xFE, 0x60, 0x30, 0x00, // 0D
  1439. 0x3C, 0x66, 0xFF, 0xDB, 0xDB, 0xFF, 0x66, 0x3C, // 0E
  1440. 0x3C, 0x66, 0xC3, 0xDB, 0xDB, 0xC3, 0x66, 0x3C, // 0F
  1441. 0xFF, 0xC3, 0xC3, 0xFF, 0xC3, 0xC3, 0xC3, 0xFF, // 10
  1442. 0x3C, 0x7E, 0xDB, 0xDB, 0xDF, 0xC3, 0x66, 0x3C, // 11
  1443. 0x3C, 0x66, 0xC3, 0xDF, 0xDB, 0xDB, 0x7E, 0x3C, // 12
  1444. 0x3C, 0x66, 0xC3, 0xFB, 0xDB, 0xDB, 0x7E, 0x3C, // 13
  1445. 0x3C, 0x7E, 0xDB, 0xDB, 0xFB, 0xC3, 0x66, 0x3C, // 14
  1446. 0x00, 0x01, 0x33, 0x1E, 0xCE, 0x7B, 0x31, 0x00, // 15
  1447. 0x7E, 0x66, 0x66, 0x66, 0x66, 0x66, 0x66, 0xE7, // 16
  1448. 0x03, 0x03, 0x03, 0xFF, 0x03, 0x03, 0x03, 0x00, // 17
  1449. 0xFF, 0x66, 0x3C, 0x18, 0x18, 0x3C, 0x66, 0xFF, // 18
  1450. 0x18, 0x18, 0x3C, 0x3C, 0x3C, 0x3C, 0x18, 0x18, // 19
  1451. 0x3C, 0x66, 0x66, 0x30, 0x18, 0x00, 0x18, 0x00, // 1A
  1452. 0x3C, 0x66, 0xC3, 0xFF, 0xC3, 0xC3, 0x66, 0x3C, // 1B
  1453. 0xFF, 0xDB, 0xDB, 0xDB, 0xFB, 0xC3, 0xC3, 0xFF, // 1C
  1454. 0xFF, 0xC3, 0xC3, 0xFB, 0xDB, 0xDB, 0xDB, 0xFF, // 1D
  1455. 0xFF, 0xC3, 0xC3, 0xDF, 0xDB, 0xDB, 0xDB, 0xFF, // 1E
  1456. 0xFF, 0xDB, 0xDB, 0xDB, 0xDF, 0xC3, 0xC3, 0xFF, // 1F
  1457. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 20
  1458. 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x18, 0x00, // 21
  1459. 0x6C, 0x6C, 0x6C, 0x00, 0x00, 0x00, 0x00, 0x00, // 22
  1460. 0x6C, 0x6C, 0xFE, 0x6C, 0xFE, 0x6C, 0x6C, 0x00, // 23
  1461. 0x18, 0x3E, 0x58, 0x3C, 0x1A, 0x7C, 0x18, 0x00, // 24
  1462. 0x00, 0xC6, 0xCC, 0x18, 0x30, 0x66, 0xC6, 0x00, // 25
  1463. 0x38, 0x6C, 0x38, 0x76, 0xDC, 0xCC, 0x76, 0x00, // 26
  1464. 0x18, 0x18, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, // 27
  1465. 0x0C, 0x18, 0x30, 0x30, 0x30, 0x18, 0x0C, 0x00, // 28
  1466. 0x30, 0x18, 0x0C, 0x0C, 0x0C, 0x18, 0x30, 0x00, // 29
  1467. 0x00, 0x66, 0x3C, 0xFF, 0x3C, 0x66, 0x00, 0x00, // 2A
  1468. 0x00, 0x18, 0x18, 0x7E, 0x18, 0x18, 0x00, 0x00, // 2B
  1469. 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x30, // 2C
  1470. 0x00, 0x00, 0x00, 0x7E, 0x00, 0x00, 0x00, 0x00, // 2D
  1471. 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, // 2E
  1472. 0x06, 0x0C, 0x18, 0x30, 0x60, 0xC0, 0x80, 0x00, // 2F
  1473. 0x7C, 0xC6, 0xCE, 0xD6, 0xE6, 0xC6, 0x7C, 0x00, // 30
  1474. 0x18, 0x38, 0x18, 0x18, 0x18, 0x18, 0x7E, 0x00, // 31
  1475. 0x3C, 0x66, 0x06, 0x3C, 0x60, 0x66, 0x7E, 0x00, // 32
  1476. 0x3C, 0x66, 0x06, 0x1C, 0x06, 0x66, 0x3C, 0x00, // 33
  1477. 0x1C, 0x3C, 0x6C, 0xCC, 0xFE, 0x0C, 0x1E, 0x00, // 34
  1478. 0x7E, 0x62, 0x60, 0x7C, 0x06, 0x66, 0x3C, 0x00, // 35
  1479. 0x3C, 0x66, 0x60, 0x7C, 0x66, 0x66, 0x3C, 0x00, // 36
  1480. 0x7E, 0x66, 0x06, 0x0C, 0x18, 0x18, 0x18, 0x00, // 37
  1481. 0x3C, 0x66, 0x66, 0x3C, 0x66, 0x66, 0x3C, 0x00, // 38
  1482. 0x3C, 0x66, 0x66, 0x3E, 0x06, 0x66, 0x3C, 0x00, // 39
  1483. 0x00, 0x00, 0x18, 0x18, 0x00, 0x18, 0x18, 0x00, // 3A
  1484. 0x00, 0x00, 0x18, 0x18, 0x00, 0x18, 0x18, 0x30, // 3B
  1485. 0x0C, 0x18, 0x30, 0x60, 0x30, 0x18, 0x0C, 0x00, // 3C
  1486. 0x00, 0x00, 0x7E, 0x00, 0x00, 0x7E, 0x00, 0x00, // 3D
  1487. 0x60, 0x30, 0x18, 0x0C, 0x18, 0x30, 0x60, 0x00, // 3E
  1488. 0x3C, 0x66, 0x66, 0x0C, 0x18, 0x00, 0x18, 0x00, // 3F
  1489. 0x7C, 0xC6, 0xDE, 0xDE, 0xDE, 0xC0, 0x7C, 0x00, // 40
  1490. 0x18, 0x3C, 0x66, 0x66, 0x7E, 0x66, 0x66, 0x00, // 41
  1491. 0xFC, 0x66, 0x66, 0x7C, 0x66, 0x66, 0xFC, 0x00, // 42
  1492. 0x3C, 0x66, 0xC0, 0xC0, 0xC0, 0x66, 0x3C, 0x00, // 43
  1493. 0xF8, 0x6C, 0x66, 0x66, 0x66, 0x6C, 0xF8, 0x00, // 44
  1494. 0xFE, 0x62, 0x68, 0x78, 0x68, 0x62, 0xFE, 0x00, // 45
  1495. 0xFE, 0x62, 0x68, 0x78, 0x68, 0x60, 0xF0, 0x00, // 46
  1496. 0x3C, 0x66, 0xC0, 0xC0, 0xCE, 0x66, 0x3E, 0x00, // 47
  1497. 0x66, 0x66, 0x66, 0x7E, 0x66, 0x66, 0x66, 0x00, // 48
  1498. 0x7E, 0x18, 0x18, 0x18, 0x18, 0x18, 0x7E, 0x00, // 49
  1499. 0x1E, 0x0C, 0x0C, 0x0C, 0xCC, 0xCC, 0x78, 0x00, // 4A
  1500. 0xE6, 0x66, 0x6C, 0x78, 0x6C, 0x66, 0xE6, 0x00, // 4B
  1501. 0xF0, 0x60, 0x60, 0x60, 0x62, 0x66, 0xFE, 0x00, // 4C
  1502. 0xC6, 0xEE, 0xFE, 0xFE, 0xD6, 0xC6, 0xC6, 0x00, // 4D
  1503. 0xC6, 0xE6, 0xF6, 0xDE, 0xCE, 0xC6, 0xC6, 0x00, // 4E
  1504. 0x38, 0x6C, 0xC6, 0xC6, 0xC6, 0x6C, 0x38, 0x00, // 4F
  1505. 0xFC, 0x66, 0x66, 0x7C, 0x60, 0x60, 0xF0, 0x00, // 50
  1506. 0x38, 0x6C, 0xC6, 0xC6, 0xDA, 0xCC, 0x76, 0x00, // 51
  1507. 0xFC, 0x66, 0x66, 0x7C, 0x6C, 0x66, 0xE6, 0x00, // 52
  1508. 0x3C, 0x66, 0x60, 0x3C, 0x06, 0x66, 0x3C, 0x00, // 53
  1509. 0x7E, 0x5A, 0x18, 0x18, 0x18, 0x18, 0x3C, 0x00, // 54
  1510. 0x66, 0x66, 0x66, 0x66, 0x66, 0x66, 0x3C, 0x00, // 55
  1511. 0x66, 0x66, 0x66, 0x66, 0x66, 0x3C, 0x18, 0x00, // 56
  1512. 0xC6, 0xC6, 0xC6, 0xD6, 0xFE, 0xEE, 0xC6, 0x00, // 57
  1513. 0xC6, 0x6C, 0x38, 0x38, 0x6C, 0xC6, 0xC6, 0x00, // 58
  1514. 0x66, 0x66, 0x66, 0x3C, 0x18, 0x18, 0x3C, 0x00, // 59
  1515. 0xFE, 0xC6, 0x8C, 0x18, 0x32, 0x66, 0xFE, 0x00, // 5A
  1516. 0x3C, 0x30, 0x30, 0x30, 0x30, 0x30, 0x3C, 0x00, // 5B
  1517. 0xC0, 0x60, 0x30, 0x18, 0x0C, 0x06, 0x02, 0x00, // 5C
  1518. 0x3C, 0x0C, 0x0C, 0x0C, 0x0C, 0x0C, 0x3C, 0x00, // 5D
  1519. 0x18, 0x3C, 0x7E, 0x18, 0x18, 0x18, 0x18, 0x00, // 5E
  1520. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, // 5F
  1521. 0x30, 0x18, 0x0C, 0x00, 0x00, 0x00, 0x00, 0x00, // 60
  1522. 0x00, 0x00, 0x78, 0x0C, 0x7C, 0xCC, 0x76, 0x00, // 61
  1523. 0xE0, 0x60, 0x7C, 0x66, 0x66, 0x66, 0xDC, 0x00, // 62
  1524. 0x00, 0x00, 0x3C, 0x66, 0x60, 0x66, 0x3C, 0x00, // 63
  1525. 0x1C, 0x0C, 0x7C, 0xCC, 0xCC, 0xCC, 0x76, 0x00, // 64
  1526. 0x00, 0x00, 0x3C, 0x66, 0x7E, 0x60, 0x3C, 0x00, // 65
  1527. 0x1C, 0x36, 0x30, 0x78, 0x30, 0x30, 0x78, 0x00, // 66
  1528. 0x00, 0x00, 0x3E, 0x66, 0x66, 0x3E, 0x06, 0x7C, // 67
  1529. 0xE0, 0x60, 0x6C, 0x76, 0x66, 0x66, 0xE6, 0x00, // 68
  1530. 0x18, 0x00, 0x38, 0x18, 0x18, 0x18, 0x3C, 0x00, // 69
  1531. 0x06, 0x00, 0x0E, 0x06, 0x06, 0x66, 0x66, 0x3C, // 6A
  1532. 0xE0, 0x60, 0x66, 0x6C, 0x78, 0x6C, 0xE6, 0x00, // 6B
  1533. 0x38, 0x18, 0x18, 0x18, 0x18, 0x18, 0x3C, 0x00, // 6C
  1534. 0x00, 0x00, 0x6C, 0xFE, 0xD6, 0xD6, 0xC6, 0x00, // 6D
  1535. 0x00, 0x00, 0xDC, 0x66, 0x66, 0x66, 0x66, 0x00, // 6E
  1536. 0x00, 0x00, 0x3C, 0x66, 0x66, 0x66, 0x3C, 0x00, // 6F
  1537. 0x00, 0x00, 0xDC, 0x66, 0x66, 0x7C, 0x60, 0xF0, // 70
  1538. 0x00, 0x00, 0x76, 0xCC, 0xCC, 0x7C, 0x0C, 0x1E, // 71
  1539. 0x00, 0x00, 0xDC, 0x76, 0x60, 0x60, 0xF0, 0x00, // 72
  1540. 0x00, 0x00, 0x3C, 0x60, 0x3C, 0x06, 0x7C, 0x00, // 73
  1541. 0x30, 0x30, 0x7C, 0x30, 0x30, 0x36, 0x1C, 0x00, // 74
  1542. 0x00, 0x00, 0x66, 0x66, 0x66, 0x66, 0x3E, 0x00, // 75
  1543. 0x00, 0x00, 0x66, 0x66, 0x66, 0x3C, 0x18, 0x00, // 76
  1544. 0x00, 0x00, 0xC6, 0xD6, 0xD6, 0xFE, 0x6C, 0x00, // 77
  1545. 0x00, 0x00, 0xC6, 0x6C, 0x38, 0x6C, 0xC6, 0x00, // 78
  1546. 0x00, 0x00, 0x66, 0x66, 0x66, 0x3E, 0x06, 0x7C, // 79
  1547. 0x00, 0x00, 0x7E, 0x4C, 0x18, 0x32, 0x7E, 0x00, // 7A
  1548. 0x0E, 0x18, 0x18, 0x70, 0x18, 0x18, 0x0E, 0x00, // 7B
  1549. 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, // 7C
  1550. 0x70, 0x18, 0x18, 0x0E, 0x18, 0x18, 0x70, 0x00, // 7D
  1551. 0x76, 0xDC, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 7E
  1552. 0xCC, 0x33, 0xCC, 0x33, 0xCC, 0x33, 0xCC, 0x33, // 7F
  1553. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 80
  1554. 0xF0, 0xF0, 0xF0, 0xF0, 0x00, 0x00, 0x00, 0x00, // 81
  1555. 0x0F, 0x0F, 0x0F, 0x0F, 0x00, 0x00, 0x00, 0x00, // 82
  1556. 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x00, // 83
  1557. 0x00, 0x00, 0x00, 0x00, 0xF0, 0xF0, 0xF0, 0xF0, // 84
  1558. 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, // 85
  1559. 0x0F, 0x0F, 0x0F, 0x0F, 0xF0, 0xF0, 0xF0, 0xF0, // 86
  1560. 0xFF, 0xFF, 0xFF, 0xFF, 0xF0, 0xF0, 0xF0, 0xF0, // 87
  1561. 0x00, 0x00, 0x00, 0x00, 0x0F, 0x0F, 0x0F, 0x0F, // 88
  1562. 0xF0, 0xF0, 0xF0, 0xF0, 0x0F, 0x0F, 0x0F, 0x0F, // 89
  1563. 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, // 8A
  1564. 0xFF, 0xFF, 0xFF, 0xFF, 0x0F, 0x0F, 0x0F, 0x0F, // 8B
  1565. 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, // 8C
  1566. 0xF0, 0xF0, 0xF0, 0xF0, 0xFF, 0xFF, 0xFF, 0xFF, // 8D
  1567. 0x0F, 0x0F, 0x0F, 0x0F, 0xFF, 0xFF, 0xFF, 0xFF, // 8E
  1568. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // 8F
  1569. 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, // 90
  1570. 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00, 0x00, // 91
  1571. 0x00, 0x00, 0x00, 0x1F, 0x1F, 0x00, 0x00, 0x00, // 92
  1572. 0x18, 0x18, 0x18, 0x1F, 0x0F, 0x00, 0x00, 0x00, // 93
  1573. 0x00, 0x00, 0x00, 0x18, 0x18, 0x18, 0x18, 0x18, // 94
  1574. 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, // 95
  1575. 0x00, 0x00, 0x00, 0x0F, 0x1F, 0x18, 0x18, 0x18, // 96
  1576. 0x18, 0x18, 0x18, 0x1F, 0x1F, 0x18, 0x18, 0x18, // 97
  1577. 0x00, 0x00, 0x00, 0xF8, 0xF8, 0x00, 0x00, 0x00, // 98
  1578. 0x18, 0x18, 0x18, 0xF8, 0xF0, 0x00, 0x00, 0x00, // 99
  1579. 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x00, 0x00, 0x00, // 9A
  1580. 0x18, 0x18, 0x18, 0xFF, 0xFF, 0x00, 0x00, 0x00, // 9B
  1581. 0x00, 0x00, 0x00, 0xF0, 0xF8, 0x18, 0x18, 0x18, // 9C
  1582. 0x18, 0x18, 0x18, 0xF8, 0xF8, 0x18, 0x18, 0x18, // 9D
  1583. 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x18, 0x18, 0x18, // 9E
  1584. 0x18, 0x18, 0x18, 0xFF, 0xFF, 0x18, 0x18, 0x18, // 9F
  1585. 0x10, 0x38, 0x6C, 0xC6, 0x00, 0x00, 0x00, 0x00, // A0
  1586. 0x0C, 0x18, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, // A1
  1587. 0x66, 0x66, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // A2
  1588. 0x3C, 0x66, 0x60, 0xF8, 0x60, 0x66, 0xFE, 0x00, // A3
  1589. 0x38, 0x44, 0xBA, 0xA2, 0xBA, 0x44, 0x38, 0x00, // A4
  1590. 0x7E, 0xF4, 0xF4, 0x74, 0x34, 0x34, 0x34, 0x00, // A5
  1591. 0x1E, 0x30, 0x38, 0x6C, 0x38, 0x18, 0xF0, 0x00, // A6
  1592. 0x18, 0x18, 0x0C, 0x00, 0x00, 0x00, 0x00, 0x00, // A7
  1593. 0x40, 0xC0, 0x44, 0x4C, 0x54, 0x1E, 0x04, 0x00, // A8
  1594. 0x40, 0xC0, 0x4C, 0x52, 0x44, 0x08, 0x1E, 0x00, // A9
  1595. 0xE0, 0x10, 0x62, 0x16, 0xEA, 0x0F, 0x02, 0x00, // AA
  1596. 0x00, 0x18, 0x18, 0x7E, 0x18, 0x18, 0x7E, 0x00, // AB
  1597. 0x18, 0x18, 0x00, 0x7E, 0x00, 0x18, 0x18, 0x00, // AC
  1598. 0x00, 0x00, 0x00, 0x7E, 0x06, 0x06, 0x00, 0x00, // AD
  1599. 0x18, 0x00, 0x18, 0x30, 0x66, 0x66, 0x3C, 0x00, // AE
  1600. 0x18, 0x00, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, // AF
  1601. 0x00, 0x00, 0x73, 0xDE, 0xCC, 0xDE, 0x73, 0x00, // B0
  1602. 0x7C, 0xC6, 0xC6, 0xFC, 0xC6, 0xC6, 0xF8, 0xC0, // B1
  1603. 0x00, 0x66, 0x66, 0x3C, 0x66, 0x66, 0x3C, 0x00, // B2
  1604. 0x3C, 0x60, 0x60, 0x3C, 0x66, 0x66, 0x3C, 0x00, // B3
  1605. 0x00, 0x00, 0x1E, 0x30, 0x7C, 0x30, 0x1E, 0x00, // B4
  1606. 0x38, 0x6C, 0xC6, 0xFE, 0xC6, 0x6C, 0x38, 0x00, // B5
  1607. 0x00, 0xC0, 0x60, 0x30, 0x38, 0x6C, 0xC6, 0x00, // B6
  1608. 0x00, 0x00, 0x66, 0x66, 0x66, 0x7C, 0x60, 0x60, // B7
  1609. 0x00, 0x00, 0x00, 0xFE, 0x6C, 0x6C, 0x6C, 0x00, // B8
  1610. 0x00, 0x00, 0x00, 0x7E, 0xD8, 0xD8, 0x70, 0x00, // B9
  1611. 0x03, 0x06, 0x0C, 0x3C, 0x66, 0x3C, 0x60, 0xC0, // BA
  1612. 0x03, 0x06, 0x0C, 0x66, 0x66, 0x3C, 0x60, 0xC0, // BB
  1613. 0x00, 0xE6, 0x3C, 0x18, 0x38, 0x6C, 0xC7, 0x00, // BC
  1614. 0x00, 0x00, 0x66, 0xC3, 0xDB, 0xDB, 0x7E, 0x00, // BD
  1615. 0xFE, 0xC6, 0x60, 0x30, 0x60, 0xC6, 0xFE, 0x00, // BE
  1616. 0x00, 0x7C, 0xC6, 0xC6, 0xC6, 0x6C, 0xEE, 0x00, // BF
  1617. 0x18, 0x30, 0x60, 0xC0, 0x80, 0x00, 0x00, 0x00, // C0
  1618. 0x18, 0x0C, 0x06, 0x03, 0x01, 0x00, 0x00, 0x00, // C1
  1619. 0x00, 0x00, 0x00, 0x01, 0x03, 0x06, 0x0C, 0x18, // C2
  1620. 0x00, 0x00, 0x00, 0x80, 0xC0, 0x60, 0x30, 0x18, // C3
  1621. 0x18, 0x3C, 0x66, 0xC3, 0x81, 0x00, 0x00, 0x00, // C4
  1622. 0x18, 0x0C, 0x06, 0x03, 0x03, 0x06, 0x0C, 0x18, // C5
  1623. 0x00, 0x00, 0x00, 0x81, 0xC3, 0x66, 0x3C, 0x18, // C6
  1624. 0x18, 0x30, 0x60, 0xC0, 0xC0, 0x60, 0x30, 0x18, // C7
  1625. 0x18, 0x30, 0x60, 0xC1, 0x83, 0x06, 0x0C, 0x18, // C8
  1626. 0x18, 0x0C, 0x06, 0x83, 0xC1, 0x60, 0x30, 0x18, // C9
  1627. 0x18, 0x3C, 0x66, 0xC3, 0xC3, 0x66, 0x3C, 0x18, // CA
  1628. 0xC3, 0xE7, 0x7E, 0x3C, 0x3C, 0x7E, 0xE7, 0xC3, // CB
  1629. 0x03, 0x07, 0x0E, 0x1C, 0x38, 0x70, 0xE0, 0xC0, // CC
  1630. 0xC0, 0xE0, 0x70, 0x38, 0x1C, 0x0E, 0x07, 0x03, // CD
  1631. 0xCC, 0xCC, 0x33, 0x33, 0xCC, 0xCC, 0x33, 0x33, // CE
  1632. 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, // CF
  1633. 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // D0
  1634. 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, // D1
  1635. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, // D2
  1636. 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, // D3
  1637. 0xFF, 0xFE, 0xFC, 0xF8, 0xF0, 0xE0, 0xC0, 0x80, // D4
  1638. 0xFF, 0x7F, 0x3F, 0x1F, 0x0F, 0x07, 0x03, 0x01, // D5
  1639. 0x01, 0x03, 0x07, 0x0F, 0x1F, 0x3F, 0x7F, 0xFF, // D6
  1640. 0x80, 0xC0, 0xE0, 0xF0, 0xF8, 0xFC, 0xFE, 0xFF, // D7
  1641. 0xAA, 0x55, 0xAA, 0x55, 0x00, 0x00, 0x00, 0x00, // D8
  1642. 0x0A, 0x05, 0x0A, 0x05, 0x0A, 0x05, 0x0A, 0x05, // D9
  1643. 0x00, 0x00, 0x00, 0x00, 0xAA, 0x55, 0xAA, 0x55, // DA
  1644. 0xA0, 0x50, 0xA0, 0x50, 0xA0, 0x50, 0xA0, 0x50, // DB
  1645. 0xAA, 0x54, 0xA8, 0x50, 0xA0, 0x40, 0x80, 0x00, // DC
  1646. 0xAA, 0x55, 0x2A, 0x15, 0x0A, 0x05, 0x02, 0x01, // DD
  1647. 0x01, 0x02, 0x05, 0x0A, 0x15, 0x2A, 0x55, 0xAA, // DE
  1648. 0x00, 0x80, 0x40, 0xA0, 0x50, 0xA8, 0x54, 0xAA, // DF
  1649. 0x7E, 0xFF, 0x99, 0xFF, 0xBD, 0xC3, 0xFF, 0x7E, // E0
  1650. 0x7E, 0xFF, 0x99, 0xFF, 0xC3, 0xBD, 0xFF, 0x7E, // E1
  1651. 0x38, 0x38, 0xFE, 0xFE, 0xFE, 0x10, 0x38, 0x00, // E2
  1652. 0x10, 0x38, 0x7C, 0xFE, 0x7C, 0x38, 0x10, 0x00, // E3
  1653. 0x6C, 0xFE, 0xFE, 0xFE, 0x7C, 0x38, 0x10, 0x00, // E4
  1654. 0x10, 0x38, 0x7C, 0xFE, 0xFE, 0x10, 0x38, 0x00, // E5
  1655. 0x00, 0x3C, 0x66, 0xC3, 0xC3, 0x66, 0x3C, 0x00, // E6
  1656. 0x00, 0x3C, 0x7E, 0xFF, 0xFF, 0x7E, 0x3C, 0x00, // E7
  1657. 0x00, 0x7E, 0x66, 0x66, 0x66, 0x66, 0x7E, 0x00, // E8
  1658. 0x00, 0x7E, 0x7E, 0x7E, 0x7E, 0x7E, 0x7E, 0x00, // E9
  1659. 0x0F, 0x07, 0x0D, 0x78, 0xCC, 0xCC, 0xCC, 0x78, // EA
  1660. 0x3C, 0x66, 0x66, 0x66, 0x3C, 0x18, 0x7E, 0x18, // EB
  1661. 0x0C, 0x0C, 0x0C, 0x0C, 0x0C, 0x3C, 0x7C, 0x38, // EC
  1662. 0x18, 0x1C, 0x1E, 0x1B, 0x18, 0x78, 0xF8, 0x70, // ED
  1663. 0x99, 0x5A, 0x24, 0xC3, 0xC3, 0x24, 0x5A, 0x99, // EE
  1664. 0x10, 0x38, 0x38, 0x38, 0x38, 0x38, 0x7C, 0xD6, // EF
  1665. 0x18, 0x3C, 0x7E, 0xFF, 0x18, 0x18, 0x18, 0x18, // F0
  1666. 0x18, 0x18, 0x18, 0x18, 0xFF, 0x7E, 0x3C, 0x18, // F1
  1667. 0x10, 0x30, 0x70, 0xFF, 0xFF, 0x70, 0x30, 0x10, // F2
  1668. 0x08, 0x0C, 0x0E, 0xFF, 0xFF, 0x0E, 0x0C, 0x08, // F3
  1669. 0x00, 0x00, 0x18, 0x3C, 0x7E, 0xFF, 0xFF, 0x00, // F4
  1670. 0x00, 0x00, 0xFF, 0xFF, 0x7E, 0x3C, 0x18, 0x00, // F5
  1671. 0x80, 0xE0, 0xF8, 0xFE, 0xF8, 0xE0, 0x80, 0x00, // F6
  1672. 0x02, 0x0E, 0x3E, 0xFE, 0x3E, 0x0E, 0x02, 0x00, // F7
  1673. 0x38, 0x38, 0x92, 0x7C, 0x10, 0x28, 0x28, 0x28, // F8
  1674. 0x38, 0x38, 0x10, 0xFE, 0x10, 0x28, 0x44, 0x82, // F9
  1675. 0x38, 0x38, 0x12, 0x7C, 0x90, 0x28, 0x24, 0x22, // FA
  1676. 0x38, 0x38, 0x90, 0x7C, 0x12, 0x28, 0x48, 0x88, // FB
  1677. 0x00, 0x3C, 0x18, 0x3C, 0x3C, 0x3C, 0x18, 0x00, // FC
  1678. 0x3C, 0xFF, 0xFF, 0x18, 0x0C, 0x18, 0x30, 0x18, // FD
  1679. 0x18, 0x3C, 0x7E, 0x18, 0x18, 0x7E, 0x3C, 0x18, // FE
  1680. 0x00, 0x24, 0x66, 0xFF, 0x66, 0x24, 0x00, 0x00, // FF
  1681. };
  1682. static const uint8_t _sdtx_font_c64[2048] = {
  1683. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 00
  1684. 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, // 01
  1685. 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, // 02
  1686. 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 03
  1687. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, // 04
  1688. 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, // 05
  1689. 0xCC, 0xCC, 0x33, 0x33, 0xCC, 0xCC, 0x33, 0x33, // 06
  1690. 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, // 07
  1691. 0x00, 0x00, 0x00, 0x00, 0xCC, 0xCC, 0x33, 0x33, // 08
  1692. 0xCC, 0x99, 0x33, 0x66, 0xCC, 0x99, 0x33, 0x66, // 09
  1693. 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, // 0A
  1694. 0x18, 0x18, 0x18, 0x1F, 0x1F, 0x18, 0x18, 0x18, // 0B
  1695. 0x00, 0x00, 0x00, 0x00, 0x0F, 0x0F, 0x0F, 0x0F, // 0C
  1696. 0x18, 0x18, 0x18, 0x1F, 0x1F, 0x00, 0x00, 0x00, // 0D
  1697. 0x00, 0x00, 0x00, 0xF8, 0xF8, 0x18, 0x18, 0x18, // 0E
  1698. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, // 0F
  1699. 0x00, 0x00, 0x00, 0x1F, 0x1F, 0x18, 0x18, 0x18, // 10
  1700. 0x18, 0x18, 0x18, 0xFF, 0xFF, 0x00, 0x00, 0x00, // 11
  1701. 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x18, 0x18, 0x18, // 12
  1702. 0x18, 0x18, 0x18, 0xF8, 0xF8, 0x18, 0x18, 0x18, // 13
  1703. 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, // 14
  1704. 0xE0, 0xE0, 0xE0, 0xE0, 0xE0, 0xE0, 0xE0, 0xE0, // 15
  1705. 0x07, 0x07, 0x07, 0x07, 0x07, 0x07, 0x07, 0x07, // 16
  1706. 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 17
  1707. 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, // 18
  1708. 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xFF, // 19
  1709. 0x01, 0x03, 0x06, 0x6C, 0x78, 0x70, 0x60, 0x00, // 1A
  1710. 0x00, 0x00, 0x00, 0x00, 0xF0, 0xF0, 0xF0, 0xF0, // 1B
  1711. 0x0F, 0x0F, 0x0F, 0x0F, 0x00, 0x00, 0x00, 0x00, // 1C
  1712. 0x18, 0x18, 0x18, 0xF8, 0xF8, 0x00, 0x00, 0x00, // 1D
  1713. 0xF0, 0xF0, 0xF0, 0xF0, 0x00, 0x00, 0x00, 0x00, // 1E
  1714. 0xF0, 0xF0, 0xF0, 0xF0, 0x0F, 0x0F, 0x0F, 0x0F, // 1F
  1715. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 20
  1716. 0x18, 0x18, 0x18, 0x18, 0x00, 0x00, 0x18, 0x00, // 21
  1717. 0x66, 0x66, 0x66, 0x00, 0x00, 0x00, 0x00, 0x00, // 22
  1718. 0x66, 0x66, 0xFF, 0x66, 0xFF, 0x66, 0x66, 0x00, // 23
  1719. 0x18, 0x3E, 0x60, 0x3C, 0x06, 0x7C, 0x18, 0x00, // 24
  1720. 0x62, 0x66, 0x0C, 0x18, 0x30, 0x66, 0x46, 0x00, // 25
  1721. 0x3C, 0x66, 0x3C, 0x38, 0x67, 0x66, 0x3F, 0x00, // 26
  1722. 0x06, 0x0C, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, // 27
  1723. 0x0C, 0x18, 0x30, 0x30, 0x30, 0x18, 0x0C, 0x00, // 28
  1724. 0x30, 0x18, 0x0C, 0x0C, 0x0C, 0x18, 0x30, 0x00, // 29
  1725. 0x00, 0x66, 0x3C, 0xFF, 0x3C, 0x66, 0x00, 0x00, // 2A
  1726. 0x00, 0x18, 0x18, 0x7E, 0x18, 0x18, 0x00, 0x00, // 2B
  1727. 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x30, // 2C
  1728. 0x00, 0x00, 0x00, 0x7E, 0x00, 0x00, 0x00, 0x00, // 2D
  1729. 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, // 2E
  1730. 0x00, 0x03, 0x06, 0x0C, 0x18, 0x30, 0x60, 0x00, // 2F
  1731. 0x3C, 0x66, 0x6E, 0x76, 0x66, 0x66, 0x3C, 0x00, // 30
  1732. 0x18, 0x18, 0x38, 0x18, 0x18, 0x18, 0x7E, 0x00, // 31
  1733. 0x3C, 0x66, 0x06, 0x0C, 0x30, 0x60, 0x7E, 0x00, // 32
  1734. 0x3C, 0x66, 0x06, 0x1C, 0x06, 0x66, 0x3C, 0x00, // 33
  1735. 0x06, 0x0E, 0x1E, 0x66, 0x7F, 0x06, 0x06, 0x00, // 34
  1736. 0x7E, 0x60, 0x7C, 0x06, 0x06, 0x66, 0x3C, 0x00, // 35
  1737. 0x3C, 0x66, 0x60, 0x7C, 0x66, 0x66, 0x3C, 0x00, // 36
  1738. 0x7E, 0x66, 0x0C, 0x18, 0x18, 0x18, 0x18, 0x00, // 37
  1739. 0x3C, 0x66, 0x66, 0x3C, 0x66, 0x66, 0x3C, 0x00, // 38
  1740. 0x3C, 0x66, 0x66, 0x3E, 0x06, 0x66, 0x3C, 0x00, // 39
  1741. 0x00, 0x00, 0x18, 0x00, 0x00, 0x18, 0x00, 0x00, // 3A
  1742. 0x00, 0x00, 0x18, 0x00, 0x00, 0x18, 0x18, 0x30, // 3B
  1743. 0x0E, 0x18, 0x30, 0x60, 0x30, 0x18, 0x0E, 0x00, // 3C
  1744. 0x00, 0x00, 0x7E, 0x00, 0x7E, 0x00, 0x00, 0x00, // 3D
  1745. 0x70, 0x18, 0x0C, 0x06, 0x0C, 0x18, 0x70, 0x00, // 3E
  1746. 0x3C, 0x66, 0x06, 0x0C, 0x18, 0x00, 0x18, 0x00, // 3F
  1747. 0x3C, 0x66, 0x6E, 0x6E, 0x60, 0x62, 0x3C, 0x00, // 40
  1748. 0x18, 0x3C, 0x66, 0x7E, 0x66, 0x66, 0x66, 0x00, // 41
  1749. 0x7C, 0x66, 0x66, 0x7C, 0x66, 0x66, 0x7C, 0x00, // 42
  1750. 0x3C, 0x66, 0x60, 0x60, 0x60, 0x66, 0x3C, 0x00, // 43
  1751. 0x78, 0x6C, 0x66, 0x66, 0x66, 0x6C, 0x78, 0x00, // 44
  1752. 0x7E, 0x60, 0x60, 0x78, 0x60, 0x60, 0x7E, 0x00, // 45
  1753. 0x7E, 0x60, 0x60, 0x78, 0x60, 0x60, 0x60, 0x00, // 46
  1754. 0x3C, 0x66, 0x60, 0x6E, 0x66, 0x66, 0x3C, 0x00, // 47
  1755. 0x66, 0x66, 0x66, 0x7E, 0x66, 0x66, 0x66, 0x00, // 48
  1756. 0x3C, 0x18, 0x18, 0x18, 0x18, 0x18, 0x3C, 0x00, // 49
  1757. 0x1E, 0x0C, 0x0C, 0x0C, 0x0C, 0x6C, 0x38, 0x00, // 4A
  1758. 0x66, 0x6C, 0x78, 0x70, 0x78, 0x6C, 0x66, 0x00, // 4B
  1759. 0x60, 0x60, 0x60, 0x60, 0x60, 0x60, 0x7E, 0x00, // 4C
  1760. 0x63, 0x77, 0x7F, 0x6B, 0x63, 0x63, 0x63, 0x00, // 4D
  1761. 0x66, 0x76, 0x7E, 0x7E, 0x6E, 0x66, 0x66, 0x00, // 4E
  1762. 0x3C, 0x66, 0x66, 0x66, 0x66, 0x66, 0x3C, 0x00, // 4F
  1763. 0x7C, 0x66, 0x66, 0x7C, 0x60, 0x60, 0x60, 0x00, // 50
  1764. 0x3C, 0x66, 0x66, 0x66, 0x66, 0x3C, 0x0E, 0x00, // 51
  1765. 0x7C, 0x66, 0x66, 0x7C, 0x78, 0x6C, 0x66, 0x00, // 52
  1766. 0x3C, 0x66, 0x60, 0x3C, 0x06, 0x66, 0x3C, 0x00, // 53
  1767. 0x7E, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, // 54
  1768. 0x66, 0x66, 0x66, 0x66, 0x66, 0x66, 0x3C, 0x00, // 55
  1769. 0x66, 0x66, 0x66, 0x66, 0x66, 0x3C, 0x18, 0x00, // 56
  1770. 0x63, 0x63, 0x63, 0x6B, 0x7F, 0x77, 0x63, 0x00, // 57
  1771. 0x66, 0x66, 0x3C, 0x18, 0x3C, 0x66, 0x66, 0x00, // 58
  1772. 0x66, 0x66, 0x66, 0x3C, 0x18, 0x18, 0x18, 0x00, // 59
  1773. 0x7E, 0x06, 0x0C, 0x18, 0x30, 0x60, 0x7E, 0x00, // 5A
  1774. 0x3C, 0x30, 0x30, 0x30, 0x30, 0x30, 0x3C, 0x00, // 5B
  1775. 0x0C, 0x12, 0x30, 0x7C, 0x30, 0x62, 0xFC, 0x00, // 5C
  1776. 0x3C, 0x0C, 0x0C, 0x0C, 0x0C, 0x0C, 0x3C, 0x00, // 5D
  1777. 0x00, 0x18, 0x3C, 0x7E, 0x18, 0x18, 0x18, 0x18, // 5E
  1778. 0x00, 0x10, 0x30, 0x7F, 0x7F, 0x30, 0x10, 0x00, // 5F
  1779. 0x3C, 0x66, 0x6E, 0x6E, 0x60, 0x62, 0x3C, 0x00, // 60
  1780. 0x00, 0x00, 0x3C, 0x06, 0x3E, 0x66, 0x3E, 0x00, // 61
  1781. 0x00, 0x60, 0x60, 0x7C, 0x66, 0x66, 0x7C, 0x00, // 62
  1782. 0x00, 0x00, 0x3C, 0x60, 0x60, 0x60, 0x3C, 0x00, // 63
  1783. 0x00, 0x06, 0x06, 0x3E, 0x66, 0x66, 0x3E, 0x00, // 64
  1784. 0x00, 0x00, 0x3C, 0x66, 0x7E, 0x60, 0x3C, 0x00, // 65
  1785. 0x00, 0x0E, 0x18, 0x3E, 0x18, 0x18, 0x18, 0x00, // 66
  1786. 0x00, 0x00, 0x3E, 0x66, 0x66, 0x3E, 0x06, 0x7C, // 67
  1787. 0x00, 0x60, 0x60, 0x7C, 0x66, 0x66, 0x66, 0x00, // 68
  1788. 0x00, 0x18, 0x00, 0x38, 0x18, 0x18, 0x3C, 0x00, // 69
  1789. 0x00, 0x06, 0x00, 0x06, 0x06, 0x06, 0x06, 0x3C, // 6A
  1790. 0x00, 0x60, 0x60, 0x6C, 0x78, 0x6C, 0x66, 0x00, // 6B
  1791. 0x00, 0x38, 0x18, 0x18, 0x18, 0x18, 0x3C, 0x00, // 6C
  1792. 0x00, 0x00, 0x66, 0x7F, 0x7F, 0x6B, 0x63, 0x00, // 6D
  1793. 0x00, 0x00, 0x7C, 0x66, 0x66, 0x66, 0x66, 0x00, // 6E
  1794. 0x00, 0x00, 0x3C, 0x66, 0x66, 0x66, 0x3C, 0x00, // 6F
  1795. 0x00, 0x00, 0x7C, 0x66, 0x66, 0x7C, 0x60, 0x60, // 70
  1796. 0x00, 0x00, 0x3E, 0x66, 0x66, 0x3E, 0x06, 0x06, // 71
  1797. 0x00, 0x00, 0x7C, 0x66, 0x60, 0x60, 0x60, 0x00, // 72
  1798. 0x00, 0x00, 0x3E, 0x60, 0x3C, 0x06, 0x7C, 0x00, // 73
  1799. 0x00, 0x18, 0x7E, 0x18, 0x18, 0x18, 0x0E, 0x00, // 74
  1800. 0x00, 0x00, 0x66, 0x66, 0x66, 0x66, 0x3E, 0x00, // 75
  1801. 0x00, 0x00, 0x66, 0x66, 0x66, 0x3C, 0x18, 0x00, // 76
  1802. 0x00, 0x00, 0x63, 0x6B, 0x7F, 0x3E, 0x36, 0x00, // 77
  1803. 0x00, 0x00, 0x66, 0x3C, 0x18, 0x3C, 0x66, 0x00, // 78
  1804. 0x00, 0x00, 0x66, 0x66, 0x66, 0x3E, 0x0C, 0x78, // 79
  1805. 0x00, 0x00, 0x7E, 0x0C, 0x18, 0x30, 0x7E, 0x00, // 7A
  1806. 0x3C, 0x30, 0x30, 0x30, 0x30, 0x30, 0x3C, 0x00, // 7B
  1807. 0x0C, 0x12, 0x30, 0x7C, 0x30, 0x62, 0xFC, 0x00, // 7C
  1808. 0x3C, 0x0C, 0x0C, 0x0C, 0x0C, 0x0C, 0x3C, 0x00, // 7D
  1809. 0x00, 0x18, 0x3C, 0x7E, 0x18, 0x18, 0x18, 0x18, // 7E
  1810. 0x00, 0x10, 0x30, 0x7F, 0x7F, 0x30, 0x10, 0x00, // 7F
  1811. 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x00, 0x00, 0x00, // 80
  1812. 0x08, 0x1C, 0x3E, 0x7F, 0x7F, 0x1C, 0x3E, 0x00, // 81
  1813. 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, // 82
  1814. 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x00, 0x00, 0x00, // 83
  1815. 0x00, 0x00, 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x00, // 84
  1816. 0x00, 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, // 85
  1817. 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x00, 0x00, // 86
  1818. 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, // 87
  1819. 0x0C, 0x0C, 0x0C, 0x0C, 0x0C, 0x0C, 0x0C, 0x0C, // 88
  1820. 0x00, 0x00, 0x00, 0xE0, 0xF0, 0x38, 0x18, 0x18, // 89
  1821. 0x18, 0x18, 0x1C, 0x0F, 0x07, 0x00, 0x00, 0x00, // 8A
  1822. 0x18, 0x18, 0x38, 0xF0, 0xE0, 0x00, 0x00, 0x00, // 8B
  1823. 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xFF, 0xFF, // 8C
  1824. 0xC0, 0xE0, 0x70, 0x38, 0x1C, 0x0E, 0x07, 0x03, // 8D
  1825. 0x03, 0x07, 0x0E, 0x1C, 0x38, 0x70, 0xE0, 0xC0, // 8E
  1826. 0xFF, 0xFF, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, // 8F
  1827. 0xFF, 0xFF, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, // 90
  1828. 0x00, 0x3C, 0x7E, 0x7E, 0x7E, 0x7E, 0x3C, 0x00, // 91
  1829. 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x00, // 92
  1830. 0x36, 0x7F, 0x7F, 0x7F, 0x3E, 0x1C, 0x08, 0x00, // 93
  1831. 0x60, 0x60, 0x60, 0x60, 0x60, 0x60, 0x60, 0x60, // 94
  1832. 0x00, 0x00, 0x00, 0x07, 0x0F, 0x1C, 0x18, 0x18, // 95
  1833. 0xC3, 0xE7, 0x7E, 0x3C, 0x3C, 0x7E, 0xE7, 0xC3, // 96
  1834. 0x00, 0x3C, 0x7E, 0x66, 0x66, 0x7E, 0x3C, 0x00, // 97
  1835. 0x18, 0x18, 0x66, 0x66, 0x18, 0x18, 0x3C, 0x00, // 98
  1836. 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, // 99
  1837. 0x08, 0x1C, 0x3E, 0x7F, 0x3E, 0x1C, 0x08, 0x00, // 9A
  1838. 0x18, 0x18, 0x18, 0xFF, 0xFF, 0x18, 0x18, 0x18, // 9B
  1839. 0xC0, 0xC0, 0x30, 0x30, 0xC0, 0xC0, 0x30, 0x30, // 9C
  1840. 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, // 9D
  1841. 0x00, 0x00, 0x03, 0x3E, 0x76, 0x36, 0x36, 0x00, // 9E
  1842. 0xFF, 0x7F, 0x3F, 0x1F, 0x0F, 0x07, 0x03, 0x01, // 9F
  1843. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // A0
  1844. 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, // A1
  1845. 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, // A2
  1846. 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // A3
  1847. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, // A4
  1848. 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, // A5
  1849. 0xCC, 0xCC, 0x33, 0x33, 0xCC, 0xCC, 0x33, 0x33, // A6
  1850. 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, // A7
  1851. 0x00, 0x00, 0x00, 0x00, 0xCC, 0xCC, 0x33, 0x33, // A8
  1852. 0xFF, 0xFE, 0xFC, 0xF8, 0xF0, 0xE0, 0xC0, 0x80, // A9
  1853. 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, // AA
  1854. 0x18, 0x18, 0x18, 0x1F, 0x1F, 0x18, 0x18, 0x18, // AB
  1855. 0x00, 0x00, 0x00, 0x00, 0x0F, 0x0F, 0x0F, 0x0F, // AC
  1856. 0x18, 0x18, 0x18, 0x1F, 0x1F, 0x00, 0x00, 0x00, // AD
  1857. 0x00, 0x00, 0x00, 0xF8, 0xF8, 0x18, 0x18, 0x18, // AE
  1858. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, // AF
  1859. 0x00, 0x00, 0x00, 0x1F, 0x1F, 0x18, 0x18, 0x18, // B0
  1860. 0x18, 0x18, 0x18, 0xFF, 0xFF, 0x00, 0x00, 0x00, // B1
  1861. 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x18, 0x18, 0x18, // B2
  1862. 0x18, 0x18, 0x18, 0xF8, 0xF8, 0x18, 0x18, 0x18, // B3
  1863. 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, // B4
  1864. 0xE0, 0xE0, 0xE0, 0xE0, 0xE0, 0xE0, 0xE0, 0xE0, // B5
  1865. 0x07, 0x07, 0x07, 0x07, 0x07, 0x07, 0x07, 0x07, // B6
  1866. 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // B7
  1867. 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, // B8
  1868. 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xFF, // B9
  1869. 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0xFF, 0xFF, // BA
  1870. 0x00, 0x00, 0x00, 0x00, 0xF0, 0xF0, 0xF0, 0xF0, // BB
  1871. 0x0F, 0x0F, 0x0F, 0x0F, 0x00, 0x00, 0x00, 0x00, // BC
  1872. 0x18, 0x18, 0x18, 0xF8, 0xF8, 0x00, 0x00, 0x00, // BD
  1873. 0xF0, 0xF0, 0xF0, 0xF0, 0x00, 0x00, 0x00, 0x00, // BE
  1874. 0xF0, 0xF0, 0xF0, 0xF0, 0x0F, 0x0F, 0x0F, 0x0F, // BF
  1875. 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0xFF, 0xFF, 0xFF, // C0
  1876. 0xF7, 0xE3, 0xC1, 0x80, 0x80, 0xE3, 0xC1, 0xFF, // C1
  1877. 0xE7, 0xE7, 0xE7, 0xE7, 0xE7, 0xE7, 0xE7, 0xE7, // C2
  1878. 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0xFF, 0xFF, 0xFF, // C3
  1879. 0xFF, 0xFF, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, // C4
  1880. 0xFF, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // C5
  1881. 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0xFF, 0xFF, // C6
  1882. 0xCF, 0xCF, 0xCF, 0xCF, 0xCF, 0xCF, 0xCF, 0xCF, // C7
  1883. 0xF3, 0xF3, 0xF3, 0xF3, 0xF3, 0xF3, 0xF3, 0xF3, // C8
  1884. 0xFF, 0xFF, 0xFF, 0x1F, 0x0F, 0xC7, 0xE7, 0xE7, // C9
  1885. 0xE7, 0xE7, 0xE3, 0xF0, 0xF8, 0xFF, 0xFF, 0xFF, // CA
  1886. 0xE7, 0xE7, 0xC7, 0x0F, 0x1F, 0xFF, 0xFF, 0xFF, // CB
  1887. 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x00, 0x00, // CC
  1888. 0x3F, 0x1F, 0x8F, 0xC7, 0xE3, 0xF1, 0xF8, 0xFC, // CD
  1889. 0xFC, 0xF8, 0xF1, 0xE3, 0xC7, 0x8F, 0x1F, 0x3F, // CE
  1890. 0x00, 0x00, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, // CF
  1891. 0x00, 0x00, 0xFC, 0xFC, 0xFC, 0xFC, 0xFC, 0xFC, // D0
  1892. 0xFF, 0xC3, 0x81, 0x81, 0x81, 0x81, 0xC3, 0xFF, // D1
  1893. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0xFF, // D2
  1894. 0xC9, 0x80, 0x80, 0x80, 0xC1, 0xE3, 0xF7, 0xFF, // D3
  1895. 0x9F, 0x9F, 0x9F, 0x9F, 0x9F, 0x9F, 0x9F, 0x9F, // D4
  1896. 0xFF, 0xFF, 0xFF, 0xF8, 0xF0, 0xE3, 0xE7, 0xE7, // D5
  1897. 0x3C, 0x18, 0x81, 0xC3, 0xC3, 0x81, 0x18, 0x3C, // D6
  1898. 0xFF, 0xC3, 0x81, 0x99, 0x99, 0x81, 0xC3, 0xFF, // D7
  1899. 0xE7, 0xE7, 0x99, 0x99, 0xE7, 0xE7, 0xC3, 0xFF, // D8
  1900. 0xF9, 0xF9, 0xF9, 0xF9, 0xF9, 0xF9, 0xF9, 0xF9, // D9
  1901. 0xF7, 0xE3, 0xC1, 0x80, 0xC1, 0xE3, 0xF7, 0xFF, // DA
  1902. 0xE7, 0xE7, 0xE7, 0x00, 0x00, 0xE7, 0xE7, 0xE7, // DB
  1903. 0x3F, 0x3F, 0xCF, 0xCF, 0x3F, 0x3F, 0xCF, 0xCF, // DC
  1904. 0xE7, 0xE7, 0xE7, 0xE7, 0xE7, 0xE7, 0xE7, 0xE7, // DD
  1905. 0xFF, 0xFF, 0xFC, 0xC1, 0x89, 0xC9, 0xC9, 0xFF, // DE
  1906. 0x00, 0x80, 0xC0, 0xE0, 0xF0, 0xF8, 0xFC, 0xFE, // DF
  1907. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // E0
  1908. 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, // E1
  1909. 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x00, // E2
  1910. 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // E3
  1911. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, // E4
  1912. 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, // E5
  1913. 0x33, 0x33, 0xCC, 0xCC, 0x33, 0x33, 0xCC, 0xCC, // E6
  1914. 0xFC, 0xFC, 0xFC, 0xFC, 0xFC, 0xFC, 0xFC, 0xFC, // E7
  1915. 0xFF, 0xFF, 0xFF, 0xFF, 0x33, 0x33, 0xCC, 0xCC, // E8
  1916. 0x00, 0x01, 0x03, 0x07, 0x0F, 0x1F, 0x3F, 0x7F, // E9
  1917. 0xFC, 0xFC, 0xFC, 0xFC, 0xFC, 0xFC, 0xFC, 0xFC, // EA
  1918. 0xE7, 0xE7, 0xE7, 0xE0, 0xE0, 0xE7, 0xE7, 0xE7, // EB
  1919. 0xFF, 0xFF, 0xFF, 0xFF, 0xF0, 0xF0, 0xF0, 0xF0, // EC
  1920. 0xE7, 0xE7, 0xE7, 0xE0, 0xE0, 0xFF, 0xFF, 0xFF, // ED
  1921. 0xFF, 0xFF, 0xFF, 0x07, 0x07, 0xE7, 0xE7, 0xE7, // EE
  1922. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, // EF
  1923. 0xFF, 0xFF, 0xFF, 0xE0, 0xE0, 0xE7, 0xE7, 0xE7, // F0
  1924. 0xE7, 0xE7, 0xE7, 0x00, 0x00, 0xFF, 0xFF, 0xFF, // F1
  1925. 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0xE7, 0xE7, 0xE7, // F2
  1926. 0xE7, 0xE7, 0xE7, 0x07, 0x07, 0xE7, 0xE7, 0xE7, // F3
  1927. 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, // F4
  1928. 0x1F, 0x1F, 0x1F, 0x1F, 0x1F, 0x1F, 0x1F, 0x1F, // F5
  1929. 0xF8, 0xF8, 0xF8, 0xF8, 0xF8, 0xF8, 0xF8, 0xF8, // F6
  1930. 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // F7
  1931. 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // F8
  1932. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0x00, // F9
  1933. 0xFC, 0xFC, 0xFC, 0xFC, 0xFC, 0xFC, 0x00, 0x00, // FA
  1934. 0xFF, 0xFF, 0xFF, 0xFF, 0x0F, 0x0F, 0x0F, 0x0F, // FB
  1935. 0xF0, 0xF0, 0xF0, 0xF0, 0xFF, 0xFF, 0xFF, 0xFF, // FC
  1936. 0xE7, 0xE7, 0xE7, 0x07, 0x07, 0xFF, 0xFF, 0xFF, // FD
  1937. 0x0F, 0x0F, 0x0F, 0x0F, 0xFF, 0xFF, 0xFF, 0xFF, // FE
  1938. 0x0F, 0x0F, 0x0F, 0x0F, 0xF0, 0xF0, 0xF0, 0xF0, // FF
  1939. };
  1940. static const uint8_t _sdtx_font_oric[2048] = {
  1941. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 00
  1942. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 01
  1943. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 02
  1944. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 03
  1945. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 04
  1946. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 05
  1947. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 06
  1948. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 07
  1949. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 08
  1950. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 09
  1951. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0A
  1952. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0B
  1953. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0C
  1954. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0D
  1955. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0E
  1956. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 0F
  1957. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 10
  1958. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 11
  1959. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 12
  1960. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 13
  1961. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 14
  1962. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 15
  1963. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 16
  1964. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 17
  1965. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 18
  1966. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 19
  1967. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 1A
  1968. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 1B
  1969. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 1C
  1970. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 1D
  1971. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 1E
  1972. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 1F
  1973. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 20
  1974. 0x08, 0x08, 0x08, 0x08, 0x08, 0x00, 0x08, 0x00, // 21
  1975. 0x14, 0x14, 0x14, 0x00, 0x00, 0x00, 0x00, 0x00, // 22
  1976. 0x14, 0x14, 0x3E, 0x14, 0x3E, 0x14, 0x14, 0x00, // 23
  1977. 0x08, 0x1E, 0x28, 0x1C, 0x0A, 0x3C, 0x08, 0x00, // 24
  1978. 0x30, 0x32, 0x04, 0x08, 0x10, 0x26, 0x06, 0x00, // 25
  1979. 0x10, 0x28, 0x28, 0x10, 0x2A, 0x24, 0x1A, 0x00, // 26
  1980. 0x08, 0x08, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, // 27
  1981. 0x08, 0x10, 0x20, 0x20, 0x20, 0x10, 0x08, 0x00, // 28
  1982. 0x08, 0x04, 0x02, 0x02, 0x02, 0x04, 0x08, 0x00, // 29
  1983. 0x08, 0x2A, 0x1C, 0x08, 0x1C, 0x2A, 0x08, 0x00, // 2A
  1984. 0x00, 0x08, 0x08, 0x3E, 0x08, 0x08, 0x00, 0x00, // 2B
  1985. 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x08, 0x10, // 2C
  1986. 0x00, 0x00, 0x00, 0x3E, 0x00, 0x00, 0x00, 0x00, // 2D
  1987. 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, // 2E
  1988. 0x00, 0x02, 0x04, 0x08, 0x10, 0x20, 0x00, 0x00, // 2F
  1989. 0x1C, 0x22, 0x26, 0x2A, 0x32, 0x22, 0x1C, 0x00, // 30
  1990. 0x08, 0x18, 0x08, 0x08, 0x08, 0x08, 0x1C, 0x00, // 31
  1991. 0x1C, 0x22, 0x02, 0x04, 0x08, 0x10, 0x3E, 0x00, // 32
  1992. 0x3E, 0x02, 0x04, 0x0C, 0x02, 0x22, 0x1C, 0x00, // 33
  1993. 0x04, 0x0C, 0x14, 0x24, 0x3E, 0x04, 0x04, 0x00, // 34
  1994. 0x3E, 0x20, 0x3C, 0x02, 0x02, 0x22, 0x1C, 0x00, // 35
  1995. 0x0C, 0x10, 0x20, 0x3C, 0x22, 0x22, 0x1C, 0x00, // 36
  1996. 0x3E, 0x02, 0x04, 0x08, 0x10, 0x10, 0x10, 0x00, // 37
  1997. 0x1C, 0x22, 0x22, 0x1C, 0x22, 0x22, 0x1C, 0x00, // 38
  1998. 0x1C, 0x22, 0x22, 0x1E, 0x02, 0x04, 0x18, 0x00, // 39
  1999. 0x00, 0x00, 0x08, 0x00, 0x00, 0x08, 0x00, 0x00, // 3A
  2000. 0x00, 0x00, 0x08, 0x00, 0x00, 0x08, 0x08, 0x10, // 3B
  2001. 0x04, 0x08, 0x10, 0x20, 0x10, 0x08, 0x04, 0x00, // 3C
  2002. 0x00, 0x00, 0x3E, 0x00, 0x3E, 0x00, 0x00, 0x00, // 3D
  2003. 0x10, 0x08, 0x04, 0x02, 0x04, 0x08, 0x10, 0x00, // 3E
  2004. 0x1C, 0x22, 0x04, 0x08, 0x08, 0x00, 0x08, 0x00, // 3F
  2005. 0x1C, 0x22, 0x2A, 0x2E, 0x2C, 0x20, 0x1E, 0x00, // 40
  2006. 0x08, 0x14, 0x22, 0x22, 0x3E, 0x22, 0x22, 0x00, // 41
  2007. 0x3C, 0x22, 0x22, 0x3C, 0x22, 0x22, 0x3C, 0x00, // 42
  2008. 0x1C, 0x22, 0x20, 0x20, 0x20, 0x22, 0x1C, 0x00, // 43
  2009. 0x3C, 0x22, 0x22, 0x22, 0x22, 0x22, 0x3C, 0x00, // 44
  2010. 0x3E, 0x20, 0x20, 0x3C, 0x20, 0x20, 0x3E, 0x00, // 45
  2011. 0x3E, 0x20, 0x20, 0x3C, 0x20, 0x20, 0x20, 0x00, // 46
  2012. 0x1E, 0x20, 0x20, 0x20, 0x26, 0x22, 0x1E, 0x00, // 47
  2013. 0x22, 0x22, 0x22, 0x3E, 0x22, 0x22, 0x22, 0x00, // 48
  2014. 0x1C, 0x08, 0x08, 0x08, 0x08, 0x08, 0x1C, 0x00, // 49
  2015. 0x02, 0x02, 0x02, 0x02, 0x02, 0x22, 0x1C, 0x00, // 4A
  2016. 0x22, 0x24, 0x28, 0x30, 0x28, 0x24, 0x22, 0x00, // 4B
  2017. 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x3E, 0x00, // 4C
  2018. 0x22, 0x36, 0x2A, 0x2A, 0x22, 0x22, 0x22, 0x00, // 4D
  2019. 0x22, 0x22, 0x32, 0x2A, 0x26, 0x22, 0x22, 0x00, // 4E
  2020. 0x1C, 0x22, 0x22, 0x22, 0x22, 0x22, 0x1C, 0x00, // 4F
  2021. 0x3C, 0x22, 0x22, 0x3C, 0x20, 0x20, 0x20, 0x00, // 50
  2022. 0x1C, 0x22, 0x22, 0x22, 0x2A, 0x24, 0x1A, 0x00, // 51
  2023. 0x3C, 0x22, 0x22, 0x3C, 0x28, 0x24, 0x22, 0x00, // 52
  2024. 0x1C, 0x22, 0x20, 0x1C, 0x02, 0x22, 0x1C, 0x00, // 53
  2025. 0x3E, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x00, // 54
  2026. 0x22, 0x22, 0x22, 0x22, 0x22, 0x22, 0x1C, 0x00, // 55
  2027. 0x22, 0x22, 0x22, 0x22, 0x22, 0x14, 0x08, 0x00, // 56
  2028. 0x22, 0x22, 0x22, 0x2A, 0x2A, 0x36, 0x22, 0x00, // 57
  2029. 0x22, 0x22, 0x14, 0x08, 0x14, 0x22, 0x22, 0x00, // 58
  2030. 0x22, 0x22, 0x14, 0x08, 0x08, 0x08, 0x08, 0x00, // 59
  2031. 0x3E, 0x02, 0x04, 0x08, 0x10, 0x20, 0x3E, 0x00, // 5A
  2032. 0x1E, 0x10, 0x10, 0x10, 0x10, 0x10, 0x1E, 0x00, // 5B
  2033. 0x00, 0x20, 0x10, 0x08, 0x04, 0x02, 0x00, 0x00, // 5C
  2034. 0x3C, 0x04, 0x04, 0x04, 0x04, 0x04, 0x3C, 0x00, // 5D
  2035. 0x08, 0x14, 0x2A, 0x08, 0x08, 0x08, 0x08, 0x00, // 5E
  2036. 0x0E, 0x11, 0x3C, 0x10, 0x3C, 0x11, 0x0E, 0x00, // 5F
  2037. 0x0C, 0x12, 0x2D, 0x29, 0x29, 0x2D, 0x12, 0x0C, // 60
  2038. 0x00, 0x00, 0x1C, 0x02, 0x1E, 0x22, 0x1E, 0x00, // 61
  2039. 0x20, 0x20, 0x3C, 0x22, 0x22, 0x22, 0x3C, 0x00, // 62
  2040. 0x00, 0x00, 0x1E, 0x20, 0x20, 0x20, 0x1E, 0x00, // 63
  2041. 0x02, 0x02, 0x1E, 0x22, 0x22, 0x22, 0x1E, 0x00, // 64
  2042. 0x00, 0x00, 0x1C, 0x22, 0x3E, 0x20, 0x1E, 0x00, // 65
  2043. 0x0C, 0x12, 0x10, 0x3C, 0x10, 0x10, 0x10, 0x00, // 66
  2044. 0x00, 0x00, 0x1C, 0x22, 0x22, 0x1E, 0x02, 0x1C, // 67
  2045. 0x20, 0x20, 0x3C, 0x22, 0x22, 0x22, 0x22, 0x00, // 68
  2046. 0x08, 0x00, 0x18, 0x08, 0x08, 0x08, 0x1C, 0x00, // 69
  2047. 0x04, 0x00, 0x0C, 0x04, 0x04, 0x04, 0x24, 0x18, // 6A
  2048. 0x20, 0x20, 0x22, 0x24, 0x38, 0x24, 0x22, 0x00, // 6B
  2049. 0x18, 0x08, 0x08, 0x08, 0x08, 0x08, 0x1C, 0x00, // 6C
  2050. 0x00, 0x00, 0x36, 0x2A, 0x2A, 0x2A, 0x22, 0x00, // 6D
  2051. 0x00, 0x00, 0x3C, 0x22, 0x22, 0x22, 0x22, 0x00, // 6E
  2052. 0x00, 0x00, 0x1C, 0x22, 0x22, 0x22, 0x1C, 0x00, // 6F
  2053. 0x00, 0x00, 0x3C, 0x22, 0x22, 0x3C, 0x20, 0x20, // 70
  2054. 0x00, 0x00, 0x1E, 0x22, 0x22, 0x1E, 0x02, 0x02, // 71
  2055. 0x00, 0x00, 0x2E, 0x30, 0x20, 0x20, 0x20, 0x00, // 72
  2056. 0x00, 0x00, 0x1E, 0x20, 0x1C, 0x02, 0x3C, 0x00, // 73
  2057. 0x10, 0x10, 0x3C, 0x10, 0x10, 0x12, 0x0C, 0x00, // 74
  2058. 0x00, 0x00, 0x22, 0x22, 0x22, 0x26, 0x1A, 0x00, // 75
  2059. 0x00, 0x00, 0x22, 0x22, 0x22, 0x14, 0x08, 0x00, // 76
  2060. 0x00, 0x00, 0x22, 0x22, 0x2A, 0x2A, 0x36, 0x00, // 77
  2061. 0x00, 0x00, 0x22, 0x14, 0x08, 0x14, 0x22, 0x00, // 78
  2062. 0x00, 0x00, 0x22, 0x22, 0x22, 0x1E, 0x02, 0x1C, // 79
  2063. 0x00, 0x00, 0x3E, 0x04, 0x08, 0x10, 0x3E, 0x00, // 7A
  2064. 0x0E, 0x18, 0x18, 0x30, 0x18, 0x18, 0x0E, 0x00, // 7B
  2065. 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, // 7C
  2066. 0x38, 0x0C, 0x0C, 0x06, 0x0C, 0x0C, 0x38, 0x00, // 7D
  2067. 0x2A, 0x15, 0x2A, 0x15, 0x2A, 0x15, 0x2A, 0x15, // 7E
  2068. 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, // 7F
  2069. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 80
  2070. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 81
  2071. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 82
  2072. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 83
  2073. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 84
  2074. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 85
  2075. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 86
  2076. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 87
  2077. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 88
  2078. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 89
  2079. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 8A
  2080. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 8B
  2081. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 8C
  2082. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 8D
  2083. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 8E
  2084. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 8F
  2085. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 90
  2086. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 91
  2087. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 92
  2088. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 93
  2089. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 94
  2090. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 95
  2091. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 96
  2092. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 97
  2093. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 98
  2094. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 99
  2095. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 9A
  2096. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 9B
  2097. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 9C
  2098. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 9D
  2099. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 9E
  2100. 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // 9F
  2101. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // A0
  2102. 0xF7, 0xF7, 0xF7, 0xF7, 0xF7, 0xFF, 0xF7, 0xFF, // A1
  2103. 0xEB, 0xEB, 0xEB, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // A2
  2104. 0xEB, 0xEB, 0xC1, 0xEB, 0xC1, 0xEB, 0xEB, 0xFF, // A3
  2105. 0xF7, 0xE1, 0xD7, 0xE3, 0xF5, 0xC3, 0xF7, 0xFF, // A4
  2106. 0xCF, 0xCD, 0xFB, 0xF7, 0xEF, 0xD9, 0xF9, 0xFF, // A5
  2107. 0xEF, 0xD7, 0xD7, 0xEF, 0xD5, 0xDB, 0xE5, 0xFF, // A6
  2108. 0xF7, 0xF7, 0xF7, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, // A7
  2109. 0xF7, 0xEF, 0xDF, 0xDF, 0xDF, 0xEF, 0xF7, 0xFF, // A8
  2110. 0xF7, 0xFB, 0xFD, 0xFD, 0xFD, 0xFB, 0xF7, 0xFF, // A9
  2111. 0xF7, 0xD5, 0xE3, 0xF7, 0xE3, 0xD5, 0xF7, 0xFF, // AA
  2112. 0xFF, 0xF7, 0xF7, 0xC1, 0xF7, 0xF7, 0xFF, 0xFF, // AB
  2113. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xF7, 0xF7, 0xEF, // AC
  2114. 0xFF, 0xFF, 0xFF, 0xC1, 0xFF, 0xFF, 0xFF, 0xFF, // AD
  2115. 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFB, 0xFF, 0xFF, // AE
  2116. 0xFF, 0xFD, 0xFB, 0xF7, 0xEF, 0xDF, 0xFF, 0xFF, // AF
  2117. 0xE3, 0xDD, 0xD9, 0xD5, 0xCD, 0xDD, 0xE3, 0xFF, // B0
  2118. 0xF7, 0xE7, 0xF7, 0xF7, 0xF7, 0xF7, 0xE3, 0xFF, // B1
  2119. 0xE3, 0xDD, 0xFD, 0xFB, 0xF7, 0xEF, 0xC1, 0xFF, // B2
  2120. 0xC1, 0xFD, 0xFB, 0xF3, 0xFD, 0xDD, 0xE3, 0xFF, // B3
  2121. 0xFB, 0xF3, 0xEB, 0xDB, 0xC1, 0xFB, 0xFB, 0xFF, // B4
  2122. 0xC1, 0xDF, 0xC3, 0xFD, 0xFD, 0xDD, 0xE3, 0xFF, // B5
  2123. 0xF3, 0xEF, 0xDF, 0xC3, 0xDD, 0xDD, 0xE3, 0xFF, // B6
  2124. 0xC1, 0xFD, 0xFB, 0xF7, 0xEF, 0xEF, 0xEF, 0xFF, // B7
  2125. 0xE3, 0xDD, 0xDD, 0xE3, 0xDD, 0xDD, 0xE3, 0xFF, // B8
  2126. 0xE3, 0xDD, 0xDD, 0xE1, 0xFD, 0xFB, 0xE7, 0xFF, // B9
  2127. 0xFF, 0xFF, 0xF7, 0xFF, 0xFF, 0xF7, 0xFF, 0xFF, // BA
  2128. 0xFF, 0xFF, 0xF7, 0xFF, 0xFF, 0xF7, 0xF7, 0xEF, // BB
  2129. 0xFB, 0xF7, 0xEF, 0xDF, 0xEF, 0xF7, 0xFB, 0xFF, // BC
  2130. 0xFF, 0xFF, 0xC1, 0xFF, 0xC1, 0xFF, 0xFF, 0xFF, // BD
  2131. 0xEF, 0xF7, 0xFB, 0xFD, 0xFB, 0xF7, 0xEF, 0xFF, // BE
  2132. 0xE3, 0xDD, 0xFB, 0xF7, 0xF7, 0xFF, 0xF7, 0xFF, // BF
  2133. 0xE3, 0xDD, 0xD5, 0xD1, 0xD3, 0xDF, 0xE1, 0xFF, // C0
  2134. 0xF7, 0xEB, 0xDD, 0xDD, 0xC1, 0xDD, 0xDD, 0xFF, // C1
  2135. 0xC3, 0xDD, 0xDD, 0xC3, 0xDD, 0xDD, 0xC3, 0xFF, // C2
  2136. 0xE3, 0xDD, 0xDF, 0xDF, 0xDF, 0xDD, 0xE3, 0xFF, // C3
  2137. 0xC3, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xC3, 0xFF, // C4
  2138. 0xC1, 0xDF, 0xDF, 0xC3, 0xDF, 0xDF, 0xC1, 0xFF, // C5
  2139. 0xC1, 0xDF, 0xDF, 0xC3, 0xDF, 0xDF, 0xDF, 0xFF, // C6
  2140. 0xE1, 0xDF, 0xDF, 0xDF, 0xD9, 0xDD, 0xE1, 0xFF, // C7
  2141. 0xDD, 0xDD, 0xDD, 0xC1, 0xDD, 0xDD, 0xDD, 0xFF, // C8
  2142. 0xE3, 0xF7, 0xF7, 0xF7, 0xF7, 0xF7, 0xE3, 0xFF, // C9
  2143. 0xFD, 0xFD, 0xFD, 0xFD, 0xFD, 0xDD, 0xE3, 0xFF, // CA
  2144. 0xDD, 0xDB, 0xD7, 0xCF, 0xD7, 0xDB, 0xDD, 0xFF, // CB
  2145. 0xDF, 0xDF, 0xDF, 0xDF, 0xDF, 0xDF, 0xC1, 0xFF, // CC
  2146. 0xDD, 0xC9, 0xD5, 0xD5, 0xDD, 0xDD, 0xDD, 0xFF, // CD
  2147. 0xDD, 0xDD, 0xCD, 0xD5, 0xD9, 0xDD, 0xDD, 0xFF, // CE
  2148. 0xE3, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xE3, 0xFF, // CF
  2149. 0xC3, 0xDD, 0xDD, 0xC3, 0xDF, 0xDF, 0xDF, 0xFF, // D0
  2150. 0xE3, 0xDD, 0xDD, 0xDD, 0xD5, 0xDB, 0xE5, 0xFF, // D1
  2151. 0xC3, 0xDD, 0xDD, 0xC3, 0xD7, 0xDB, 0xDD, 0xFF, // D2
  2152. 0xE3, 0xDD, 0xDF, 0xE3, 0xFD, 0xDD, 0xE3, 0xFF, // D3
  2153. 0xC1, 0xF7, 0xF7, 0xF7, 0xF7, 0xF7, 0xF7, 0xFF, // D4
  2154. 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xE3, 0xFF, // D5
  2155. 0xDD, 0xDD, 0xDD, 0xDD, 0xDD, 0xEB, 0xF7, 0xFF, // D6
  2156. 0xDD, 0xDD, 0xDD, 0xD5, 0xD5, 0xC9, 0xDD, 0xFF, // D7
  2157. 0xDD, 0xDD, 0xEB, 0xF7, 0xEB, 0xDD, 0xDD, 0xFF, // D8
  2158. 0xDD, 0xDD, 0xEB, 0xF7, 0xF7, 0xF7, 0xF7, 0xFF, // D9
  2159. 0xC1, 0xFD, 0xFB, 0xF7, 0xEF, 0xDF, 0xC1, 0xFF, // DA
  2160. 0xE1, 0xEF, 0xEF, 0xEF, 0xEF, 0xEF, 0xE1, 0xFF, // DB
  2161. 0xFF, 0xDF, 0xEF, 0xF7, 0xFB, 0xFD, 0xFF, 0xFF, // DC
  2162. 0xC3, 0xFB, 0xFB, 0xFB, 0xFB, 0xFB, 0xC3, 0xFF, // DD
  2163. 0xF7, 0xEB, 0xD5, 0xF7, 0xF7, 0xF7, 0xF7, 0xFF, // DE
  2164. 0xF1, 0xEE, 0xC3, 0xEF, 0xC3, 0xEE, 0xF1, 0xFF, // DF
  2165. 0xF3, 0xED, 0xD2, 0xD6, 0xD6, 0xD2, 0xED, 0xF3, // E0
  2166. 0xFF, 0xFF, 0xE3, 0xFD, 0xE1, 0xDD, 0xE1, 0xFF, // E1
  2167. 0xDF, 0xDF, 0xC3, 0xDD, 0xDD, 0xDD, 0xC3, 0xFF, // E2
  2168. 0xFF, 0xFF, 0xE1, 0xDF, 0xDF, 0xDF, 0xE1, 0xFF, // E3
  2169. 0xFD, 0xFD, 0xE1, 0xDD, 0xDD, 0xDD, 0xE1, 0xFF, // E4
  2170. 0xFF, 0xFF, 0xE3, 0xDD, 0xC1, 0xDF, 0xE1, 0xFF, // E5
  2171. 0xF3, 0xED, 0xEF, 0xC3, 0xEF, 0xEF, 0xEF, 0xFF, // E6
  2172. 0xFF, 0xFF, 0xE3, 0xDD, 0xDD, 0xE1, 0xFD, 0xE3, // E7
  2173. 0xDF, 0xDF, 0xC3, 0xDD, 0xDD, 0xDD, 0xDD, 0xFF, // E8
  2174. 0xF7, 0xFF, 0xE7, 0xF7, 0xF7, 0xF7, 0xE3, 0xFF, // E9
  2175. 0xFB, 0xFF, 0xF3, 0xFB, 0xFB, 0xFB, 0xDB, 0xE7, // EA
  2176. 0xDF, 0xDF, 0xDD, 0xDB, 0xC7, 0xDB, 0xDD, 0xFF, // EB
  2177. 0xE7, 0xF7, 0xF7, 0xF7, 0xF7, 0xF7, 0xE3, 0xFF, // EC
  2178. 0xFF, 0xFF, 0xC9, 0xD5, 0xD5, 0xD5, 0xDD, 0xFF, // ED
  2179. 0xFF, 0xFF, 0xC3, 0xDD, 0xDD, 0xDD, 0xDD, 0xFF, // EE
  2180. 0xFF, 0xFF, 0xE3, 0xDD, 0xDD, 0xDD, 0xE3, 0xFF, // EF
  2181. 0xFF, 0xFF, 0xC3, 0xDD, 0xDD, 0xC3, 0xDF, 0xDF, // F0
  2182. 0xFF, 0xFF, 0xE1, 0xDD, 0xDD, 0xE1, 0xFD, 0xFD, // F1
  2183. 0xFF, 0xFF, 0xD1, 0xCF, 0xDF, 0xDF, 0xDF, 0xFF, // F2
  2184. 0xFF, 0xFF, 0xE1, 0xDF, 0xE3, 0xFD, 0xC3, 0xFF, // F3
  2185. 0xEF, 0xEF, 0xC3, 0xEF, 0xEF, 0xED, 0xF3, 0xFF, // F4
  2186. 0xFF, 0xFF, 0xDD, 0xDD, 0xDD, 0xD9, 0xE5, 0xFF, // F5
  2187. 0xFF, 0xFF, 0xDD, 0xDD, 0xDD, 0xEB, 0xF7, 0xFF, // F6
  2188. 0xFF, 0xFF, 0xDD, 0xDD, 0xD5, 0xD5, 0xC9, 0xFF, // F7
  2189. 0xFF, 0xFF, 0xDD, 0xEB, 0xF7, 0xEB, 0xDD, 0xFF, // F8
  2190. 0xFF, 0xFF, 0xDD, 0xDD, 0xDD, 0xE1, 0xFD, 0xE3, // F9
  2191. 0xFF, 0xFF, 0xC1, 0xFB, 0xF7, 0xEF, 0xC1, 0xFF, // FA
  2192. 0xF1, 0xE7, 0xE7, 0xCF, 0xE7, 0xE7, 0xF1, 0xFF, // FB
  2193. 0xF7, 0xF7, 0xF7, 0xF7, 0xF7, 0xF7, 0xF7, 0xF7, // FC
  2194. 0xC7, 0xF3, 0xF3, 0xF9, 0xF3, 0xF3, 0xC7, 0xFF, // FD
  2195. 0xD5, 0xEA, 0xD5, 0xEA, 0xD5, 0xEA, 0xD5, 0xEA, // FE
  2196. 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, 0xC0, // FF
  2197. };
  2198. /*
  2199. Embedded source code compiled with:
  2200. sokol-shdc -i debugtext.glsl -o debugtext.h -l glsl410:glsl300es:hlsl4:metal_macos:metal_ios:metal_sim:wgsl:spirv_vk -b
  2201. (not that for Metal and D3D11 byte code, sokol-shdc must be run
  2202. on macOS and Windows)
  2203. @vs vs
  2204. in vec2 position;
  2205. in vec2 texcoord0;
  2206. in vec4 color0;
  2207. out vec2 uv;
  2208. out vec4 color;
  2209. void main() {
  2210. gl_Position = vec4(position * vec2(2.0, -2.0) + vec2(-1.0, +1.0), 0.0, 1.0);
  2211. uv = texcoord0;
  2212. color = color0;
  2213. }
  2214. @end
  2215. @fs fs
  2216. layout(binding=0) uniform texture2D tex;
  2217. layout(binding=0) uniform sampler smp;
  2218. in vec2 uv;
  2219. in vec4 color;
  2220. out vec4 frag_color;
  2221. void main() {
  2222. frag_color = texture(sampler2D(tex, smp), uv).xxxx * color;
  2223. }
  2224. @end
  2225. @program debugtext vs fs
  2226. */
  2227. #if defined(SOKOL_GLCORE)
  2228. /*
  2229. #version 410
  2230. layout(location = 0) in vec2 position;
  2231. layout(location = 0) out vec2 uv;
  2232. layout(location = 1) in vec2 texcoord0;
  2233. layout(location = 1) out vec4 color;
  2234. layout(location = 2) in vec4 color0;
  2235. void main()
  2236. {
  2237. gl_Position = vec4(fma(position, vec2(2.0, -2.0), vec2(-1.0, 1.0)), 0.0, 1.0);
  2238. uv = texcoord0;
  2239. color = color0;
  2240. }
  2241. */
  2242. static const uint8_t _sdtx_vs_source_glsl410[343] = {
  2243. 0x23,0x76,0x65,0x72,0x73,0x69,0x6f,0x6e,0x20,0x34,0x31,0x30,0x0a,0x0a,0x6c,0x61,
  2244. 0x79,0x6f,0x75,0x74,0x28,0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,
  2245. 0x30,0x29,0x20,0x69,0x6e,0x20,0x76,0x65,0x63,0x32,0x20,0x70,0x6f,0x73,0x69,0x74,
  2246. 0x69,0x6f,0x6e,0x3b,0x0a,0x6c,0x61,0x79,0x6f,0x75,0x74,0x28,0x6c,0x6f,0x63,0x61,
  2247. 0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x30,0x29,0x20,0x6f,0x75,0x74,0x20,0x76,0x65,
  2248. 0x63,0x32,0x20,0x75,0x76,0x3b,0x0a,0x6c,0x61,0x79,0x6f,0x75,0x74,0x28,0x6c,0x6f,
  2249. 0x63,0x61,0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x31,0x29,0x20,0x69,0x6e,0x20,0x76,
  2250. 0x65,0x63,0x32,0x20,0x74,0x65,0x78,0x63,0x6f,0x6f,0x72,0x64,0x30,0x3b,0x0a,0x6c,
  2251. 0x61,0x79,0x6f,0x75,0x74,0x28,0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e,0x20,0x3d,
  2252. 0x20,0x31,0x29,0x20,0x6f,0x75,0x74,0x20,0x76,0x65,0x63,0x34,0x20,0x63,0x6f,0x6c,
  2253. 0x6f,0x72,0x3b,0x0a,0x6c,0x61,0x79,0x6f,0x75,0x74,0x28,0x6c,0x6f,0x63,0x61,0x74,
  2254. 0x69,0x6f,0x6e,0x20,0x3d,0x20,0x32,0x29,0x20,0x69,0x6e,0x20,0x76,0x65,0x63,0x34,
  2255. 0x20,0x63,0x6f,0x6c,0x6f,0x72,0x30,0x3b,0x0a,0x0a,0x76,0x6f,0x69,0x64,0x20,0x6d,
  2256. 0x61,0x69,0x6e,0x28,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x67,0x6c,0x5f,0x50,
  2257. 0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x76,0x65,0x63,0x34,0x28,0x66,
  2258. 0x6d,0x61,0x28,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x2c,0x20,0x76,0x65,0x63,
  2259. 0x32,0x28,0x32,0x2e,0x30,0x2c,0x20,0x2d,0x32,0x2e,0x30,0x29,0x2c,0x20,0x76,0x65,
  2260. 0x63,0x32,0x28,0x2d,0x31,0x2e,0x30,0x2c,0x20,0x31,0x2e,0x30,0x29,0x29,0x2c,0x20,
  2261. 0x30,0x2e,0x30,0x2c,0x20,0x31,0x2e,0x30,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x75,
  2262. 0x76,0x20,0x3d,0x20,0x74,0x65,0x78,0x63,0x6f,0x6f,0x72,0x64,0x30,0x3b,0x0a,0x20,
  2263. 0x20,0x20,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x63,0x6f,0x6c,0x6f,0x72,
  2264. 0x30,0x3b,0x0a,0x7d,0x0a,0x0a,0x00,
  2265. };
  2266. /*
  2267. #version 410
  2268. uniform sampler2D tex_smp;
  2269. layout(location = 0) out vec4 frag_color;
  2270. layout(location = 0) in vec2 uv;
  2271. layout(location = 1) in vec4 color;
  2272. void main()
  2273. {
  2274. frag_color = texture(tex_smp, uv).xxxx * color;
  2275. }
  2276. */
  2277. static const uint8_t _sdtx_fs_source_glsl410[224] = {
  2278. 0x23,0x76,0x65,0x72,0x73,0x69,0x6f,0x6e,0x20,0x34,0x31,0x30,0x0a,0x0a,0x75,0x6e,
  2279. 0x69,0x66,0x6f,0x72,0x6d,0x20,0x73,0x61,0x6d,0x70,0x6c,0x65,0x72,0x32,0x44,0x20,
  2280. 0x74,0x65,0x78,0x5f,0x73,0x6d,0x70,0x3b,0x0a,0x0a,0x6c,0x61,0x79,0x6f,0x75,0x74,
  2281. 0x28,0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x30,0x29,0x20,0x6f,
  2282. 0x75,0x74,0x20,0x76,0x65,0x63,0x34,0x20,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,
  2283. 0x6f,0x72,0x3b,0x0a,0x6c,0x61,0x79,0x6f,0x75,0x74,0x28,0x6c,0x6f,0x63,0x61,0x74,
  2284. 0x69,0x6f,0x6e,0x20,0x3d,0x20,0x30,0x29,0x20,0x69,0x6e,0x20,0x76,0x65,0x63,0x32,
  2285. 0x20,0x75,0x76,0x3b,0x0a,0x6c,0x61,0x79,0x6f,0x75,0x74,0x28,0x6c,0x6f,0x63,0x61,
  2286. 0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x31,0x29,0x20,0x69,0x6e,0x20,0x76,0x65,0x63,
  2287. 0x34,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x3b,0x0a,0x0a,0x76,0x6f,0x69,0x64,0x20,0x6d,
  2288. 0x61,0x69,0x6e,0x28,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x66,0x72,0x61,0x67,
  2289. 0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x74,0x65,0x78,0x74,0x75,0x72,0x65,
  2290. 0x28,0x74,0x65,0x78,0x5f,0x73,0x6d,0x70,0x2c,0x20,0x75,0x76,0x29,0x2e,0x78,0x78,
  2291. 0x78,0x78,0x20,0x2a,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x3b,0x0a,0x7d,0x0a,0x0a,0x00,
  2292. };
  2293. #elif defined(SOKOL_GLES3)
  2294. /*
  2295. #version 300 es
  2296. layout(location = 0) in vec2 position;
  2297. out vec2 uv;
  2298. layout(location = 1) in vec2 texcoord0;
  2299. out vec4 color;
  2300. layout(location = 2) in vec4 color0;
  2301. void main()
  2302. {
  2303. gl_Position = vec4(position * vec2(2.0, -2.0) + vec2(-1.0, 1.0), 0.0, 1.0);
  2304. uv = texcoord0;
  2305. color = color0;
  2306. }
  2307. */
  2308. static const uint8_t _sdtx_vs_source_glsl300es[301] = {
  2309. 0x23,0x76,0x65,0x72,0x73,0x69,0x6f,0x6e,0x20,0x33,0x30,0x30,0x20,0x65,0x73,0x0a,
  2310. 0x0a,0x6c,0x61,0x79,0x6f,0x75,0x74,0x28,0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e,
  2311. 0x20,0x3d,0x20,0x30,0x29,0x20,0x69,0x6e,0x20,0x76,0x65,0x63,0x32,0x20,0x70,0x6f,
  2312. 0x73,0x69,0x74,0x69,0x6f,0x6e,0x3b,0x0a,0x6f,0x75,0x74,0x20,0x76,0x65,0x63,0x32,
  2313. 0x20,0x75,0x76,0x3b,0x0a,0x6c,0x61,0x79,0x6f,0x75,0x74,0x28,0x6c,0x6f,0x63,0x61,
  2314. 0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x31,0x29,0x20,0x69,0x6e,0x20,0x76,0x65,0x63,
  2315. 0x32,0x20,0x74,0x65,0x78,0x63,0x6f,0x6f,0x72,0x64,0x30,0x3b,0x0a,0x6f,0x75,0x74,
  2316. 0x20,0x76,0x65,0x63,0x34,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x3b,0x0a,0x6c,0x61,0x79,
  2317. 0x6f,0x75,0x74,0x28,0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x32,
  2318. 0x29,0x20,0x69,0x6e,0x20,0x76,0x65,0x63,0x34,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x30,
  2319. 0x3b,0x0a,0x0a,0x76,0x6f,0x69,0x64,0x20,0x6d,0x61,0x69,0x6e,0x28,0x29,0x0a,0x7b,
  2320. 0x0a,0x20,0x20,0x20,0x20,0x67,0x6c,0x5f,0x50,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,
  2321. 0x20,0x3d,0x20,0x76,0x65,0x63,0x34,0x28,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,
  2322. 0x20,0x2a,0x20,0x76,0x65,0x63,0x32,0x28,0x32,0x2e,0x30,0x2c,0x20,0x2d,0x32,0x2e,
  2323. 0x30,0x29,0x20,0x2b,0x20,0x76,0x65,0x63,0x32,0x28,0x2d,0x31,0x2e,0x30,0x2c,0x20,
  2324. 0x31,0x2e,0x30,0x29,0x2c,0x20,0x30,0x2e,0x30,0x2c,0x20,0x31,0x2e,0x30,0x29,0x3b,
  2325. 0x0a,0x20,0x20,0x20,0x20,0x75,0x76,0x20,0x3d,0x20,0x74,0x65,0x78,0x63,0x6f,0x6f,
  2326. 0x72,0x64,0x30,0x3b,0x0a,0x20,0x20,0x20,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,
  2327. 0x20,0x63,0x6f,0x6c,0x6f,0x72,0x30,0x3b,0x0a,0x7d,0x0a,0x0a,0x00,
  2328. };
  2329. /*
  2330. #version 300 es
  2331. precision mediump float;
  2332. precision highp int;
  2333. uniform highp sampler2D tex_smp;
  2334. layout(location = 0) out highp vec4 frag_color;
  2335. in highp vec2 uv;
  2336. in highp vec4 color;
  2337. void main()
  2338. {
  2339. frag_color = texture(tex_smp, uv).xxxx * color;
  2340. }
  2341. */
  2342. static const uint8_t _sdtx_fs_source_glsl300es[255] = {
  2343. 0x23,0x76,0x65,0x72,0x73,0x69,0x6f,0x6e,0x20,0x33,0x30,0x30,0x20,0x65,0x73,0x0a,
  2344. 0x70,0x72,0x65,0x63,0x69,0x73,0x69,0x6f,0x6e,0x20,0x6d,0x65,0x64,0x69,0x75,0x6d,
  2345. 0x70,0x20,0x66,0x6c,0x6f,0x61,0x74,0x3b,0x0a,0x70,0x72,0x65,0x63,0x69,0x73,0x69,
  2346. 0x6f,0x6e,0x20,0x68,0x69,0x67,0x68,0x70,0x20,0x69,0x6e,0x74,0x3b,0x0a,0x0a,0x75,
  2347. 0x6e,0x69,0x66,0x6f,0x72,0x6d,0x20,0x68,0x69,0x67,0x68,0x70,0x20,0x73,0x61,0x6d,
  2348. 0x70,0x6c,0x65,0x72,0x32,0x44,0x20,0x74,0x65,0x78,0x5f,0x73,0x6d,0x70,0x3b,0x0a,
  2349. 0x0a,0x6c,0x61,0x79,0x6f,0x75,0x74,0x28,0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e,
  2350. 0x20,0x3d,0x20,0x30,0x29,0x20,0x6f,0x75,0x74,0x20,0x68,0x69,0x67,0x68,0x70,0x20,
  2351. 0x76,0x65,0x63,0x34,0x20,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x3b,
  2352. 0x0a,0x69,0x6e,0x20,0x68,0x69,0x67,0x68,0x70,0x20,0x76,0x65,0x63,0x32,0x20,0x75,
  2353. 0x76,0x3b,0x0a,0x69,0x6e,0x20,0x68,0x69,0x67,0x68,0x70,0x20,0x76,0x65,0x63,0x34,
  2354. 0x20,0x63,0x6f,0x6c,0x6f,0x72,0x3b,0x0a,0x0a,0x76,0x6f,0x69,0x64,0x20,0x6d,0x61,
  2355. 0x69,0x6e,0x28,0x29,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x66,0x72,0x61,0x67,0x5f,
  2356. 0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x74,0x65,0x78,0x74,0x75,0x72,0x65,0x28,
  2357. 0x74,0x65,0x78,0x5f,0x73,0x6d,0x70,0x2c,0x20,0x75,0x76,0x29,0x2e,0x78,0x78,0x78,
  2358. 0x78,0x20,0x2a,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x3b,0x0a,0x7d,0x0a,0x0a,0x00,
  2359. };
  2360. #elif defined(SOKOL_METAL)
  2361. /*
  2362. #include <metal_stdlib>
  2363. #include <simd/simd.h>
  2364. using namespace metal;
  2365. struct main0_out
  2366. {
  2367. float2 uv [[user(locn0)]];
  2368. float4 color [[user(locn1)]];
  2369. float4 gl_Position [[position]];
  2370. };
  2371. struct main0_in
  2372. {
  2373. float2 position [[attribute(0)]];
  2374. float2 texcoord0 [[attribute(1)]];
  2375. float4 color0 [[attribute(2)]];
  2376. };
  2377. vertex main0_out main0(main0_in in [[stage_in]])
  2378. {
  2379. main0_out out = {};
  2380. out.gl_Position = float4(fma(in.position, float2(2.0, -2.0), float2(-1.0, 1.0)), 0.0, 1.0);
  2381. out.uv = in.texcoord0;
  2382. out.color = in.color0;
  2383. return out;
  2384. }
  2385. */
  2386. static const uint8_t _sdtx_vs_bytecode_metal_macos[2892] = {
  2387. 0x4d,0x54,0x4c,0x42,0x01,0x80,0x02,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  2388. 0x4c,0x0b,0x00,0x00,0x00,0x00,0x00,0x00,0x58,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  2389. 0x6d,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc9,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  2390. 0x3b,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x01,0x00,0x00,0x00,0x00,0x00,0x00,
  2391. 0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0c,0x01,0x00,0x00,0x00,0x00,0x00,0x00,
  2392. 0x40,0x0a,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x6d,0x00,0x00,0x00,
  2393. 0x4e,0x41,0x4d,0x45,0x06,0x00,0x6d,0x61,0x69,0x6e,0x30,0x00,0x54,0x59,0x50,0x45,
  2394. 0x01,0x00,0x00,0x48,0x41,0x53,0x48,0x20,0x00,0x54,0x27,0xd2,0x9c,0x99,0x28,0x3d,
  2395. 0x28,0xcf,0x09,0x1c,0x55,0xac,0x1d,0xfa,0x23,0x34,0x9b,0xc3,0x82,0x58,0xe9,0xeb,
  2396. 0xdc,0x0c,0xa5,0xd3,0x0c,0xa1,0xbf,0xa0,0xe7,0x4f,0x46,0x46,0x54,0x18,0x00,0x00,
  2397. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  2398. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x56,0x45,0x52,0x53,0x08,0x00,0x01,0x00,0x08,
  2399. 0x00,0x01,0x00,0x01,0x00,0x45,0x4e,0x44,0x54,0x37,0x00,0x00,0x00,0x56,0x41,0x54,
  2400. 0x54,0x22,0x00,0x03,0x00,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x00,0x00,0x80,
  2401. 0x74,0x65,0x78,0x63,0x6f,0x6f,0x72,0x64,0x30,0x00,0x01,0x80,0x63,0x6f,0x6c,0x6f,
  2402. 0x72,0x30,0x00,0x02,0x80,0x56,0x41,0x54,0x59,0x05,0x00,0x03,0x00,0x04,0x04,0x06,
  2403. 0x45,0x4e,0x44,0x54,0x04,0x00,0x00,0x00,0x45,0x4e,0x44,0x54,0xde,0xc0,0x17,0x0b,
  2404. 0x00,0x00,0x00,0x00,0x14,0x00,0x00,0x00,0x20,0x0a,0x00,0x00,0xff,0xff,0xff,0xff,
  2405. 0x42,0x43,0xc0,0xde,0x21,0x0c,0x00,0x00,0x85,0x02,0x00,0x00,0x0b,0x82,0x20,0x00,
  2406. 0x02,0x00,0x00,0x00,0x12,0x00,0x00,0x00,0x07,0x81,0x23,0x91,0x41,0xc8,0x04,0x49,
  2407. 0x06,0x10,0x32,0x39,0x92,0x01,0x84,0x0c,0x25,0x05,0x08,0x19,0x1e,0x04,0x8b,0x62,
  2408. 0x80,0x10,0x45,0x02,0x42,0x92,0x0b,0x42,0x84,0x10,0x32,0x14,0x38,0x08,0x18,0x49,
  2409. 0x0a,0x32,0x44,0x24,0x48,0x0a,0x90,0x21,0x23,0xc4,0x52,0x80,0x0c,0x19,0x21,0x72,
  2410. 0x24,0x07,0xc8,0x08,0x11,0x62,0xa8,0xa0,0xa8,0x40,0xc6,0xf0,0x01,0x00,0x00,0x00,
  2411. 0x51,0x18,0x00,0x00,0x6c,0x00,0x00,0x00,0x1b,0x7e,0x24,0xf8,0xff,0xff,0xff,0xff,
  2412. 0x01,0x90,0x00,0x8a,0x08,0x07,0x78,0x80,0x07,0x79,0x78,0x07,0x7c,0x68,0x03,0x73,
  2413. 0xa8,0x07,0x77,0x18,0x87,0x36,0x30,0x07,0x78,0x68,0x83,0x76,0x08,0x07,0x7a,0x40,
  2414. 0x07,0x80,0x1e,0xe4,0xa1,0x1e,0xca,0x01,0x20,0xda,0x21,0x1d,0xdc,0xa1,0x0d,0xd8,
  2415. 0xa1,0x1c,0xce,0x21,0x1c,0xd8,0xa1,0x0d,0xec,0xa1,0x1c,0xc6,0x81,0x1e,0xde,0x41,
  2416. 0x1e,0xda,0xe0,0x1e,0xd2,0x81,0x1c,0xe8,0x01,0x1d,0x80,0x38,0x90,0x03,0x3c,0x00,
  2417. 0x06,0x77,0x78,0x87,0x36,0x10,0x87,0x7a,0x48,0x07,0x76,0xa0,0x87,0x74,0x70,0x87,
  2418. 0x79,0x00,0x08,0x77,0x78,0x87,0x36,0x30,0x07,0x79,0x08,0x87,0x76,0x28,0x87,0x36,
  2419. 0x80,0x87,0x77,0x48,0x07,0x77,0xa0,0x87,0x72,0x90,0x87,0x36,0x28,0x07,0x76,0x48,
  2420. 0x87,0x76,0x00,0xe8,0x41,0x1e,0xea,0xa1,0x1c,0x00,0xc2,0x1d,0xde,0xa1,0x0d,0xcc,
  2421. 0x41,0x1e,0xc2,0xa1,0x1d,0xca,0xa1,0x0d,0xe0,0xe1,0x1d,0xd2,0xc1,0x1d,0xe8,0xa1,
  2422. 0x1c,0xe4,0xa1,0x0d,0xca,0x81,0x1d,0xd2,0xa1,0x1d,0xda,0xc0,0x1d,0xde,0xc1,0x1d,
  2423. 0xda,0x80,0x1d,0xca,0x21,0x1c,0xcc,0x01,0xa0,0x07,0x79,0xa8,0x87,0x72,0x00,0x08,
  2424. 0x77,0x78,0x87,0x36,0x48,0x07,0x77,0x30,0x87,0x79,0x68,0x03,0x73,0x80,0x87,0x36,
  2425. 0x68,0x87,0x70,0xa0,0x07,0x74,0x00,0xe8,0x41,0x1e,0xea,0xa1,0x1c,0x00,0xc2,0x1d,
  2426. 0xde,0xa1,0x0d,0xdc,0x21,0x1c,0xdc,0x61,0x1e,0xda,0xc0,0x1c,0xe0,0xa1,0x0d,0xda,
  2427. 0x21,0x1c,0xe8,0x01,0x1d,0x00,0x7a,0x90,0x87,0x7a,0x28,0x07,0x80,0x70,0x87,0x77,
  2428. 0x68,0x83,0x79,0x48,0x87,0x73,0x70,0x87,0x72,0x20,0x87,0x36,0xd0,0x87,0x72,0x90,
  2429. 0x87,0x77,0x98,0x87,0x36,0x30,0x07,0x78,0x68,0x83,0x76,0x08,0x07,0x7a,0x40,0x07,
  2430. 0x80,0x1e,0xe4,0xa1,0x1e,0xca,0x01,0x20,0xdc,0xe1,0x1d,0xda,0x80,0x1e,0xe4,0x21,
  2431. 0x1c,0xe0,0x01,0x1e,0xd2,0xc1,0x1d,0xce,0xa1,0x0d,0xda,0x21,0x1c,0xe8,0x01,0x1d,
  2432. 0x00,0x7a,0x90,0x87,0x7a,0x28,0x07,0x80,0x98,0x07,0x7a,0x08,0x87,0x71,0x58,0x87,
  2433. 0x36,0x80,0x07,0x79,0x78,0x07,0x7a,0x28,0x87,0x71,0xa0,0x87,0x77,0x90,0x87,0x36,
  2434. 0x10,0x87,0x7a,0x30,0x07,0x73,0x28,0x07,0x79,0x68,0x83,0x79,0x48,0x07,0x7d,0x28,
  2435. 0x07,0x00,0x0f,0x00,0xa2,0x1e,0xdc,0x61,0x1e,0xc2,0xc1,0x1c,0xca,0xa1,0x0d,0xcc,
  2436. 0x01,0x1e,0xda,0xa0,0x1d,0xc2,0x81,0x1e,0xd0,0x01,0xa0,0x07,0x79,0xa8,0x87,0x72,
  2437. 0x00,0x36,0x18,0xc2,0xff,0xff,0xff,0xff,0x0f,0x80,0x04,0x50,0x1b,0x8c,0xe1,0xff,
  2438. 0xff,0xff,0xff,0x07,0x40,0x02,0x28,0x00,0x49,0x18,0x00,0x00,0x03,0x00,0x00,0x00,
  2439. 0x13,0x82,0x60,0x42,0x20,0x4c,0x08,0x06,0x00,0x00,0x00,0x00,0x89,0x20,0x00,0x00,
  2440. 0x11,0x00,0x00,0x00,0x32,0x22,0x08,0x09,0x20,0x64,0x85,0x04,0x13,0x22,0xa4,0x84,
  2441. 0x04,0x13,0x22,0xe3,0x84,0xa1,0x90,0x14,0x12,0x4c,0x88,0x8c,0x0b,0x84,0x84,0x4c,
  2442. 0x10,0x34,0x33,0x00,0xc3,0x08,0x02,0x30,0x8c,0x40,0x00,0x76,0x08,0x91,0x42,0x4c,
  2443. 0x84,0x10,0x15,0x22,0x22,0x82,0x6c,0x20,0x60,0x8e,0x00,0x0c,0x52,0x20,0x87,0x11,
  2444. 0x88,0x64,0x04,0x00,0x00,0x00,0x00,0x00,0x13,0xb2,0x70,0x48,0x07,0x79,0xb0,0x03,
  2445. 0x3a,0x68,0x83,0x70,0x80,0x07,0x78,0x60,0x87,0x72,0x68,0x83,0x76,0x08,0x87,0x71,
  2446. 0x78,0x87,0x79,0xc0,0x87,0x38,0x80,0x03,0x37,0x88,0x83,0x38,0x70,0x03,0x38,0xd8,
  2447. 0x70,0x1b,0xe5,0xd0,0x06,0xf0,0xa0,0x07,0x76,0x40,0x07,0x7a,0x60,0x07,0x74,0xa0,
  2448. 0x07,0x76,0x40,0x07,0x6d,0x90,0x0e,0x71,0xa0,0x07,0x78,0xa0,0x07,0x78,0xd0,0x06,
  2449. 0xe9,0x80,0x07,0x7a,0x80,0x07,0x7a,0x80,0x07,0x6d,0x90,0x0e,0x71,0x60,0x07,0x7a,
  2450. 0x10,0x07,0x76,0xa0,0x07,0x71,0x60,0x07,0x6d,0x90,0x0e,0x73,0x20,0x07,0x7a,0x30,
  2451. 0x07,0x72,0xa0,0x07,0x73,0x20,0x07,0x6d,0x90,0x0e,0x76,0x40,0x07,0x7a,0x60,0x07,
  2452. 0x74,0xa0,0x07,0x76,0x40,0x07,0x6d,0x60,0x0e,0x73,0x20,0x07,0x7a,0x30,0x07,0x72,
  2453. 0xa0,0x07,0x73,0x20,0x07,0x6d,0x60,0x0e,0x76,0x40,0x07,0x7a,0x60,0x07,0x74,0xa0,
  2454. 0x07,0x76,0x40,0x07,0x6d,0x60,0x0f,0x71,0x60,0x07,0x7a,0x10,0x07,0x76,0xa0,0x07,
  2455. 0x71,0x60,0x07,0x6d,0x60,0x0f,0x72,0x40,0x07,0x7a,0x30,0x07,0x72,0xa0,0x07,0x73,
  2456. 0x20,0x07,0x6d,0x60,0x0f,0x73,0x20,0x07,0x7a,0x30,0x07,0x72,0xa0,0x07,0x73,0x20,
  2457. 0x07,0x6d,0x60,0x0f,0x74,0x80,0x07,0x7a,0x60,0x07,0x74,0xa0,0x07,0x76,0x40,0x07,
  2458. 0x6d,0x60,0x0f,0x76,0x40,0x07,0x7a,0x60,0x07,0x74,0xa0,0x07,0x76,0x40,0x07,0x6d,
  2459. 0x60,0x0f,0x79,0x60,0x07,0x7a,0x10,0x07,0x72,0x80,0x07,0x7a,0x10,0x07,0x72,0x80,
  2460. 0x07,0x6d,0x60,0x0f,0x71,0x20,0x07,0x78,0xa0,0x07,0x71,0x20,0x07,0x78,0xa0,0x07,
  2461. 0x71,0x20,0x07,0x78,0xd0,0x06,0xf6,0x10,0x07,0x79,0x20,0x07,0x7a,0x20,0x07,0x75,
  2462. 0x60,0x07,0x7a,0x20,0x07,0x75,0x60,0x07,0x6d,0x60,0x0f,0x72,0x50,0x07,0x76,0xa0,
  2463. 0x07,0x72,0x50,0x07,0x76,0xa0,0x07,0x72,0x50,0x07,0x76,0xd0,0x06,0xf6,0x50,0x07,
  2464. 0x71,0x20,0x07,0x7a,0x50,0x07,0x71,0x20,0x07,0x7a,0x50,0x07,0x71,0x20,0x07,0x6d,
  2465. 0x60,0x0f,0x71,0x00,0x07,0x72,0x40,0x07,0x7a,0x10,0x07,0x70,0x20,0x07,0x74,0xa0,
  2466. 0x07,0x71,0x00,0x07,0x72,0x40,0x07,0x6d,0xe0,0x0e,0x78,0xa0,0x07,0x71,0x60,0x07,
  2467. 0x7a,0x30,0x07,0x72,0x30,0x84,0x29,0x00,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x18,
  2468. 0xc2,0x1c,0x40,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x64,0x81,0x00,0x00,0x00,0x00,
  2469. 0x08,0x00,0x00,0x00,0x32,0x1e,0x98,0x10,0x19,0x11,0x4c,0x90,0x8c,0x09,0x26,0x47,
  2470. 0xc6,0x04,0x43,0xca,0x12,0x18,0x01,0x28,0x82,0x42,0x28,0x08,0xd2,0xb1,0x84,0x07,
  2471. 0x00,0x00,0x00,0x00,0x79,0x18,0x00,0x00,0xb1,0x00,0x00,0x00,0x1a,0x03,0x4c,0x10,
  2472. 0x97,0x29,0xa2,0x25,0x10,0xab,0x32,0xb9,0xb9,0xb4,0x37,0xb7,0x21,0x46,0x42,0x20,
  2473. 0x80,0x72,0x50,0xb9,0x1b,0x43,0x0b,0x93,0xfb,0x9a,0x4b,0xd3,0x2b,0x1b,0x62,0x24,
  2474. 0x02,0x22,0x24,0x05,0xe3,0x20,0x08,0x0e,0x8e,0xad,0x0c,0xa4,0xad,0x8c,0x2e,0x8c,
  2475. 0x0d,0xc4,0xae,0x4c,0x6e,0x2e,0xed,0xcd,0x0d,0x64,0x46,0x06,0x46,0x66,0xc6,0x65,
  2476. 0x66,0xa6,0x06,0x04,0xa5,0xad,0x8c,0x2e,0x8c,0xcd,0xac,0xac,0x65,0x46,0x06,0x46,
  2477. 0x66,0xc6,0x65,0x66,0xa6,0x26,0x65,0x88,0x80,0x10,0x43,0x8c,0x44,0x48,0x8c,0x64,
  2478. 0x60,0xd1,0x54,0x46,0x17,0xc6,0x36,0x04,0x41,0x8e,0x44,0x48,0x84,0x64,0xe0,0x16,
  2479. 0x96,0x26,0xe7,0x32,0xf6,0xd6,0x06,0x97,0xc6,0x56,0xe6,0x42,0x56,0xe6,0xf6,0x26,
  2480. 0xd7,0x36,0xf7,0x45,0x96,0x36,0x17,0x26,0xc6,0x56,0x36,0x44,0x40,0x12,0x72,0x61,
  2481. 0x69,0x72,0x2e,0x63,0x6f,0x6d,0x70,0x69,0x6c,0x65,0x2e,0x66,0x61,0x73,0x74,0x5f,
  2482. 0x6d,0x61,0x74,0x68,0x5f,0x65,0x6e,0x61,0x62,0x6c,0x65,0x43,0x04,0x64,0x61,0x19,
  2483. 0x84,0xa5,0xc9,0xb9,0x8c,0xbd,0xb5,0xc1,0xa5,0xb1,0x95,0xb9,0x98,0xc9,0x85,0xb5,
  2484. 0x95,0x89,0xd5,0x99,0x99,0x95,0xc9,0x7d,0x99,0x95,0xd1,0x8d,0xa1,0x7d,0x91,0xa5,
  2485. 0xcd,0x85,0x89,0xb1,0x95,0x0d,0x11,0x90,0x86,0x51,0x58,0x9a,0x9c,0x8b,0x5d,0x99,
  2486. 0x1c,0x5d,0x19,0xde,0xd7,0x5b,0x1d,0x1d,0x5c,0x1d,0x1d,0x97,0xba,0xb9,0x32,0x39,
  2487. 0x14,0xb6,0xb7,0x31,0x37,0x98,0x14,0x46,0x61,0x69,0x72,0x2e,0x61,0x72,0x67,0x5f,
  2488. 0x74,0x79,0x70,0x65,0x5f,0x6e,0x61,0x6d,0x65,0x34,0xcc,0xd8,0xde,0xc2,0xe8,0x64,
  2489. 0xc8,0x84,0xa5,0xc9,0xb9,0x84,0xc9,0x9d,0x7d,0xb9,0x85,0xb5,0x95,0x51,0xa8,0xb3,
  2490. 0x1b,0xc2,0x20,0x0f,0x02,0x21,0x11,0x22,0x21,0x13,0x42,0x71,0xa9,0x9b,0x2b,0x93,
  2491. 0x43,0x61,0x7b,0x1b,0x73,0x8b,0x49,0xa1,0x61,0xc6,0xf6,0x16,0x46,0x47,0xc3,0x62,
  2492. 0xec,0x8d,0xed,0x4d,0x6e,0x08,0x83,0x3c,0x88,0x85,0x44,0xc8,0x85,0x4c,0x08,0x46,
  2493. 0x26,0x2c,0x4d,0xce,0x05,0xee,0x6d,0x2e,0x8d,0x2e,0xed,0xcd,0x8d,0xcb,0x19,0xdb,
  2494. 0x17,0xd4,0xdb,0x5c,0x1a,0x5d,0xda,0x9b,0xdb,0x10,0x05,0xd1,0x90,0x08,0xb9,0x90,
  2495. 0x09,0xd9,0x86,0x18,0x48,0x85,0x64,0x08,0x47,0x28,0x2c,0x4d,0xce,0xc5,0xae,0x4c,
  2496. 0x8e,0xae,0x0c,0xef,0x2b,0xcd,0x0d,0xae,0x8e,0x8e,0x52,0x58,0x9a,0x9c,0x0b,0xdb,
  2497. 0xdb,0x58,0x18,0x5d,0xda,0x9b,0xdb,0x57,0x9a,0x1b,0x59,0x19,0x1e,0xbd,0xb3,0x32,
  2498. 0xb7,0x32,0xb9,0x30,0xba,0x32,0x32,0x94,0xaf,0xaf,0xb0,0x34,0xb9,0x2f,0x38,0xb6,
  2499. 0xb0,0xb1,0x32,0xb4,0x37,0x36,0xb2,0x32,0xb9,0xaf,0xaf,0x14,0x22,0x70,0x6f,0x73,
  2500. 0x69,0x74,0x69,0x6f,0x6e,0x43,0xa8,0x64,0x40,0x3c,0xe4,0x4b,0x86,0x44,0x40,0xc0,
  2501. 0x00,0x89,0x10,0x09,0x99,0x90,0x30,0x60,0x42,0x57,0x86,0x37,0xf6,0xf6,0x26,0x47,
  2502. 0x06,0x33,0x84,0x4a,0x04,0xc4,0x43,0xbe,0x44,0x48,0x04,0x04,0x0c,0x90,0x08,0x91,
  2503. 0x90,0x09,0x19,0x03,0x1a,0x63,0x6f,0x6c,0x6f,0x72,0x30,0x43,0xa8,0x84,0x40,0x3c,
  2504. 0xe4,0x4b,0x88,0x44,0x40,0xc0,0x00,0x89,0x90,0x0b,0x99,0x90,0x32,0x18,0x62,0x20,
  2505. 0x62,0x80,0x90,0x01,0x62,0x06,0x43,0x8c,0x02,0x40,0x3a,0xe4,0x0c,0x46,0x44,0xec,
  2506. 0xc0,0x0e,0xf6,0xd0,0x0e,0x6e,0xd0,0x0e,0xef,0x40,0x0e,0xf5,0xc0,0x0e,0xe5,0xe0,
  2507. 0x06,0xe6,0xc0,0x0e,0xe1,0x70,0x0e,0xf3,0x30,0x45,0x08,0x86,0x11,0x0a,0x3b,0xb0,
  2508. 0x83,0x3d,0xb4,0x83,0x1b,0xa4,0x03,0x39,0x94,0x83,0x3b,0xd0,0xc3,0x94,0xa0,0x18,
  2509. 0xb1,0x84,0x43,0x3a,0xc8,0x83,0x1b,0xd8,0x43,0x39,0xc8,0xc3,0x3c,0xa4,0xc3,0x3b,
  2510. 0xb8,0xc3,0x94,0xc0,0x18,0x41,0x85,0x43,0x3a,0xc8,0x83,0x1b,0xb0,0x43,0x38,0xb8,
  2511. 0xc3,0x39,0xd4,0x43,0x38,0x9c,0x43,0x39,0xfc,0x82,0x3d,0x94,0x83,0x3c,0xcc,0x43,
  2512. 0x3a,0xbc,0x83,0x3b,0x4c,0x09,0x90,0x11,0x53,0x38,0xa4,0x83,0x3c,0xb8,0xc1,0x38,
  2513. 0xbc,0x43,0x3b,0xc0,0x43,0x3a,0xb0,0x43,0x39,0xfc,0xc2,0x3b,0xc0,0x03,0x3d,0xa4,
  2514. 0xc3,0x3b,0xb8,0xc3,0x3c,0x4c,0x19,0x14,0xc6,0x19,0xa1,0x84,0x43,0x3a,0xc8,0x83,
  2515. 0x1b,0xd8,0x43,0x39,0xc8,0x03,0x3d,0x94,0x03,0x3e,0x4c,0x09,0xd0,0x00,0x00,0x00,
  2516. 0x79,0x18,0x00,0x00,0xa5,0x00,0x00,0x00,0x33,0x08,0x80,0x1c,0xc4,0xe1,0x1c,0x66,
  2517. 0x14,0x01,0x3d,0x88,0x43,0x38,0x84,0xc3,0x8c,0x42,0x80,0x07,0x79,0x78,0x07,0x73,
  2518. 0x98,0x71,0x0c,0xe6,0x00,0x0f,0xed,0x10,0x0e,0xf4,0x80,0x0e,0x33,0x0c,0x42,0x1e,
  2519. 0xc2,0xc1,0x1d,0xce,0xa1,0x1c,0x66,0x30,0x05,0x3d,0x88,0x43,0x38,0x84,0x83,0x1b,
  2520. 0xcc,0x03,0x3d,0xc8,0x43,0x3d,0x8c,0x03,0x3d,0xcc,0x78,0x8c,0x74,0x70,0x07,0x7b,
  2521. 0x08,0x07,0x79,0x48,0x87,0x70,0x70,0x07,0x7a,0x70,0x03,0x76,0x78,0x87,0x70,0x20,
  2522. 0x87,0x19,0xcc,0x11,0x0e,0xec,0x90,0x0e,0xe1,0x30,0x0f,0x6e,0x30,0x0f,0xe3,0xf0,
  2523. 0x0e,0xf0,0x50,0x0e,0x33,0x10,0xc4,0x1d,0xde,0x21,0x1c,0xd8,0x21,0x1d,0xc2,0x61,
  2524. 0x1e,0x66,0x30,0x89,0x3b,0xbc,0x83,0x3b,0xd0,0x43,0x39,0xb4,0x03,0x3c,0xbc,0x83,
  2525. 0x3c,0x84,0x03,0x3b,0xcc,0xf0,0x14,0x76,0x60,0x07,0x7b,0x68,0x07,0x37,0x68,0x87,
  2526. 0x72,0x68,0x07,0x37,0x80,0x87,0x70,0x90,0x87,0x70,0x60,0x07,0x76,0x28,0x07,0x76,
  2527. 0xf8,0x05,0x76,0x78,0x87,0x77,0x80,0x87,0x5f,0x08,0x87,0x71,0x18,0x87,0x72,0x98,
  2528. 0x87,0x79,0x98,0x81,0x2c,0xee,0xf0,0x0e,0xee,0xe0,0x0e,0xf5,0xc0,0x0e,0xec,0x30,
  2529. 0x03,0x62,0xc8,0xa1,0x1c,0xe4,0xa1,0x1c,0xcc,0xa1,0x1c,0xe4,0xa1,0x1c,0xdc,0x61,
  2530. 0x1c,0xca,0x21,0x1c,0xc4,0x81,0x1d,0xca,0x61,0x06,0xd6,0x90,0x43,0x39,0xc8,0x43,
  2531. 0x39,0x98,0x43,0x39,0xc8,0x43,0x39,0xb8,0xc3,0x38,0x94,0x43,0x38,0x88,0x03,0x3b,
  2532. 0x94,0xc3,0x2f,0xbc,0x83,0x3c,0xfc,0x82,0x3b,0xd4,0x03,0x3b,0xb0,0xc3,0x0c,0xc7,
  2533. 0x69,0x87,0x70,0x58,0x87,0x72,0x70,0x83,0x74,0x68,0x07,0x78,0x60,0x87,0x74,0x18,
  2534. 0x87,0x74,0xa0,0x87,0x19,0xce,0x53,0x0f,0xee,0x00,0x0f,0xf2,0x50,0x0e,0xe4,0x90,
  2535. 0x0e,0xe3,0x40,0x0f,0xe1,0x20,0x0e,0xec,0x50,0x0e,0x33,0x20,0x28,0x1d,0xdc,0xc1,
  2536. 0x1e,0xc2,0x41,0x1e,0xd2,0x21,0x1c,0xdc,0x81,0x1e,0xdc,0xe0,0x1c,0xe4,0xe1,0x1d,
  2537. 0xea,0x01,0x1e,0x66,0x18,0x51,0x38,0xb0,0x43,0x3a,0x9c,0x83,0x3b,0xcc,0x50,0x24,
  2538. 0x76,0x60,0x07,0x7b,0x68,0x07,0x37,0x60,0x87,0x77,0x78,0x07,0x78,0x98,0x51,0x4c,
  2539. 0xf4,0x90,0x0f,0xf0,0x50,0x0e,0x33,0x1e,0x6a,0x1e,0xca,0x61,0x1c,0xe8,0x21,0x1d,
  2540. 0xde,0xc1,0x1d,0x7e,0x01,0x1e,0xe4,0xa1,0x1c,0xcc,0x21,0x1d,0xf0,0x61,0x06,0x54,
  2541. 0x85,0x83,0x38,0xcc,0xc3,0x3b,0xb0,0x43,0x3d,0xd0,0x43,0x39,0xfc,0xc2,0x3c,0xe4,
  2542. 0x43,0x3b,0x88,0xc3,0x3b,0xb0,0xc3,0x8c,0xc5,0x0a,0x87,0x79,0x98,0x87,0x77,0x18,
  2543. 0x87,0x74,0x08,0x07,0x7a,0x28,0x07,0x72,0x98,0x81,0x5c,0xe3,0x10,0x0e,0xec,0xc0,
  2544. 0x0e,0xe5,0x50,0x0e,0xf3,0x30,0x23,0xc1,0xd2,0x41,0x1e,0xe4,0xe1,0x17,0xd8,0xe1,
  2545. 0x1d,0xde,0x01,0x1e,0x66,0x48,0x19,0x3b,0xb0,0x83,0x3d,0xb4,0x83,0x1b,0x84,0xc3,
  2546. 0x38,0x8c,0x43,0x39,0xcc,0xc3,0x3c,0xb8,0xc1,0x39,0xc8,0xc3,0x3b,0xd4,0x03,0x3c,
  2547. 0xcc,0x48,0xb4,0x71,0x08,0x07,0x76,0x60,0x07,0x71,0x08,0x87,0x71,0x58,0x87,0x19,
  2548. 0xdb,0xc6,0x0e,0xec,0x60,0x0f,0xed,0xe0,0x06,0xf0,0x20,0x0f,0xe5,0x30,0x0f,0xe5,
  2549. 0x20,0x0f,0xf6,0x50,0x0e,0x6e,0x10,0x0e,0xe3,0x30,0x0e,0xe5,0x30,0x0f,0xf3,0xe0,
  2550. 0x06,0xe9,0xe0,0x0e,0xe4,0x50,0x0e,0xf8,0x30,0x23,0xe2,0xec,0x61,0x1c,0xc2,0x81,
  2551. 0x1d,0xd8,0xe1,0x17,0xec,0x21,0x1d,0xe6,0x21,0x1d,0xc4,0x21,0x1d,0xd8,0x21,0x1d,
  2552. 0xe8,0x21,0x1f,0x66,0x20,0x9d,0x3b,0xbc,0x43,0x3d,0xb8,0x03,0x39,0x94,0x83,0x39,
  2553. 0xcc,0x58,0xbc,0x70,0x70,0x07,0x77,0x78,0x07,0x7a,0x08,0x07,0x7a,0x48,0x87,0x77,
  2554. 0x70,0x87,0x19,0xce,0x87,0x0e,0xe5,0x10,0x0e,0xf0,0x10,0x0e,0xec,0xc0,0x0e,0xef,
  2555. 0x30,0x0e,0xf3,0x90,0x0e,0xf4,0x50,0x0e,0x33,0x28,0x30,0x08,0x87,0x74,0x90,0x07,
  2556. 0x37,0x30,0x87,0x7a,0x70,0x87,0x71,0xa0,0x87,0x74,0x78,0x07,0x77,0xf8,0x85,0x73,
  2557. 0x90,0x87,0x77,0xa8,0x07,0x78,0x98,0x07,0x00,0x00,0x00,0x00,0x71,0x20,0x00,0x00,
  2558. 0x05,0x00,0x00,0x00,0x06,0x50,0x30,0x00,0xd2,0xd0,0x16,0xd0,0x00,0x48,0xe4,0x17,
  2559. 0x0c,0xe0,0x57,0x76,0x71,0xdb,0x00,0x00,0x61,0x20,0x00,0x00,0x1b,0x00,0x00,0x00,
  2560. 0x13,0x04,0x41,0x2c,0x10,0x00,0x00,0x00,0x10,0x00,0x00,0x00,0xb4,0x63,0x11,0x40,
  2561. 0x60,0x1c,0x73,0x10,0x83,0xd0,0x34,0x94,0x33,0x00,0x14,0x63,0x09,0x20,0x08,0x82,
  2562. 0x20,0x18,0x80,0x20,0x08,0x82,0xe0,0x30,0x96,0x00,0x82,0x20,0x88,0xff,0x02,0x08,
  2563. 0x82,0x20,0xfe,0xcd,0x00,0x90,0xcc,0x41,0x54,0x15,0x35,0xd1,0xcc,0x00,0x10,0x8c,
  2564. 0x11,0x80,0x20,0x08,0xe2,0xdf,0x08,0xc0,0x0c,0x00,0x00,0x00,0x23,0x06,0xc6,0x10,
  2565. 0x54,0x0e,0x72,0x0c,0x32,0x04,0xc7,0x32,0xc8,0x10,0x1c,0xcd,0x6c,0xc3,0x01,0x01,
  2566. 0xb3,0x0d,0x01,0x14,0xcc,0x36,0x04,0x83,0x90,0x01,0x00,0x00,0x00,0x00,0x00,0x00,
  2567. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  2568. };
  2569. /*
  2570. #include <metal_stdlib>
  2571. #include <simd/simd.h>
  2572. using namespace metal;
  2573. struct main0_out
  2574. {
  2575. float4 frag_color [[color(0)]];
  2576. };
  2577. struct main0_in
  2578. {
  2579. float2 uv [[user(locn0)]];
  2580. float4 color [[user(locn1)]];
  2581. };
  2582. fragment main0_out main0(main0_in in [[stage_in]], texture2d<float> tex [[texture(0)]], sampler smp [[sampler(0)]])
  2583. {
  2584. main0_out out = {};
  2585. out.frag_color = tex.sample(smp, in.uv).xxxx * in.color;
  2586. return out;
  2587. }
  2588. */
  2589. static const uint8_t _sdtx_fs_bytecode_metal_macos[3033] = {
  2590. 0x4d,0x54,0x4c,0x42,0x01,0x80,0x02,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  2591. 0xd9,0x0b,0x00,0x00,0x00,0x00,0x00,0x00,0x58,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  2592. 0x6d,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc9,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  2593. 0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xd1,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  2594. 0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xd9,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  2595. 0x00,0x0b,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x6d,0x00,0x00,0x00,
  2596. 0x4e,0x41,0x4d,0x45,0x06,0x00,0x6d,0x61,0x69,0x6e,0x30,0x00,0x54,0x59,0x50,0x45,
  2597. 0x01,0x00,0x01,0x48,0x41,0x53,0x48,0x20,0x00,0x60,0xb0,0xd5,0x97,0xc2,0xac,0x24,
  2598. 0x52,0x1f,0x4a,0x56,0x12,0x1a,0x52,0xd7,0xb5,0xc0,0x14,0xee,0xce,0x96,0x55,0xcf,
  2599. 0x7d,0x2c,0x16,0x4c,0x83,0x17,0xaf,0xc3,0x9d,0x4f,0x46,0x46,0x54,0x18,0x00,0x00,
  2600. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  2601. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x56,0x45,0x52,0x53,0x08,0x00,0x01,0x00,0x08,
  2602. 0x00,0x01,0x00,0x01,0x00,0x45,0x4e,0x44,0x54,0x04,0x00,0x00,0x00,0x45,0x4e,0x44,
  2603. 0x54,0x04,0x00,0x00,0x00,0x45,0x4e,0x44,0x54,0xde,0xc0,0x17,0x0b,0x00,0x00,0x00,
  2604. 0x00,0x14,0x00,0x00,0x00,0xec,0x0a,0x00,0x00,0xff,0xff,0xff,0xff,0x42,0x43,0xc0,
  2605. 0xde,0x21,0x0c,0x00,0x00,0xb8,0x02,0x00,0x00,0x0b,0x82,0x20,0x00,0x02,0x00,0x00,
  2606. 0x00,0x12,0x00,0x00,0x00,0x07,0x81,0x23,0x91,0x41,0xc8,0x04,0x49,0x06,0x10,0x32,
  2607. 0x39,0x92,0x01,0x84,0x0c,0x25,0x05,0x08,0x19,0x1e,0x04,0x8b,0x62,0x80,0x14,0x45,
  2608. 0x02,0x42,0x92,0x0b,0x42,0xa4,0x10,0x32,0x14,0x38,0x08,0x18,0x49,0x0a,0x32,0x44,
  2609. 0x24,0x48,0x0a,0x90,0x21,0x23,0xc4,0x52,0x80,0x0c,0x19,0x21,0x72,0x24,0x07,0xc8,
  2610. 0x48,0x11,0x62,0xa8,0xa0,0xa8,0x40,0xc6,0xf0,0x01,0x00,0x00,0x00,0x51,0x18,0x00,
  2611. 0x00,0x74,0x00,0x00,0x00,0x1b,0xc2,0x24,0xf8,0xff,0xff,0xff,0xff,0x01,0x60,0x00,
  2612. 0x09,0xa8,0x88,0x70,0x80,0x07,0x78,0x90,0x87,0x77,0xc0,0x87,0x36,0x30,0x87,0x7a,
  2613. 0x70,0x87,0x71,0x68,0x03,0x73,0x80,0x87,0x36,0x68,0x87,0x70,0xa0,0x07,0x74,0x00,
  2614. 0xe8,0x41,0x1e,0xea,0xa1,0x1c,0x00,0xa2,0x1d,0xd2,0xc1,0x1d,0xda,0x80,0x1d,0xca,
  2615. 0xe1,0x1c,0xc2,0x81,0x1d,0xda,0xc0,0x1e,0xca,0x61,0x1c,0xe8,0xe1,0x1d,0xe4,0xa1,
  2616. 0x0d,0xee,0x21,0x1d,0xc8,0x81,0x1e,0xd0,0x01,0x88,0x03,0x39,0xc0,0x03,0x60,0x70,
  2617. 0x87,0x77,0x68,0x03,0x71,0xa8,0x87,0x74,0x60,0x07,0x7a,0x48,0x07,0x77,0x98,0x07,
  2618. 0x80,0x70,0x87,0x77,0x68,0x03,0x73,0x90,0x87,0x70,0x68,0x87,0x72,0x68,0x03,0x78,
  2619. 0x78,0x87,0x74,0x70,0x07,0x7a,0x28,0x07,0x79,0x68,0x83,0x72,0x60,0x87,0x74,0x68,
  2620. 0x07,0x80,0x1e,0xe4,0xa1,0x1e,0xca,0x01,0x20,0xdc,0xe1,0x1d,0xda,0xc0,0x1c,0xe4,
  2621. 0x21,0x1c,0xda,0xa1,0x1c,0xda,0x00,0x1e,0xde,0x21,0x1d,0xdc,0x81,0x1e,0xca,0x41,
  2622. 0x1e,0xda,0xa0,0x1c,0xd8,0x21,0x1d,0xda,0xa1,0x0d,0xdc,0xe1,0x1d,0xdc,0xa1,0x0d,
  2623. 0xd8,0xa1,0x1c,0xc2,0xc1,0x1c,0x00,0x7a,0x90,0x87,0x7a,0x28,0x07,0x80,0x70,0x87,
  2624. 0x77,0x68,0x83,0x74,0x70,0x07,0x73,0x98,0x87,0x36,0x30,0x07,0x78,0x68,0x83,0x76,
  2625. 0x08,0x07,0x7a,0x40,0x07,0x80,0x1e,0xe4,0xa1,0x1e,0xca,0x01,0x20,0xdc,0xe1,0x1d,
  2626. 0xda,0xc0,0x1d,0xc2,0xc1,0x1d,0xe6,0xa1,0x0d,0xcc,0x01,0x1e,0xda,0xa0,0x1d,0xc2,
  2627. 0x81,0x1e,0xd0,0x01,0xa0,0x07,0x79,0xa8,0x87,0x72,0x00,0x08,0x77,0x78,0x87,0x36,
  2628. 0x98,0x87,0x74,0x38,0x07,0x77,0x28,0x07,0x72,0x68,0x03,0x7d,0x28,0x07,0x79,0x78,
  2629. 0x87,0x79,0x68,0x03,0x73,0x80,0x87,0x36,0x68,0x87,0x70,0xa0,0x07,0x74,0x00,0xe8,
  2630. 0x41,0x1e,0xea,0xa1,0x1c,0x00,0xc2,0x1d,0xde,0xa1,0x0d,0xe8,0x41,0x1e,0xc2,0x01,
  2631. 0x1e,0xe0,0x21,0x1d,0xdc,0xe1,0x1c,0xda,0xa0,0x1d,0xc2,0x81,0x1e,0xd0,0x01,0xa0,
  2632. 0x07,0x79,0xa8,0x87,0x72,0x00,0x88,0x79,0xa0,0x87,0x70,0x18,0x87,0x75,0x68,0x03,
  2633. 0x78,0x90,0x87,0x77,0xa0,0x87,0x72,0x18,0x07,0x7a,0x78,0x07,0x79,0x68,0x03,0x71,
  2634. 0xa8,0x07,0x73,0x30,0x87,0x72,0x90,0x87,0x36,0x98,0x87,0x74,0xd0,0x87,0x72,0x00,
  2635. 0xf0,0x00,0x20,0xea,0xc1,0x1d,0xe6,0x21,0x1c,0xcc,0xa1,0x1c,0xda,0xc0,0x1c,0xe0,
  2636. 0xa1,0x0d,0xda,0x21,0x1c,0xe8,0x01,0x1d,0x00,0x7a,0x90,0x87,0x7a,0x28,0x07,0x60,
  2637. 0x83,0x21,0x0c,0xc0,0x02,0x54,0x1b,0x8c,0x81,0x00,0x16,0xa0,0xda,0x80,0x10,0xff,
  2638. 0xff,0xff,0xff,0x3f,0x00,0x0c,0x20,0x01,0xd5,0x06,0xa3,0x08,0x80,0x05,0xa8,0x36,
  2639. 0x18,0x86,0x00,0x2c,0x40,0xb5,0x01,0x39,0xfe,0xff,0xff,0xff,0x7f,0x00,0x18,0x40,
  2640. 0x02,0x2a,0x00,0x00,0x00,0x49,0x18,0x00,0x00,0x04,0x00,0x00,0x00,0x13,0x86,0x40,
  2641. 0x18,0x26,0x0c,0x44,0x61,0x4c,0x18,0x8e,0xc2,0x00,0x00,0x00,0x00,0x89,0x20,0x00,
  2642. 0x00,0x1e,0x00,0x00,0x00,0x32,0x22,0x48,0x09,0x20,0x64,0x85,0x04,0x93,0x22,0xa4,
  2643. 0x84,0x04,0x93,0x22,0xe3,0x84,0xa1,0x90,0x14,0x12,0x4c,0x8a,0x8c,0x0b,0x84,0xa4,
  2644. 0x4c,0x10,0x4c,0x33,0x00,0xc3,0x08,0x04,0x60,0x83,0x30,0x8c,0x20,0x00,0x47,0x49,
  2645. 0x53,0x44,0x09,0x93,0xff,0x4f,0xc4,0x35,0x51,0x11,0xf1,0xdb,0xc3,0x3f,0x8d,0x11,
  2646. 0x00,0x83,0x08,0x44,0x70,0x91,0x34,0x45,0x94,0x30,0xf9,0xbf,0x04,0x30,0xcf,0x42,
  2647. 0x44,0xff,0x34,0x46,0x00,0x0c,0x22,0x18,0x42,0x29,0xc4,0x08,0xe5,0x10,0x9a,0x23,
  2648. 0x08,0xe6,0x08,0xc0,0x60,0x18,0x41,0x58,0x0a,0x12,0xca,0x19,0x8a,0x29,0x40,0x6d,
  2649. 0x20,0x20,0x05,0xd6,0x30,0x02,0xb1,0x8c,0x00,0x00,0x00,0x00,0x00,0x13,0xb2,0x70,
  2650. 0x48,0x07,0x79,0xb0,0x03,0x3a,0x68,0x83,0x70,0x80,0x07,0x78,0x60,0x87,0x72,0x68,
  2651. 0x83,0x76,0x08,0x87,0x71,0x78,0x87,0x79,0xc0,0x87,0x38,0x80,0x03,0x37,0x88,0x83,
  2652. 0x38,0x70,0x03,0x38,0xd8,0x70,0x1b,0xe5,0xd0,0x06,0xf0,0xa0,0x07,0x76,0x40,0x07,
  2653. 0x7a,0x60,0x07,0x74,0xa0,0x07,0x76,0x40,0x07,0x6d,0x90,0x0e,0x71,0xa0,0x07,0x78,
  2654. 0xa0,0x07,0x78,0xd0,0x06,0xe9,0x80,0x07,0x7a,0x80,0x07,0x7a,0x80,0x07,0x6d,0x90,
  2655. 0x0e,0x71,0x60,0x07,0x7a,0x10,0x07,0x76,0xa0,0x07,0x71,0x60,0x07,0x6d,0x90,0x0e,
  2656. 0x73,0x20,0x07,0x7a,0x30,0x07,0x72,0xa0,0x07,0x73,0x20,0x07,0x6d,0x90,0x0e,0x76,
  2657. 0x40,0x07,0x7a,0x60,0x07,0x74,0xa0,0x07,0x76,0x40,0x07,0x6d,0x60,0x0e,0x73,0x20,
  2658. 0x07,0x7a,0x30,0x07,0x72,0xa0,0x07,0x73,0x20,0x07,0x6d,0x60,0x0e,0x76,0x40,0x07,
  2659. 0x7a,0x60,0x07,0x74,0xa0,0x07,0x76,0x40,0x07,0x6d,0x60,0x0f,0x71,0x60,0x07,0x7a,
  2660. 0x10,0x07,0x76,0xa0,0x07,0x71,0x60,0x07,0x6d,0x60,0x0f,0x72,0x40,0x07,0x7a,0x30,
  2661. 0x07,0x72,0xa0,0x07,0x73,0x20,0x07,0x6d,0x60,0x0f,0x73,0x20,0x07,0x7a,0x30,0x07,
  2662. 0x72,0xa0,0x07,0x73,0x20,0x07,0x6d,0x60,0x0f,0x74,0x80,0x07,0x7a,0x60,0x07,0x74,
  2663. 0xa0,0x07,0x76,0x40,0x07,0x6d,0x60,0x0f,0x76,0x40,0x07,0x7a,0x60,0x07,0x74,0xa0,
  2664. 0x07,0x76,0x40,0x07,0x6d,0x60,0x0f,0x79,0x60,0x07,0x7a,0x10,0x07,0x72,0x80,0x07,
  2665. 0x7a,0x10,0x07,0x72,0x80,0x07,0x6d,0x60,0x0f,0x71,0x20,0x07,0x78,0xa0,0x07,0x71,
  2666. 0x20,0x07,0x78,0xa0,0x07,0x71,0x20,0x07,0x78,0xd0,0x06,0xf6,0x10,0x07,0x79,0x20,
  2667. 0x07,0x7a,0x20,0x07,0x75,0x60,0x07,0x7a,0x20,0x07,0x75,0x60,0x07,0x6d,0x60,0x0f,
  2668. 0x72,0x50,0x07,0x76,0xa0,0x07,0x72,0x50,0x07,0x76,0xa0,0x07,0x72,0x50,0x07,0x76,
  2669. 0xd0,0x06,0xf6,0x50,0x07,0x71,0x20,0x07,0x7a,0x50,0x07,0x71,0x20,0x07,0x7a,0x50,
  2670. 0x07,0x71,0x20,0x07,0x6d,0x60,0x0f,0x71,0x00,0x07,0x72,0x40,0x07,0x7a,0x10,0x07,
  2671. 0x70,0x20,0x07,0x74,0xa0,0x07,0x71,0x00,0x07,0x72,0x40,0x07,0x6d,0xe0,0x0e,0x78,
  2672. 0xa0,0x07,0x71,0x60,0x07,0x7a,0x30,0x07,0x72,0x30,0x84,0x49,0x00,0x00,0x08,0x00,
  2673. 0x00,0x00,0x00,0x00,0x18,0xc2,0x38,0x40,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x64,
  2674. 0x81,0x00,0x00,0x00,0x00,0x08,0x00,0x00,0x00,0x32,0x1e,0x98,0x10,0x19,0x11,0x4c,
  2675. 0x90,0x8c,0x09,0x26,0x47,0xc6,0x04,0x43,0x5a,0x25,0x30,0x02,0x50,0x04,0x85,0x50,
  2676. 0x10,0x65,0x40,0x70,0x2c,0xe1,0x01,0x00,0x00,0x79,0x18,0x00,0x00,0xd2,0x00,0x00,
  2677. 0x00,0x1a,0x03,0x4c,0x10,0x97,0x29,0xa2,0x25,0x10,0xab,0x32,0xb9,0xb9,0xb4,0x37,
  2678. 0xb7,0x21,0xc6,0x42,0x3c,0x00,0x84,0x50,0xb9,0x1b,0x43,0x0b,0x93,0xfb,0x9a,0x4b,
  2679. 0xd3,0x2b,0x1b,0x62,0x2c,0xc2,0x23,0x2c,0x05,0xe3,0x20,0x08,0x0e,0x8e,0xad,0x0c,
  2680. 0xa4,0xad,0x8c,0x2e,0x8c,0x0d,0xc4,0xae,0x4c,0x6e,0x2e,0xed,0xcd,0x0d,0x64,0x46,
  2681. 0x06,0x46,0x66,0xc6,0x65,0x66,0xa6,0x06,0x04,0xa5,0xad,0x8c,0x2e,0x8c,0xcd,0xac,
  2682. 0xac,0x65,0x46,0x06,0x46,0x66,0xc6,0x65,0x66,0xa6,0x26,0x65,0x88,0xf0,0x10,0x43,
  2683. 0x8c,0x45,0x58,0x8c,0x65,0x60,0xd1,0x54,0x46,0x17,0xc6,0x36,0x04,0x79,0x8e,0x45,
  2684. 0x58,0x84,0x65,0xe0,0x16,0x96,0x26,0xe7,0x32,0xf6,0xd6,0x06,0x97,0xc6,0x56,0xe6,
  2685. 0x42,0x56,0xe6,0xf6,0x26,0xd7,0x36,0xf7,0x45,0x96,0x36,0x17,0x26,0xc6,0x56,0x36,
  2686. 0x44,0x78,0x12,0x72,0x61,0x69,0x72,0x2e,0x63,0x6f,0x6d,0x70,0x69,0x6c,0x65,0x2e,
  2687. 0x66,0x61,0x73,0x74,0x5f,0x6d,0x61,0x74,0x68,0x5f,0x65,0x6e,0x61,0x62,0x6c,0x65,
  2688. 0x43,0x84,0x67,0x61,0x19,0x84,0xa5,0xc9,0xb9,0x8c,0xbd,0xb5,0xc1,0xa5,0xb1,0x95,
  2689. 0xb9,0x98,0xc9,0x85,0xb5,0x95,0x89,0xd5,0x99,0x99,0x95,0xc9,0x7d,0x99,0x95,0xd1,
  2690. 0x8d,0xa1,0x7d,0x91,0xa5,0xcd,0x85,0x89,0xb1,0x95,0x0d,0x11,0x9e,0x86,0x51,0x58,
  2691. 0x9a,0x9c,0x8b,0x5c,0x99,0x1b,0x59,0x99,0xdc,0x17,0x5d,0x98,0xdc,0x59,0x19,0x1d,
  2692. 0xa3,0xb0,0x34,0x39,0x97,0x30,0xb9,0xb3,0x2f,0xba,0x3c,0xb8,0xb2,0x2f,0xb7,0xb0,
  2693. 0xb6,0x32,0x1a,0x66,0x6c,0x6f,0x61,0x74,0x34,0x64,0xc2,0xd2,0xe4,0x5c,0xc2,0xe4,
  2694. 0xce,0xbe,0xdc,0xc2,0xda,0xca,0xa8,0x98,0xc9,0x85,0x9d,0x7d,0x8d,0xbd,0xb1,0xbd,
  2695. 0xc9,0x0d,0x61,0x9e,0x67,0x19,0x1e,0xe8,0x89,0x1e,0xe9,0x99,0x86,0x08,0x0f,0x45,
  2696. 0x29,0x2c,0x4d,0xce,0xc5,0x4c,0x2e,0xec,0xac,0xad,0xcc,0x8d,0xee,0x2b,0xcd,0x0d,
  2697. 0xae,0x8e,0x8e,0x4b,0xdd,0x5c,0x99,0x1c,0x0a,0xdb,0xdb,0x98,0x1b,0x4c,0x0a,0x95,
  2698. 0xb0,0x34,0x39,0x97,0xb1,0x32,0x37,0xba,0x32,0x39,0x3e,0x61,0x69,0x72,0x2e,0x70,
  2699. 0x65,0x72,0x73,0x70,0x65,0x63,0x74,0x69,0x76,0x65,0x34,0xcc,0xd8,0xde,0xc2,0xe8,
  2700. 0x64,0x28,0xd4,0xd9,0x0d,0x91,0x96,0xe1,0xb1,0x9e,0xeb,0xc1,0x9e,0xec,0x81,0x1e,
  2701. 0xed,0x91,0x9e,0x8d,0x4b,0xdd,0x5c,0x99,0x1c,0x0a,0xdb,0xdb,0x98,0x5b,0x4c,0x0a,
  2702. 0x8b,0xb1,0x37,0xb6,0x37,0xb9,0x21,0xd2,0x22,0x3c,0xd6,0xd3,0x3d,0xd8,0x93,0x3d,
  2703. 0xd0,0x13,0x3d,0xd2,0xe3,0x71,0x09,0x4b,0x93,0x73,0xa1,0x2b,0xc3,0xa3,0xab,0x93,
  2704. 0x2b,0xa3,0x14,0x96,0x26,0xe7,0xc2,0xf6,0x36,0x16,0x46,0x97,0xf6,0xe6,0xf6,0x95,
  2705. 0xe6,0x46,0x56,0x86,0x47,0x25,0x2c,0x4d,0xce,0x65,0x2e,0xac,0x0d,0x8e,0xad,0x8c,
  2706. 0x18,0x5d,0x19,0x1e,0x5d,0x9d,0x5c,0x99,0x0c,0x19,0x8f,0x19,0xdb,0x5b,0x18,0x1d,
  2707. 0x0b,0xc8,0x5c,0x58,0x1b,0x1c,0x5b,0x99,0x0f,0x07,0xba,0x32,0xbc,0x21,0xd4,0x42,
  2708. 0x3c,0x60,0xf0,0x84,0xc1,0x32,0x2c,0xc2,0x23,0x06,0x0f,0xf4,0x8c,0xc1,0x23,0x3d,
  2709. 0x64,0xc0,0x25,0x2c,0x4d,0xce,0x65,0x2e,0xac,0x0d,0x8e,0xad,0x4c,0x8e,0xc7,0x5c,
  2710. 0x58,0x1b,0x1c,0x5b,0x99,0x1c,0x87,0xb9,0x36,0xb8,0x21,0xd2,0x72,0x3c,0x66,0xf0,
  2711. 0x84,0xc1,0x32,0x2c,0xc2,0x03,0x3d,0x67,0xf0,0x48,0x0f,0x1a,0x0c,0x41,0x1e,0xee,
  2712. 0xf9,0x9e,0x32,0x78,0xd2,0x60,0x88,0x91,0x00,0x4f,0xf5,0xa8,0x01,0xaf,0xb0,0x34,
  2713. 0xb9,0x96,0x30,0xb6,0xb4,0xb0,0xb9,0x96,0xb9,0xb1,0x37,0xb8,0xb2,0x39,0x94,0xb6,
  2714. 0xb0,0x34,0x37,0x98,0x94,0x21,0xc4,0xd3,0x06,0x0f,0x1b,0x10,0x0b,0x4b,0x93,0x6b,
  2715. 0x09,0x63,0x4b,0x0b,0x9b,0x6b,0x99,0x1b,0x7b,0x83,0x2b,0x6b,0xa1,0x2b,0xc3,0xa3,
  2716. 0xab,0x93,0x2b,0x9b,0x1b,0x62,0x3c,0x6f,0xf0,0xb4,0xc1,0xe3,0x06,0xc4,0xc2,0xd2,
  2717. 0xe4,0x5a,0xc2,0xd8,0xd2,0xc2,0xe6,0x5a,0xe6,0xc6,0xde,0xe0,0xca,0x5a,0xe6,0xc2,
  2718. 0xda,0xe0,0xd8,0xca,0xe4,0xe6,0x86,0x18,0x4f,0x1c,0x3c,0x6d,0xf0,0xc0,0xc1,0x10,
  2719. 0xe2,0x79,0x83,0x27,0x0e,0x46,0x44,0xec,0xc0,0x0e,0xf6,0xd0,0x0e,0x6e,0xd0,0x0e,
  2720. 0xef,0x40,0x0e,0xf5,0xc0,0x0e,0xe5,0xe0,0x06,0xe6,0xc0,0x0e,0xe1,0x70,0x0e,0xf3,
  2721. 0x30,0x45,0x08,0x86,0x11,0x0a,0x3b,0xb0,0x83,0x3d,0xb4,0x83,0x1b,0xa4,0x03,0x39,
  2722. 0x94,0x83,0x3b,0xd0,0xc3,0x94,0xa0,0x18,0xb1,0x84,0x43,0x3a,0xc8,0x83,0x1b,0xd8,
  2723. 0x43,0x39,0xc8,0xc3,0x3c,0xa4,0xc3,0x3b,0xb8,0xc3,0x94,0xc0,0x18,0x41,0x85,0x43,
  2724. 0x3a,0xc8,0x83,0x1b,0xb0,0x43,0x38,0xb8,0xc3,0x39,0xd4,0x43,0x38,0x9c,0x43,0x39,
  2725. 0xfc,0x82,0x3d,0x94,0x83,0x3c,0xcc,0x43,0x3a,0xbc,0x83,0x3b,0x4c,0x09,0x90,0x11,
  2726. 0x53,0x38,0xa4,0x83,0x3c,0xb8,0xc1,0x38,0xbc,0x43,0x3b,0xc0,0x43,0x3a,0xb0,0x43,
  2727. 0x39,0xfc,0xc2,0x3b,0xc0,0x03,0x3d,0xa4,0xc3,0x3b,0xb8,0xc3,0x3c,0x4c,0x19,0x14,
  2728. 0xc6,0x19,0xc1,0x84,0x43,0x3a,0xc8,0x83,0x1b,0x98,0x83,0x3c,0x84,0xc3,0x39,0xb4,
  2729. 0x43,0x39,0xb8,0x03,0x3d,0x4c,0x09,0xd6,0x00,0x79,0x18,0x00,0x00,0xa5,0x00,0x00,
  2730. 0x00,0x33,0x08,0x80,0x1c,0xc4,0xe1,0x1c,0x66,0x14,0x01,0x3d,0x88,0x43,0x38,0x84,
  2731. 0xc3,0x8c,0x42,0x80,0x07,0x79,0x78,0x07,0x73,0x98,0x71,0x0c,0xe6,0x00,0x0f,0xed,
  2732. 0x10,0x0e,0xf4,0x80,0x0e,0x33,0x0c,0x42,0x1e,0xc2,0xc1,0x1d,0xce,0xa1,0x1c,0x66,
  2733. 0x30,0x05,0x3d,0x88,0x43,0x38,0x84,0x83,0x1b,0xcc,0x03,0x3d,0xc8,0x43,0x3d,0x8c,
  2734. 0x03,0x3d,0xcc,0x78,0x8c,0x74,0x70,0x07,0x7b,0x08,0x07,0x79,0x48,0x87,0x70,0x70,
  2735. 0x07,0x7a,0x70,0x03,0x76,0x78,0x87,0x70,0x20,0x87,0x19,0xcc,0x11,0x0e,0xec,0x90,
  2736. 0x0e,0xe1,0x30,0x0f,0x6e,0x30,0x0f,0xe3,0xf0,0x0e,0xf0,0x50,0x0e,0x33,0x10,0xc4,
  2737. 0x1d,0xde,0x21,0x1c,0xd8,0x21,0x1d,0xc2,0x61,0x1e,0x66,0x30,0x89,0x3b,0xbc,0x83,
  2738. 0x3b,0xd0,0x43,0x39,0xb4,0x03,0x3c,0xbc,0x83,0x3c,0x84,0x03,0x3b,0xcc,0xf0,0x14,
  2739. 0x76,0x60,0x07,0x7b,0x68,0x07,0x37,0x68,0x87,0x72,0x68,0x07,0x37,0x80,0x87,0x70,
  2740. 0x90,0x87,0x70,0x60,0x07,0x76,0x28,0x07,0x76,0xf8,0x05,0x76,0x78,0x87,0x77,0x80,
  2741. 0x87,0x5f,0x08,0x87,0x71,0x18,0x87,0x72,0x98,0x87,0x79,0x98,0x81,0x2c,0xee,0xf0,
  2742. 0x0e,0xee,0xe0,0x0e,0xf5,0xc0,0x0e,0xec,0x30,0x03,0x62,0xc8,0xa1,0x1c,0xe4,0xa1,
  2743. 0x1c,0xcc,0xa1,0x1c,0xe4,0xa1,0x1c,0xdc,0x61,0x1c,0xca,0x21,0x1c,0xc4,0x81,0x1d,
  2744. 0xca,0x61,0x06,0xd6,0x90,0x43,0x39,0xc8,0x43,0x39,0x98,0x43,0x39,0xc8,0x43,0x39,
  2745. 0xb8,0xc3,0x38,0x94,0x43,0x38,0x88,0x03,0x3b,0x94,0xc3,0x2f,0xbc,0x83,0x3c,0xfc,
  2746. 0x82,0x3b,0xd4,0x03,0x3b,0xb0,0xc3,0x0c,0xc7,0x69,0x87,0x70,0x58,0x87,0x72,0x70,
  2747. 0x83,0x74,0x68,0x07,0x78,0x60,0x87,0x74,0x18,0x87,0x74,0xa0,0x87,0x19,0xce,0x53,
  2748. 0x0f,0xee,0x00,0x0f,0xf2,0x50,0x0e,0xe4,0x90,0x0e,0xe3,0x40,0x0f,0xe1,0x20,0x0e,
  2749. 0xec,0x50,0x0e,0x33,0x20,0x28,0x1d,0xdc,0xc1,0x1e,0xc2,0x41,0x1e,0xd2,0x21,0x1c,
  2750. 0xdc,0x81,0x1e,0xdc,0xe0,0x1c,0xe4,0xe1,0x1d,0xea,0x01,0x1e,0x66,0x18,0x51,0x38,
  2751. 0xb0,0x43,0x3a,0x9c,0x83,0x3b,0xcc,0x50,0x24,0x76,0x60,0x07,0x7b,0x68,0x07,0x37,
  2752. 0x60,0x87,0x77,0x78,0x07,0x78,0x98,0x51,0x4c,0xf4,0x90,0x0f,0xf0,0x50,0x0e,0x33,
  2753. 0x1e,0x6a,0x1e,0xca,0x61,0x1c,0xe8,0x21,0x1d,0xde,0xc1,0x1d,0x7e,0x01,0x1e,0xe4,
  2754. 0xa1,0x1c,0xcc,0x21,0x1d,0xf0,0x61,0x06,0x54,0x85,0x83,0x38,0xcc,0xc3,0x3b,0xb0,
  2755. 0x43,0x3d,0xd0,0x43,0x39,0xfc,0xc2,0x3c,0xe4,0x43,0x3b,0x88,0xc3,0x3b,0xb0,0xc3,
  2756. 0x8c,0xc5,0x0a,0x87,0x79,0x98,0x87,0x77,0x18,0x87,0x74,0x08,0x07,0x7a,0x28,0x07,
  2757. 0x72,0x98,0x81,0x5c,0xe3,0x10,0x0e,0xec,0xc0,0x0e,0xe5,0x50,0x0e,0xf3,0x30,0x23,
  2758. 0xc1,0xd2,0x41,0x1e,0xe4,0xe1,0x17,0xd8,0xe1,0x1d,0xde,0x01,0x1e,0x66,0x48,0x19,
  2759. 0x3b,0xb0,0x83,0x3d,0xb4,0x83,0x1b,0x84,0xc3,0x38,0x8c,0x43,0x39,0xcc,0xc3,0x3c,
  2760. 0xb8,0xc1,0x39,0xc8,0xc3,0x3b,0xd4,0x03,0x3c,0xcc,0x48,0xb4,0x71,0x08,0x07,0x76,
  2761. 0x60,0x07,0x71,0x08,0x87,0x71,0x58,0x87,0x19,0xdb,0xc6,0x0e,0xec,0x60,0x0f,0xed,
  2762. 0xe0,0x06,0xf0,0x20,0x0f,0xe5,0x30,0x0f,0xe5,0x20,0x0f,0xf6,0x50,0x0e,0x6e,0x10,
  2763. 0x0e,0xe3,0x30,0x0e,0xe5,0x30,0x0f,0xf3,0xe0,0x06,0xe9,0xe0,0x0e,0xe4,0x50,0x0e,
  2764. 0xf8,0x30,0x23,0xe2,0xec,0x61,0x1c,0xc2,0x81,0x1d,0xd8,0xe1,0x17,0xec,0x21,0x1d,
  2765. 0xe6,0x21,0x1d,0xc4,0x21,0x1d,0xd8,0x21,0x1d,0xe8,0x21,0x1f,0x66,0x20,0x9d,0x3b,
  2766. 0xbc,0x43,0x3d,0xb8,0x03,0x39,0x94,0x83,0x39,0xcc,0x58,0xbc,0x70,0x70,0x07,0x77,
  2767. 0x78,0x07,0x7a,0x08,0x07,0x7a,0x48,0x87,0x77,0x70,0x87,0x19,0xce,0x87,0x0e,0xe5,
  2768. 0x10,0x0e,0xf0,0x10,0x0e,0xec,0xc0,0x0e,0xef,0x30,0x0e,0xf3,0x90,0x0e,0xf4,0x50,
  2769. 0x0e,0x33,0x28,0x30,0x08,0x87,0x74,0x90,0x07,0x37,0x30,0x87,0x7a,0x70,0x87,0x71,
  2770. 0xa0,0x87,0x74,0x78,0x07,0x77,0xf8,0x85,0x73,0x90,0x87,0x77,0xa8,0x07,0x78,0x98,
  2771. 0x07,0x00,0x00,0x00,0x00,0x71,0x20,0x00,0x00,0x08,0x00,0x00,0x00,0x16,0xb0,0x01,
  2772. 0x48,0xe4,0x4b,0x00,0xf3,0x2c,0xc4,0x3f,0x11,0xd7,0x44,0x45,0xc4,0x6f,0x0f,0x7e,
  2773. 0x85,0x17,0xb7,0x6d,0x00,0x05,0x03,0x20,0x0d,0x0d,0x00,0x00,0x00,0x61,0x20,0x00,
  2774. 0x00,0x14,0x00,0x00,0x00,0x13,0x04,0x41,0x2c,0x10,0x00,0x00,0x00,0x06,0x00,0x00,
  2775. 0x00,0x14,0x47,0x00,0x88,0x8d,0x00,0x90,0x1a,0x01,0xa8,0x01,0x12,0x33,0x00,0x14,
  2776. 0x66,0x00,0x08,0x8c,0x00,0x00,0x00,0x00,0x00,0x23,0x06,0xca,0x10,0x4c,0x09,0xb2,
  2777. 0x10,0x46,0x11,0x0c,0x32,0x04,0x03,0x62,0x01,0x23,0x9f,0xd9,0x06,0x23,0x00,0x32,
  2778. 0x08,0x88,0x01,0x00,0x00,0x02,0x00,0x00,0x00,0x5b,0x06,0xe0,0x90,0x03,0x00,0x00,
  2779. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  2780. };
  2781. /*
  2782. #include <metal_stdlib>
  2783. #include <simd/simd.h>
  2784. using namespace metal;
  2785. struct main0_out
  2786. {
  2787. float2 uv [[user(locn0)]];
  2788. float4 color [[user(locn1)]];
  2789. float4 gl_Position [[position]];
  2790. };
  2791. struct main0_in
  2792. {
  2793. float2 position [[attribute(0)]];
  2794. float2 texcoord0 [[attribute(1)]];
  2795. float4 color0 [[attribute(2)]];
  2796. };
  2797. vertex main0_out main0(main0_in in [[stage_in]])
  2798. {
  2799. main0_out out = {};
  2800. out.gl_Position = float4(fma(in.position, float2(2.0, -2.0), float2(-1.0, 1.0)), 0.0, 1.0);
  2801. out.uv = in.texcoord0;
  2802. out.color = in.color0;
  2803. return out;
  2804. }
  2805. */
  2806. static const uint8_t _sdtx_vs_bytecode_metal_ios[2876] = {
  2807. 0x4d,0x54,0x4c,0x42,0x01,0x00,0x02,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  2808. 0x3c,0x0b,0x00,0x00,0x00,0x00,0x00,0x00,0x58,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  2809. 0x6d,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc9,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  2810. 0x3b,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x01,0x00,0x00,0x00,0x00,0x00,0x00,
  2811. 0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0c,0x01,0x00,0x00,0x00,0x00,0x00,0x00,
  2812. 0x30,0x0a,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x6d,0x00,0x00,0x00,
  2813. 0x4e,0x41,0x4d,0x45,0x06,0x00,0x6d,0x61,0x69,0x6e,0x30,0x00,0x54,0x59,0x50,0x45,
  2814. 0x01,0x00,0x00,0x48,0x41,0x53,0x48,0x20,0x00,0x54,0x27,0x6d,0x17,0x18,0x1b,0xd1,
  2815. 0x64,0x91,0xfe,0x8a,0x4c,0x49,0xdf,0xe3,0x15,0x74,0xcb,0x3e,0x43,0xde,0xeb,0xfa,
  2816. 0x8e,0xf0,0xf5,0xf8,0x4b,0xd2,0xac,0x23,0xe4,0x4f,0x46,0x46,0x54,0x18,0x00,0x00,
  2817. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  2818. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x56,0x45,0x52,0x53,0x08,0x00,0x01,0x00,0x08,
  2819. 0x00,0x01,0x00,0x01,0x00,0x45,0x4e,0x44,0x54,0x37,0x00,0x00,0x00,0x56,0x41,0x54,
  2820. 0x54,0x22,0x00,0x03,0x00,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x00,0x00,0x80,
  2821. 0x74,0x65,0x78,0x63,0x6f,0x6f,0x72,0x64,0x30,0x00,0x01,0x80,0x63,0x6f,0x6c,0x6f,
  2822. 0x72,0x30,0x00,0x02,0x80,0x56,0x41,0x54,0x59,0x05,0x00,0x03,0x00,0x04,0x04,0x06,
  2823. 0x45,0x4e,0x44,0x54,0x04,0x00,0x00,0x00,0x45,0x4e,0x44,0x54,0xde,0xc0,0x17,0x0b,
  2824. 0x00,0x00,0x00,0x00,0x14,0x00,0x00,0x00,0x18,0x0a,0x00,0x00,0xff,0xff,0xff,0xff,
  2825. 0x42,0x43,0xc0,0xde,0x21,0x0c,0x00,0x00,0x83,0x02,0x00,0x00,0x0b,0x82,0x20,0x00,
  2826. 0x02,0x00,0x00,0x00,0x12,0x00,0x00,0x00,0x07,0x81,0x23,0x91,0x41,0xc8,0x04,0x49,
  2827. 0x06,0x10,0x32,0x39,0x92,0x01,0x84,0x0c,0x25,0x05,0x08,0x19,0x1e,0x04,0x8b,0x62,
  2828. 0x80,0x10,0x45,0x02,0x42,0x92,0x0b,0x42,0x84,0x10,0x32,0x14,0x38,0x08,0x18,0x49,
  2829. 0x0a,0x32,0x44,0x24,0x48,0x0a,0x90,0x21,0x23,0xc4,0x52,0x80,0x0c,0x19,0x21,0x72,
  2830. 0x24,0x07,0xc8,0x08,0x11,0x62,0xa8,0xa0,0xa8,0x40,0xc6,0xf0,0x01,0x00,0x00,0x00,
  2831. 0x51,0x18,0x00,0x00,0x6c,0x00,0x00,0x00,0x1b,0x7e,0x24,0xf8,0xff,0xff,0xff,0xff,
  2832. 0x01,0x90,0x00,0x8a,0x08,0x07,0x78,0x80,0x07,0x79,0x78,0x07,0x7c,0x68,0x03,0x73,
  2833. 0xa8,0x07,0x77,0x18,0x87,0x36,0x30,0x07,0x78,0x68,0x83,0x76,0x08,0x07,0x7a,0x40,
  2834. 0x07,0x80,0x1e,0xe4,0xa1,0x1e,0xca,0x01,0x20,0xda,0x21,0x1d,0xdc,0xa1,0x0d,0xd8,
  2835. 0xa1,0x1c,0xce,0x21,0x1c,0xd8,0xa1,0x0d,0xec,0xa1,0x1c,0xc6,0x81,0x1e,0xde,0x41,
  2836. 0x1e,0xda,0xe0,0x1e,0xd2,0x81,0x1c,0xe8,0x01,0x1d,0x80,0x38,0x90,0x03,0x3c,0x00,
  2837. 0x06,0x77,0x78,0x87,0x36,0x10,0x87,0x7a,0x48,0x07,0x76,0xa0,0x87,0x74,0x70,0x87,
  2838. 0x79,0x00,0x08,0x77,0x78,0x87,0x36,0x30,0x07,0x79,0x08,0x87,0x76,0x28,0x87,0x36,
  2839. 0x80,0x87,0x77,0x48,0x07,0x77,0xa0,0x87,0x72,0x90,0x87,0x36,0x28,0x07,0x76,0x48,
  2840. 0x87,0x76,0x00,0xe8,0x41,0x1e,0xea,0xa1,0x1c,0x00,0xc2,0x1d,0xde,0xa1,0x0d,0xcc,
  2841. 0x41,0x1e,0xc2,0xa1,0x1d,0xca,0xa1,0x0d,0xe0,0xe1,0x1d,0xd2,0xc1,0x1d,0xe8,0xa1,
  2842. 0x1c,0xe4,0xa1,0x0d,0xca,0x81,0x1d,0xd2,0xa1,0x1d,0xda,0xc0,0x1d,0xde,0xc1,0x1d,
  2843. 0xda,0x80,0x1d,0xca,0x21,0x1c,0xcc,0x01,0xa0,0x07,0x79,0xa8,0x87,0x72,0x00,0x08,
  2844. 0x77,0x78,0x87,0x36,0x48,0x07,0x77,0x30,0x87,0x79,0x68,0x03,0x73,0x80,0x87,0x36,
  2845. 0x68,0x87,0x70,0xa0,0x07,0x74,0x00,0xe8,0x41,0x1e,0xea,0xa1,0x1c,0x00,0xc2,0x1d,
  2846. 0xde,0xa1,0x0d,0xdc,0x21,0x1c,0xdc,0x61,0x1e,0xda,0xc0,0x1c,0xe0,0xa1,0x0d,0xda,
  2847. 0x21,0x1c,0xe8,0x01,0x1d,0x00,0x7a,0x90,0x87,0x7a,0x28,0x07,0x80,0x70,0x87,0x77,
  2848. 0x68,0x83,0x79,0x48,0x87,0x73,0x70,0x87,0x72,0x20,0x87,0x36,0xd0,0x87,0x72,0x90,
  2849. 0x87,0x77,0x98,0x87,0x36,0x30,0x07,0x78,0x68,0x83,0x76,0x08,0x07,0x7a,0x40,0x07,
  2850. 0x80,0x1e,0xe4,0xa1,0x1e,0xca,0x01,0x20,0xdc,0xe1,0x1d,0xda,0x80,0x1e,0xe4,0x21,
  2851. 0x1c,0xe0,0x01,0x1e,0xd2,0xc1,0x1d,0xce,0xa1,0x0d,0xda,0x21,0x1c,0xe8,0x01,0x1d,
  2852. 0x00,0x7a,0x90,0x87,0x7a,0x28,0x07,0x80,0x98,0x07,0x7a,0x08,0x87,0x71,0x58,0x87,
  2853. 0x36,0x80,0x07,0x79,0x78,0x07,0x7a,0x28,0x87,0x71,0xa0,0x87,0x77,0x90,0x87,0x36,
  2854. 0x10,0x87,0x7a,0x30,0x07,0x73,0x28,0x07,0x79,0x68,0x83,0x79,0x48,0x07,0x7d,0x28,
  2855. 0x07,0x00,0x0f,0x00,0xa2,0x1e,0xdc,0x61,0x1e,0xc2,0xc1,0x1c,0xca,0xa1,0x0d,0xcc,
  2856. 0x01,0x1e,0xda,0xa0,0x1d,0xc2,0x81,0x1e,0xd0,0x01,0xa0,0x07,0x79,0xa8,0x87,0x72,
  2857. 0x00,0x36,0x18,0xc2,0xff,0xff,0xff,0xff,0x0f,0x80,0x04,0x50,0x1b,0x8c,0xe1,0xff,
  2858. 0xff,0xff,0xff,0x07,0x40,0x02,0x28,0x00,0x49,0x18,0x00,0x00,0x03,0x00,0x00,0x00,
  2859. 0x13,0x82,0x60,0x42,0x20,0x4c,0x08,0x06,0x00,0x00,0x00,0x00,0x89,0x20,0x00,0x00,
  2860. 0x11,0x00,0x00,0x00,0x32,0x22,0x08,0x09,0x20,0x64,0x85,0x04,0x13,0x22,0xa4,0x84,
  2861. 0x04,0x13,0x22,0xe3,0x84,0xa1,0x90,0x14,0x12,0x4c,0x88,0x8c,0x0b,0x84,0x84,0x4c,
  2862. 0x10,0x34,0x33,0x00,0xc3,0x08,0x02,0x30,0x8c,0x40,0x00,0x76,0x08,0x91,0x42,0x4c,
  2863. 0x84,0x10,0x15,0x22,0x22,0x82,0x6c,0x20,0x60,0x8e,0x00,0x0c,0x52,0x20,0x87,0x11,
  2864. 0x88,0x64,0x04,0x00,0x00,0x00,0x00,0x00,0x13,0xa8,0x70,0x48,0x07,0x79,0xb0,0x03,
  2865. 0x3a,0x68,0x83,0x70,0x80,0x07,0x78,0x60,0x87,0x72,0x68,0x83,0x74,0x78,0x87,0x79,
  2866. 0xc8,0x03,0x37,0x80,0x03,0x37,0x80,0x83,0x0d,0xb7,0x51,0x0e,0x6d,0x00,0x0f,0x7a,
  2867. 0x60,0x07,0x74,0xa0,0x07,0x76,0x40,0x07,0x7a,0x60,0x07,0x74,0xd0,0x06,0xe9,0x10,
  2868. 0x07,0x7a,0x80,0x07,0x7a,0x80,0x07,0x6d,0x90,0x0e,0x78,0xa0,0x07,0x78,0xa0,0x07,
  2869. 0x78,0xd0,0x06,0xe9,0x10,0x07,0x76,0xa0,0x07,0x71,0x60,0x07,0x7a,0x10,0x07,0x76,
  2870. 0xd0,0x06,0xe9,0x30,0x07,0x72,0xa0,0x07,0x73,0x20,0x07,0x7a,0x30,0x07,0x72,0xd0,
  2871. 0x06,0xe9,0x60,0x07,0x74,0xa0,0x07,0x76,0x40,0x07,0x7a,0x60,0x07,0x74,0xd0,0x06,
  2872. 0xe6,0x30,0x07,0x72,0xa0,0x07,0x73,0x20,0x07,0x7a,0x30,0x07,0x72,0xd0,0x06,0xe6,
  2873. 0x60,0x07,0x74,0xa0,0x07,0x76,0x40,0x07,0x7a,0x60,0x07,0x74,0xd0,0x06,0xf6,0x10,
  2874. 0x07,0x76,0xa0,0x07,0x71,0x60,0x07,0x7a,0x10,0x07,0x76,0xd0,0x06,0xf6,0x20,0x07,
  2875. 0x74,0xa0,0x07,0x73,0x20,0x07,0x7a,0x30,0x07,0x72,0xd0,0x06,0xf6,0x30,0x07,0x72,
  2876. 0xa0,0x07,0x73,0x20,0x07,0x7a,0x30,0x07,0x72,0xd0,0x06,0xf6,0x40,0x07,0x78,0xa0,
  2877. 0x07,0x76,0x40,0x07,0x7a,0x60,0x07,0x74,0xd0,0x06,0xf6,0x60,0x07,0x74,0xa0,0x07,
  2878. 0x76,0x40,0x07,0x7a,0x60,0x07,0x74,0xd0,0x06,0xf6,0x90,0x07,0x76,0xa0,0x07,0x71,
  2879. 0x20,0x07,0x78,0xa0,0x07,0x71,0x20,0x07,0x78,0xd0,0x06,0xf6,0x10,0x07,0x72,0x80,
  2880. 0x07,0x7a,0x10,0x07,0x72,0x80,0x07,0x7a,0x10,0x07,0x72,0x80,0x07,0x6d,0x60,0x0f,
  2881. 0x71,0x90,0x07,0x72,0xa0,0x07,0x72,0x50,0x07,0x76,0xa0,0x07,0x72,0x50,0x07,0x76,
  2882. 0xd0,0x06,0xf6,0x20,0x07,0x75,0x60,0x07,0x7a,0x20,0x07,0x75,0x60,0x07,0x7a,0x20,
  2883. 0x07,0x75,0x60,0x07,0x6d,0x60,0x0f,0x75,0x10,0x07,0x72,0xa0,0x07,0x75,0x10,0x07,
  2884. 0x72,0xa0,0x07,0x75,0x10,0x07,0x72,0xd0,0x06,0xf6,0x10,0x07,0x70,0x20,0x07,0x74,
  2885. 0xa0,0x07,0x71,0x00,0x07,0x72,0x40,0x07,0x7a,0x10,0x07,0x70,0x20,0x07,0x74,0xd0,
  2886. 0x06,0xee,0x80,0x07,0x7a,0x10,0x07,0x76,0xa0,0x07,0x73,0x20,0x07,0x43,0x98,0x02,
  2887. 0x00,0x80,0x00,0x00,0x00,0x00,0x00,0x80,0x21,0xcc,0x01,0x04,0x80,0x00,0x00,0x00,
  2888. 0x00,0x00,0x40,0x16,0x08,0x00,0x00,0x00,0x08,0x00,0x00,0x00,0x32,0x1e,0x98,0x10,
  2889. 0x19,0x11,0x4c,0x90,0x8c,0x09,0x26,0x47,0xc6,0x04,0x43,0xca,0x12,0x18,0x01,0x28,
  2890. 0x82,0x42,0x28,0x08,0xd2,0xb1,0x04,0x09,0x00,0x00,0x00,0x00,0x79,0x18,0x00,0x00,
  2891. 0xb1,0x00,0x00,0x00,0x1a,0x03,0x4c,0x10,0x97,0x29,0xa2,0x25,0x10,0xab,0x32,0xb9,
  2892. 0xb9,0xb4,0x37,0xb7,0x21,0x46,0x42,0x20,0x80,0x72,0x50,0xb9,0x1b,0x43,0x0b,0x93,
  2893. 0xfb,0x9a,0x4b,0xd3,0x2b,0x1b,0x62,0x24,0x02,0x22,0x24,0x05,0xe3,0x20,0x08,0x0e,
  2894. 0x8e,0xad,0x0c,0xa4,0xad,0x8c,0x2e,0x8c,0x0d,0xc4,0xae,0x4c,0x6e,0x2e,0xed,0xcd,
  2895. 0x0d,0x64,0x46,0x06,0x46,0x66,0xc6,0x65,0x66,0xa6,0x06,0x04,0xa5,0xad,0x8c,0x2e,
  2896. 0x8c,0xcd,0xac,0xac,0x65,0x46,0x06,0x46,0x66,0xc6,0x65,0x66,0xa6,0x26,0x65,0x88,
  2897. 0x80,0x10,0x43,0x8c,0x44,0x48,0x8c,0x64,0x60,0xd1,0x54,0x46,0x17,0xc6,0x36,0x04,
  2898. 0x41,0x8e,0x44,0x48,0x84,0x64,0xe0,0x16,0x96,0x26,0xe7,0x32,0xf6,0xd6,0x06,0x97,
  2899. 0xc6,0x56,0xe6,0x42,0x56,0xe6,0xf6,0x26,0xd7,0x36,0xf7,0x45,0x96,0x36,0x17,0x26,
  2900. 0xc6,0x56,0x36,0x44,0x40,0x12,0x72,0x61,0x69,0x72,0x2e,0x63,0x6f,0x6d,0x70,0x69,
  2901. 0x6c,0x65,0x2e,0x66,0x61,0x73,0x74,0x5f,0x6d,0x61,0x74,0x68,0x5f,0x65,0x6e,0x61,
  2902. 0x62,0x6c,0x65,0x43,0x04,0x64,0x21,0x19,0x84,0xa5,0xc9,0xb9,0x8c,0xbd,0xb5,0xc1,
  2903. 0xa5,0xb1,0x95,0xb9,0x98,0xc9,0x85,0xb5,0x95,0x89,0xd5,0x99,0x99,0x95,0xc9,0x7d,
  2904. 0x99,0x95,0xd1,0x8d,0xa1,0x7d,0x95,0xb9,0x85,0x89,0xb1,0x95,0x0d,0x11,0x90,0x86,
  2905. 0x51,0x58,0x9a,0x9c,0x8b,0x5d,0x99,0x1c,0x5d,0x19,0xde,0xd7,0x5b,0x1d,0x1d,0x5c,
  2906. 0x1d,0x1d,0x97,0xba,0xb9,0x32,0x39,0x14,0xb6,0xb7,0x31,0x37,0x98,0x14,0x46,0x61,
  2907. 0x69,0x72,0x2e,0x61,0x72,0x67,0x5f,0x74,0x79,0x70,0x65,0x5f,0x6e,0x61,0x6d,0x65,
  2908. 0x34,0xcc,0xd8,0xde,0xc2,0xe8,0x64,0xc8,0x84,0xa5,0xc9,0xb9,0x84,0xc9,0x9d,0x7d,
  2909. 0xb9,0x85,0xb5,0x95,0x51,0xa8,0xb3,0x1b,0xc2,0x20,0x0f,0x02,0x21,0x11,0x22,0x21,
  2910. 0x13,0x42,0x71,0xa9,0x9b,0x2b,0x93,0x43,0x61,0x7b,0x1b,0x73,0x8b,0x49,0xa1,0x61,
  2911. 0xc6,0xf6,0x16,0x46,0x47,0xc3,0x62,0xec,0x8d,0xed,0x4d,0x6e,0x08,0x83,0x3c,0x88,
  2912. 0x85,0x44,0xc8,0x85,0x4c,0x08,0x46,0x26,0x2c,0x4d,0xce,0x05,0xee,0x6d,0x2e,0x8d,
  2913. 0x2e,0xed,0xcd,0x8d,0xcb,0x19,0xdb,0x17,0xd4,0xdb,0x5c,0x1a,0x5d,0xda,0x9b,0xdb,
  2914. 0x10,0x05,0xd1,0x90,0x08,0xb9,0x90,0x09,0xd9,0x86,0x18,0x48,0x85,0x64,0x08,0x47,
  2915. 0x28,0x2c,0x4d,0xce,0xc5,0xae,0x4c,0x8e,0xae,0x0c,0xef,0x2b,0xcd,0x0d,0xae,0x8e,
  2916. 0x8e,0x52,0x58,0x9a,0x9c,0x0b,0xdb,0xdb,0x58,0x18,0x5d,0xda,0x9b,0xdb,0x57,0x9a,
  2917. 0x1b,0x59,0x19,0x1e,0xbd,0xb3,0x32,0xb7,0x32,0xb9,0x30,0xba,0x32,0x32,0x94,0xaf,
  2918. 0xaf,0xb0,0x34,0xb9,0x2f,0x38,0xb6,0xb0,0xb1,0x32,0xb4,0x37,0x36,0xb2,0x32,0xb9,
  2919. 0xaf,0xaf,0x14,0x22,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x43,0xa8,0x64,0x40,
  2920. 0x3c,0xe4,0x4b,0x86,0x44,0x40,0xc0,0x00,0x89,0x10,0x09,0x99,0x90,0x30,0x60,0x42,
  2921. 0x57,0x86,0x37,0xf6,0xf6,0x26,0x47,0x06,0x33,0x84,0x4a,0x04,0xc4,0x43,0xbe,0x44,
  2922. 0x48,0x04,0x04,0x0c,0x90,0x08,0x91,0x90,0x09,0x19,0x03,0x1a,0x63,0x6f,0x6c,0x6f,
  2923. 0x72,0x30,0x43,0xa8,0x84,0x40,0x3c,0xe4,0x4b,0x88,0x44,0x40,0xc0,0x00,0x89,0x90,
  2924. 0x0b,0x99,0x90,0x32,0x18,0x62,0x20,0x62,0x80,0x90,0x01,0x62,0x06,0x43,0x8c,0x02,
  2925. 0x40,0x3a,0xe4,0x0c,0x46,0x44,0xec,0xc0,0x0e,0xf6,0xd0,0x0e,0x6e,0xd0,0x0e,0xef,
  2926. 0x40,0x0e,0xf5,0xc0,0x0e,0xe5,0xe0,0x06,0xe6,0xc0,0x0e,0xe1,0x70,0x0e,0xf3,0x30,
  2927. 0x45,0x08,0x86,0x11,0x0a,0x3b,0xb0,0x83,0x3d,0xb4,0x83,0x1b,0xa4,0x03,0x39,0x94,
  2928. 0x83,0x3b,0xd0,0xc3,0x94,0xa0,0x18,0xb1,0x84,0x43,0x3a,0xc8,0x83,0x1b,0xd8,0x43,
  2929. 0x39,0xc8,0xc3,0x3c,0xa4,0xc3,0x3b,0xb8,0xc3,0x94,0xc0,0x18,0x41,0x85,0x43,0x3a,
  2930. 0xc8,0x83,0x1b,0xb0,0x43,0x38,0xb8,0xc3,0x39,0xd4,0x43,0x38,0x9c,0x43,0x39,0xfc,
  2931. 0x82,0x3d,0x94,0x83,0x3c,0xcc,0x43,0x3a,0xbc,0x83,0x3b,0x4c,0x09,0x90,0x11,0x53,
  2932. 0x38,0xa4,0x83,0x3c,0xb8,0xc1,0x38,0xbc,0x43,0x3b,0xc0,0x43,0x3a,0xb0,0x43,0x39,
  2933. 0xfc,0xc2,0x3b,0xc0,0x03,0x3d,0xa4,0xc3,0x3b,0xb8,0xc3,0x3c,0x4c,0x19,0x14,0xc6,
  2934. 0x19,0xa1,0x84,0x43,0x3a,0xc8,0x83,0x1b,0xd8,0x43,0x39,0xc8,0x03,0x3d,0x94,0x03,
  2935. 0x3e,0x4c,0x09,0xd0,0x00,0x00,0x00,0x00,0x79,0x18,0x00,0x00,0xa5,0x00,0x00,0x00,
  2936. 0x33,0x08,0x80,0x1c,0xc4,0xe1,0x1c,0x66,0x14,0x01,0x3d,0x88,0x43,0x38,0x84,0xc3,
  2937. 0x8c,0x42,0x80,0x07,0x79,0x78,0x07,0x73,0x98,0x71,0x0c,0xe6,0x00,0x0f,0xed,0x10,
  2938. 0x0e,0xf4,0x80,0x0e,0x33,0x0c,0x42,0x1e,0xc2,0xc1,0x1d,0xce,0xa1,0x1c,0x66,0x30,
  2939. 0x05,0x3d,0x88,0x43,0x38,0x84,0x83,0x1b,0xcc,0x03,0x3d,0xc8,0x43,0x3d,0x8c,0x03,
  2940. 0x3d,0xcc,0x78,0x8c,0x74,0x70,0x07,0x7b,0x08,0x07,0x79,0x48,0x87,0x70,0x70,0x07,
  2941. 0x7a,0x70,0x03,0x76,0x78,0x87,0x70,0x20,0x87,0x19,0xcc,0x11,0x0e,0xec,0x90,0x0e,
  2942. 0xe1,0x30,0x0f,0x6e,0x30,0x0f,0xe3,0xf0,0x0e,0xf0,0x50,0x0e,0x33,0x10,0xc4,0x1d,
  2943. 0xde,0x21,0x1c,0xd8,0x21,0x1d,0xc2,0x61,0x1e,0x66,0x30,0x89,0x3b,0xbc,0x83,0x3b,
  2944. 0xd0,0x43,0x39,0xb4,0x03,0x3c,0xbc,0x83,0x3c,0x84,0x03,0x3b,0xcc,0xf0,0x14,0x76,
  2945. 0x60,0x07,0x7b,0x68,0x07,0x37,0x68,0x87,0x72,0x68,0x07,0x37,0x80,0x87,0x70,0x90,
  2946. 0x87,0x70,0x60,0x07,0x76,0x28,0x07,0x76,0xf8,0x05,0x76,0x78,0x87,0x77,0x80,0x87,
  2947. 0x5f,0x08,0x87,0x71,0x18,0x87,0x72,0x98,0x87,0x79,0x98,0x81,0x2c,0xee,0xf0,0x0e,
  2948. 0xee,0xe0,0x0e,0xf5,0xc0,0x0e,0xec,0x30,0x03,0x62,0xc8,0xa1,0x1c,0xe4,0xa1,0x1c,
  2949. 0xcc,0xa1,0x1c,0xe4,0xa1,0x1c,0xdc,0x61,0x1c,0xca,0x21,0x1c,0xc4,0x81,0x1d,0xca,
  2950. 0x61,0x06,0xd6,0x90,0x43,0x39,0xc8,0x43,0x39,0x98,0x43,0x39,0xc8,0x43,0x39,0xb8,
  2951. 0xc3,0x38,0x94,0x43,0x38,0x88,0x03,0x3b,0x94,0xc3,0x2f,0xbc,0x83,0x3c,0xfc,0x82,
  2952. 0x3b,0xd4,0x03,0x3b,0xb0,0xc3,0x0c,0xc7,0x69,0x87,0x70,0x58,0x87,0x72,0x70,0x83,
  2953. 0x74,0x68,0x07,0x78,0x60,0x87,0x74,0x18,0x87,0x74,0xa0,0x87,0x19,0xce,0x53,0x0f,
  2954. 0xee,0x00,0x0f,0xf2,0x50,0x0e,0xe4,0x90,0x0e,0xe3,0x40,0x0f,0xe1,0x20,0x0e,0xec,
  2955. 0x50,0x0e,0x33,0x20,0x28,0x1d,0xdc,0xc1,0x1e,0xc2,0x41,0x1e,0xd2,0x21,0x1c,0xdc,
  2956. 0x81,0x1e,0xdc,0xe0,0x1c,0xe4,0xe1,0x1d,0xea,0x01,0x1e,0x66,0x18,0x51,0x38,0xb0,
  2957. 0x43,0x3a,0x9c,0x83,0x3b,0xcc,0x50,0x24,0x76,0x60,0x07,0x7b,0x68,0x07,0x37,0x60,
  2958. 0x87,0x77,0x78,0x07,0x78,0x98,0x51,0x4c,0xf4,0x90,0x0f,0xf0,0x50,0x0e,0x33,0x1e,
  2959. 0x6a,0x1e,0xca,0x61,0x1c,0xe8,0x21,0x1d,0xde,0xc1,0x1d,0x7e,0x01,0x1e,0xe4,0xa1,
  2960. 0x1c,0xcc,0x21,0x1d,0xf0,0x61,0x06,0x54,0x85,0x83,0x38,0xcc,0xc3,0x3b,0xb0,0x43,
  2961. 0x3d,0xd0,0x43,0x39,0xfc,0xc2,0x3c,0xe4,0x43,0x3b,0x88,0xc3,0x3b,0xb0,0xc3,0x8c,
  2962. 0xc5,0x0a,0x87,0x79,0x98,0x87,0x77,0x18,0x87,0x74,0x08,0x07,0x7a,0x28,0x07,0x72,
  2963. 0x98,0x81,0x5c,0xe3,0x10,0x0e,0xec,0xc0,0x0e,0xe5,0x50,0x0e,0xf3,0x30,0x23,0xc1,
  2964. 0xd2,0x41,0x1e,0xe4,0xe1,0x17,0xd8,0xe1,0x1d,0xde,0x01,0x1e,0x66,0x48,0x19,0x3b,
  2965. 0xb0,0x83,0x3d,0xb4,0x83,0x1b,0x84,0xc3,0x38,0x8c,0x43,0x39,0xcc,0xc3,0x3c,0xb8,
  2966. 0xc1,0x39,0xc8,0xc3,0x3b,0xd4,0x03,0x3c,0xcc,0x48,0xb4,0x71,0x08,0x07,0x76,0x60,
  2967. 0x07,0x71,0x08,0x87,0x71,0x58,0x87,0x19,0xdb,0xc6,0x0e,0xec,0x60,0x0f,0xed,0xe0,
  2968. 0x06,0xf0,0x20,0x0f,0xe5,0x30,0x0f,0xe5,0x20,0x0f,0xf6,0x50,0x0e,0x6e,0x10,0x0e,
  2969. 0xe3,0x30,0x0e,0xe5,0x30,0x0f,0xf3,0xe0,0x06,0xe9,0xe0,0x0e,0xe4,0x50,0x0e,0xf8,
  2970. 0x30,0x23,0xe2,0xec,0x61,0x1c,0xc2,0x81,0x1d,0xd8,0xe1,0x17,0xec,0x21,0x1d,0xe6,
  2971. 0x21,0x1d,0xc4,0x21,0x1d,0xd8,0x21,0x1d,0xe8,0x21,0x1f,0x66,0x20,0x9d,0x3b,0xbc,
  2972. 0x43,0x3d,0xb8,0x03,0x39,0x94,0x83,0x39,0xcc,0x58,0xbc,0x70,0x70,0x07,0x77,0x78,
  2973. 0x07,0x7a,0x08,0x07,0x7a,0x48,0x87,0x77,0x70,0x87,0x19,0xce,0x87,0x0e,0xe5,0x10,
  2974. 0x0e,0xf0,0x10,0x0e,0xec,0xc0,0x0e,0xef,0x30,0x0e,0xf3,0x90,0x0e,0xf4,0x50,0x0e,
  2975. 0x33,0x28,0x30,0x08,0x87,0x74,0x90,0x07,0x37,0x30,0x87,0x7a,0x70,0x87,0x71,0xa0,
  2976. 0x87,0x74,0x78,0x07,0x77,0xf8,0x85,0x73,0x90,0x87,0x77,0xa8,0x07,0x78,0x98,0x07,
  2977. 0x00,0x00,0x00,0x00,0x71,0x20,0x00,0x00,0x05,0x00,0x00,0x00,0x06,0x50,0x30,0x00,
  2978. 0xd2,0xd0,0x16,0xd0,0x00,0x48,0xe4,0x17,0x0c,0xe0,0x57,0x76,0x71,0xdb,0x00,0x00,
  2979. 0x61,0x20,0x00,0x00,0x1b,0x00,0x00,0x00,0x13,0x04,0x41,0x2c,0x10,0x00,0x00,0x00,
  2980. 0x10,0x00,0x00,0x00,0xb4,0x63,0x11,0x40,0x60,0x1c,0x73,0x10,0x83,0xd0,0x34,0x94,
  2981. 0x33,0x00,0x14,0x63,0x09,0x20,0x08,0x82,0x20,0x18,0x80,0x20,0x08,0x82,0xe0,0x30,
  2982. 0x96,0x00,0x82,0x20,0x88,0xff,0x02,0x08,0x82,0x20,0xfe,0xcd,0x00,0x90,0xcc,0x41,
  2983. 0x54,0x15,0x35,0xd1,0xcc,0x00,0x10,0x8c,0x11,0x80,0x20,0x08,0xe2,0xdf,0x08,0xc0,
  2984. 0x0c,0x00,0x00,0x00,0x23,0x06,0xc6,0x10,0x54,0x0e,0x72,0x0c,0x32,0x04,0xc7,0x32,
  2985. 0xc8,0x10,0x1c,0xcd,0x6c,0xc3,0x01,0x01,0xb3,0x0d,0x01,0x14,0xcc,0x36,0x04,0x83,
  2986. 0x90,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  2987. };
  2988. /*
  2989. #include <metal_stdlib>
  2990. #include <simd/simd.h>
  2991. using namespace metal;
  2992. struct main0_out
  2993. {
  2994. float4 frag_color [[color(0)]];
  2995. };
  2996. struct main0_in
  2997. {
  2998. float2 uv [[user(locn0)]];
  2999. float4 color [[user(locn1)]];
  3000. };
  3001. fragment main0_out main0(main0_in in [[stage_in]], texture2d<float> tex [[texture(0)]], sampler smp [[sampler(0)]])
  3002. {
  3003. main0_out out = {};
  3004. out.frag_color = tex.sample(smp, in.uv).xxxx * in.color;
  3005. return out;
  3006. }
  3007. */
  3008. static const uint8_t _sdtx_fs_bytecode_metal_ios[3033] = {
  3009. 0x4d,0x54,0x4c,0x42,0x01,0x00,0x02,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3010. 0xd9,0x0b,0x00,0x00,0x00,0x00,0x00,0x00,0x58,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3011. 0x6d,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc9,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3012. 0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xd1,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3013. 0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xd9,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3014. 0x00,0x0b,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x6d,0x00,0x00,0x00,
  3015. 0x4e,0x41,0x4d,0x45,0x06,0x00,0x6d,0x61,0x69,0x6e,0x30,0x00,0x54,0x59,0x50,0x45,
  3016. 0x01,0x00,0x01,0x48,0x41,0x53,0x48,0x20,0x00,0x64,0xff,0xce,0xd3,0x48,0x71,0xaf,
  3017. 0x68,0xf3,0x79,0x4e,0x9f,0x9e,0xbf,0x16,0xda,0xcc,0x0f,0x60,0xbc,0x56,0x43,0x8f,
  3018. 0x4b,0x45,0xa7,0x93,0x35,0x40,0xfe,0x60,0x45,0x4f,0x46,0x46,0x54,0x18,0x00,0x00,
  3019. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3020. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x56,0x45,0x52,0x53,0x08,0x00,0x01,0x00,0x08,
  3021. 0x00,0x01,0x00,0x01,0x00,0x45,0x4e,0x44,0x54,0x04,0x00,0x00,0x00,0x45,0x4e,0x44,
  3022. 0x54,0x04,0x00,0x00,0x00,0x45,0x4e,0x44,0x54,0xde,0xc0,0x17,0x0b,0x00,0x00,0x00,
  3023. 0x00,0x14,0x00,0x00,0x00,0xe4,0x0a,0x00,0x00,0xff,0xff,0xff,0xff,0x42,0x43,0xc0,
  3024. 0xde,0x21,0x0c,0x00,0x00,0xb6,0x02,0x00,0x00,0x0b,0x82,0x20,0x00,0x02,0x00,0x00,
  3025. 0x00,0x12,0x00,0x00,0x00,0x07,0x81,0x23,0x91,0x41,0xc8,0x04,0x49,0x06,0x10,0x32,
  3026. 0x39,0x92,0x01,0x84,0x0c,0x25,0x05,0x08,0x19,0x1e,0x04,0x8b,0x62,0x80,0x14,0x45,
  3027. 0x02,0x42,0x92,0x0b,0x42,0xa4,0x10,0x32,0x14,0x38,0x08,0x18,0x49,0x0a,0x32,0x44,
  3028. 0x24,0x48,0x0a,0x90,0x21,0x23,0xc4,0x52,0x80,0x0c,0x19,0x21,0x72,0x24,0x07,0xc8,
  3029. 0x48,0x11,0x62,0xa8,0xa0,0xa8,0x40,0xc6,0xf0,0x01,0x00,0x00,0x00,0x51,0x18,0x00,
  3030. 0x00,0x74,0x00,0x00,0x00,0x1b,0xc2,0x24,0xf8,0xff,0xff,0xff,0xff,0x01,0x60,0x00,
  3031. 0x09,0xa8,0x88,0x70,0x80,0x07,0x78,0x90,0x87,0x77,0xc0,0x87,0x36,0x30,0x87,0x7a,
  3032. 0x70,0x87,0x71,0x68,0x03,0x73,0x80,0x87,0x36,0x68,0x87,0x70,0xa0,0x07,0x74,0x00,
  3033. 0xe8,0x41,0x1e,0xea,0xa1,0x1c,0x00,0xa2,0x1d,0xd2,0xc1,0x1d,0xda,0x80,0x1d,0xca,
  3034. 0xe1,0x1c,0xc2,0x81,0x1d,0xda,0xc0,0x1e,0xca,0x61,0x1c,0xe8,0xe1,0x1d,0xe4,0xa1,
  3035. 0x0d,0xee,0x21,0x1d,0xc8,0x81,0x1e,0xd0,0x01,0x88,0x03,0x39,0xc0,0x03,0x60,0x70,
  3036. 0x87,0x77,0x68,0x03,0x71,0xa8,0x87,0x74,0x60,0x07,0x7a,0x48,0x07,0x77,0x98,0x07,
  3037. 0x80,0x70,0x87,0x77,0x68,0x03,0x73,0x90,0x87,0x70,0x68,0x87,0x72,0x68,0x03,0x78,
  3038. 0x78,0x87,0x74,0x70,0x07,0x7a,0x28,0x07,0x79,0x68,0x83,0x72,0x60,0x87,0x74,0x68,
  3039. 0x07,0x80,0x1e,0xe4,0xa1,0x1e,0xca,0x01,0x20,0xdc,0xe1,0x1d,0xda,0xc0,0x1c,0xe4,
  3040. 0x21,0x1c,0xda,0xa1,0x1c,0xda,0x00,0x1e,0xde,0x21,0x1d,0xdc,0x81,0x1e,0xca,0x41,
  3041. 0x1e,0xda,0xa0,0x1c,0xd8,0x21,0x1d,0xda,0xa1,0x0d,0xdc,0xe1,0x1d,0xdc,0xa1,0x0d,
  3042. 0xd8,0xa1,0x1c,0xc2,0xc1,0x1c,0x00,0x7a,0x90,0x87,0x7a,0x28,0x07,0x80,0x70,0x87,
  3043. 0x77,0x68,0x83,0x74,0x70,0x07,0x73,0x98,0x87,0x36,0x30,0x07,0x78,0x68,0x83,0x76,
  3044. 0x08,0x07,0x7a,0x40,0x07,0x80,0x1e,0xe4,0xa1,0x1e,0xca,0x01,0x20,0xdc,0xe1,0x1d,
  3045. 0xda,0xc0,0x1d,0xc2,0xc1,0x1d,0xe6,0xa1,0x0d,0xcc,0x01,0x1e,0xda,0xa0,0x1d,0xc2,
  3046. 0x81,0x1e,0xd0,0x01,0xa0,0x07,0x79,0xa8,0x87,0x72,0x00,0x08,0x77,0x78,0x87,0x36,
  3047. 0x98,0x87,0x74,0x38,0x07,0x77,0x28,0x07,0x72,0x68,0x03,0x7d,0x28,0x07,0x79,0x78,
  3048. 0x87,0x79,0x68,0x03,0x73,0x80,0x87,0x36,0x68,0x87,0x70,0xa0,0x07,0x74,0x00,0xe8,
  3049. 0x41,0x1e,0xea,0xa1,0x1c,0x00,0xc2,0x1d,0xde,0xa1,0x0d,0xe8,0x41,0x1e,0xc2,0x01,
  3050. 0x1e,0xe0,0x21,0x1d,0xdc,0xe1,0x1c,0xda,0xa0,0x1d,0xc2,0x81,0x1e,0xd0,0x01,0xa0,
  3051. 0x07,0x79,0xa8,0x87,0x72,0x00,0x88,0x79,0xa0,0x87,0x70,0x18,0x87,0x75,0x68,0x03,
  3052. 0x78,0x90,0x87,0x77,0xa0,0x87,0x72,0x18,0x07,0x7a,0x78,0x07,0x79,0x68,0x03,0x71,
  3053. 0xa8,0x07,0x73,0x30,0x87,0x72,0x90,0x87,0x36,0x98,0x87,0x74,0xd0,0x87,0x72,0x00,
  3054. 0xf0,0x00,0x20,0xea,0xc1,0x1d,0xe6,0x21,0x1c,0xcc,0xa1,0x1c,0xda,0xc0,0x1c,0xe0,
  3055. 0xa1,0x0d,0xda,0x21,0x1c,0xe8,0x01,0x1d,0x00,0x7a,0x90,0x87,0x7a,0x28,0x07,0x60,
  3056. 0x83,0x21,0x0c,0xc0,0x02,0x54,0x1b,0x8c,0x81,0x00,0x16,0xa0,0xda,0x80,0x10,0xff,
  3057. 0xff,0xff,0xff,0x3f,0x00,0x0c,0x20,0x01,0xd5,0x06,0xa3,0x08,0x80,0x05,0xa8,0x36,
  3058. 0x18,0x86,0x00,0x2c,0x40,0xb5,0x01,0x39,0xfe,0xff,0xff,0xff,0x7f,0x00,0x18,0x40,
  3059. 0x02,0x2a,0x00,0x00,0x00,0x49,0x18,0x00,0x00,0x04,0x00,0x00,0x00,0x13,0x86,0x40,
  3060. 0x18,0x26,0x0c,0x44,0x61,0x4c,0x18,0x8e,0xc2,0x00,0x00,0x00,0x00,0x89,0x20,0x00,
  3061. 0x00,0x1e,0x00,0x00,0x00,0x32,0x22,0x48,0x09,0x20,0x64,0x85,0x04,0x93,0x22,0xa4,
  3062. 0x84,0x04,0x93,0x22,0xe3,0x84,0xa1,0x90,0x14,0x12,0x4c,0x8a,0x8c,0x0b,0x84,0xa4,
  3063. 0x4c,0x10,0x4c,0x33,0x00,0xc3,0x08,0x04,0x60,0x83,0x30,0x8c,0x20,0x00,0x47,0x49,
  3064. 0x53,0x44,0x09,0x93,0xff,0x4f,0xc4,0x35,0x51,0x11,0xf1,0xdb,0xc3,0x3f,0x8d,0x11,
  3065. 0x00,0x83,0x08,0x44,0x70,0x91,0x34,0x45,0x94,0x30,0xf9,0xbf,0x04,0x30,0xcf,0x42,
  3066. 0x44,0xff,0x34,0x46,0x00,0x0c,0x22,0x18,0x42,0x29,0xc4,0x08,0xe5,0x10,0x9a,0x23,
  3067. 0x08,0xe6,0x08,0xc0,0x60,0x18,0x41,0x58,0x0a,0x12,0xca,0x19,0x8a,0x29,0x40,0x6d,
  3068. 0x20,0x20,0x05,0xd6,0x30,0x02,0xb1,0x8c,0x00,0x00,0x00,0x00,0x00,0x13,0xa8,0x70,
  3069. 0x48,0x07,0x79,0xb0,0x03,0x3a,0x68,0x83,0x70,0x80,0x07,0x78,0x60,0x87,0x72,0x68,
  3070. 0x83,0x74,0x78,0x87,0x79,0xc8,0x03,0x37,0x80,0x03,0x37,0x80,0x83,0x0d,0xb7,0x51,
  3071. 0x0e,0x6d,0x00,0x0f,0x7a,0x60,0x07,0x74,0xa0,0x07,0x76,0x40,0x07,0x7a,0x60,0x07,
  3072. 0x74,0xd0,0x06,0xe9,0x10,0x07,0x7a,0x80,0x07,0x7a,0x80,0x07,0x6d,0x90,0x0e,0x78,
  3073. 0xa0,0x07,0x78,0xa0,0x07,0x78,0xd0,0x06,0xe9,0x10,0x07,0x76,0xa0,0x07,0x71,0x60,
  3074. 0x07,0x7a,0x10,0x07,0x76,0xd0,0x06,0xe9,0x30,0x07,0x72,0xa0,0x07,0x73,0x20,0x07,
  3075. 0x7a,0x30,0x07,0x72,0xd0,0x06,0xe9,0x60,0x07,0x74,0xa0,0x07,0x76,0x40,0x07,0x7a,
  3076. 0x60,0x07,0x74,0xd0,0x06,0xe6,0x30,0x07,0x72,0xa0,0x07,0x73,0x20,0x07,0x7a,0x30,
  3077. 0x07,0x72,0xd0,0x06,0xe6,0x60,0x07,0x74,0xa0,0x07,0x76,0x40,0x07,0x7a,0x60,0x07,
  3078. 0x74,0xd0,0x06,0xf6,0x10,0x07,0x76,0xa0,0x07,0x71,0x60,0x07,0x7a,0x10,0x07,0x76,
  3079. 0xd0,0x06,0xf6,0x20,0x07,0x74,0xa0,0x07,0x73,0x20,0x07,0x7a,0x30,0x07,0x72,0xd0,
  3080. 0x06,0xf6,0x30,0x07,0x72,0xa0,0x07,0x73,0x20,0x07,0x7a,0x30,0x07,0x72,0xd0,0x06,
  3081. 0xf6,0x40,0x07,0x78,0xa0,0x07,0x76,0x40,0x07,0x7a,0x60,0x07,0x74,0xd0,0x06,0xf6,
  3082. 0x60,0x07,0x74,0xa0,0x07,0x76,0x40,0x07,0x7a,0x60,0x07,0x74,0xd0,0x06,0xf6,0x90,
  3083. 0x07,0x76,0xa0,0x07,0x71,0x20,0x07,0x78,0xa0,0x07,0x71,0x20,0x07,0x78,0xd0,0x06,
  3084. 0xf6,0x10,0x07,0x72,0x80,0x07,0x7a,0x10,0x07,0x72,0x80,0x07,0x7a,0x10,0x07,0x72,
  3085. 0x80,0x07,0x6d,0x60,0x0f,0x71,0x90,0x07,0x72,0xa0,0x07,0x72,0x50,0x07,0x76,0xa0,
  3086. 0x07,0x72,0x50,0x07,0x76,0xd0,0x06,0xf6,0x20,0x07,0x75,0x60,0x07,0x7a,0x20,0x07,
  3087. 0x75,0x60,0x07,0x7a,0x20,0x07,0x75,0x60,0x07,0x6d,0x60,0x0f,0x75,0x10,0x07,0x72,
  3088. 0xa0,0x07,0x75,0x10,0x07,0x72,0xa0,0x07,0x75,0x10,0x07,0x72,0xd0,0x06,0xf6,0x10,
  3089. 0x07,0x70,0x20,0x07,0x74,0xa0,0x07,0x71,0x00,0x07,0x72,0x40,0x07,0x7a,0x10,0x07,
  3090. 0x70,0x20,0x07,0x74,0xd0,0x06,0xee,0x80,0x07,0x7a,0x10,0x07,0x76,0xa0,0x07,0x73,
  3091. 0x20,0x07,0x43,0x98,0x04,0x00,0x80,0x00,0x00,0x00,0x00,0x00,0x80,0x21,0x8c,0x03,
  3092. 0x04,0x80,0x00,0x00,0x00,0x00,0x00,0x40,0x16,0x08,0x00,0x00,0x00,0x08,0x00,0x00,
  3093. 0x00,0x32,0x1e,0x98,0x10,0x19,0x11,0x4c,0x90,0x8c,0x09,0x26,0x47,0xc6,0x04,0x43,
  3094. 0x5a,0x25,0x30,0x02,0x50,0x04,0x85,0x50,0x10,0x65,0x40,0x70,0x2c,0x41,0x02,0x00,
  3095. 0x00,0x79,0x18,0x00,0x00,0xd2,0x00,0x00,0x00,0x1a,0x03,0x4c,0x10,0x97,0x29,0xa2,
  3096. 0x25,0x10,0xab,0x32,0xb9,0xb9,0xb4,0x37,0xb7,0x21,0xc6,0x42,0x3c,0x00,0x84,0x50,
  3097. 0xb9,0x1b,0x43,0x0b,0x93,0xfb,0x9a,0x4b,0xd3,0x2b,0x1b,0x62,0x2c,0xc2,0x23,0x2c,
  3098. 0x05,0xe3,0x20,0x08,0x0e,0x8e,0xad,0x0c,0xa4,0xad,0x8c,0x2e,0x8c,0x0d,0xc4,0xae,
  3099. 0x4c,0x6e,0x2e,0xed,0xcd,0x0d,0x64,0x46,0x06,0x46,0x66,0xc6,0x65,0x66,0xa6,0x06,
  3100. 0x04,0xa5,0xad,0x8c,0x2e,0x8c,0xcd,0xac,0xac,0x65,0x46,0x06,0x46,0x66,0xc6,0x65,
  3101. 0x66,0xa6,0x26,0x65,0x88,0xf0,0x10,0x43,0x8c,0x45,0x58,0x8c,0x65,0x60,0xd1,0x54,
  3102. 0x46,0x17,0xc6,0x36,0x04,0x79,0x8e,0x45,0x58,0x84,0x65,0xe0,0x16,0x96,0x26,0xe7,
  3103. 0x32,0xf6,0xd6,0x06,0x97,0xc6,0x56,0xe6,0x42,0x56,0xe6,0xf6,0x26,0xd7,0x36,0xf7,
  3104. 0x45,0x96,0x36,0x17,0x26,0xc6,0x56,0x36,0x44,0x78,0x12,0x72,0x61,0x69,0x72,0x2e,
  3105. 0x63,0x6f,0x6d,0x70,0x69,0x6c,0x65,0x2e,0x66,0x61,0x73,0x74,0x5f,0x6d,0x61,0x74,
  3106. 0x68,0x5f,0x65,0x6e,0x61,0x62,0x6c,0x65,0x43,0x84,0x67,0x21,0x19,0x84,0xa5,0xc9,
  3107. 0xb9,0x8c,0xbd,0xb5,0xc1,0xa5,0xb1,0x95,0xb9,0x98,0xc9,0x85,0xb5,0x95,0x89,0xd5,
  3108. 0x99,0x99,0x95,0xc9,0x7d,0x99,0x95,0xd1,0x8d,0xa1,0x7d,0x95,0xb9,0x85,0x89,0xb1,
  3109. 0x95,0x0d,0x11,0x9e,0x86,0x51,0x58,0x9a,0x9c,0x8b,0x5c,0x99,0x1b,0x59,0x99,0xdc,
  3110. 0x17,0x5d,0x98,0xdc,0x59,0x19,0x1d,0xa3,0xb0,0x34,0x39,0x97,0x30,0xb9,0xb3,0x2f,
  3111. 0xba,0x3c,0xb8,0xb2,0x2f,0xb7,0xb0,0xb6,0x32,0x1a,0x66,0x6c,0x6f,0x61,0x74,0x34,
  3112. 0x64,0xc2,0xd2,0xe4,0x5c,0xc2,0xe4,0xce,0xbe,0xdc,0xc2,0xda,0xca,0xa8,0x98,0xc9,
  3113. 0x85,0x9d,0x7d,0x8d,0xbd,0xb1,0xbd,0xc9,0x0d,0x61,0x9e,0x67,0x19,0x1e,0xe8,0x89,
  3114. 0x1e,0xe9,0x99,0x86,0x08,0x0f,0x45,0x29,0x2c,0x4d,0xce,0xc5,0x4c,0x2e,0xec,0xac,
  3115. 0xad,0xcc,0x8d,0xee,0x2b,0xcd,0x0d,0xae,0x8e,0x8e,0x4b,0xdd,0x5c,0x99,0x1c,0x0a,
  3116. 0xdb,0xdb,0x98,0x1b,0x4c,0x0a,0x95,0xb0,0x34,0x39,0x97,0xb1,0x32,0x37,0xba,0x32,
  3117. 0x39,0x3e,0x61,0x69,0x72,0x2e,0x70,0x65,0x72,0x73,0x70,0x65,0x63,0x74,0x69,0x76,
  3118. 0x65,0x34,0xcc,0xd8,0xde,0xc2,0xe8,0x64,0x28,0xd4,0xd9,0x0d,0x91,0x96,0xe1,0xb1,
  3119. 0x9e,0xeb,0xc1,0x9e,0xec,0x81,0x1e,0xed,0x91,0x9e,0x8d,0x4b,0xdd,0x5c,0x99,0x1c,
  3120. 0x0a,0xdb,0xdb,0x98,0x5b,0x4c,0x0a,0x8b,0xb1,0x37,0xb6,0x37,0xb9,0x21,0xd2,0x22,
  3121. 0x3c,0xd6,0xd3,0x3d,0xd8,0x93,0x3d,0xd0,0x13,0x3d,0xd2,0xe3,0x71,0x09,0x4b,0x93,
  3122. 0x73,0xa1,0x2b,0xc3,0xa3,0xab,0x93,0x2b,0xa3,0x14,0x96,0x26,0xe7,0xc2,0xf6,0x36,
  3123. 0x16,0x46,0x97,0xf6,0xe6,0xf6,0x95,0xe6,0x46,0x56,0x86,0x47,0x25,0x2c,0x4d,0xce,
  3124. 0x65,0x2e,0xac,0x0d,0x8e,0xad,0x8c,0x18,0x5d,0x19,0x1e,0x5d,0x9d,0x5c,0x99,0x0c,
  3125. 0x19,0x8f,0x19,0xdb,0x5b,0x18,0x1d,0x0b,0xc8,0x5c,0x58,0x1b,0x1c,0x5b,0x99,0x0f,
  3126. 0x07,0xba,0x32,0xbc,0x21,0xd4,0x42,0x3c,0x60,0xf0,0x84,0xc1,0x32,0x2c,0xc2,0x23,
  3127. 0x06,0x0f,0xf4,0x8c,0xc1,0x23,0x3d,0x64,0xc0,0x25,0x2c,0x4d,0xce,0x65,0x2e,0xac,
  3128. 0x0d,0x8e,0xad,0x4c,0x8e,0xc7,0x5c,0x58,0x1b,0x1c,0x5b,0x99,0x1c,0x87,0xb9,0x36,
  3129. 0xb8,0x21,0xd2,0x72,0x3c,0x66,0xf0,0x84,0xc1,0x32,0x2c,0xc2,0x03,0x3d,0x67,0xf0,
  3130. 0x48,0x0f,0x1a,0x0c,0x41,0x1e,0xee,0xf9,0x9e,0x32,0x78,0xd2,0x60,0x88,0x91,0x00,
  3131. 0x4f,0xf5,0xa8,0x01,0xaf,0xb0,0x34,0xb9,0x96,0x30,0xb6,0xb4,0xb0,0xb9,0x96,0xb9,
  3132. 0xb1,0x37,0xb8,0xb2,0x39,0x94,0xb6,0xb0,0x34,0x37,0x98,0x94,0x21,0xc4,0xd3,0x06,
  3133. 0x0f,0x1b,0x10,0x0b,0x4b,0x93,0x6b,0x09,0x63,0x4b,0x0b,0x9b,0x6b,0x99,0x1b,0x7b,
  3134. 0x83,0x2b,0x6b,0xa1,0x2b,0xc3,0xa3,0xab,0x93,0x2b,0x9b,0x1b,0x62,0x3c,0x6f,0xf0,
  3135. 0xb4,0xc1,0xe3,0x06,0xc4,0xc2,0xd2,0xe4,0x5a,0xc2,0xd8,0xd2,0xc2,0xe6,0x5a,0xe6,
  3136. 0xc6,0xde,0xe0,0xca,0x5a,0xe6,0xc2,0xda,0xe0,0xd8,0xca,0xe4,0xe6,0x86,0x18,0x4f,
  3137. 0x1c,0x3c,0x6d,0xf0,0xc0,0xc1,0x10,0xe2,0x79,0x83,0x27,0x0e,0x46,0x44,0xec,0xc0,
  3138. 0x0e,0xf6,0xd0,0x0e,0x6e,0xd0,0x0e,0xef,0x40,0x0e,0xf5,0xc0,0x0e,0xe5,0xe0,0x06,
  3139. 0xe6,0xc0,0x0e,0xe1,0x70,0x0e,0xf3,0x30,0x45,0x08,0x86,0x11,0x0a,0x3b,0xb0,0x83,
  3140. 0x3d,0xb4,0x83,0x1b,0xa4,0x03,0x39,0x94,0x83,0x3b,0xd0,0xc3,0x94,0xa0,0x18,0xb1,
  3141. 0x84,0x43,0x3a,0xc8,0x83,0x1b,0xd8,0x43,0x39,0xc8,0xc3,0x3c,0xa4,0xc3,0x3b,0xb8,
  3142. 0xc3,0x94,0xc0,0x18,0x41,0x85,0x43,0x3a,0xc8,0x83,0x1b,0xb0,0x43,0x38,0xb8,0xc3,
  3143. 0x39,0xd4,0x43,0x38,0x9c,0x43,0x39,0xfc,0x82,0x3d,0x94,0x83,0x3c,0xcc,0x43,0x3a,
  3144. 0xbc,0x83,0x3b,0x4c,0x09,0x90,0x11,0x53,0x38,0xa4,0x83,0x3c,0xb8,0xc1,0x38,0xbc,
  3145. 0x43,0x3b,0xc0,0x43,0x3a,0xb0,0x43,0x39,0xfc,0xc2,0x3b,0xc0,0x03,0x3d,0xa4,0xc3,
  3146. 0x3b,0xb8,0xc3,0x3c,0x4c,0x19,0x14,0xc6,0x19,0xc1,0x84,0x43,0x3a,0xc8,0x83,0x1b,
  3147. 0x98,0x83,0x3c,0x84,0xc3,0x39,0xb4,0x43,0x39,0xb8,0x03,0x3d,0x4c,0x09,0xd6,0x00,
  3148. 0x00,0x79,0x18,0x00,0x00,0xa5,0x00,0x00,0x00,0x33,0x08,0x80,0x1c,0xc4,0xe1,0x1c,
  3149. 0x66,0x14,0x01,0x3d,0x88,0x43,0x38,0x84,0xc3,0x8c,0x42,0x80,0x07,0x79,0x78,0x07,
  3150. 0x73,0x98,0x71,0x0c,0xe6,0x00,0x0f,0xed,0x10,0x0e,0xf4,0x80,0x0e,0x33,0x0c,0x42,
  3151. 0x1e,0xc2,0xc1,0x1d,0xce,0xa1,0x1c,0x66,0x30,0x05,0x3d,0x88,0x43,0x38,0x84,0x83,
  3152. 0x1b,0xcc,0x03,0x3d,0xc8,0x43,0x3d,0x8c,0x03,0x3d,0xcc,0x78,0x8c,0x74,0x70,0x07,
  3153. 0x7b,0x08,0x07,0x79,0x48,0x87,0x70,0x70,0x07,0x7a,0x70,0x03,0x76,0x78,0x87,0x70,
  3154. 0x20,0x87,0x19,0xcc,0x11,0x0e,0xec,0x90,0x0e,0xe1,0x30,0x0f,0x6e,0x30,0x0f,0xe3,
  3155. 0xf0,0x0e,0xf0,0x50,0x0e,0x33,0x10,0xc4,0x1d,0xde,0x21,0x1c,0xd8,0x21,0x1d,0xc2,
  3156. 0x61,0x1e,0x66,0x30,0x89,0x3b,0xbc,0x83,0x3b,0xd0,0x43,0x39,0xb4,0x03,0x3c,0xbc,
  3157. 0x83,0x3c,0x84,0x03,0x3b,0xcc,0xf0,0x14,0x76,0x60,0x07,0x7b,0x68,0x07,0x37,0x68,
  3158. 0x87,0x72,0x68,0x07,0x37,0x80,0x87,0x70,0x90,0x87,0x70,0x60,0x07,0x76,0x28,0x07,
  3159. 0x76,0xf8,0x05,0x76,0x78,0x87,0x77,0x80,0x87,0x5f,0x08,0x87,0x71,0x18,0x87,0x72,
  3160. 0x98,0x87,0x79,0x98,0x81,0x2c,0xee,0xf0,0x0e,0xee,0xe0,0x0e,0xf5,0xc0,0x0e,0xec,
  3161. 0x30,0x03,0x62,0xc8,0xa1,0x1c,0xe4,0xa1,0x1c,0xcc,0xa1,0x1c,0xe4,0xa1,0x1c,0xdc,
  3162. 0x61,0x1c,0xca,0x21,0x1c,0xc4,0x81,0x1d,0xca,0x61,0x06,0xd6,0x90,0x43,0x39,0xc8,
  3163. 0x43,0x39,0x98,0x43,0x39,0xc8,0x43,0x39,0xb8,0xc3,0x38,0x94,0x43,0x38,0x88,0x03,
  3164. 0x3b,0x94,0xc3,0x2f,0xbc,0x83,0x3c,0xfc,0x82,0x3b,0xd4,0x03,0x3b,0xb0,0xc3,0x0c,
  3165. 0xc7,0x69,0x87,0x70,0x58,0x87,0x72,0x70,0x83,0x74,0x68,0x07,0x78,0x60,0x87,0x74,
  3166. 0x18,0x87,0x74,0xa0,0x87,0x19,0xce,0x53,0x0f,0xee,0x00,0x0f,0xf2,0x50,0x0e,0xe4,
  3167. 0x90,0x0e,0xe3,0x40,0x0f,0xe1,0x20,0x0e,0xec,0x50,0x0e,0x33,0x20,0x28,0x1d,0xdc,
  3168. 0xc1,0x1e,0xc2,0x41,0x1e,0xd2,0x21,0x1c,0xdc,0x81,0x1e,0xdc,0xe0,0x1c,0xe4,0xe1,
  3169. 0x1d,0xea,0x01,0x1e,0x66,0x18,0x51,0x38,0xb0,0x43,0x3a,0x9c,0x83,0x3b,0xcc,0x50,
  3170. 0x24,0x76,0x60,0x07,0x7b,0x68,0x07,0x37,0x60,0x87,0x77,0x78,0x07,0x78,0x98,0x51,
  3171. 0x4c,0xf4,0x90,0x0f,0xf0,0x50,0x0e,0x33,0x1e,0x6a,0x1e,0xca,0x61,0x1c,0xe8,0x21,
  3172. 0x1d,0xde,0xc1,0x1d,0x7e,0x01,0x1e,0xe4,0xa1,0x1c,0xcc,0x21,0x1d,0xf0,0x61,0x06,
  3173. 0x54,0x85,0x83,0x38,0xcc,0xc3,0x3b,0xb0,0x43,0x3d,0xd0,0x43,0x39,0xfc,0xc2,0x3c,
  3174. 0xe4,0x43,0x3b,0x88,0xc3,0x3b,0xb0,0xc3,0x8c,0xc5,0x0a,0x87,0x79,0x98,0x87,0x77,
  3175. 0x18,0x87,0x74,0x08,0x07,0x7a,0x28,0x07,0x72,0x98,0x81,0x5c,0xe3,0x10,0x0e,0xec,
  3176. 0xc0,0x0e,0xe5,0x50,0x0e,0xf3,0x30,0x23,0xc1,0xd2,0x41,0x1e,0xe4,0xe1,0x17,0xd8,
  3177. 0xe1,0x1d,0xde,0x01,0x1e,0x66,0x48,0x19,0x3b,0xb0,0x83,0x3d,0xb4,0x83,0x1b,0x84,
  3178. 0xc3,0x38,0x8c,0x43,0x39,0xcc,0xc3,0x3c,0xb8,0xc1,0x39,0xc8,0xc3,0x3b,0xd4,0x03,
  3179. 0x3c,0xcc,0x48,0xb4,0x71,0x08,0x07,0x76,0x60,0x07,0x71,0x08,0x87,0x71,0x58,0x87,
  3180. 0x19,0xdb,0xc6,0x0e,0xec,0x60,0x0f,0xed,0xe0,0x06,0xf0,0x20,0x0f,0xe5,0x30,0x0f,
  3181. 0xe5,0x20,0x0f,0xf6,0x50,0x0e,0x6e,0x10,0x0e,0xe3,0x30,0x0e,0xe5,0x30,0x0f,0xf3,
  3182. 0xe0,0x06,0xe9,0xe0,0x0e,0xe4,0x50,0x0e,0xf8,0x30,0x23,0xe2,0xec,0x61,0x1c,0xc2,
  3183. 0x81,0x1d,0xd8,0xe1,0x17,0xec,0x21,0x1d,0xe6,0x21,0x1d,0xc4,0x21,0x1d,0xd8,0x21,
  3184. 0x1d,0xe8,0x21,0x1f,0x66,0x20,0x9d,0x3b,0xbc,0x43,0x3d,0xb8,0x03,0x39,0x94,0x83,
  3185. 0x39,0xcc,0x58,0xbc,0x70,0x70,0x07,0x77,0x78,0x07,0x7a,0x08,0x07,0x7a,0x48,0x87,
  3186. 0x77,0x70,0x87,0x19,0xce,0x87,0x0e,0xe5,0x10,0x0e,0xf0,0x10,0x0e,0xec,0xc0,0x0e,
  3187. 0xef,0x30,0x0e,0xf3,0x90,0x0e,0xf4,0x50,0x0e,0x33,0x28,0x30,0x08,0x87,0x74,0x90,
  3188. 0x07,0x37,0x30,0x87,0x7a,0x70,0x87,0x71,0xa0,0x87,0x74,0x78,0x07,0x77,0xf8,0x85,
  3189. 0x73,0x90,0x87,0x77,0xa8,0x07,0x78,0x98,0x07,0x00,0x00,0x00,0x00,0x71,0x20,0x00,
  3190. 0x00,0x08,0x00,0x00,0x00,0x16,0xb0,0x01,0x48,0xe4,0x4b,0x00,0xf3,0x2c,0xc4,0x3f,
  3191. 0x11,0xd7,0x44,0x45,0xc4,0x6f,0x0f,0x7e,0x85,0x17,0xb7,0x6d,0x00,0x05,0x03,0x20,
  3192. 0x0d,0x0d,0x00,0x00,0x00,0x61,0x20,0x00,0x00,0x14,0x00,0x00,0x00,0x13,0x04,0x41,
  3193. 0x2c,0x10,0x00,0x00,0x00,0x06,0x00,0x00,0x00,0x14,0x47,0x00,0x88,0x8d,0x00,0x90,
  3194. 0x1a,0x01,0xa8,0x01,0x12,0x33,0x00,0x14,0x66,0x00,0x08,0x8c,0x00,0x00,0x00,0x00,
  3195. 0x00,0x23,0x06,0xca,0x10,0x4c,0x09,0xb2,0x10,0x46,0x11,0x0c,0x32,0x04,0x03,0x62,
  3196. 0x01,0x23,0x9f,0xd9,0x06,0x23,0x00,0x32,0x08,0x88,0x01,0x00,0x00,0x02,0x00,0x00,
  3197. 0x00,0x5b,0x06,0xe0,0x90,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3198. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3199. };
  3200. /*
  3201. #include <metal_stdlib>
  3202. #include <simd/simd.h>
  3203. using namespace metal;
  3204. struct main0_out
  3205. {
  3206. float2 uv [[user(locn0)]];
  3207. float4 color [[user(locn1)]];
  3208. float4 gl_Position [[position]];
  3209. };
  3210. struct main0_in
  3211. {
  3212. float2 position [[attribute(0)]];
  3213. float2 texcoord0 [[attribute(1)]];
  3214. float4 color0 [[attribute(2)]];
  3215. };
  3216. vertex main0_out main0(main0_in in [[stage_in]])
  3217. {
  3218. main0_out out = {};
  3219. out.gl_Position = float4(fma(in.position, float2(2.0, -2.0), float2(-1.0, 1.0)), 0.0, 1.0);
  3220. out.uv = in.texcoord0;
  3221. out.color = in.color0;
  3222. return out;
  3223. }
  3224. */
  3225. static const uint8_t _sdtx_vs_source_metal_sim[577] = {
  3226. 0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x20,0x3c,0x6d,0x65,0x74,0x61,0x6c,0x5f,
  3227. 0x73,0x74,0x64,0x6c,0x69,0x62,0x3e,0x0a,0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,
  3228. 0x20,0x3c,0x73,0x69,0x6d,0x64,0x2f,0x73,0x69,0x6d,0x64,0x2e,0x68,0x3e,0x0a,0x0a,
  3229. 0x75,0x73,0x69,0x6e,0x67,0x20,0x6e,0x61,0x6d,0x65,0x73,0x70,0x61,0x63,0x65,0x20,
  3230. 0x6d,0x65,0x74,0x61,0x6c,0x3b,0x0a,0x0a,0x73,0x74,0x72,0x75,0x63,0x74,0x20,0x6d,
  3231. 0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x66,
  3232. 0x6c,0x6f,0x61,0x74,0x32,0x20,0x75,0x76,0x20,0x5b,0x5b,0x75,0x73,0x65,0x72,0x28,
  3233. 0x6c,0x6f,0x63,0x6e,0x30,0x29,0x5d,0x5d,0x3b,0x0a,0x20,0x20,0x20,0x20,0x66,0x6c,
  3234. 0x6f,0x61,0x74,0x34,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x5b,0x5b,0x75,0x73,0x65,
  3235. 0x72,0x28,0x6c,0x6f,0x63,0x6e,0x31,0x29,0x5d,0x5d,0x3b,0x0a,0x20,0x20,0x20,0x20,
  3236. 0x66,0x6c,0x6f,0x61,0x74,0x34,0x20,0x67,0x6c,0x5f,0x50,0x6f,0x73,0x69,0x74,0x69,
  3237. 0x6f,0x6e,0x20,0x5b,0x5b,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x5d,0x5d,0x3b,
  3238. 0x0a,0x7d,0x3b,0x0a,0x0a,0x73,0x74,0x72,0x75,0x63,0x74,0x20,0x6d,0x61,0x69,0x6e,
  3239. 0x30,0x5f,0x69,0x6e,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,
  3240. 0x32,0x20,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x5b,0x5b,0x61,0x74,0x74,
  3241. 0x72,0x69,0x62,0x75,0x74,0x65,0x28,0x30,0x29,0x5d,0x5d,0x3b,0x0a,0x20,0x20,0x20,
  3242. 0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x20,0x74,0x65,0x78,0x63,0x6f,0x6f,0x72,0x64,
  3243. 0x30,0x20,0x5b,0x5b,0x61,0x74,0x74,0x72,0x69,0x62,0x75,0x74,0x65,0x28,0x31,0x29,
  3244. 0x5d,0x5d,0x3b,0x0a,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x34,0x20,0x63,
  3245. 0x6f,0x6c,0x6f,0x72,0x30,0x20,0x5b,0x5b,0x61,0x74,0x74,0x72,0x69,0x62,0x75,0x74,
  3246. 0x65,0x28,0x32,0x29,0x5d,0x5d,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x76,0x65,0x72,0x74,
  3247. 0x65,0x78,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6d,0x61,0x69,
  3248. 0x6e,0x30,0x28,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x69,0x6e,0x20,0x69,0x6e,0x20,0x5b,
  3249. 0x5b,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x5d,0x5d,0x29,0x0a,0x7b,0x0a,0x20,
  3250. 0x20,0x20,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6f,0x75,0x74,
  3251. 0x20,0x3d,0x20,0x7b,0x7d,0x3b,0x0a,0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,0x67,
  3252. 0x6c,0x5f,0x50,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x66,0x6c,0x6f,
  3253. 0x61,0x74,0x34,0x28,0x66,0x6d,0x61,0x28,0x69,0x6e,0x2e,0x70,0x6f,0x73,0x69,0x74,
  3254. 0x69,0x6f,0x6e,0x2c,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x28,0x32,0x2e,0x30,0x2c,
  3255. 0x20,0x2d,0x32,0x2e,0x30,0x29,0x2c,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x28,0x2d,
  3256. 0x31,0x2e,0x30,0x2c,0x20,0x31,0x2e,0x30,0x29,0x29,0x2c,0x20,0x30,0x2e,0x30,0x2c,
  3257. 0x20,0x31,0x2e,0x30,0x29,0x3b,0x0a,0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,0x75,
  3258. 0x76,0x20,0x3d,0x20,0x69,0x6e,0x2e,0x74,0x65,0x78,0x63,0x6f,0x6f,0x72,0x64,0x30,
  3259. 0x3b,0x0a,0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,0x63,0x6f,0x6c,0x6f,0x72,0x20,
  3260. 0x3d,0x20,0x69,0x6e,0x2e,0x63,0x6f,0x6c,0x6f,0x72,0x30,0x3b,0x0a,0x20,0x20,0x20,
  3261. 0x20,0x72,0x65,0x74,0x75,0x72,0x6e,0x20,0x6f,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x0a,
  3262. 0x00,
  3263. };
  3264. /*
  3265. #include <metal_stdlib>
  3266. #include <simd/simd.h>
  3267. using namespace metal;
  3268. struct main0_out
  3269. {
  3270. float4 frag_color [[color(0)]];
  3271. };
  3272. struct main0_in
  3273. {
  3274. float2 uv [[user(locn0)]];
  3275. float4 color [[user(locn1)]];
  3276. };
  3277. fragment main0_out main0(main0_in in [[stage_in]], texture2d<float> tex [[texture(0)]], sampler smp [[sampler(0)]])
  3278. {
  3279. main0_out out = {};
  3280. out.frag_color = tex.sample(smp, in.uv).xxxx * in.color;
  3281. return out;
  3282. }
  3283. */
  3284. static const uint8_t _sdtx_fs_source_metal_sim[441] = {
  3285. 0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x20,0x3c,0x6d,0x65,0x74,0x61,0x6c,0x5f,
  3286. 0x73,0x74,0x64,0x6c,0x69,0x62,0x3e,0x0a,0x23,0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,
  3287. 0x20,0x3c,0x73,0x69,0x6d,0x64,0x2f,0x73,0x69,0x6d,0x64,0x2e,0x68,0x3e,0x0a,0x0a,
  3288. 0x75,0x73,0x69,0x6e,0x67,0x20,0x6e,0x61,0x6d,0x65,0x73,0x70,0x61,0x63,0x65,0x20,
  3289. 0x6d,0x65,0x74,0x61,0x6c,0x3b,0x0a,0x0a,0x73,0x74,0x72,0x75,0x63,0x74,0x20,0x6d,
  3290. 0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x66,
  3291. 0x6c,0x6f,0x61,0x74,0x34,0x20,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72,
  3292. 0x20,0x5b,0x5b,0x63,0x6f,0x6c,0x6f,0x72,0x28,0x30,0x29,0x5d,0x5d,0x3b,0x0a,0x7d,
  3293. 0x3b,0x0a,0x0a,0x73,0x74,0x72,0x75,0x63,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,
  3294. 0x69,0x6e,0x0a,0x7b,0x0a,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x32,0x20,
  3295. 0x75,0x76,0x20,0x5b,0x5b,0x75,0x73,0x65,0x72,0x28,0x6c,0x6f,0x63,0x6e,0x30,0x29,
  3296. 0x5d,0x5d,0x3b,0x0a,0x20,0x20,0x20,0x20,0x66,0x6c,0x6f,0x61,0x74,0x34,0x20,0x63,
  3297. 0x6f,0x6c,0x6f,0x72,0x20,0x5b,0x5b,0x75,0x73,0x65,0x72,0x28,0x6c,0x6f,0x63,0x6e,
  3298. 0x31,0x29,0x5d,0x5d,0x3b,0x0a,0x7d,0x3b,0x0a,0x0a,0x66,0x72,0x61,0x67,0x6d,0x65,
  3299. 0x6e,0x74,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6d,0x61,0x69,
  3300. 0x6e,0x30,0x28,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x69,0x6e,0x20,0x69,0x6e,0x20,0x5b,
  3301. 0x5b,0x73,0x74,0x61,0x67,0x65,0x5f,0x69,0x6e,0x5d,0x5d,0x2c,0x20,0x74,0x65,0x78,
  3302. 0x74,0x75,0x72,0x65,0x32,0x64,0x3c,0x66,0x6c,0x6f,0x61,0x74,0x3e,0x20,0x74,0x65,
  3303. 0x78,0x20,0x5b,0x5b,0x74,0x65,0x78,0x74,0x75,0x72,0x65,0x28,0x30,0x29,0x5d,0x5d,
  3304. 0x2c,0x20,0x73,0x61,0x6d,0x70,0x6c,0x65,0x72,0x20,0x73,0x6d,0x70,0x20,0x5b,0x5b,
  3305. 0x73,0x61,0x6d,0x70,0x6c,0x65,0x72,0x28,0x30,0x29,0x5d,0x5d,0x29,0x0a,0x7b,0x0a,
  3306. 0x20,0x20,0x20,0x20,0x6d,0x61,0x69,0x6e,0x30,0x5f,0x6f,0x75,0x74,0x20,0x6f,0x75,
  3307. 0x74,0x20,0x3d,0x20,0x7b,0x7d,0x3b,0x0a,0x20,0x20,0x20,0x20,0x6f,0x75,0x74,0x2e,
  3308. 0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x74,0x65,0x78,
  3309. 0x2e,0x73,0x61,0x6d,0x70,0x6c,0x65,0x28,0x73,0x6d,0x70,0x2c,0x20,0x69,0x6e,0x2e,
  3310. 0x75,0x76,0x29,0x2e,0x78,0x78,0x78,0x78,0x20,0x2a,0x20,0x69,0x6e,0x2e,0x63,0x6f,
  3311. 0x6c,0x6f,0x72,0x3b,0x0a,0x20,0x20,0x20,0x20,0x72,0x65,0x74,0x75,0x72,0x6e,0x20,
  3312. 0x6f,0x75,0x74,0x3b,0x0a,0x7d,0x0a,0x0a,0x00,
  3313. };
  3314. #elif defined(SOKOL_D3D11)
  3315. /*
  3316. static float4 gl_Position;
  3317. static float2 position;
  3318. static float2 uv;
  3319. static float2 texcoord0;
  3320. static float4 color;
  3321. static float4 color0;
  3322. struct SPIRV_Cross_Input
  3323. {
  3324. float2 position : TEXCOORD0;
  3325. float2 texcoord0 : TEXCOORD1;
  3326. float4 color0 : TEXCOORD2;
  3327. };
  3328. struct SPIRV_Cross_Output
  3329. {
  3330. float2 uv : TEXCOORD0;
  3331. float4 color : TEXCOORD1;
  3332. float4 gl_Position : SV_Position;
  3333. };
  3334. void vert_main()
  3335. {
  3336. gl_Position = float4(mad(position, float2(2.0f, -2.0f), float2(-1.0f, 1.0f)), 0.0f, 1.0f);
  3337. uv = texcoord0;
  3338. color = color0;
  3339. }
  3340. SPIRV_Cross_Output main(SPIRV_Cross_Input stage_input)
  3341. {
  3342. position = stage_input.position;
  3343. texcoord0 = stage_input.texcoord0;
  3344. color0 = stage_input.color0;
  3345. vert_main();
  3346. SPIRV_Cross_Output stage_output;
  3347. stage_output.gl_Position = gl_Position;
  3348. stage_output.uv = uv;
  3349. stage_output.color = color;
  3350. return stage_output;
  3351. }
  3352. */
  3353. static const uint8_t _sdtx_vs_bytecode_hlsl4[692] = {
  3354. 0x44,0x58,0x42,0x43,0x07,0x05,0xa0,0xb3,0x53,0xc1,0x0a,0x0d,0x1e,0xf4,0xe4,0xa6,
  3355. 0x91,0xaf,0x4c,0xca,0x01,0x00,0x00,0x00,0xb4,0x02,0x00,0x00,0x05,0x00,0x00,0x00,
  3356. 0x34,0x00,0x00,0x00,0x80,0x00,0x00,0x00,0xe4,0x00,0x00,0x00,0x54,0x01,0x00,0x00,
  3357. 0x38,0x02,0x00,0x00,0x52,0x44,0x45,0x46,0x44,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3358. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1c,0x00,0x00,0x00,0x00,0x04,0xfe,0xff,
  3359. 0x10,0x81,0x00,0x00,0x1c,0x00,0x00,0x00,0x4d,0x69,0x63,0x72,0x6f,0x73,0x6f,0x66,
  3360. 0x74,0x20,0x28,0x52,0x29,0x20,0x48,0x4c,0x53,0x4c,0x20,0x53,0x68,0x61,0x64,0x65,
  3361. 0x72,0x20,0x43,0x6f,0x6d,0x70,0x69,0x6c,0x65,0x72,0x20,0x31,0x30,0x2e,0x31,0x00,
  3362. 0x49,0x53,0x47,0x4e,0x5c,0x00,0x00,0x00,0x03,0x00,0x00,0x00,0x08,0x00,0x00,0x00,
  3363. 0x50,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x03,0x00,0x00,0x00,
  3364. 0x00,0x00,0x00,0x00,0x03,0x03,0x00,0x00,0x50,0x00,0x00,0x00,0x01,0x00,0x00,0x00,
  3365. 0x00,0x00,0x00,0x00,0x03,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x03,0x03,0x00,0x00,
  3366. 0x50,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x03,0x00,0x00,0x00,
  3367. 0x02,0x00,0x00,0x00,0x0f,0x0f,0x00,0x00,0x54,0x45,0x58,0x43,0x4f,0x4f,0x52,0x44,
  3368. 0x00,0xab,0xab,0xab,0x4f,0x53,0x47,0x4e,0x68,0x00,0x00,0x00,0x03,0x00,0x00,0x00,
  3369. 0x08,0x00,0x00,0x00,0x50,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3370. 0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x03,0x0c,0x00,0x00,0x50,0x00,0x00,0x00,
  3371. 0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x03,0x00,0x00,0x00,0x01,0x00,0x00,0x00,
  3372. 0x0f,0x00,0x00,0x00,0x59,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,
  3373. 0x03,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x0f,0x00,0x00,0x00,0x54,0x45,0x58,0x43,
  3374. 0x4f,0x4f,0x52,0x44,0x00,0x53,0x56,0x5f,0x50,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,
  3375. 0x00,0xab,0xab,0xab,0x53,0x48,0x44,0x52,0xdc,0x00,0x00,0x00,0x40,0x00,0x01,0x00,
  3376. 0x37,0x00,0x00,0x00,0x5f,0x00,0x00,0x03,0x32,0x10,0x10,0x00,0x00,0x00,0x00,0x00,
  3377. 0x5f,0x00,0x00,0x03,0x32,0x10,0x10,0x00,0x01,0x00,0x00,0x00,0x5f,0x00,0x00,0x03,
  3378. 0xf2,0x10,0x10,0x00,0x02,0x00,0x00,0x00,0x65,0x00,0x00,0x03,0x32,0x20,0x10,0x00,
  3379. 0x00,0x00,0x00,0x00,0x65,0x00,0x00,0x03,0xf2,0x20,0x10,0x00,0x01,0x00,0x00,0x00,
  3380. 0x67,0x00,0x00,0x04,0xf2,0x20,0x10,0x00,0x02,0x00,0x00,0x00,0x01,0x00,0x00,0x00,
  3381. 0x36,0x00,0x00,0x05,0x32,0x20,0x10,0x00,0x00,0x00,0x00,0x00,0x46,0x10,0x10,0x00,
  3382. 0x01,0x00,0x00,0x00,0x36,0x00,0x00,0x05,0xf2,0x20,0x10,0x00,0x01,0x00,0x00,0x00,
  3383. 0x46,0x1e,0x10,0x00,0x02,0x00,0x00,0x00,0x32,0x00,0x00,0x0f,0x32,0x20,0x10,0x00,
  3384. 0x02,0x00,0x00,0x00,0x46,0x10,0x10,0x00,0x00,0x00,0x00,0x00,0x02,0x40,0x00,0x00,
  3385. 0x00,0x00,0x00,0x40,0x00,0x00,0x00,0xc0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3386. 0x02,0x40,0x00,0x00,0x00,0x00,0x80,0xbf,0x00,0x00,0x80,0x3f,0x00,0x00,0x00,0x00,
  3387. 0x00,0x00,0x00,0x00,0x36,0x00,0x00,0x08,0xc2,0x20,0x10,0x00,0x02,0x00,0x00,0x00,
  3388. 0x02,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3389. 0x00,0x00,0x80,0x3f,0x3e,0x00,0x00,0x01,0x53,0x54,0x41,0x54,0x74,0x00,0x00,0x00,
  3390. 0x05,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x06,0x00,0x00,0x00,
  3391. 0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,
  3392. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3393. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3394. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x03,0x00,0x00,0x00,
  3395. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3396. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3397. 0x00,0x00,0x00,0x00,
  3398. };
  3399. /*
  3400. Texture2D<float4> tex : register(t0);
  3401. SamplerState smp : register(s0);
  3402. static float4 frag_color;
  3403. static float2 uv;
  3404. static float4 color;
  3405. struct SPIRV_Cross_Input
  3406. {
  3407. float2 uv : TEXCOORD0;
  3408. float4 color : TEXCOORD1;
  3409. };
  3410. struct SPIRV_Cross_Output
  3411. {
  3412. float4 frag_color : SV_Target0;
  3413. };
  3414. void frag_main()
  3415. {
  3416. frag_color = tex.Sample(smp, uv).xxxx * color;
  3417. }
  3418. SPIRV_Cross_Output main(SPIRV_Cross_Input stage_input)
  3419. {
  3420. uv = stage_input.uv;
  3421. color = stage_input.color;
  3422. frag_main();
  3423. SPIRV_Cross_Output stage_output;
  3424. stage_output.frag_color = frag_color;
  3425. return stage_output;
  3426. }
  3427. */
  3428. static const uint8_t _sdtx_fs_bytecode_hlsl4[608] = {
  3429. 0x44,0x58,0x42,0x43,0xb7,0xcd,0xbd,0xb1,0x6f,0x85,0x5d,0x59,0x07,0x7e,0xa3,0x6e,
  3430. 0xe2,0x23,0x68,0xa0,0x01,0x00,0x00,0x00,0x60,0x02,0x00,0x00,0x05,0x00,0x00,0x00,
  3431. 0x34,0x00,0x00,0x00,0xc8,0x00,0x00,0x00,0x14,0x01,0x00,0x00,0x48,0x01,0x00,0x00,
  3432. 0xe4,0x01,0x00,0x00,0x52,0x44,0x45,0x46,0x8c,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3433. 0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x1c,0x00,0x00,0x00,0x00,0x04,0xff,0xff,
  3434. 0x10,0x81,0x00,0x00,0x64,0x00,0x00,0x00,0x5c,0x00,0x00,0x00,0x03,0x00,0x00,0x00,
  3435. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3436. 0x01,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x60,0x00,0x00,0x00,0x02,0x00,0x00,0x00,
  3437. 0x05,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0xff,0xff,0xff,0xff,0x00,0x00,0x00,0x00,
  3438. 0x01,0x00,0x00,0x00,0x0d,0x00,0x00,0x00,0x73,0x6d,0x70,0x00,0x74,0x65,0x78,0x00,
  3439. 0x4d,0x69,0x63,0x72,0x6f,0x73,0x6f,0x66,0x74,0x20,0x28,0x52,0x29,0x20,0x48,0x4c,
  3440. 0x53,0x4c,0x20,0x53,0x68,0x61,0x64,0x65,0x72,0x20,0x43,0x6f,0x6d,0x70,0x69,0x6c,
  3441. 0x65,0x72,0x20,0x31,0x30,0x2e,0x31,0x00,0x49,0x53,0x47,0x4e,0x44,0x00,0x00,0x00,
  3442. 0x02,0x00,0x00,0x00,0x08,0x00,0x00,0x00,0x38,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3443. 0x00,0x00,0x00,0x00,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x03,0x03,0x00,0x00,
  3444. 0x38,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x03,0x00,0x00,0x00,
  3445. 0x01,0x00,0x00,0x00,0x0f,0x0f,0x00,0x00,0x54,0x45,0x58,0x43,0x4f,0x4f,0x52,0x44,
  3446. 0x00,0xab,0xab,0xab,0x4f,0x53,0x47,0x4e,0x2c,0x00,0x00,0x00,0x01,0x00,0x00,0x00,
  3447. 0x08,0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3448. 0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0f,0x00,0x00,0x00,0x53,0x56,0x5f,0x54,
  3449. 0x61,0x72,0x67,0x65,0x74,0x00,0xab,0xab,0x53,0x48,0x44,0x52,0x94,0x00,0x00,0x00,
  3450. 0x40,0x00,0x00,0x00,0x25,0x00,0x00,0x00,0x5a,0x00,0x00,0x03,0x00,0x60,0x10,0x00,
  3451. 0x00,0x00,0x00,0x00,0x58,0x18,0x00,0x04,0x00,0x70,0x10,0x00,0x00,0x00,0x00,0x00,
  3452. 0x55,0x55,0x00,0x00,0x62,0x10,0x00,0x03,0x32,0x10,0x10,0x00,0x00,0x00,0x00,0x00,
  3453. 0x62,0x10,0x00,0x03,0xf2,0x10,0x10,0x00,0x01,0x00,0x00,0x00,0x65,0x00,0x00,0x03,
  3454. 0xf2,0x20,0x10,0x00,0x00,0x00,0x00,0x00,0x68,0x00,0x00,0x02,0x01,0x00,0x00,0x00,
  3455. 0x45,0x00,0x00,0x09,0xf2,0x00,0x10,0x00,0x00,0x00,0x00,0x00,0x46,0x10,0x10,0x00,
  3456. 0x00,0x00,0x00,0x00,0x46,0x7e,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x10,0x00,
  3457. 0x00,0x00,0x00,0x00,0x38,0x00,0x00,0x07,0xf2,0x20,0x10,0x00,0x00,0x00,0x00,0x00,
  3458. 0x06,0x00,0x10,0x00,0x00,0x00,0x00,0x00,0x46,0x1e,0x10,0x00,0x01,0x00,0x00,0x00,
  3459. 0x3e,0x00,0x00,0x01,0x53,0x54,0x41,0x54,0x74,0x00,0x00,0x00,0x03,0x00,0x00,0x00,
  3460. 0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x03,0x00,0x00,0x00,0x01,0x00,0x00,0x00,
  3461. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3462. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3463. 0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3464. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3465. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3466. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3467. };
  3468. #elif defined(SOKOL_WGPU)
  3469. /*
  3470. diagnostic(off, derivative_uniformity);
  3471. var<private> position_1 : vec2f;
  3472. var<private> uv : vec2f;
  3473. var<private> texcoord0 : vec2f;
  3474. var<private> color : vec4f;
  3475. var<private> color0 : vec4f;
  3476. var<private> gl_Position : vec4f;
  3477. fn main_1() {
  3478. let x_27 = ((position_1 * vec2f(2.0f, -2.0f)) + vec2f(-1.0f, 1.0f));
  3479. gl_Position = vec4f(x_27.x, x_27.y, 0.0f, 1.0f);
  3480. uv = texcoord0;
  3481. color = color0;
  3482. return;
  3483. }
  3484. struct main_out {
  3485. @builtin(position)
  3486. gl_Position : vec4f,
  3487. @location(0)
  3488. uv_1 : vec2f,
  3489. @location(1)
  3490. color_1 : vec4f,
  3491. }
  3492. @vertex
  3493. fn main(@location(0) position_1_param : vec2f, @location(1) texcoord0_param : vec2f, @location(2) color0_param : vec4f) -> main_out {
  3494. position_1 = position_1_param;
  3495. texcoord0 = texcoord0_param;
  3496. color0 = color0_param;
  3497. main_1();
  3498. return main_out(gl_Position, uv, color);
  3499. }
  3500. */
  3501. static const uint8_t _sdtx_vs_source_wgsl[832] = {
  3502. 0x64,0x69,0x61,0x67,0x6e,0x6f,0x73,0x74,0x69,0x63,0x28,0x6f,0x66,0x66,0x2c,0x20,
  3503. 0x64,0x65,0x72,0x69,0x76,0x61,0x74,0x69,0x76,0x65,0x5f,0x75,0x6e,0x69,0x66,0x6f,
  3504. 0x72,0x6d,0x69,0x74,0x79,0x29,0x3b,0x0a,0x0a,0x76,0x61,0x72,0x3c,0x70,0x72,0x69,
  3505. 0x76,0x61,0x74,0x65,0x3e,0x20,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x5f,0x31,
  3506. 0x20,0x3a,0x20,0x76,0x65,0x63,0x32,0x66,0x3b,0x0a,0x0a,0x76,0x61,0x72,0x3c,0x70,
  3507. 0x72,0x69,0x76,0x61,0x74,0x65,0x3e,0x20,0x75,0x76,0x20,0x3a,0x20,0x76,0x65,0x63,
  3508. 0x32,0x66,0x3b,0x0a,0x0a,0x76,0x61,0x72,0x3c,0x70,0x72,0x69,0x76,0x61,0x74,0x65,
  3509. 0x3e,0x20,0x74,0x65,0x78,0x63,0x6f,0x6f,0x72,0x64,0x30,0x20,0x3a,0x20,0x76,0x65,
  3510. 0x63,0x32,0x66,0x3b,0x0a,0x0a,0x76,0x61,0x72,0x3c,0x70,0x72,0x69,0x76,0x61,0x74,
  3511. 0x65,0x3e,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3a,0x20,0x76,0x65,0x63,0x34,0x66,
  3512. 0x3b,0x0a,0x0a,0x76,0x61,0x72,0x3c,0x70,0x72,0x69,0x76,0x61,0x74,0x65,0x3e,0x20,
  3513. 0x63,0x6f,0x6c,0x6f,0x72,0x30,0x20,0x3a,0x20,0x76,0x65,0x63,0x34,0x66,0x3b,0x0a,
  3514. 0x0a,0x76,0x61,0x72,0x3c,0x70,0x72,0x69,0x76,0x61,0x74,0x65,0x3e,0x20,0x67,0x6c,
  3515. 0x5f,0x50,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x3a,0x20,0x76,0x65,0x63,0x34,
  3516. 0x66,0x3b,0x0a,0x0a,0x66,0x6e,0x20,0x6d,0x61,0x69,0x6e,0x5f,0x31,0x28,0x29,0x20,
  3517. 0x7b,0x0a,0x20,0x20,0x6c,0x65,0x74,0x20,0x78,0x5f,0x32,0x37,0x20,0x3d,0x20,0x28,
  3518. 0x28,0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x5f,0x31,0x20,0x2a,0x20,0x76,0x65,
  3519. 0x63,0x32,0x66,0x28,0x32,0x2e,0x30,0x66,0x2c,0x20,0x2d,0x32,0x2e,0x30,0x66,0x29,
  3520. 0x29,0x20,0x2b,0x20,0x76,0x65,0x63,0x32,0x66,0x28,0x2d,0x31,0x2e,0x30,0x66,0x2c,
  3521. 0x20,0x31,0x2e,0x30,0x66,0x29,0x29,0x3b,0x0a,0x20,0x20,0x67,0x6c,0x5f,0x50,0x6f,
  3522. 0x73,0x69,0x74,0x69,0x6f,0x6e,0x20,0x3d,0x20,0x76,0x65,0x63,0x34,0x66,0x28,0x78,
  3523. 0x5f,0x32,0x37,0x2e,0x78,0x2c,0x20,0x78,0x5f,0x32,0x37,0x2e,0x79,0x2c,0x20,0x30,
  3524. 0x2e,0x30,0x66,0x2c,0x20,0x31,0x2e,0x30,0x66,0x29,0x3b,0x0a,0x20,0x20,0x75,0x76,
  3525. 0x20,0x3d,0x20,0x74,0x65,0x78,0x63,0x6f,0x6f,0x72,0x64,0x30,0x3b,0x0a,0x20,0x20,
  3526. 0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x30,0x3b,0x0a,
  3527. 0x20,0x20,0x72,0x65,0x74,0x75,0x72,0x6e,0x3b,0x0a,0x7d,0x0a,0x0a,0x73,0x74,0x72,
  3528. 0x75,0x63,0x74,0x20,0x6d,0x61,0x69,0x6e,0x5f,0x6f,0x75,0x74,0x20,0x7b,0x0a,0x20,
  3529. 0x20,0x40,0x62,0x75,0x69,0x6c,0x74,0x69,0x6e,0x28,0x70,0x6f,0x73,0x69,0x74,0x69,
  3530. 0x6f,0x6e,0x29,0x0a,0x20,0x20,0x67,0x6c,0x5f,0x50,0x6f,0x73,0x69,0x74,0x69,0x6f,
  3531. 0x6e,0x20,0x3a,0x20,0x76,0x65,0x63,0x34,0x66,0x2c,0x0a,0x20,0x20,0x40,0x6c,0x6f,
  3532. 0x63,0x61,0x74,0x69,0x6f,0x6e,0x28,0x30,0x29,0x0a,0x20,0x20,0x75,0x76,0x5f,0x31,
  3533. 0x20,0x3a,0x20,0x76,0x65,0x63,0x32,0x66,0x2c,0x0a,0x20,0x20,0x40,0x6c,0x6f,0x63,
  3534. 0x61,0x74,0x69,0x6f,0x6e,0x28,0x31,0x29,0x0a,0x20,0x20,0x63,0x6f,0x6c,0x6f,0x72,
  3535. 0x5f,0x31,0x20,0x3a,0x20,0x76,0x65,0x63,0x34,0x66,0x2c,0x0a,0x7d,0x0a,0x0a,0x40,
  3536. 0x76,0x65,0x72,0x74,0x65,0x78,0x0a,0x66,0x6e,0x20,0x6d,0x61,0x69,0x6e,0x28,0x40,
  3537. 0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e,0x28,0x30,0x29,0x20,0x70,0x6f,0x73,0x69,
  3538. 0x74,0x69,0x6f,0x6e,0x5f,0x31,0x5f,0x70,0x61,0x72,0x61,0x6d,0x20,0x3a,0x20,0x76,
  3539. 0x65,0x63,0x32,0x66,0x2c,0x20,0x40,0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e,0x28,
  3540. 0x31,0x29,0x20,0x74,0x65,0x78,0x63,0x6f,0x6f,0x72,0x64,0x30,0x5f,0x70,0x61,0x72,
  3541. 0x61,0x6d,0x20,0x3a,0x20,0x76,0x65,0x63,0x32,0x66,0x2c,0x20,0x40,0x6c,0x6f,0x63,
  3542. 0x61,0x74,0x69,0x6f,0x6e,0x28,0x32,0x29,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x30,0x5f,
  3543. 0x70,0x61,0x72,0x61,0x6d,0x20,0x3a,0x20,0x76,0x65,0x63,0x34,0x66,0x29,0x20,0x2d,
  3544. 0x3e,0x20,0x6d,0x61,0x69,0x6e,0x5f,0x6f,0x75,0x74,0x20,0x7b,0x0a,0x20,0x20,0x70,
  3545. 0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x5f,0x31,0x20,0x3d,0x20,0x70,0x6f,0x73,0x69,
  3546. 0x74,0x69,0x6f,0x6e,0x5f,0x31,0x5f,0x70,0x61,0x72,0x61,0x6d,0x3b,0x0a,0x20,0x20,
  3547. 0x74,0x65,0x78,0x63,0x6f,0x6f,0x72,0x64,0x30,0x20,0x3d,0x20,0x74,0x65,0x78,0x63,
  3548. 0x6f,0x6f,0x72,0x64,0x30,0x5f,0x70,0x61,0x72,0x61,0x6d,0x3b,0x0a,0x20,0x20,0x63,
  3549. 0x6f,0x6c,0x6f,0x72,0x30,0x20,0x3d,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x30,0x5f,0x70,
  3550. 0x61,0x72,0x61,0x6d,0x3b,0x0a,0x20,0x20,0x6d,0x61,0x69,0x6e,0x5f,0x31,0x28,0x29,
  3551. 0x3b,0x0a,0x20,0x20,0x72,0x65,0x74,0x75,0x72,0x6e,0x20,0x6d,0x61,0x69,0x6e,0x5f,
  3552. 0x6f,0x75,0x74,0x28,0x67,0x6c,0x5f,0x50,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x2c,
  3553. 0x20,0x75,0x76,0x2c,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x29,0x3b,0x0a,0x7d,0x0a,0x00,
  3554. };
  3555. /*
  3556. diagnostic(off, derivative_uniformity);
  3557. var<private> frag_color : vec4f;
  3558. @binding(0) @group(1) var tex : texture_2d<f32>;
  3559. @binding(32) @group(1) var smp : sampler;
  3560. var<private> uv : vec2f;
  3561. var<private> color : vec4f;
  3562. fn main_1() {
  3563. let x_23 = uv;
  3564. let x_24 = textureSample(tex, smp, x_23);
  3565. frag_color = (x_24.xxxx * color);
  3566. return;
  3567. }
  3568. struct main_out {
  3569. @location(0)
  3570. frag_color_1 : vec4f,
  3571. }
  3572. @fragment
  3573. fn main(@location(0) uv_param : vec2f, @location(1) color_param : vec4f) -> main_out {
  3574. uv = uv_param;
  3575. color = color_param;
  3576. main_1();
  3577. return main_out(frag_color);
  3578. }
  3579. */
  3580. static const uint8_t _sdtx_fs_source_wgsl[590] = {
  3581. 0x64,0x69,0x61,0x67,0x6e,0x6f,0x73,0x74,0x69,0x63,0x28,0x6f,0x66,0x66,0x2c,0x20,
  3582. 0x64,0x65,0x72,0x69,0x76,0x61,0x74,0x69,0x76,0x65,0x5f,0x75,0x6e,0x69,0x66,0x6f,
  3583. 0x72,0x6d,0x69,0x74,0x79,0x29,0x3b,0x0a,0x0a,0x76,0x61,0x72,0x3c,0x70,0x72,0x69,
  3584. 0x76,0x61,0x74,0x65,0x3e,0x20,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72,
  3585. 0x20,0x3a,0x20,0x76,0x65,0x63,0x34,0x66,0x3b,0x0a,0x0a,0x40,0x62,0x69,0x6e,0x64,
  3586. 0x69,0x6e,0x67,0x28,0x30,0x29,0x20,0x40,0x67,0x72,0x6f,0x75,0x70,0x28,0x31,0x29,
  3587. 0x20,0x76,0x61,0x72,0x20,0x74,0x65,0x78,0x20,0x3a,0x20,0x74,0x65,0x78,0x74,0x75,
  3588. 0x72,0x65,0x5f,0x32,0x64,0x3c,0x66,0x33,0x32,0x3e,0x3b,0x0a,0x0a,0x40,0x62,0x69,
  3589. 0x6e,0x64,0x69,0x6e,0x67,0x28,0x33,0x32,0x29,0x20,0x40,0x67,0x72,0x6f,0x75,0x70,
  3590. 0x28,0x31,0x29,0x20,0x76,0x61,0x72,0x20,0x73,0x6d,0x70,0x20,0x3a,0x20,0x73,0x61,
  3591. 0x6d,0x70,0x6c,0x65,0x72,0x3b,0x0a,0x0a,0x76,0x61,0x72,0x3c,0x70,0x72,0x69,0x76,
  3592. 0x61,0x74,0x65,0x3e,0x20,0x75,0x76,0x20,0x3a,0x20,0x76,0x65,0x63,0x32,0x66,0x3b,
  3593. 0x0a,0x0a,0x76,0x61,0x72,0x3c,0x70,0x72,0x69,0x76,0x61,0x74,0x65,0x3e,0x20,0x63,
  3594. 0x6f,0x6c,0x6f,0x72,0x20,0x3a,0x20,0x76,0x65,0x63,0x34,0x66,0x3b,0x0a,0x0a,0x66,
  3595. 0x6e,0x20,0x6d,0x61,0x69,0x6e,0x5f,0x31,0x28,0x29,0x20,0x7b,0x0a,0x20,0x20,0x6c,
  3596. 0x65,0x74,0x20,0x78,0x5f,0x32,0x33,0x20,0x3d,0x20,0x75,0x76,0x3b,0x0a,0x20,0x20,
  3597. 0x6c,0x65,0x74,0x20,0x78,0x5f,0x32,0x34,0x20,0x3d,0x20,0x74,0x65,0x78,0x74,0x75,
  3598. 0x72,0x65,0x53,0x61,0x6d,0x70,0x6c,0x65,0x28,0x74,0x65,0x78,0x2c,0x20,0x73,0x6d,
  3599. 0x70,0x2c,0x20,0x78,0x5f,0x32,0x33,0x29,0x3b,0x0a,0x20,0x20,0x66,0x72,0x61,0x67,
  3600. 0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x20,0x3d,0x20,0x28,0x78,0x5f,0x32,0x34,0x2e,0x78,
  3601. 0x78,0x78,0x78,0x20,0x2a,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x29,0x3b,0x0a,0x20,0x20,
  3602. 0x72,0x65,0x74,0x75,0x72,0x6e,0x3b,0x0a,0x7d,0x0a,0x0a,0x73,0x74,0x72,0x75,0x63,
  3603. 0x74,0x20,0x6d,0x61,0x69,0x6e,0x5f,0x6f,0x75,0x74,0x20,0x7b,0x0a,0x20,0x20,0x40,
  3604. 0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e,0x28,0x30,0x29,0x0a,0x20,0x20,0x66,0x72,
  3605. 0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x5f,0x31,0x20,0x3a,0x20,0x76,0x65,0x63,
  3606. 0x34,0x66,0x2c,0x0a,0x7d,0x0a,0x0a,0x40,0x66,0x72,0x61,0x67,0x6d,0x65,0x6e,0x74,
  3607. 0x0a,0x66,0x6e,0x20,0x6d,0x61,0x69,0x6e,0x28,0x40,0x6c,0x6f,0x63,0x61,0x74,0x69,
  3608. 0x6f,0x6e,0x28,0x30,0x29,0x20,0x75,0x76,0x5f,0x70,0x61,0x72,0x61,0x6d,0x20,0x3a,
  3609. 0x20,0x76,0x65,0x63,0x32,0x66,0x2c,0x20,0x40,0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,
  3610. 0x6e,0x28,0x31,0x29,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x5f,0x70,0x61,0x72,0x61,0x6d,
  3611. 0x20,0x3a,0x20,0x76,0x65,0x63,0x34,0x66,0x29,0x20,0x2d,0x3e,0x20,0x6d,0x61,0x69,
  3612. 0x6e,0x5f,0x6f,0x75,0x74,0x20,0x7b,0x0a,0x20,0x20,0x75,0x76,0x20,0x3d,0x20,0x75,
  3613. 0x76,0x5f,0x70,0x61,0x72,0x61,0x6d,0x3b,0x0a,0x20,0x20,0x63,0x6f,0x6c,0x6f,0x72,
  3614. 0x20,0x3d,0x20,0x63,0x6f,0x6c,0x6f,0x72,0x5f,0x70,0x61,0x72,0x61,0x6d,0x3b,0x0a,
  3615. 0x20,0x20,0x6d,0x61,0x69,0x6e,0x5f,0x31,0x28,0x29,0x3b,0x0a,0x20,0x20,0x72,0x65,
  3616. 0x74,0x75,0x72,0x6e,0x20,0x6d,0x61,0x69,0x6e,0x5f,0x6f,0x75,0x74,0x28,0x66,0x72,
  3617. 0x61,0x67,0x5f,0x63,0x6f,0x6c,0x6f,0x72,0x29,0x3b,0x0a,0x7d,0x0a,0x00,
  3618. };
  3619. #elif defined(SOKOL_VULKAN)
  3620. /*
  3621. #version 460
  3622. layout(location = 0) in vec2 position;
  3623. layout(location = 0) out vec2 uv;
  3624. layout(location = 1) in vec2 texcoord0;
  3625. layout(location = 1) out vec4 color;
  3626. layout(location = 2) in vec4 color0;
  3627. void main()
  3628. {
  3629. gl_Position = vec4((position * vec2(2.0, -2.0)) + vec2(-1.0, 1.0), 0.0, 1.0);
  3630. uv = texcoord0;
  3631. color = color0;
  3632. }
  3633. */
  3634. static const uint8_t _sdtx_vs_bytecode_spirv_vk[1248] = {
  3635. 0x03,0x02,0x23,0x07,0x00,0x04,0x01,0x00,0x0b,0x00,0x08,0x00,0x2a,0x00,0x00,0x00,
  3636. 0x00,0x00,0x00,0x00,0x11,0x00,0x02,0x00,0x01,0x00,0x00,0x00,0x0b,0x00,0x06,0x00,
  3637. 0x01,0x00,0x00,0x00,0x47,0x4c,0x53,0x4c,0x2e,0x73,0x74,0x64,0x2e,0x34,0x35,0x30,
  3638. 0x00,0x00,0x00,0x00,0x0e,0x00,0x03,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,
  3639. 0x0f,0x00,0x0b,0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x6d,0x61,0x69,0x6e,
  3640. 0x00,0x00,0x00,0x00,0x0d,0x00,0x00,0x00,0x12,0x00,0x00,0x00,0x23,0x00,0x00,0x00,
  3641. 0x24,0x00,0x00,0x00,0x26,0x00,0x00,0x00,0x28,0x00,0x00,0x00,0x03,0x00,0x03,0x00,
  3642. 0x02,0x00,0x00,0x00,0xcc,0x01,0x00,0x00,0x05,0x00,0x04,0x00,0x04,0x00,0x00,0x00,
  3643. 0x6d,0x61,0x69,0x6e,0x00,0x00,0x00,0x00,0x05,0x00,0x06,0x00,0x0b,0x00,0x00,0x00,
  3644. 0x67,0x6c,0x5f,0x50,0x65,0x72,0x56,0x65,0x72,0x74,0x65,0x78,0x00,0x00,0x00,0x00,
  3645. 0x06,0x00,0x06,0x00,0x0b,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x67,0x6c,0x5f,0x50,
  3646. 0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x00,0x06,0x00,0x07,0x00,0x0b,0x00,0x00,0x00,
  3647. 0x01,0x00,0x00,0x00,0x67,0x6c,0x5f,0x50,0x6f,0x69,0x6e,0x74,0x53,0x69,0x7a,0x65,
  3648. 0x00,0x00,0x00,0x00,0x06,0x00,0x07,0x00,0x0b,0x00,0x00,0x00,0x02,0x00,0x00,0x00,
  3649. 0x67,0x6c,0x5f,0x43,0x6c,0x69,0x70,0x44,0x69,0x73,0x74,0x61,0x6e,0x63,0x65,0x00,
  3650. 0x06,0x00,0x07,0x00,0x0b,0x00,0x00,0x00,0x03,0x00,0x00,0x00,0x67,0x6c,0x5f,0x43,
  3651. 0x75,0x6c,0x6c,0x44,0x69,0x73,0x74,0x61,0x6e,0x63,0x65,0x00,0x05,0x00,0x03,0x00,
  3652. 0x0d,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x05,0x00,0x05,0x00,0x12,0x00,0x00,0x00,
  3653. 0x70,0x6f,0x73,0x69,0x74,0x69,0x6f,0x6e,0x00,0x00,0x00,0x00,0x05,0x00,0x03,0x00,
  3654. 0x23,0x00,0x00,0x00,0x75,0x76,0x00,0x00,0x05,0x00,0x05,0x00,0x24,0x00,0x00,0x00,
  3655. 0x74,0x65,0x78,0x63,0x6f,0x6f,0x72,0x64,0x30,0x00,0x00,0x00,0x05,0x00,0x04,0x00,
  3656. 0x26,0x00,0x00,0x00,0x63,0x6f,0x6c,0x6f,0x72,0x00,0x00,0x00,0x05,0x00,0x04,0x00,
  3657. 0x28,0x00,0x00,0x00,0x63,0x6f,0x6c,0x6f,0x72,0x30,0x00,0x00,0x47,0x00,0x03,0x00,
  3658. 0x0b,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x48,0x00,0x05,0x00,0x0b,0x00,0x00,0x00,
  3659. 0x00,0x00,0x00,0x00,0x0b,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x48,0x00,0x05,0x00,
  3660. 0x0b,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x0b,0x00,0x00,0x00,0x01,0x00,0x00,0x00,
  3661. 0x48,0x00,0x05,0x00,0x0b,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x0b,0x00,0x00,0x00,
  3662. 0x03,0x00,0x00,0x00,0x48,0x00,0x05,0x00,0x0b,0x00,0x00,0x00,0x03,0x00,0x00,0x00,
  3663. 0x0b,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x47,0x00,0x04,0x00,0x12,0x00,0x00,0x00,
  3664. 0x1e,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x47,0x00,0x04,0x00,0x23,0x00,0x00,0x00,
  3665. 0x1e,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x47,0x00,0x04,0x00,0x24,0x00,0x00,0x00,
  3666. 0x1e,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x47,0x00,0x04,0x00,0x26,0x00,0x00,0x00,
  3667. 0x1e,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x47,0x00,0x04,0x00,0x28,0x00,0x00,0x00,
  3668. 0x1e,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x13,0x00,0x02,0x00,0x02,0x00,0x00,0x00,
  3669. 0x21,0x00,0x03,0x00,0x03,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x16,0x00,0x03,0x00,
  3670. 0x06,0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x17,0x00,0x04,0x00,0x07,0x00,0x00,0x00,
  3671. 0x06,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x15,0x00,0x04,0x00,0x08,0x00,0x00,0x00,
  3672. 0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x2b,0x00,0x04,0x00,0x08,0x00,0x00,0x00,
  3673. 0x09,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x1c,0x00,0x04,0x00,0x0a,0x00,0x00,0x00,
  3674. 0x06,0x00,0x00,0x00,0x09,0x00,0x00,0x00,0x1e,0x00,0x06,0x00,0x0b,0x00,0x00,0x00,
  3675. 0x07,0x00,0x00,0x00,0x06,0x00,0x00,0x00,0x0a,0x00,0x00,0x00,0x0a,0x00,0x00,0x00,
  3676. 0x20,0x00,0x04,0x00,0x0c,0x00,0x00,0x00,0x03,0x00,0x00,0x00,0x0b,0x00,0x00,0x00,
  3677. 0x3b,0x00,0x04,0x00,0x0c,0x00,0x00,0x00,0x0d,0x00,0x00,0x00,0x03,0x00,0x00,0x00,
  3678. 0x15,0x00,0x04,0x00,0x0e,0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x01,0x00,0x00,0x00,
  3679. 0x2b,0x00,0x04,0x00,0x0e,0x00,0x00,0x00,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3680. 0x17,0x00,0x04,0x00,0x10,0x00,0x00,0x00,0x06,0x00,0x00,0x00,0x02,0x00,0x00,0x00,
  3681. 0x20,0x00,0x04,0x00,0x11,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x10,0x00,0x00,0x00,
  3682. 0x3b,0x00,0x04,0x00,0x11,0x00,0x00,0x00,0x12,0x00,0x00,0x00,0x01,0x00,0x00,0x00,
  3683. 0x2b,0x00,0x04,0x00,0x06,0x00,0x00,0x00,0x14,0x00,0x00,0x00,0x00,0x00,0x00,0x40,
  3684. 0x2b,0x00,0x04,0x00,0x06,0x00,0x00,0x00,0x15,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,
  3685. 0x2c,0x00,0x05,0x00,0x10,0x00,0x00,0x00,0x16,0x00,0x00,0x00,0x14,0x00,0x00,0x00,
  3686. 0x15,0x00,0x00,0x00,0x2b,0x00,0x04,0x00,0x06,0x00,0x00,0x00,0x18,0x00,0x00,0x00,
  3687. 0x00,0x00,0x80,0xbf,0x2b,0x00,0x04,0x00,0x06,0x00,0x00,0x00,0x19,0x00,0x00,0x00,
  3688. 0x00,0x00,0x80,0x3f,0x2c,0x00,0x05,0x00,0x10,0x00,0x00,0x00,0x1a,0x00,0x00,0x00,
  3689. 0x18,0x00,0x00,0x00,0x19,0x00,0x00,0x00,0x2b,0x00,0x04,0x00,0x06,0x00,0x00,0x00,
  3690. 0x1c,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x00,0x04,0x00,0x20,0x00,0x00,0x00,
  3691. 0x03,0x00,0x00,0x00,0x07,0x00,0x00,0x00,0x20,0x00,0x04,0x00,0x22,0x00,0x00,0x00,
  3692. 0x03,0x00,0x00,0x00,0x10,0x00,0x00,0x00,0x3b,0x00,0x04,0x00,0x22,0x00,0x00,0x00,
  3693. 0x23,0x00,0x00,0x00,0x03,0x00,0x00,0x00,0x3b,0x00,0x04,0x00,0x11,0x00,0x00,0x00,
  3694. 0x24,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x3b,0x00,0x04,0x00,0x20,0x00,0x00,0x00,
  3695. 0x26,0x00,0x00,0x00,0x03,0x00,0x00,0x00,0x20,0x00,0x04,0x00,0x27,0x00,0x00,0x00,
  3696. 0x01,0x00,0x00,0x00,0x07,0x00,0x00,0x00,0x3b,0x00,0x04,0x00,0x27,0x00,0x00,0x00,
  3697. 0x28,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x36,0x00,0x05,0x00,0x02,0x00,0x00,0x00,
  3698. 0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x03,0x00,0x00,0x00,0xf8,0x00,0x02,0x00,
  3699. 0x05,0x00,0x00,0x00,0x3d,0x00,0x04,0x00,0x10,0x00,0x00,0x00,0x13,0x00,0x00,0x00,
  3700. 0x12,0x00,0x00,0x00,0x85,0x00,0x05,0x00,0x10,0x00,0x00,0x00,0x17,0x00,0x00,0x00,
  3701. 0x13,0x00,0x00,0x00,0x16,0x00,0x00,0x00,0x81,0x00,0x05,0x00,0x10,0x00,0x00,0x00,
  3702. 0x1b,0x00,0x00,0x00,0x17,0x00,0x00,0x00,0x1a,0x00,0x00,0x00,0x51,0x00,0x05,0x00,
  3703. 0x06,0x00,0x00,0x00,0x1d,0x00,0x00,0x00,0x1b,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3704. 0x51,0x00,0x05,0x00,0x06,0x00,0x00,0x00,0x1e,0x00,0x00,0x00,0x1b,0x00,0x00,0x00,
  3705. 0x01,0x00,0x00,0x00,0x50,0x00,0x07,0x00,0x07,0x00,0x00,0x00,0x1f,0x00,0x00,0x00,
  3706. 0x1d,0x00,0x00,0x00,0x1e,0x00,0x00,0x00,0x1c,0x00,0x00,0x00,0x19,0x00,0x00,0x00,
  3707. 0x41,0x00,0x05,0x00,0x20,0x00,0x00,0x00,0x21,0x00,0x00,0x00,0x0d,0x00,0x00,0x00,
  3708. 0x0f,0x00,0x00,0x00,0x3e,0x00,0x03,0x00,0x21,0x00,0x00,0x00,0x1f,0x00,0x00,0x00,
  3709. 0x3d,0x00,0x04,0x00,0x10,0x00,0x00,0x00,0x25,0x00,0x00,0x00,0x24,0x00,0x00,0x00,
  3710. 0x3e,0x00,0x03,0x00,0x23,0x00,0x00,0x00,0x25,0x00,0x00,0x00,0x3d,0x00,0x04,0x00,
  3711. 0x07,0x00,0x00,0x00,0x29,0x00,0x00,0x00,0x28,0x00,0x00,0x00,0x3e,0x00,0x03,0x00,
  3712. 0x26,0x00,0x00,0x00,0x29,0x00,0x00,0x00,0xfd,0x00,0x01,0x00,0x38,0x00,0x01,0x00,
  3713. };
  3714. /*
  3715. #version 460
  3716. layout(set = 1, binding = 0) uniform texture2D tex;
  3717. layout(set = 1, binding = 32) uniform sampler smp;
  3718. layout(location = 0) out vec4 frag_color;
  3719. layout(location = 0) in vec2 uv;
  3720. layout(location = 1) in vec4 color;
  3721. void main()
  3722. {
  3723. frag_color = texture(sampler2D(tex, smp), uv).xxxx * color;
  3724. }
  3725. */
  3726. static const uint8_t _sdtx_fs_bytecode_spirv_vk[816] = {
  3727. 0x03,0x02,0x23,0x07,0x00,0x04,0x01,0x00,0x0b,0x00,0x08,0x00,0x1e,0x00,0x00,0x00,
  3728. 0x00,0x00,0x00,0x00,0x11,0x00,0x02,0x00,0x01,0x00,0x00,0x00,0x0b,0x00,0x06,0x00,
  3729. 0x01,0x00,0x00,0x00,0x47,0x4c,0x53,0x4c,0x2e,0x73,0x74,0x64,0x2e,0x34,0x35,0x30,
  3730. 0x00,0x00,0x00,0x00,0x0e,0x00,0x03,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,
  3731. 0x0f,0x00,0x0a,0x00,0x04,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x6d,0x61,0x69,0x6e,
  3732. 0x00,0x00,0x00,0x00,0x09,0x00,0x00,0x00,0x0c,0x00,0x00,0x00,0x10,0x00,0x00,0x00,
  3733. 0x16,0x00,0x00,0x00,0x1b,0x00,0x00,0x00,0x10,0x00,0x03,0x00,0x04,0x00,0x00,0x00,
  3734. 0x07,0x00,0x00,0x00,0x03,0x00,0x03,0x00,0x02,0x00,0x00,0x00,0xcc,0x01,0x00,0x00,
  3735. 0x05,0x00,0x04,0x00,0x04,0x00,0x00,0x00,0x6d,0x61,0x69,0x6e,0x00,0x00,0x00,0x00,
  3736. 0x05,0x00,0x05,0x00,0x09,0x00,0x00,0x00,0x66,0x72,0x61,0x67,0x5f,0x63,0x6f,0x6c,
  3737. 0x6f,0x72,0x00,0x00,0x05,0x00,0x03,0x00,0x0c,0x00,0x00,0x00,0x74,0x65,0x78,0x00,
  3738. 0x05,0x00,0x03,0x00,0x10,0x00,0x00,0x00,0x73,0x6d,0x70,0x00,0x05,0x00,0x03,0x00,
  3739. 0x16,0x00,0x00,0x00,0x75,0x76,0x00,0x00,0x05,0x00,0x04,0x00,0x1b,0x00,0x00,0x00,
  3740. 0x63,0x6f,0x6c,0x6f,0x72,0x00,0x00,0x00,0x47,0x00,0x04,0x00,0x09,0x00,0x00,0x00,
  3741. 0x1e,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x47,0x00,0x04,0x00,0x0c,0x00,0x00,0x00,
  3742. 0x21,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x47,0x00,0x04,0x00,0x0c,0x00,0x00,0x00,
  3743. 0x22,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x47,0x00,0x04,0x00,0x10,0x00,0x00,0x00,
  3744. 0x21,0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x47,0x00,0x04,0x00,0x10,0x00,0x00,0x00,
  3745. 0x22,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x47,0x00,0x04,0x00,0x16,0x00,0x00,0x00,
  3746. 0x1e,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x47,0x00,0x04,0x00,0x1b,0x00,0x00,0x00,
  3747. 0x1e,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x13,0x00,0x02,0x00,0x02,0x00,0x00,0x00,
  3748. 0x21,0x00,0x03,0x00,0x03,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x16,0x00,0x03,0x00,
  3749. 0x06,0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x17,0x00,0x04,0x00,0x07,0x00,0x00,0x00,
  3750. 0x06,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x20,0x00,0x04,0x00,0x08,0x00,0x00,0x00,
  3751. 0x03,0x00,0x00,0x00,0x07,0x00,0x00,0x00,0x3b,0x00,0x04,0x00,0x08,0x00,0x00,0x00,
  3752. 0x09,0x00,0x00,0x00,0x03,0x00,0x00,0x00,0x19,0x00,0x09,0x00,0x0a,0x00,0x00,0x00,
  3753. 0x06,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3754. 0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x00,0x04,0x00,
  3755. 0x0b,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0a,0x00,0x00,0x00,0x3b,0x00,0x04,0x00,
  3756. 0x0b,0x00,0x00,0x00,0x0c,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1a,0x00,0x02,0x00,
  3757. 0x0e,0x00,0x00,0x00,0x20,0x00,0x04,0x00,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3758. 0x0e,0x00,0x00,0x00,0x3b,0x00,0x04,0x00,0x0f,0x00,0x00,0x00,0x10,0x00,0x00,0x00,
  3759. 0x00,0x00,0x00,0x00,0x1b,0x00,0x03,0x00,0x12,0x00,0x00,0x00,0x0a,0x00,0x00,0x00,
  3760. 0x17,0x00,0x04,0x00,0x14,0x00,0x00,0x00,0x06,0x00,0x00,0x00,0x02,0x00,0x00,0x00,
  3761. 0x20,0x00,0x04,0x00,0x15,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x14,0x00,0x00,0x00,
  3762. 0x3b,0x00,0x04,0x00,0x15,0x00,0x00,0x00,0x16,0x00,0x00,0x00,0x01,0x00,0x00,0x00,
  3763. 0x20,0x00,0x04,0x00,0x1a,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x07,0x00,0x00,0x00,
  3764. 0x3b,0x00,0x04,0x00,0x1a,0x00,0x00,0x00,0x1b,0x00,0x00,0x00,0x01,0x00,0x00,0x00,
  3765. 0x36,0x00,0x05,0x00,0x02,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3766. 0x03,0x00,0x00,0x00,0xf8,0x00,0x02,0x00,0x05,0x00,0x00,0x00,0x3d,0x00,0x04,0x00,
  3767. 0x0a,0x00,0x00,0x00,0x0d,0x00,0x00,0x00,0x0c,0x00,0x00,0x00,0x3d,0x00,0x04,0x00,
  3768. 0x0e,0x00,0x00,0x00,0x11,0x00,0x00,0x00,0x10,0x00,0x00,0x00,0x56,0x00,0x05,0x00,
  3769. 0x12,0x00,0x00,0x00,0x13,0x00,0x00,0x00,0x0d,0x00,0x00,0x00,0x11,0x00,0x00,0x00,
  3770. 0x3d,0x00,0x04,0x00,0x14,0x00,0x00,0x00,0x17,0x00,0x00,0x00,0x16,0x00,0x00,0x00,
  3771. 0x57,0x00,0x05,0x00,0x07,0x00,0x00,0x00,0x18,0x00,0x00,0x00,0x13,0x00,0x00,0x00,
  3772. 0x17,0x00,0x00,0x00,0x4f,0x00,0x09,0x00,0x07,0x00,0x00,0x00,0x19,0x00,0x00,0x00,
  3773. 0x18,0x00,0x00,0x00,0x18,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  3774. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3d,0x00,0x04,0x00,0x07,0x00,0x00,0x00,
  3775. 0x1c,0x00,0x00,0x00,0x1b,0x00,0x00,0x00,0x85,0x00,0x05,0x00,0x07,0x00,0x00,0x00,
  3776. 0x1d,0x00,0x00,0x00,0x19,0x00,0x00,0x00,0x1c,0x00,0x00,0x00,0x3e,0x00,0x03,0x00,
  3777. 0x09,0x00,0x00,0x00,0x1d,0x00,0x00,0x00,0xfd,0x00,0x01,0x00,0x38,0x00,0x01,0x00,
  3778. };
  3779. #elif defined(SOKOL_DUMMY_BACKEND)
  3780. static const char* _sdtx_vs_src_dummy = "";
  3781. static const char* _sdtx_fs_src_dummy = "";
  3782. #else
  3783. #error "Please define one of SOKOL_GLCORE, SOKOL_GLES3, SOKOL_D3D11, SOKOL_METAL, SOKOL_WGPU or SOKOL_DUMMY_BACKEND!"
  3784. #endif
  3785. // ███████ ████████ ██████ ██ ██ ██████ ████████ ███████
  3786. // ██ ██ ██ ██ ██ ██ ██ ██ ██
  3787. // ███████ ██ ██████ ██ ██ ██ ██ ███████
  3788. // ██ ██ ██ ██ ██ ██ ██ ██ ██
  3789. // ███████ ██ ██ ██ ██████ ██████ ██ ███████
  3790. //
  3791. // >>structs
  3792. typedef struct {
  3793. uint32_t id;
  3794. sg_resource_state state;
  3795. } _sdtx_slot_t;
  3796. typedef struct {
  3797. int size;
  3798. int queue_top;
  3799. uint32_t* gen_ctrs;
  3800. int* free_queue;
  3801. } _sdtx_pool_t;
  3802. typedef struct {
  3803. float x, y;
  3804. } _sdtx_float2_t;
  3805. typedef struct {
  3806. float x, y;
  3807. uint16_t u, v;
  3808. uint32_t color;
  3809. } _sdtx_vertex_t;
  3810. typedef struct {
  3811. int layer_id;
  3812. int first_vertex;
  3813. int num_vertices;
  3814. } _sdtx_command_t;
  3815. typedef struct {
  3816. _sdtx_slot_t slot;
  3817. sdtx_context_desc_t desc;
  3818. uint32_t frame_id;
  3819. uint32_t update_frame_id;
  3820. struct {
  3821. int cap;
  3822. int next;
  3823. _sdtx_vertex_t* ptr;
  3824. } vertices;
  3825. struct {
  3826. int cap;
  3827. int next;
  3828. _sdtx_command_t* ptr;
  3829. } commands;
  3830. sg_buffer vbuf;
  3831. sg_pipeline pip;
  3832. int cur_font;
  3833. int cur_layer_id;
  3834. _sdtx_float2_t canvas_size;
  3835. _sdtx_float2_t glyph_size;
  3836. _sdtx_float2_t origin;
  3837. _sdtx_float2_t pos;
  3838. float tab_width;
  3839. uint32_t color;
  3840. } _sdtx_context_t;
  3841. typedef struct {
  3842. _sdtx_pool_t pool;
  3843. _sdtx_context_t* contexts;
  3844. } _sdtx_context_pool_t;
  3845. typedef struct {
  3846. uint32_t init_cookie;
  3847. sdtx_desc_t desc;
  3848. sg_image font_img;
  3849. sg_view font_view;
  3850. sg_sampler font_smp;
  3851. sg_shader shader;
  3852. uint32_t fmt_buf_size;
  3853. char* fmt_buf;
  3854. sdtx_context def_ctx_id;
  3855. sdtx_context cur_ctx_id;
  3856. _sdtx_context_t* cur_ctx; // may be 0!
  3857. _sdtx_context_pool_t context_pool;
  3858. uint8_t font_pixels[SDTX_MAX_FONTS * 256 * 8 * 8];
  3859. } _sdtx_t;
  3860. static _sdtx_t _sdtx;
  3861. // ██ ██████ ██████ ██████ ██ ███ ██ ██████
  3862. // ██ ██ ██ ██ ██ ██ ████ ██ ██
  3863. // ██ ██ ██ ██ ███ ██ ███ ██ ██ ██ ██ ██ ███
  3864. // ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██
  3865. // ███████ ██████ ██████ ██████ ██ ██ ████ ██████
  3866. //
  3867. // >>logging
  3868. #if defined(SOKOL_DEBUG)
  3869. #define _SDTX_LOGITEM_XMACRO(item,msg) #item ": " msg,
  3870. static const char* _sdtx_log_messages[] = {
  3871. _SDTX_LOG_ITEMS
  3872. };
  3873. #undef _SDTX_LOGITEM_XMACRO
  3874. #endif // SOKOL_DEBUG
  3875. #define _SDTX_PANIC(code) _sdtx_log(SDTX_LOGITEM_ ##code, 0, __LINE__)
  3876. #define _SDTX_ERROR(code) _sdtx_log(SDTX_LOGITEM_ ##code, 1, __LINE__)
  3877. #define _SDTX_WARN(code) _sdtx_log(SDTX_LOGITEM_ ##code, 2, __LINE__)
  3878. #define _SDTX_INFO(code) _sdtx_log(SDTX_LOGITEM_ ##code, 3, __LINE__)
  3879. static void _sdtx_log(sdtx_log_item_t log_item, uint32_t log_level, uint32_t line_nr) {
  3880. if (_sdtx.desc.logger.func) {
  3881. #if defined(SOKOL_DEBUG)
  3882. const char* filename = __FILE__;
  3883. const char* message = _sdtx_log_messages[log_item];
  3884. #else
  3885. const char* filename = 0;
  3886. const char* message = 0;
  3887. #endif
  3888. _sdtx.desc.logger.func("sdtx", log_level, (uint32_t)log_item, message, line_nr, filename, _sdtx.desc.logger.user_data);
  3889. } else {
  3890. // for log level PANIC it would be 'undefined behaviour' to continue
  3891. if (log_level == 0) {
  3892. abort();
  3893. }
  3894. }
  3895. }
  3896. // ███ ███ ███████ ███ ███ ██████ ██████ ██ ██
  3897. // ████ ████ ██ ████ ████ ██ ██ ██ ██ ██ ██
  3898. // ██ ████ ██ █████ ██ ████ ██ ██ ██ ██████ ████
  3899. // ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██
  3900. // ██ ██ ███████ ██ ██ ██████ ██ ██ ██
  3901. //
  3902. // >>memory
  3903. static void _sdtx_clear(void* ptr, size_t size) {
  3904. SOKOL_ASSERT(ptr && (size > 0));
  3905. memset(ptr, 0, size);
  3906. }
  3907. static void* _sdtx_malloc(size_t size) {
  3908. SOKOL_ASSERT(size > 0);
  3909. void* ptr;
  3910. if (_sdtx.desc.allocator.alloc_fn) {
  3911. ptr = _sdtx.desc.allocator.alloc_fn(size, _sdtx.desc.allocator.user_data);
  3912. } else {
  3913. ptr = malloc(size);
  3914. }
  3915. if (0 == ptr) {
  3916. _SDTX_PANIC(MALLOC_FAILED);
  3917. }
  3918. return ptr;
  3919. }
  3920. static void* _sdtx_malloc_clear(size_t size) {
  3921. void* ptr = _sdtx_malloc(size);
  3922. _sdtx_clear(ptr, size);
  3923. return ptr;
  3924. }
  3925. static void _sdtx_free(void* ptr) {
  3926. if (_sdtx.desc.allocator.free_fn) {
  3927. _sdtx.desc.allocator.free_fn(ptr, _sdtx.desc.allocator.user_data);
  3928. } else {
  3929. free(ptr);
  3930. }
  3931. }
  3932. // ██████ ██████ ███ ██ ████████ ███████ ██ ██ ████████ ██████ ██████ ██████ ██
  3933. // ██ ██ ██ ████ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██
  3934. // ██ ██ ██ ██ ██ ██ ██ █████ ███ ██ ██████ ██ ██ ██ ██ ██
  3935. // ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██
  3936. // ██████ ██████ ██ ████ ██ ███████ ██ ██ ██ ██ ██████ ██████ ███████
  3937. //
  3938. // >>context pool
  3939. static void _sdtx_init_pool(_sdtx_pool_t* pool, int num) {
  3940. SOKOL_ASSERT(pool && (num >= 1));
  3941. // slot 0 is reserved for the 'invalid id', so bump the pool size by 1
  3942. pool->size = num + 1;
  3943. pool->queue_top = 0;
  3944. // generation counters indexable by pool slot index, slot 0 is reserved
  3945. size_t gen_ctrs_size = sizeof(uint32_t) * (size_t)pool->size;
  3946. pool->gen_ctrs = (uint32_t*) _sdtx_malloc_clear(gen_ctrs_size);
  3947. // it's not a bug to only reserve 'num' here
  3948. pool->free_queue = (int*) _sdtx_malloc_clear(sizeof(int) * (size_t)num);
  3949. // never allocate the zero-th pool item since the invalid id is 0
  3950. for (int i = pool->size-1; i >= 1; i--) {
  3951. pool->free_queue[pool->queue_top++] = i;
  3952. }
  3953. }
  3954. static void _sdtx_discard_pool(_sdtx_pool_t* pool) {
  3955. SOKOL_ASSERT(pool);
  3956. SOKOL_ASSERT(pool->free_queue);
  3957. _sdtx_free(pool->free_queue);
  3958. pool->free_queue = 0;
  3959. SOKOL_ASSERT(pool->gen_ctrs);
  3960. _sdtx_free(pool->gen_ctrs);
  3961. pool->gen_ctrs = 0;
  3962. pool->size = 0;
  3963. pool->queue_top = 0;
  3964. }
  3965. static int _sdtx_pool_alloc_index(_sdtx_pool_t* pool) {
  3966. SOKOL_ASSERT(pool);
  3967. SOKOL_ASSERT(pool->free_queue);
  3968. if (pool->queue_top > 0) {
  3969. int slot_index = pool->free_queue[--pool->queue_top];
  3970. SOKOL_ASSERT((slot_index > 0) && (slot_index < pool->size));
  3971. return slot_index;
  3972. } else {
  3973. // pool exhausted
  3974. return _SDTX_INVALID_SLOT_INDEX;
  3975. }
  3976. }
  3977. static void _sdtx_pool_free_index(_sdtx_pool_t* pool, int slot_index) {
  3978. SOKOL_ASSERT((slot_index > _SDTX_INVALID_SLOT_INDEX) && (slot_index < pool->size));
  3979. SOKOL_ASSERT(pool);
  3980. SOKOL_ASSERT(pool->free_queue);
  3981. SOKOL_ASSERT(pool->queue_top < pool->size);
  3982. #ifdef SOKOL_DEBUG
  3983. // debug check against double-free
  3984. for (int i = 0; i < pool->queue_top; i++) {
  3985. SOKOL_ASSERT(pool->free_queue[i] != slot_index);
  3986. }
  3987. #endif
  3988. pool->free_queue[pool->queue_top++] = slot_index;
  3989. SOKOL_ASSERT(pool->queue_top <= (pool->size-1));
  3990. }
  3991. static void _sdtx_setup_context_pool(const sdtx_desc_t* desc) {
  3992. SOKOL_ASSERT(desc);
  3993. // note: the pool will have an additional item, since slot 0 is reserved
  3994. SOKOL_ASSERT((desc->context_pool_size > 0) && (desc->context_pool_size < _SDTX_MAX_POOL_SIZE));
  3995. _sdtx_init_pool(&_sdtx.context_pool.pool, desc->context_pool_size);
  3996. size_t pool_byte_size = sizeof(_sdtx_context_t) * (size_t)_sdtx.context_pool.pool.size;
  3997. _sdtx.context_pool.contexts = (_sdtx_context_t*) _sdtx_malloc_clear(pool_byte_size);
  3998. }
  3999. static void _sdtx_discard_context_pool(void) {
  4000. SOKOL_ASSERT(_sdtx.context_pool.contexts);
  4001. _sdtx_free(_sdtx.context_pool.contexts);
  4002. _sdtx.context_pool.contexts = 0;
  4003. _sdtx_discard_pool(&_sdtx.context_pool.pool);
  4004. }
  4005. /* allocate the slot at slot_index:
  4006. - bump the slot's generation counter
  4007. - create a resource id from the generation counter and slot index
  4008. - set the slot's id to this id
  4009. - set the slot's state to ALLOC
  4010. - return the resource id
  4011. */
  4012. static uint32_t _sdtx_slot_alloc(_sdtx_pool_t* pool, _sdtx_slot_t* slot, int slot_index) {
  4013. /* FIXME: add handling for an overflowing generation counter,
  4014. for now, just overflow (another option is to disable
  4015. the slot)
  4016. */
  4017. SOKOL_ASSERT(pool && pool->gen_ctrs);
  4018. SOKOL_ASSERT((slot_index > _SDTX_INVALID_SLOT_INDEX) && (slot_index < pool->size));
  4019. SOKOL_ASSERT((slot->state == SG_RESOURCESTATE_INITIAL) && (slot->id == SG_INVALID_ID));
  4020. uint32_t ctr = ++pool->gen_ctrs[slot_index];
  4021. slot->id = (ctr<<_SDTX_SLOT_SHIFT)|(slot_index & _SDTX_SLOT_MASK);
  4022. slot->state = SG_RESOURCESTATE_ALLOC;
  4023. return slot->id;
  4024. }
  4025. // extract slot index from id
  4026. static int _sdtx_slot_index(uint32_t id) {
  4027. int slot_index = (int) (id & _SDTX_SLOT_MASK);
  4028. SOKOL_ASSERT(_SDTX_INVALID_SLOT_INDEX != slot_index);
  4029. return slot_index;
  4030. }
  4031. // get context pointer without id-check
  4032. static _sdtx_context_t* _sdtx_context_at(uint32_t ctx_id) {
  4033. SOKOL_ASSERT(SG_INVALID_ID != ctx_id);
  4034. int slot_index = _sdtx_slot_index(ctx_id);
  4035. SOKOL_ASSERT((slot_index > _SDTX_INVALID_SLOT_INDEX) && (slot_index < _sdtx.context_pool.pool.size));
  4036. return &_sdtx.context_pool.contexts[slot_index];
  4037. }
  4038. // get context pointer with id-check, returns 0 if no match
  4039. static _sdtx_context_t* _sdtx_lookup_context(uint32_t ctx_id) {
  4040. if (SG_INVALID_ID != ctx_id) {
  4041. _sdtx_context_t* ctx = _sdtx_context_at(ctx_id);
  4042. if (ctx->slot.id == ctx_id) {
  4043. return ctx;
  4044. }
  4045. }
  4046. return 0;
  4047. }
  4048. // make context handle from raw uint32_t id
  4049. static sdtx_context _sdtx_make_ctx_id(uint32_t ctx_id) {
  4050. sdtx_context ctx;
  4051. ctx.id = ctx_id;
  4052. return ctx;
  4053. }
  4054. static sdtx_context _sdtx_alloc_context(void) {
  4055. sdtx_context ctx_id;
  4056. int slot_index = _sdtx_pool_alloc_index(&_sdtx.context_pool.pool);
  4057. if (_SDTX_INVALID_SLOT_INDEX != slot_index) {
  4058. ctx_id = _sdtx_make_ctx_id(_sdtx_slot_alloc(&_sdtx.context_pool.pool, &_sdtx.context_pool.contexts[slot_index].slot, slot_index));
  4059. } else {
  4060. // pool is exhausted
  4061. ctx_id = _sdtx_make_ctx_id(SG_INVALID_ID);
  4062. }
  4063. return ctx_id;
  4064. }
  4065. static sdtx_context_desc_t _sdtx_context_desc_defaults(const sdtx_context_desc_t* desc) {
  4066. sdtx_context_desc_t res = *desc;
  4067. res.max_commands = _sdtx_def(res.max_commands, _SDTX_DEFAULT_MAX_COMMANDS);
  4068. res.char_buf_size = _sdtx_def(res.char_buf_size, _SDTX_DEFAULT_CHAR_BUF_SIZE);
  4069. res.canvas_width = _sdtx_def(res.canvas_width, _SDTX_DEFAULT_CANVAS_WIDTH);
  4070. res.canvas_height = _sdtx_def(res.canvas_height, _SDTX_DEFAULT_CANVAS_HEIGHT);
  4071. res.tab_width = _sdtx_def(res.tab_width, _SDTX_DEFAULT_TAB_WIDTH);
  4072. // keep pixel format attrs are passed as is into pipeline creation
  4073. SOKOL_ASSERT(res.char_buf_size > 0);
  4074. SOKOL_ASSERT(!isnan(res.canvas_width));
  4075. SOKOL_ASSERT(!isnan(res.canvas_height));
  4076. SOKOL_ASSERT(res.canvas_width > 0.0f);
  4077. SOKOL_ASSERT(res.canvas_height > 0.0f);
  4078. return res;
  4079. }
  4080. static void _sdtx_set_layer(_sdtx_context_t* ctx, int layer_id);
  4081. static void _sdtx_rewind(_sdtx_context_t* ctx) {
  4082. SOKOL_ASSERT(ctx);
  4083. ctx->frame_id++;
  4084. ctx->vertices.next = 0;
  4085. ctx->commands.next = 0;
  4086. _sdtx_set_layer(ctx, 0);
  4087. ctx->cur_font = 0;
  4088. ctx->pos.x = 0.0f;
  4089. ctx->pos.y = 0.0f;
  4090. }
  4091. static void _sdtx_commit_listener(void* userdata) {
  4092. _sdtx_context_t* ctx = _sdtx_lookup_context((uint32_t)(uintptr_t)userdata);
  4093. if (ctx) {
  4094. _sdtx_rewind(ctx);
  4095. }
  4096. }
  4097. static sg_commit_listener _sdtx_make_commit_listener(_sdtx_context_t* ctx) {
  4098. sg_commit_listener listener = { _sdtx_commit_listener, (void*)(uintptr_t)(ctx->slot.id) };
  4099. return listener;
  4100. }
  4101. static void _sdtx_init_context(sdtx_context ctx_id, const sdtx_context_desc_t* in_desc) {
  4102. sg_push_debug_group("sokol-debugtext");
  4103. SOKOL_ASSERT((ctx_id.id != SG_INVALID_ID) && in_desc);
  4104. _sdtx_context_t* ctx = _sdtx_lookup_context(ctx_id.id);
  4105. SOKOL_ASSERT(ctx);
  4106. ctx->desc = _sdtx_context_desc_defaults(in_desc);
  4107. // NOTE: frame_id must be non-zero, so that updates trigger in first frame
  4108. ctx->frame_id = 1;
  4109. ctx->vertices.cap = 6 * ctx->desc.char_buf_size;
  4110. const size_t vbuf_size = (size_t)ctx->vertices.cap * sizeof(_sdtx_vertex_t);
  4111. ctx->vertices.ptr = (_sdtx_vertex_t*) _sdtx_malloc(vbuf_size);
  4112. ctx->commands.cap = ctx->desc.max_commands;
  4113. ctx->commands.ptr = (_sdtx_command_t*) _sdtx_malloc((size_t)ctx->commands.cap * sizeof(_sdtx_command_t));
  4114. _sdtx_set_layer(ctx, 0);
  4115. sg_buffer_desc vbuf_desc;
  4116. _sdtx_clear(&vbuf_desc, sizeof(vbuf_desc));
  4117. vbuf_desc.size = vbuf_size;
  4118. vbuf_desc.usage.vertex_buffer = true;
  4119. vbuf_desc.usage.stream_update = true;
  4120. vbuf_desc.label = "sdtx-vbuf";
  4121. ctx->vbuf = sg_make_buffer(&vbuf_desc);
  4122. SOKOL_ASSERT(SG_INVALID_ID != ctx->vbuf.id);
  4123. sg_pipeline_desc pip_desc;
  4124. _sdtx_clear(&pip_desc, sizeof(pip_desc));
  4125. pip_desc.layout.buffers[0].stride = sizeof(_sdtx_vertex_t);
  4126. pip_desc.layout.attrs[0].format = SG_VERTEXFORMAT_FLOAT2;
  4127. pip_desc.layout.attrs[1].format = SG_VERTEXFORMAT_USHORT2N;
  4128. pip_desc.layout.attrs[2].format = SG_VERTEXFORMAT_UBYTE4N;
  4129. pip_desc.shader = _sdtx.shader;
  4130. pip_desc.index_type = SG_INDEXTYPE_NONE;
  4131. pip_desc.sample_count = ctx->desc.sample_count;
  4132. pip_desc.depth.pixel_format = ctx->desc.depth_format;
  4133. pip_desc.colors[0].pixel_format = ctx->desc.color_format;
  4134. pip_desc.colors[0].blend.enabled = true;
  4135. pip_desc.colors[0].blend.src_factor_rgb = SG_BLENDFACTOR_SRC_ALPHA;
  4136. pip_desc.colors[0].blend.dst_factor_rgb = SG_BLENDFACTOR_ONE_MINUS_SRC_ALPHA;
  4137. pip_desc.colors[0].blend.src_factor_alpha = SG_BLENDFACTOR_ONE;
  4138. pip_desc.colors[0].blend.dst_factor_alpha = SG_BLENDFACTOR_ZERO;
  4139. pip_desc.label = "sdtx-pipeline";
  4140. ctx->pip = sg_make_pipeline(&pip_desc);
  4141. SOKOL_ASSERT(SG_INVALID_ID != ctx->pip.id);
  4142. ctx->canvas_size.x = ctx->desc.canvas_width;
  4143. ctx->canvas_size.y = ctx->desc.canvas_height;
  4144. ctx->glyph_size.x = 8.0f / ctx->canvas_size.x;
  4145. ctx->glyph_size.y = 8.0f / ctx->canvas_size.y;
  4146. ctx->tab_width = (float) ctx->desc.tab_width;
  4147. ctx->color = _SDTX_DEFAULT_COLOR;
  4148. if (!sg_add_commit_listener(_sdtx_make_commit_listener(ctx))) {
  4149. _SDTX_ERROR(ADD_COMMIT_LISTENER_FAILED);
  4150. }
  4151. sg_pop_debug_group();
  4152. }
  4153. static void _sdtx_destroy_context(sdtx_context ctx_id) {
  4154. _sdtx_context_t* ctx = _sdtx_lookup_context(ctx_id.id);
  4155. if (ctx) {
  4156. if (ctx->vertices.ptr) {
  4157. _sdtx_free(ctx->vertices.ptr);
  4158. ctx->vertices.ptr = 0;
  4159. ctx->vertices.cap = 0;
  4160. ctx->vertices.next = 0;
  4161. }
  4162. if (ctx->commands.ptr) {
  4163. _sdtx_free(ctx->commands.ptr);
  4164. ctx->commands.ptr = 0;
  4165. ctx->commands.cap = 0;
  4166. ctx->commands.next = 0;
  4167. }
  4168. sg_push_debug_group("sokol_debugtext");
  4169. sg_destroy_buffer(ctx->vbuf);
  4170. sg_destroy_pipeline(ctx->pip);
  4171. sg_remove_commit_listener(_sdtx_make_commit_listener(ctx));
  4172. sg_pop_debug_group();
  4173. _sdtx_clear(ctx, sizeof(*ctx));
  4174. _sdtx_pool_free_index(&_sdtx.context_pool.pool, _sdtx_slot_index(ctx_id.id));
  4175. }
  4176. }
  4177. static bool _sdtx_is_default_context(sdtx_context ctx_id) {
  4178. return ctx_id.id == SDTX_DEFAULT_CONTEXT.id;
  4179. }
  4180. // ███ ███ ██ ███████ ██████
  4181. // ████ ████ ██ ██ ██
  4182. // ██ ████ ██ ██ ███████ ██
  4183. // ██ ██ ██ ██ ██ ██
  4184. // ██ ██ ██ ███████ ██████
  4185. //
  4186. // >>misc
  4187. // unpack linear 8x8 bits-per-pixel font data into 2D byte-per-pixel texture data
  4188. static void _sdtx_unpack_font(const sdtx_font_desc_t* font_desc, uint8_t* out_pixels) {
  4189. SOKOL_ASSERT(font_desc->data.ptr);
  4190. SOKOL_ASSERT((font_desc->data.size > 0) && ((font_desc->data.size % 8) == 0));
  4191. SOKOL_ASSERT(font_desc->first_char <= font_desc->last_char);
  4192. SOKOL_ASSERT((size_t)(((font_desc->last_char - font_desc->first_char) + 1) * 8) == font_desc->data.size);
  4193. const uint8_t* ptr = (const uint8_t*) font_desc->data.ptr;
  4194. for (int chr = font_desc->first_char; chr <= font_desc->last_char; chr++) {
  4195. for (int line = 0; line < 8; line++) {
  4196. uint8_t bits = *ptr++;
  4197. for (int x = 0; x < 8; x++) {
  4198. out_pixels[line*256*8 + chr*8 + x] = ((bits>>(7-x)) & 1) ? 0xFF : 0x00;
  4199. }
  4200. }
  4201. }
  4202. }
  4203. static void _sdtx_setup_common(void) {
  4204. // common printf formatting buffer
  4205. _sdtx.fmt_buf_size = (uint32_t) _sdtx.desc.printf_buf_size + 1;
  4206. _sdtx.fmt_buf = (char*) _sdtx_malloc_clear(_sdtx.fmt_buf_size);
  4207. sg_push_debug_group("sokol-debugtext");
  4208. // common shader for all contexts
  4209. sg_shader_desc shd_desc;
  4210. _sdtx_clear(&shd_desc, sizeof(shd_desc));
  4211. shd_desc.label = "sokol-debugtext-shader";
  4212. shd_desc.attrs[0].glsl_name = "position";
  4213. shd_desc.attrs[1].glsl_name = "texcoord0";
  4214. shd_desc.attrs[2].glsl_name = "color0";
  4215. shd_desc.attrs[0].hlsl_sem_name = "TEXCOORD";
  4216. shd_desc.attrs[0].hlsl_sem_index = 0;
  4217. shd_desc.attrs[1].hlsl_sem_name = "TEXCOORD";
  4218. shd_desc.attrs[1].hlsl_sem_index = 1;
  4219. shd_desc.attrs[2].hlsl_sem_name = "TEXCOORD";
  4220. shd_desc.attrs[2].hlsl_sem_index = 2;
  4221. shd_desc.attrs[0].base_type = SG_SHADERATTRBASETYPE_FLOAT;
  4222. shd_desc.attrs[1].base_type = SG_SHADERATTRBASETYPE_FLOAT;
  4223. shd_desc.attrs[2].base_type = SG_SHADERATTRBASETYPE_FLOAT;
  4224. shd_desc.views[0].texture.stage = SG_SHADERSTAGE_FRAGMENT;
  4225. shd_desc.views[0].texture.image_type = SG_IMAGETYPE_2D;
  4226. shd_desc.views[0].texture.sample_type = SG_IMAGESAMPLETYPE_FLOAT;
  4227. shd_desc.views[0].texture.hlsl_register_t_n = 0;
  4228. shd_desc.views[0].texture.msl_texture_n = 0;
  4229. shd_desc.views[0].texture.wgsl_group1_binding_n = 0;
  4230. shd_desc.views[0].texture.spirv_set1_binding_n = 0;
  4231. shd_desc.samplers[0].stage = SG_SHADERSTAGE_FRAGMENT;
  4232. shd_desc.samplers[0].sampler_type = SG_SAMPLERTYPE_FILTERING;
  4233. shd_desc.samplers[0].hlsl_register_s_n = 0;
  4234. shd_desc.samplers[0].msl_sampler_n = 0;
  4235. shd_desc.samplers[0].wgsl_group1_binding_n = 32;
  4236. shd_desc.samplers[0].spirv_set1_binding_n = 32;
  4237. shd_desc.texture_sampler_pairs[0].stage = SG_SHADERSTAGE_FRAGMENT;
  4238. shd_desc.texture_sampler_pairs[0].view_slot = 0;
  4239. shd_desc.texture_sampler_pairs[0].sampler_slot = 0;
  4240. shd_desc.texture_sampler_pairs[0].glsl_name = "tex_smp";
  4241. #if defined(SOKOL_GLCORE)
  4242. shd_desc.vertex_func.source = (const char*)_sdtx_vs_source_glsl410;
  4243. shd_desc.fragment_func.source = (const char*)_sdtx_fs_source_glsl410;
  4244. #elif defined(SOKOL_GLES3)
  4245. shd_desc.vertex_func.source = (const char*)_sdtx_vs_source_glsl300es;
  4246. shd_desc.fragment_func.source = (const char*)_sdtx_fs_source_glsl300es;
  4247. #elif defined(SOKOL_METAL)
  4248. shd_desc.vertex_func.entry = "main0";
  4249. shd_desc.fragment_func.entry = "main0";
  4250. switch (sg_query_backend()) {
  4251. case SG_BACKEND_METAL_MACOS:
  4252. shd_desc.vertex_func.bytecode = SG_RANGE(_sdtx_vs_bytecode_metal_macos);
  4253. shd_desc.fragment_func.bytecode = SG_RANGE(_sdtx_fs_bytecode_metal_macos);
  4254. break;
  4255. case SG_BACKEND_METAL_IOS:
  4256. shd_desc.vertex_func.bytecode = SG_RANGE(_sdtx_vs_bytecode_metal_ios);
  4257. shd_desc.fragment_func.bytecode = SG_RANGE(_sdtx_fs_bytecode_metal_ios);
  4258. break;
  4259. default:
  4260. shd_desc.vertex_func.source = (const char*)_sdtx_vs_source_metal_sim;
  4261. shd_desc.fragment_func.source = (const char*)_sdtx_fs_source_metal_sim;
  4262. break;
  4263. }
  4264. #elif defined(SOKOL_D3D11)
  4265. shd_desc.vertex_func.bytecode = SG_RANGE(_sdtx_vs_bytecode_hlsl4);
  4266. shd_desc.fragment_func.bytecode = SG_RANGE(_sdtx_fs_bytecode_hlsl4);
  4267. #elif defined(SOKOL_WGPU)
  4268. shd_desc.vertex_func.source = (const char*)_sdtx_vs_source_wgsl;
  4269. shd_desc.fragment_func.source = (const char*)_sdtx_fs_source_wgsl;
  4270. #elif defined(SOKOL_VULKAN)
  4271. shd_desc.vertex_func.bytecode = SG_RANGE(_sdtx_vs_bytecode_spirv_vk);
  4272. shd_desc.vertex_func.entry = "main";
  4273. shd_desc.fragment_func.bytecode = SG_RANGE(_sdtx_fs_bytecode_spirv_vk);
  4274. shd_desc.fragment_func.entry = "main";
  4275. #else
  4276. shd_desc.vertex_func.source = _sdtx_vs_src_dummy;
  4277. shd_desc.fragment_func.source = _sdtx_fs_src_dummy;
  4278. #endif
  4279. _sdtx.shader = sg_make_shader(&shd_desc);
  4280. SOKOL_ASSERT(SG_INVALID_ID != _sdtx.shader.id);
  4281. // unpack font data
  4282. memset(_sdtx.font_pixels, 0xFF, sizeof(_sdtx.font_pixels));
  4283. const int unpacked_font_size = (int) (sizeof(_sdtx.font_pixels) / SDTX_MAX_FONTS);
  4284. for (int i = 0; i < SDTX_MAX_FONTS; i++) {
  4285. if (_sdtx.desc.fonts[i].data.ptr) {
  4286. _sdtx_unpack_font(&_sdtx.desc.fonts[i], &_sdtx.font_pixels[i * unpacked_font_size]);
  4287. }
  4288. }
  4289. // create font image, texture view and sampler
  4290. sg_image_desc img_desc;
  4291. _sdtx_clear(&img_desc, sizeof(img_desc));
  4292. img_desc.width = 256 * 8;
  4293. img_desc.height = SDTX_MAX_FONTS * 8;
  4294. img_desc.pixel_format = SG_PIXELFORMAT_R8;
  4295. img_desc.data.mip_levels[0] = SG_RANGE(_sdtx.font_pixels);
  4296. img_desc.label = "sdtx-font-texture";
  4297. _sdtx.font_img = sg_make_image(&img_desc);
  4298. SOKOL_ASSERT(SG_INVALID_ID != _sdtx.font_img.id);
  4299. sg_view_desc view_desc;
  4300. _sdtx_clear(&view_desc, sizeof(view_desc));
  4301. view_desc.texture.image = _sdtx.font_img;
  4302. view_desc.label = "sdtx-font-texture-view";
  4303. _sdtx.font_view = sg_make_view(&view_desc);
  4304. SOKOL_ASSERT(SG_INVALID_ID != _sdtx.font_view.id);
  4305. sg_sampler_desc smp_desc;
  4306. _sdtx_clear(&smp_desc, sizeof(smp_desc));
  4307. smp_desc.min_filter = SG_FILTER_NEAREST;
  4308. smp_desc.mag_filter = SG_FILTER_NEAREST;
  4309. smp_desc.wrap_u = SG_WRAP_CLAMP_TO_EDGE;
  4310. smp_desc.wrap_v = SG_WRAP_CLAMP_TO_EDGE;
  4311. smp_desc.label = "sdtx-font-sampler";
  4312. _sdtx.font_smp = sg_make_sampler(&smp_desc);
  4313. SOKOL_ASSERT(SG_INVALID_ID != _sdtx.font_smp.id);
  4314. sg_pop_debug_group();
  4315. }
  4316. static void _sdtx_discard_common(void) {
  4317. sg_push_debug_group("sokol-debugtext");
  4318. sg_destroy_sampler(_sdtx.font_smp);
  4319. sg_destroy_view(_sdtx.font_view);
  4320. sg_destroy_image(_sdtx.font_img);
  4321. sg_destroy_shader(_sdtx.shader);
  4322. if (_sdtx.fmt_buf) {
  4323. _sdtx_free(_sdtx.fmt_buf);
  4324. _sdtx.fmt_buf = 0;
  4325. }
  4326. sg_pop_debug_group();
  4327. }
  4328. static uint32_t _sdtx_pack_rgbab(uint8_t r, uint8_t g, uint8_t b, uint8_t a) {
  4329. return (uint32_t)(((uint32_t)a<<24)|((uint32_t)b<<16)|((uint32_t)g<<8)|r);
  4330. }
  4331. static float _sdtx_clamp(float v, float lo, float hi) {
  4332. if (v < lo) return lo;
  4333. else if (v > hi) return hi;
  4334. else return v;
  4335. }
  4336. static uint32_t _sdtx_pack_rgbaf(float r, float g, float b, float a) {
  4337. uint8_t r_u8 = (uint8_t) (_sdtx_clamp(r, 0.0f, 1.0f) * 255.0f);
  4338. uint8_t g_u8 = (uint8_t) (_sdtx_clamp(g, 0.0f, 1.0f) * 255.0f);
  4339. uint8_t b_u8 = (uint8_t) (_sdtx_clamp(b, 0.0f, 1.0f) * 255.0f);
  4340. uint8_t a_u8 = (uint8_t) (_sdtx_clamp(a, 0.0f, 1.0f) * 255.0f);
  4341. return _sdtx_pack_rgbab(r_u8, g_u8, b_u8, a_u8);
  4342. }
  4343. static void _sdtx_ctrl_char(_sdtx_context_t* ctx, uint8_t c) {
  4344. switch (c) {
  4345. case '\r':
  4346. ctx->pos.x = 0.0f;
  4347. break;
  4348. case '\n':
  4349. ctx->pos.x = 0.0f;
  4350. ctx->pos.y += 1.0f;
  4351. break;
  4352. case '\t':
  4353. ctx->pos.x = (ctx->pos.x - fmodf(ctx->pos.x, ctx->tab_width)) + ctx->tab_width;
  4354. break;
  4355. case ' ':
  4356. ctx->pos.x += 1.0f;
  4357. break;
  4358. }
  4359. }
  4360. static _sdtx_vertex_t* _sdtx_next_vertex(_sdtx_context_t* ctx) {
  4361. if ((ctx->vertices.next + 6) <= ctx->vertices.cap) {
  4362. _sdtx_vertex_t* vx = &ctx->vertices.ptr[ctx->vertices.next];
  4363. ctx->vertices.next += 6;
  4364. return vx;
  4365. } else {
  4366. return 0;
  4367. }
  4368. }
  4369. static _sdtx_command_t* _sdtx_cur_command(_sdtx_context_t* ctx) {
  4370. if (ctx->commands.next > 0) {
  4371. return &ctx->commands.ptr[ctx->commands.next - 1];
  4372. } else {
  4373. return 0;
  4374. }
  4375. }
  4376. static _sdtx_command_t* _sdtx_next_command(_sdtx_context_t* ctx) {
  4377. if (ctx->commands.next < ctx->commands.cap) {
  4378. return &ctx->commands.ptr[ctx->commands.next++];
  4379. } else {
  4380. _SDTX_ERROR(COMMAND_BUFFER_FULL);
  4381. return 0;
  4382. }
  4383. }
  4384. static void _sdtx_set_layer(_sdtx_context_t* ctx, int layer_id) {
  4385. ctx->cur_layer_id = layer_id;
  4386. _sdtx_command_t* cur_cmd = _sdtx_cur_command(ctx);
  4387. if (cur_cmd) {
  4388. if ((cur_cmd->num_vertices == 0) || (cur_cmd->layer_id == layer_id)) {
  4389. // no vertices recorded in current draw command, or layer hasn't changed, can just reuse this
  4390. cur_cmd->layer_id = layer_id;
  4391. } else {
  4392. // layer has changed, need to start a new draw command
  4393. _sdtx_command_t* next_cmd = _sdtx_next_command(ctx);
  4394. if (next_cmd) {
  4395. next_cmd->layer_id = layer_id;
  4396. next_cmd->first_vertex = cur_cmd->first_vertex + cur_cmd->num_vertices;
  4397. next_cmd->num_vertices = 0;
  4398. }
  4399. }
  4400. } else {
  4401. // first draw command in frame
  4402. _sdtx_command_t* next_cmd = _sdtx_next_command(ctx);
  4403. if (next_cmd) {
  4404. next_cmd->layer_id = layer_id;
  4405. next_cmd->first_vertex = 0;
  4406. next_cmd->num_vertices = 0;
  4407. }
  4408. }
  4409. }
  4410. static void _sdtx_render_char(_sdtx_context_t* ctx, uint8_t c) {
  4411. _sdtx_vertex_t* vx = _sdtx_next_vertex(ctx);
  4412. _sdtx_command_t* cmd = _sdtx_cur_command(ctx);
  4413. if (vx && cmd) {
  4414. // update vertex count in current draw command
  4415. cmd->num_vertices += 6;
  4416. const float x0 = (ctx->origin.x + ctx->pos.x) * ctx->glyph_size.x;
  4417. const float y0 = (ctx->origin.y + ctx->pos.y) * ctx->glyph_size.y;
  4418. const float x1 = x0 + ctx->glyph_size.x;
  4419. const float y1 = y0 + ctx->glyph_size.y;
  4420. // glyph width and height in font texture space
  4421. // NOTE: the '+1' and '-2' fixes texture bleeding into the neighboring font texture cell
  4422. const uint16_t uvw = 0x10000 / 0x100;
  4423. const uint16_t uvh = 0x10000 / SDTX_MAX_FONTS;
  4424. const uint16_t u0 = (((uint16_t)c) * uvw) + 1;
  4425. const uint16_t v0 = (((uint16_t)ctx->cur_font) * uvh) + 1;
  4426. uint16_t u1 = (u0 + uvw) - 2;
  4427. uint16_t v1 = (v0 + uvh) - 2;
  4428. const uint32_t color = ctx->color;
  4429. // write 6 vertices
  4430. vx->x=x0; vx->y=y0; vx->u = u0; vx->v = v0; vx->color = color; vx++;
  4431. vx->x=x1; vx->y=y0; vx->u = u1; vx->v = v0; vx->color = color; vx++;
  4432. vx->x=x1; vx->y=y1; vx->u = u1; vx->v = v1; vx->color = color; vx++;
  4433. vx->x=x0; vx->y=y0; vx->u = u0; vx->v = v0; vx->color = color; vx++;
  4434. vx->x=x1; vx->y=y1; vx->u = u1; vx->v = v1; vx->color = color; vx++;
  4435. vx->x=x0; vx->y=y1; vx->u = u0; vx->v = v1; vx->color = color; vx++;
  4436. }
  4437. ctx->pos.x += 1.0f;
  4438. }
  4439. static void _sdtx_put_char(_sdtx_context_t* ctx, char c) {
  4440. uint8_t c_u8 = (uint8_t)c;
  4441. if (c_u8 <= 32) {
  4442. _sdtx_ctrl_char(ctx, c_u8);
  4443. } else {
  4444. _sdtx_render_char(ctx, c_u8);
  4445. }
  4446. }
  4447. SOKOL_API_IMPL void _sdtx_draw_layer(_sdtx_context_t* ctx, int layer_id) {
  4448. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4449. SOKOL_ASSERT(ctx);
  4450. if ((ctx->vertices.next > 0) && (ctx->commands.next > 0)) {
  4451. sg_push_debug_group("sokol-debugtext");
  4452. if (ctx->update_frame_id != ctx->frame_id) {
  4453. ctx->update_frame_id = ctx->frame_id;
  4454. const sg_range range = { ctx->vertices.ptr, (size_t)ctx->vertices.next * sizeof(_sdtx_vertex_t) };
  4455. sg_update_buffer(ctx->vbuf, &range);
  4456. }
  4457. sg_apply_pipeline(ctx->pip);
  4458. sg_bindings bindings;
  4459. _sdtx_clear(&bindings, sizeof(bindings));
  4460. bindings.vertex_buffers[0] = ctx->vbuf;
  4461. bindings.views[0] = _sdtx.font_view;
  4462. bindings.samplers[0] = _sdtx.font_smp;
  4463. sg_apply_bindings(&bindings);
  4464. for (int cmd_index = 0; cmd_index < ctx->commands.next; cmd_index++) {
  4465. const _sdtx_command_t* cmd = &ctx->commands.ptr[cmd_index];
  4466. if (cmd->layer_id != layer_id) {
  4467. continue;
  4468. }
  4469. SOKOL_ASSERT((cmd->num_vertices % 6) == 0);
  4470. sg_draw(cmd->first_vertex, cmd->num_vertices, 1);
  4471. }
  4472. sg_pop_debug_group();
  4473. }
  4474. }
  4475. static sdtx_desc_t _sdtx_desc_defaults(const sdtx_desc_t* desc) {
  4476. SOKOL_ASSERT((desc->allocator.alloc_fn && desc->allocator.free_fn) || (!desc->allocator.alloc_fn && !desc->allocator.free_fn));
  4477. sdtx_desc_t res = *desc;
  4478. res.context_pool_size = _sdtx_def(res.context_pool_size, _SDTX_DEFAULT_CONTEXT_POOL_SIZE);
  4479. res.printf_buf_size = _sdtx_def(res.printf_buf_size, _SDTX_DEFAULT_PRINTF_BUF_SIZE);
  4480. for (int i = 0; i < SDTX_MAX_FONTS; i++) {
  4481. if (res.fonts[i].data.ptr) {
  4482. res.fonts[i].last_char = _sdtx_def(res.fonts[i].last_char, 255);
  4483. }
  4484. }
  4485. res.context = _sdtx_context_desc_defaults(&res.context);
  4486. SOKOL_ASSERT(res.context_pool_size > 0);
  4487. SOKOL_ASSERT(res.printf_buf_size > 0);
  4488. SOKOL_ASSERT(res.context.char_buf_size > 0);
  4489. return res;
  4490. }
  4491. // ██████ ██ ██ ██████ ██ ██ ██████
  4492. // ██ ██ ██ ██ ██ ██ ██ ██ ██
  4493. // ██████ ██ ██ ██████ ██ ██ ██
  4494. // ██ ██ ██ ██ ██ ██ ██ ██
  4495. // ██ ██████ ██████ ███████ ██ ██████
  4496. //
  4497. // >>public
  4498. SOKOL_API_IMPL void sdtx_setup(const sdtx_desc_t* desc) {
  4499. SOKOL_ASSERT(desc);
  4500. _sdtx_clear(&_sdtx, sizeof(_sdtx));
  4501. _sdtx.init_cookie = _SDTX_INIT_COOKIE;
  4502. _sdtx.desc = _sdtx_desc_defaults(desc);
  4503. _sdtx_setup_context_pool(&_sdtx.desc);
  4504. _sdtx_setup_common();
  4505. _sdtx.def_ctx_id = sdtx_make_context(&_sdtx.desc.context);
  4506. SOKOL_ASSERT(SDTX_DEFAULT_CONTEXT.id == _sdtx.def_ctx_id.id);
  4507. sdtx_set_context(_sdtx.def_ctx_id);
  4508. }
  4509. SOKOL_API_IMPL void sdtx_shutdown(void) {
  4510. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4511. for (int i = 0; i < _sdtx.context_pool.pool.size; i++) {
  4512. _sdtx_context_t* ctx = &_sdtx.context_pool.contexts[i];
  4513. _sdtx_destroy_context(_sdtx_make_ctx_id(ctx->slot.id));
  4514. }
  4515. _sdtx_discard_common();
  4516. _sdtx_discard_context_pool();
  4517. _sdtx.init_cookie = 0;
  4518. }
  4519. SOKOL_API_IMPL sdtx_font_desc_t sdtx_font_kc853(void) {
  4520. sdtx_font_desc_t desc = { { _sdtx_font_kc853, sizeof(_sdtx_font_kc853) }, 0, 255 };
  4521. return desc;
  4522. }
  4523. SOKOL_API_IMPL sdtx_font_desc_t sdtx_font_kc854(void) {
  4524. sdtx_font_desc_t desc = { { _sdtx_font_kc854, sizeof(_sdtx_font_kc854) }, 0, 255 };
  4525. return desc;
  4526. }
  4527. SOKOL_API_IMPL sdtx_font_desc_t sdtx_font_z1013(void) {
  4528. sdtx_font_desc_t desc = { { _sdtx_font_z1013, sizeof(_sdtx_font_z1013) }, 0, 255 };
  4529. return desc;
  4530. }
  4531. SOKOL_API_IMPL sdtx_font_desc_t sdtx_font_cpc(void) {
  4532. sdtx_font_desc_t desc = { { _sdtx_font_cpc, sizeof(_sdtx_font_cpc) }, 0, 255 };
  4533. return desc;
  4534. }
  4535. SOKOL_API_IMPL sdtx_font_desc_t sdtx_font_c64(void) {
  4536. sdtx_font_desc_t desc = { { _sdtx_font_c64, sizeof(_sdtx_font_c64) }, 0, 255 };
  4537. return desc;
  4538. }
  4539. SOKOL_API_IMPL sdtx_font_desc_t sdtx_font_oric(void) {
  4540. sdtx_font_desc_t desc = { { _sdtx_font_oric, sizeof(_sdtx_font_oric) }, 0, 255 };
  4541. return desc;
  4542. }
  4543. SOKOL_API_IMPL sdtx_context sdtx_make_context(const sdtx_context_desc_t* desc) {
  4544. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4545. SOKOL_ASSERT(desc);
  4546. sdtx_context ctx_id = _sdtx_alloc_context();
  4547. if (ctx_id.id != SG_INVALID_ID) {
  4548. _sdtx_init_context(ctx_id, desc);
  4549. } else {
  4550. _SDTX_ERROR(CONTEXT_POOL_EXHAUSTED);
  4551. }
  4552. return ctx_id;
  4553. }
  4554. SOKOL_API_IMPL void sdtx_destroy_context(sdtx_context ctx_id) {
  4555. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4556. if (_sdtx_is_default_context(ctx_id)) {
  4557. _SDTX_ERROR(CANNOT_DESTROY_DEFAULT_CONTEXT);
  4558. return;
  4559. }
  4560. _sdtx_destroy_context(ctx_id);
  4561. // re-validate the current context pointer (this will return a nullptr
  4562. // if we just destroyed the current context)
  4563. _sdtx.cur_ctx = _sdtx_lookup_context(_sdtx.cur_ctx_id.id);
  4564. }
  4565. SOKOL_API_IMPL void sdtx_set_context(sdtx_context ctx_id) {
  4566. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4567. if (_sdtx_is_default_context(ctx_id)) {
  4568. _sdtx.cur_ctx_id = _sdtx.def_ctx_id;
  4569. } else {
  4570. _sdtx.cur_ctx_id = ctx_id;
  4571. }
  4572. // this may return a nullptr if the ctx_id handle is invalid
  4573. _sdtx.cur_ctx = _sdtx_lookup_context(_sdtx.cur_ctx_id.id);
  4574. }
  4575. SOKOL_API_IMPL sdtx_context sdtx_get_context(void) {
  4576. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4577. return _sdtx.cur_ctx_id;
  4578. }
  4579. SOKOL_API_IMPL sdtx_context sdtx_default_context(void) {
  4580. return SDTX_DEFAULT_CONTEXT;
  4581. }
  4582. SOKOL_API_IMPL void sdtx_layer(int layer_id) {
  4583. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4584. _sdtx_context_t* ctx = _sdtx.cur_ctx;
  4585. if (ctx) {
  4586. _sdtx_set_layer(ctx, layer_id);
  4587. }
  4588. }
  4589. SOKOL_API_IMPL void sdtx_font(int font_index) {
  4590. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4591. SOKOL_ASSERT((font_index >= 0) && (font_index < SDTX_MAX_FONTS));
  4592. _sdtx_context_t* ctx = _sdtx.cur_ctx;
  4593. if (ctx) {
  4594. ctx->cur_font = font_index;
  4595. }
  4596. }
  4597. SOKOL_API_IMPL void sdtx_canvas(float w, float h) {
  4598. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4599. SOKOL_ASSERT(!isnan(w));
  4600. SOKOL_ASSERT(!isnan(h));
  4601. SOKOL_ASSERT((w > 0.0f) && (h > 0.0f));
  4602. _sdtx_context_t* ctx = _sdtx.cur_ctx;
  4603. if (ctx) {
  4604. ctx->canvas_size.x = w;
  4605. ctx->canvas_size.y = h;
  4606. ctx->glyph_size.x = (8.0f / ctx->canvas_size.x);
  4607. ctx->glyph_size.y = (8.0f / ctx->canvas_size.y);
  4608. ctx->origin.x = 0.0f;
  4609. ctx->origin.y = 0.0f;
  4610. ctx->pos.x = 0.0f;
  4611. ctx->pos.y = 0.0f;
  4612. }
  4613. }
  4614. SOKOL_API_IMPL void sdtx_origin(float x, float y) {
  4615. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4616. _sdtx_context_t* ctx = _sdtx.cur_ctx;
  4617. if (ctx) {
  4618. ctx->origin.x = x;
  4619. ctx->origin.y = y;
  4620. }
  4621. }
  4622. SOKOL_API_IMPL void sdtx_home(void) {
  4623. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4624. _sdtx_context_t* ctx = _sdtx.cur_ctx;
  4625. if (ctx) {
  4626. ctx->pos.x = 0.0f;
  4627. ctx->pos.y = 0.0f;
  4628. }
  4629. }
  4630. SOKOL_API_IMPL void sdtx_pos(float x, float y) {
  4631. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4632. _sdtx_context_t* ctx = _sdtx.cur_ctx;
  4633. if (ctx) {
  4634. ctx->pos.x = x;
  4635. ctx->pos.y = y;
  4636. }
  4637. }
  4638. SOKOL_API_IMPL void sdtx_pos_x(float x) {
  4639. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4640. _sdtx_context_t* ctx = _sdtx.cur_ctx;
  4641. if (ctx) {
  4642. ctx->pos.x = x;
  4643. }
  4644. }
  4645. SOKOL_API_IMPL void sdtx_pos_y(float y) {
  4646. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4647. _sdtx_context_t* ctx = _sdtx.cur_ctx;
  4648. if (ctx) {
  4649. ctx->pos.y = y;
  4650. }
  4651. }
  4652. SOKOL_API_IMPL void sdtx_move(float dx, float dy) {
  4653. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4654. _sdtx_context_t* ctx = _sdtx.cur_ctx;
  4655. if (ctx) {
  4656. ctx->pos.x += dx;
  4657. ctx->pos.y += dy;
  4658. }
  4659. }
  4660. SOKOL_API_IMPL void sdtx_move_x(float dx) {
  4661. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4662. _sdtx_context_t* ctx = _sdtx.cur_ctx;
  4663. if (ctx) {
  4664. ctx->pos.x += dx;
  4665. }
  4666. }
  4667. SOKOL_API_IMPL void sdtx_move_y(float dy) {
  4668. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4669. _sdtx_context_t* ctx = _sdtx.cur_ctx;
  4670. if (ctx) {
  4671. ctx->pos.y += dy;
  4672. }
  4673. }
  4674. SOKOL_API_IMPL void sdtx_crlf(void) {
  4675. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4676. _sdtx_context_t* ctx = _sdtx.cur_ctx;
  4677. if (ctx) {
  4678. ctx->pos.x = 0.0f;
  4679. ctx->pos.y += 1.0f;
  4680. }
  4681. }
  4682. SOKOL_API_IMPL void sdtx_color3b(uint8_t r, uint8_t g, uint8_t b) {
  4683. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4684. _sdtx_context_t* ctx = _sdtx.cur_ctx;
  4685. if (ctx) {
  4686. ctx->color = _sdtx_pack_rgbab(r, g, b, 255);
  4687. }
  4688. }
  4689. SOKOL_API_IMPL void sdtx_color3f(float r, float g, float b) {
  4690. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4691. _sdtx_context_t* ctx = _sdtx.cur_ctx;
  4692. if (ctx) {
  4693. ctx->color = _sdtx_pack_rgbaf(r, g, b, 1.0f);
  4694. }
  4695. }
  4696. SOKOL_API_IMPL void sdtx_color4b(uint8_t r, uint8_t g, uint8_t b, uint8_t a) {
  4697. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4698. _sdtx_context_t* ctx = _sdtx.cur_ctx;
  4699. if (ctx) {
  4700. ctx->color = _sdtx_pack_rgbab(r, g, b, a);
  4701. }
  4702. }
  4703. SOKOL_API_IMPL void sdtx_color4f(float r, float g, float b, float a) {
  4704. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4705. _sdtx_context_t* ctx = _sdtx.cur_ctx;
  4706. if (ctx) {
  4707. ctx->color = _sdtx_pack_rgbaf(r, g, b, a);
  4708. }
  4709. }
  4710. SOKOL_API_IMPL void sdtx_color1i(uint32_t rgba) {
  4711. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4712. _sdtx_context_t* ctx = _sdtx.cur_ctx;
  4713. if (ctx) {
  4714. ctx->color = rgba;
  4715. }
  4716. }
  4717. SOKOL_DEBUGTEXT_API_DECL void sdtx_putc(char chr) {
  4718. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4719. _sdtx_context_t* ctx = _sdtx.cur_ctx;
  4720. if (ctx) {
  4721. _sdtx_put_char(ctx, chr);
  4722. }
  4723. }
  4724. SOKOL_DEBUGTEXT_API_DECL void sdtx_puts(const char* str) {
  4725. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4726. _sdtx_context_t* ctx = _sdtx.cur_ctx;
  4727. if (ctx) {
  4728. char chr;
  4729. while (0 != (chr = *str++)) {
  4730. _sdtx_put_char(ctx, chr);
  4731. }
  4732. }
  4733. }
  4734. SOKOL_DEBUGTEXT_API_DECL void sdtx_putr(const char* str, int len) {
  4735. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4736. _sdtx_context_t* ctx = _sdtx.cur_ctx;
  4737. if (ctx) {
  4738. for (int i = 0; i < len; i++) {
  4739. char chr = str[i];
  4740. if (0 == chr) {
  4741. break;
  4742. }
  4743. _sdtx_put_char(ctx, chr);
  4744. }
  4745. }
  4746. }
  4747. SOKOL_DEBUGTEXT_API_DECL int sdtx_vprintf(const char* fmt, va_list args) {
  4748. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4749. SOKOL_ASSERT(_sdtx.fmt_buf && (_sdtx.fmt_buf_size >= 2));
  4750. int res = SOKOL_VSNPRINTF(_sdtx.fmt_buf, _sdtx.fmt_buf_size, fmt, args);
  4751. // make sure we're 0-terminated in case we're on an old MSVC
  4752. _sdtx.fmt_buf[_sdtx.fmt_buf_size-1] = 0;
  4753. sdtx_puts(_sdtx.fmt_buf);
  4754. return res;
  4755. }
  4756. SOKOL_DEBUGTEXT_API_DECL int sdtx_printf(const char* fmt, ...) {
  4757. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4758. SOKOL_ASSERT(_sdtx.fmt_buf && (_sdtx.fmt_buf_size >= 2));
  4759. va_list args;
  4760. va_start(args, fmt);
  4761. int res = SOKOL_VSNPRINTF(_sdtx.fmt_buf, _sdtx.fmt_buf_size, fmt, args);
  4762. va_end(args);
  4763. // make sure we're 0-terminated in case we're on an old MSVC
  4764. _sdtx.fmt_buf[_sdtx.fmt_buf_size-1] = 0;
  4765. sdtx_puts(_sdtx.fmt_buf);
  4766. return res;
  4767. }
  4768. SOKOL_DEBUGTEXT_API_DECL sdtx_range sdtx_get_cleared_fmt_buffer(void) {
  4769. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4770. SOKOL_ASSERT(_sdtx.fmt_buf && (_sdtx.fmt_buf_size >= 2));
  4771. memset(_sdtx.fmt_buf, 0, _sdtx.fmt_buf_size);
  4772. sdtx_range res; _sdtx_clear(&res, sizeof(res));
  4773. res.ptr = _sdtx.fmt_buf;
  4774. res.size = _sdtx.fmt_buf_size - 1;
  4775. return res;
  4776. }
  4777. SOKOL_API_IMPL void sdtx_draw(void) {
  4778. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4779. _sdtx_context_t* ctx = _sdtx.cur_ctx;
  4780. if (ctx) {
  4781. _sdtx_draw_layer(ctx, 0);
  4782. }
  4783. }
  4784. SOKOL_API_IMPL void sdtx_context_draw(sdtx_context ctx_id) {
  4785. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4786. _sdtx_context_t* ctx = _sdtx_lookup_context(ctx_id.id);
  4787. if (ctx) {
  4788. _sdtx_draw_layer(ctx, 0);
  4789. }
  4790. }
  4791. SOKOL_API_IMPL void sdtx_draw_layer(int layer_id) {
  4792. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4793. _sdtx_context_t* ctx = _sdtx.cur_ctx;
  4794. if (ctx) {
  4795. _sdtx_draw_layer(ctx, layer_id);
  4796. }
  4797. }
  4798. SOKOL_API_IMPL void sdtx_context_draw_layer(sdtx_context ctx_id, int layer_id) {
  4799. SOKOL_ASSERT(_SDTX_INIT_COOKIE == _sdtx.init_cookie);
  4800. _sdtx_context_t* ctx = _sdtx_lookup_context(ctx_id.id);
  4801. if (ctx) {
  4802. _sdtx_draw_layer(ctx, layer_id);
  4803. }
  4804. }
  4805. #endif // SOKOL_DEBUGTEXT_IMPL