1
0

cara.php 26 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847
  1. <?php
  2. class cara{
  3. public function __construct(){
  4. include "lib/backend.php";
  5. $this->backend = new backend("cara");
  6. }
  7. public function getfilters($page){
  8. return [
  9. "sort" => [
  10. "display" => "Sort by",
  11. "option" => [
  12. "Top" => "Top",
  13. "MostRecent" => "Most Recent"
  14. ]
  15. ],
  16. "type" => [
  17. "display" => "Post type",
  18. "option" => [
  19. "any" => "Any type",
  20. "portfolio" => "Portfolio", // {"posts":["portfolio"]}
  21. "timeline" => "Timeline" // {"posts":["timeline"]}
  22. ]
  23. ],
  24. "fields" => [
  25. "display" => "Field/Medium",
  26. "option" => [
  27. "any" => "Any field",
  28. "2D" => "2D Work",
  29. "3D" => "3D Work",
  30. "3DPrinting" => "3D Printing",
  31. "Acrylic" => "Acrylic",
  32. "AlcoholMarkers" => "Alcohol Markers",
  33. "Animation" => "Animation",
  34. "Chalk" => "Chalk",
  35. "Charcoal" => "Charcoal",
  36. "Colored pencil" => "Colored pencil",
  37. "Conte" => "Conte",
  38. "Crayon" => "Crayon",
  39. "Digital" => "Digital",
  40. "Gouache" => "Gouache",
  41. "Ink" => "Ink",
  42. "MixedMedia" => "Mixed-Media",
  43. "Oil" => "Oil",
  44. "Oil-based Markers" => "Oil-based Markers",
  45. "Other" => "Other",
  46. "Pastels" => "Pastels",
  47. "Photography" => "Photography",
  48. "Sculpture" => "Sculpture",
  49. "Sketches" => "Sketches",
  50. "Tattoos" => "Tattoos",
  51. "Traditional" => "Traditional",
  52. "VFX" => "VFX",
  53. "Watercolor" => "Watercolor"
  54. ]
  55. ],
  56. "category" => [
  57. "display" => "Category",
  58. "option" => [
  59. "any" => "Any category",
  60. "3DScanning" => "3D Scanning",
  61. "Abstract" => "Abstract",
  62. "Adoptable" => "Adoptable",
  63. "Anatomy" => "Anatomy",
  64. "Animals" => "Animals",
  65. "Anime" => "Anime",
  66. "App" => "App",
  67. "ArchitecturalConcepts" => "Architectural Concepts",
  68. "ArchitecturalVisualization" => "Architectural Visualization",
  69. "AugmentedReality" => "Augmented Reality",
  70. "Automotive" => "Automotive",
  71. "BoardGameArt" => "Board Game Art",
  72. "BookIllustration" => "Book Illustration",
  73. "CardGameArt" => "Card Game Art",
  74. "CeramicsPottery" => "Ceramics/Pottery",
  75. "CharacterAnimation" => "Character Animation",
  76. "CharacterDesign" => "Character Design",
  77. "CharacterModeling" => "Character Modeling",
  78. "ChildrensArt" => "Children's Illustration",
  79. "Collectibles" => "Collectibles",
  80. "ColoringPage" => "Coloring Page",
  81. "ComicArt" => "Comic Art",
  82. "ConceptArt" => "Concept Art",
  83. "Cosplay" => "Cosplay",
  84. "CostumeDesign" => "Costume Design",
  85. "CoverArt" => "Cover Art",
  86. "Creatures" => "Creatures",
  87. "Diorama" => "Diorama",
  88. "EditorialIllustration" => "Editorial Illustration",
  89. "EmbroiderySewing" => "Embroidery/Sewing",
  90. "EnvironmentalConceptArt" => "Environmental Concept Art",
  91. "EnvironmentalConceptDesign" => "Environmental Concept Design",
  92. "FanArt" => "Fan Art",
  93. "Fantasy" => "Fantasy",
  94. "Fashion" => "Fashion",
  95. "FashionStyling" => "Fashion Styling",
  96. "FiberArts" => "Fiber Arts",
  97. "Furry" => "Furry",
  98. "GameArt" => "Game Art",
  99. "GameplayDesign" => "Gameplay Design",
  100. "GamesEnvironmentArt" => "Games Environment Art",
  101. "Gem" => "Gem",
  102. "GraphicDesign" => "Graphic Design",
  103. "Handicraft" => "Handicraft",
  104. "HairStyling" => "Hair Styling",
  105. "HardSurface" => "Hard Surface",
  106. "Horror" => "Horror",
  107. "Illustration" => "Illustration",
  108. "IllustrationVisualization" => "Illustration Visualization",
  109. "IndustrialDesign" => "Industrial Design",
  110. "Jewelry" => "Jewelry",
  111. "KnittingCrochet" => "Knitting/Crochet",
  112. "Landscape" => "Landscape",
  113. "LevelDesign" => "Level Design",
  114. "Lighting" => "Lighting",
  115. "Makeup" => "Makeup",
  116. "Manga" => "Manga",
  117. "MapsCartography" => "Maps/Cartography",
  118. "MattePainting" => "Matte Painting",
  119. "Materials" => "Materials",
  120. "MechanicalDesign" => "Mechanical Design",
  121. "Medical" => "Medical",
  122. "Mecha" => "Mecha",
  123. "MiniatureArt" => "Miniature Art",
  124. "MotionGraphics" => "Motion Graphics",
  125. "FrescoMurals" => "Fresco/Murals",
  126. "Natural" => "Natural",
  127. "Original Character" => "Original Character",
  128. "Overlay" => "Overlay",
  129. "PleinAir" => "Plein Air",
  130. "Photogrammetry" => "Photogrammetry",
  131. "PixelArt" => "Pixel Art",
  132. "Portraits" => "Portraits",
  133. "Props" => "Props",
  134. "ProductDesign" => "Product Design",
  135. "PublicDomain" => "Public Domain or Royalty Free",
  136. "Real-Time3DEnvironmentArt" => "Real-Time 3D Environment Art",
  137. "Realism" => "Realism",
  138. "ScienceFiction" => "Science Fiction",
  139. "ScientificVisualization" => "Scientific Visualization",
  140. "Scripts" => "Scripts",
  141. "StillLife" => "Still Life",
  142. "Storyboards" => "Storyboards",
  143. "Stylized" => "Stylized",
  144. "Surreal" => "Surreal",
  145. "TechnicalArt" => "Technical Art",
  146. "Textures" => "Textures",
  147. "Tools" => "Tools",
  148. "Toys" => "Toys",
  149. "ToyPackaging" => "Toy Packaging",
  150. "Tutorials" => "Tutorials",
  151. "UIArt" => "User Interface (UI) Art",
  152. "UrbanSketch" => "Urban Sketch",
  153. "VFXforAnimation" => "VFX for Animation",
  154. "VFXforFilm" => "VFX for Film",
  155. "VFXforGames" => "VFX for Games",
  156. "VFXforRealTime" => "VFX for Real-Time",
  157. "VFXforTV" => "VFX for TV",
  158. "Vehicles" => "Vehicles",
  159. "VirtualReality" => "Virtual Reality",
  160. "VisualDevelopment" => "Visual Development",
  161. "VoxelArt" => "Voxel Art",
  162. "Vtubers" => "Vtubers",
  163. "WIP" => "WIP (Work in Progress)",
  164. "Web" => "Web",
  165. "Weapons" => "Weapons",
  166. "Wildlife" => "Wildlife",
  167. "Woodcutting" => "Woodcutting"
  168. ]
  169. ],
  170. "software" => [
  171. "display" => "Software",
  172. "option" => [
  173. "any" => "Any software",
  174. "123D" => "123D",
  175. "123DCatch" => "123D Catch",
  176. "3DBee" => "3DBee",
  177. "3DCoat" => "3DCoat",
  178. "3DCoatPrint" => "3DCoatPrint",
  179. "3DCoatTextura" => "3DCoatTextura",
  180. "3DEqualizer" => "3DEqualizer",
  181. "3DFZephyr" => "3DF Zephyr",
  182. "3Delight" => "3Delight",
  183. "3dpeople" => "3dpeople",
  184. "3dsMax" => "3ds Max",
  185. "3DSPaint" => "3DS Paint",
  186. "ACDSeeCanvas" => "ACDSee Canvas",
  187. "AbletonLive" => "Ableton Live",
  188. "Acrobat" => "Acrobat",
  189. "AdobeDraw" => "Adobe Draw",
  190. "AdobeFlash" => "Adobe Flash",
  191. "AdobeFresco" => "Adobe Fresco",
  192. "AdobeSubstance3Dassets" => "Adobe Substance 3D assets",
  193. "AdobeXD" => "Adobe XD",
  194. "AffinityDesigner" => "Affinity Designer",
  195. "AffinityPhoto" => "Affinity Photo",
  196. "AfterEffects" => "After Effects",
  197. "Akeytsu" => "Akeytsu",
  198. "Alchemy" => "Alchemy",
  199. "AliasDesign" => "Alias Design",
  200. "AlightMotion" => "Alight Motion",
  201. "Amadine" => "Amadine",
  202. "Amberlight" => "Amberlight",
  203. "Animate" => "Animate",
  204. "AnimationMaster" => "Animation:Master",
  205. "AnimeStudio" => "Anime Studio",
  206. "Apophysis" => "Apophysis",
  207. "ArchiCAD" => "ArchiCAD",
  208. "Arion" => "Arion",
  209. "ArionFX" => "ArionFX",
  210. "Arnold" => "Arnold",
  211. "ArtEngine" => "ArtEngine",
  212. "ArtFlow" => "ArtFlow",
  213. "ArtRage" => "ArtRage",
  214. "ArtstudioPro" => "Artstudio Pro",
  215. "Artweaver" => "Artweaver",
  216. "Aseprite" => "Aseprite",
  217. "Audition" => "Audition",
  218. "AutoCAD" => "AutoCAD",
  219. "AutodeskSketchBook" => "Autodesk SketchBook",
  220. "AvidMediaComposer" => "Avid Media Composer",
  221. "AzPainter" => "AzPainter",
  222. "babylonjs" => "babylon.js",
  223. "BalsamiqMockup" => "Balsamiq Mockup",
  224. "Bforartists" => "Bforartists",
  225. "BlackInk" => "Black Ink",
  226. "BlackmagicDesignFusion" => "Blackmagic Design Fusion",
  227. "Blender" => "Blender",
  228. "Blender DeepPaint" => "Blender DeepPaint",
  229. "BlenderGreasePencil" => "Blender Grease Pencil",
  230. "Blockbench" => "Blockbench",
  231. "BodyPaint" => "BodyPaint",
  232. "Boxcutter" => "Boxcutter",
  233. "BraidMaker" => "Braid Maker",
  234. "BrickLinkStudio" => "BrickLink Studio",
  235. "Bridge" => "Bridge",
  236. "Brushifyio" => "Brushify.io",
  237. "C" => "C",
  238. "C#" => "C#",
  239. "C++" => "C++",
  240. "CACANi" => "CACANi",
  241. "CLIPSTUDIOPAINT" => "CLIP STUDIO PAINT",
  242. "CLO" => "CLO",
  243. "CRYENGINE" => "CRYENGINE",
  244. "Callipeg" => "Callipeg",
  245. "Canva" => "Canva",
  246. "CaptureOne" => "Capture One",
  247. "CartoonAnimator" => "Cartoon Animator",
  248. "Carveco" => "Carveco",
  249. "Cavalry" => "Cavalry",
  250. "Chaotica" => "Chaotica",
  251. "CharacterAnimator" => "Character Animator",
  252. "CharacterCreator" => "Character Creator",
  253. "Cinema4D" => "Cinema 4D",
  254. "ClarisseiFX" => "Clarisse iFX",
  255. "Coiffure" => "Coiffure",
  256. "ColorsLive" => "Colors Live",
  257. "Combustion" => "Combustion",
  258. "Construct2" => "Construct 2",
  259. "Core" => "Core",
  260. "CorelPainter" => "Corel Painter",
  261. "CorelDRAWGraphicsSuite" => "CorelDRAW Graphics Suite",
  262. "CoronaRenderer" => "Corona Renderer",
  263. "ProMotionNG" => "Cosmigo Pro Motion NG",
  264. "CrazyBump" => "CrazyBump",
  265. "Crocotile3D" => "Crocotile 3D",
  266. "Curvy3D" => "Curvy 3D",
  267. "Cycles4D" => "Cycles 4D",
  268. "Darkroom" => "Darkroom",
  269. "DAZStudio" => "DAZ Studio",
  270. "DDO" => "DDO",
  271. "DECIMA" => "DECIMA",
  272. "Darktable" => "Darktable",
  273. "DaVinciResolve" => "DaVinci Resolve",
  274. "Dimension" => "Dimension",
  275. "DragonBones" => "DragonBones",
  276. "Dragonframe" => "Dragonframe",
  277. "Drawpile" => "Drawpile",
  278. "Dreams" => "Dreams",
  279. "Dreamweaver" => "Dreamweaver",
  280. "DxOPhotoLab" => "DxO PhotoLab",
  281. "ECycles" => "E-Cycles",
  282. "EmberGen" => "EmberGen",
  283. "Encore" => "Encore",
  284. "Expresii" => "Expresii",
  285. "FStorm" => "FStorm",
  286. "FadeIn" => "FadeIn",
  287. "Feather3D" => "Feather 3D",
  288. "FiberShop" => "FiberShop",
  289. "Figma" => "Figma",
  290. "FilmoraWondershare" => "Filmora Wondershare",
  291. "FilterForge" => "Filter Forge",
  292. "FinalCutPro" => "Final Cut Pro",
  293. "FinalDraft" => "Final Draft",
  294. "finalRender" => "finalRender",
  295. "FireAlpaca" => "FireAlpaca",
  296. "Fireworks" => "Fireworks",
  297. "FlamePainter" => "Flame Painter",
  298. "Flash" => "Flash",
  299. "FlipaClip" => "FlipaClip",
  300. "FlipnoteStudio" => "Flipnote Studio",
  301. "Fluent" => "Fluent",
  302. "ForestPack" => "Forest Pack",
  303. "FormZ" => "Form-Z",
  304. "Fractorium" => "Fractorium",
  305. "FreeCAD" => "FreeCAD",
  306. "FreeHand" => "FreeHand",
  307. "Forger" => "Forger",
  308. "FrostbiteEngine" => "Frostbite Engine",
  309. "fSpy" => "fSpy",
  310. "FumeFX" => "FumeFX",
  311. "Fusion360" => "Fusion 360",
  312. "GIMP" => "GIMP",
  313. "GSCurveTools" => "GS CurveTools",
  314. "GSToolbox" => "GS Toolbox",
  315. "Gaea" => "Gaea",
  316. "GameTextures" => "Game Textures",
  317. "GameMakerStudio" => "GameMaker: Studio",
  318. "GarageFarmNET" => "GarageFarm.NET",
  319. "GeoGlyph" => "GeoGlyph",
  320. "GigapixelAl" => "Gigapixel Al",
  321. "Glaxnimate" => "Glaxnimate",
  322. "GnomePaint" => "Gnome Paint",
  323. "Godot" => "Godot",
  324. "Goxel" => "Goxel",
  325. "Graphite" => "Graphite",
  326. "Graswald" => "Graswald",
  327. "GravitySketch" => "Gravity Sketch",
  328. "GuerillaRender" => "GuerillaRender",
  329. "HDRLightStudio" => "HDR Light Studio",
  330. "HairStrandDesigner" => "Hair Strand Designer",
  331. "HairTGHairFur" => "HairTG - Hair &amp; Fur",
  332. "HairTGSurfaceFeatherEdition" => "HairTG - Surface, Feather Edition",
  333. "HairTGSurfaceHairEdition" => "HairTG - Surface, Hair Edition",
  334. "Handplane" => "Handplane",
  335. "Hansoft" => "Hansoft",
  336. "HardOps" => "Hard Ops",
  337. "HardMesh" => "HardMesh",
  338. "Harmony" => "Harmony",
  339. "HeavypaintWebbypaint" => "Heavypaint/Webbypaint",
  340. "HelloPaint" => "HelloPaint",
  341. "HeliconFocus" => "Helicon Focus",
  342. "Hexels" => "Hexels",
  343. "HiPaint" => "HiPaint",
  344. "Houdini" => "Houdini",
  345. "HydraRenderer" => "Hydra Renderer",
  346. "iArtbook" => "iArtbook",
  347. "IbisPaint" => "ibisPaint",
  348. "Ideas" => "Ideas",
  349. "IllustStudio" => "Illust Studio",
  350. "Illustrator" => "Illustrator",
  351. "IllustratorDraw" => "Illustrator Draw",
  352. "InDesign" => "InDesign",
  353. "Inochi2D" => "Inochi2D",
  354. "InVision" => "InVision",
  355. "InVisionCraft" => "InVision Craft",
  356. "InfinitePainter" => "Infinite Painter",
  357. "Inkscape" => "Inkscape",
  358. "Inspirit" => "Inspirit",
  359. "InstaLOD" => "InstaLOD",
  360. "InstaMAT" => "InstaMAT",
  361. "InstantLightRealtimePBR" => "Instant Light Realtime PBR",
  362. "InstantMeshes" => "Instant Meshes",
  363. "InstantTerra" => "Instant Terra",
  364. "Inventor" => "Inventor",
  365. "Iray" => "Iray",
  366. "JWildfire" => "JWildfire",
  367. "Java" => "Java",
  368. "Jira" => "Jira",
  369. "JumpPaint" => "Jump Paint by MediBang",
  370. "JSPaint" => "JS Paint",
  371. "Katana" => "Katana",
  372. "Keyshot" => "Keyshot",
  373. "KidPix" => "Kid Pix",
  374. "KitBash3D" => "KitBash3D",
  375. "Knald" => "Knald",
  376. "Kodon" => "Kodon",
  377. "KolourPaint" => "KolourPaint",
  378. "Krakatoa" => "Krakatoa",
  379. "KRESKA" => "KRESKA",
  380. "Krita" => "Krita",
  381. "LensStudio" => "Lens Studio",
  382. "LibreSprite" => "LibreSprite",
  383. "LightWave3D" => "LightWave 3D",
  384. "Lightroom" => "Lightroom",
  385. "Linearity" => "Linearity",
  386. "LiquiGen" => "LiquiGen",
  387. "Live2DCubism" => "Live2D Cubism",
  388. "LookatmyHair" => "Look at my Hair",
  389. "Lotpixel" => "Lotpixel",
  390. "Lumion" => "Lumion",
  391. "LuxRender" => "LuxRender",
  392. "MacPaint" => "MacPaint",
  393. "MagicaCSG" => "MagicaCSG",
  394. "MagicaVoxel" => "MagicaVoxel",
  395. "Magma" => "Magma",
  396. "MakeHuman" => "MakeHuman",
  397. "Malmal" => "Malmal",
  398. "Mandelbulb3D" => "Mandelbulb 3D",
  399. "Mandelbulber" => "Mandelbulber",
  400. "MangaStudio" => "Manga Studio",
  401. "Mari" => "Mari",
  402. "MarmosetToolbag" => "Marmoset Toolbag",
  403. "MarvelousDesigner" => "Marvelous Designer",
  404. "MasterpieceStudioPro" => "Masterpiece Studio Pro",
  405. "MasterpieceVR" => "MasterpieceVR",
  406. "Maverick" => "Maverick",
  407. "MaxwellRender" => "Maxwell Render",
  408. "Maya" => "Maya",
  409. "MediBangPaint" => "MediBang Paint",
  410. "MediumbyAdobe" => "Medium by Adobe",
  411. "Megascans" => "Megascans",
  412. "mentalray" => "mental ray",
  413. "MeshLab" => "MeshLab",
  414. "Meshroom" => "Meshroom",
  415. "MetaHumanCreator" => "MetaHuman Creator",
  416. "Metashape" => "Metashape",
  417. "MightyBake" => "MightyBake",
  418. "MikuMikuDance" => "MikuMikuDance",
  419. "Minecraft" => "Minecraft",
  420. "Mischief" => "Mischief",
  421. "Mixamo" => "Mixamo",
  422. "Mixer" => "Mixer",
  423. "MoI3D" => "MoI3D",
  424. "Mocha" => "Mocha",
  425. "Modo" => "Modo",
  426. "Moho" => "Moho",
  427. "MotionBuilder" => "MotionBuilder",
  428. "Mudbox" => "Mudbox",
  429. "Muse" => "Muse",
  430. "MSPaint" => "MS Paint",
  431. "MyPaint" => "MyPaint",
  432. "NDO" => "NDO",
  433. "NX" => "NX",
  434. "NdotCAD" => "NdotCAD",
  435. "NintendoNotes" => "Nintendo Notes",
  436. "NomadSculpt" => "Nomad Sculpt",
  437. "Notability" => "Notability",
  438. "Nuke" => "Nuke",
  439. "Nvil" => "Nvil",
  440. "OctaneRender" => "Octane Render",
  441. "Omniverse" => "Omniverse",
  442. "OmniverseCreate" => "Omniverse Create",
  443. "ON1PhotoRAW" => "ON1 Photo RAW",
  444. "Open3DEngine" => "Open 3D Engine",
  445. "OpenCanvas" => "OpenCanvas",
  446. "OpenGL" => "OpenGL",
  447. "OpenToonz" => "OpenToonz",
  448. "Ornatrix" => "Ornatrix",
  449. "OsciRender" => "Osci-Render",
  450. "OurPaint" => "Our Paint",
  451. "PBRMAX" => "PBRMAX",
  452. "PFTrack" => "PFTrack",
  453. "PTGui" => "PTGui",
  454. "Paintbrush" => "Paintbrush",
  455. "PaintNET" => "Paint.NET",
  456. "PaintShopPro" => "PaintShop Pro",
  457. "PaintToolSAI" => "Paint Tool SAI",
  458. "PaintstormStudio" => "Paintstorm Studio",
  459. "Paper" => "Paper",
  460. "Pencil2D" => "Pencil2D",
  461. "Penpot" => "Penpot",
  462. "PhoenixFD" => "Phoenix FD",
  463. "Phonto" => "Phonto",
  464. "PhotoLab2" => "PhotoLab 2",
  465. "Photopea" => "Photopea",
  466. "Photoscan" => "Photoscan",
  467. "Photoshop" => "Photoshop",
  468. "PhotoshopElements" => "Photoshop Elements",
  469. "PicoCAD" => "picoCAD",
  470. "PicoCAD2" => "picoCAD 2",
  471. "Pinta" => "Pinta",
  472. "Piskel" => "Piskel",
  473. "Pixilart" => "Pixilart",
  474. "Pixelitor" => "Pixelitor",
  475. "Pixelmator" => "Pixelmator",
  476. "Pixelorama" => "Pixelorama",
  477. "PixivSketch" => "pixiv Sketch",
  478. "Pixquare" => "Pixquare",
  479. "PlantCatalog" => "PlantCatalog",
  480. "PlantFactory" => "PlantFactory",
  481. "Plasticity" => "Plasticity",
  482. "PNGtuberPlus" => "PNGtuber Plus",
  483. "Poliigon" => "Poliigon",
  484. "Polybrush" => "Polybrush",
  485. "PopcornFx" => "PopcornFx",
  486. "Poser" => "Poser",
  487. "Premiere" => "Premiere",
  488. "PremiereElements" => "Premiere Elements",
  489. "PresagisCreator" => "Presagis Creator",
  490. "ProTools" => "Pro Tools",
  491. "Procreate" => "Procreate",
  492. "ProcreateDreams" => "Procreate Dreams",
  493. "Producer" => "Producer",
  494. "PrometheanAI" => "Promethean AI",
  495. "PureRef" => "PureRef",
  496. "Python" => "Python",
  497. "PyxelEdit" => "PyxelEdit",
  498. "QuadRemesher" => "Quad Remesher",
  499. "QuarkXPress" => "QuarkXPress",
  500. "Qubicle" => "Qubicle",
  501. "Quill" => "Quill",
  502. "QuixelBridge" => "Quixel Bridge",
  503. "QuixelMegascans" => "Quixel Megascans",
  504. "QuixelMixer" => "Quixel Mixer",
  505. "QuixelSuite" => "Quixel Suite",
  506. "R3DSWrap" => "R3DS Wrap",
  507. "R3DSZWRAP" => "R3DS ZWRAP",
  508. "RDTextures" => "RD-Textures",
  509. "RailClone" => "RailClone",
  510. "RealFlow" => "RealFlow",
  511. "RealisticPaintStudio" => "Realistic Paint Studio",
  512. "RealityCapture" => "RealityCapture",
  513. "RealityScan" => "RealityScan",
  514. "RealtimeBoard" => "Realtime Board",
  515. "Rebelle" => "Rebelle",
  516. "Redshift" => "Redshift",
  517. "RenderMan" => "RenderMan",
  518. "RenderNetwork" => "Render Network",
  519. "Revit" => "Revit",
  520. "Rhino" => "Rhino",
  521. "Rhinoceros" => "Rhinoceros",
  522. "RizomUV" => "RizomUV",
  523. "RoughAnimator" => "Rough Animator",
  524. "SamsungNotes" => "Samsung Notes",
  525. "SamsungPENUP" => "Samsung PENUP",
  526. "ScansLibrary" => "ScansLibrary",
  527. "Scrivener" => "Scrivener",
  528. "Sculpt+" => "Sculpt+",
  529. "Sculptris" => "Sculptris",
  530. "ShaveandaHaircut" => "Shave and a Haircut",
  531. "ShiVa3D" => "ShiVa3D",
  532. "Shotgun" => "Shotgun",
  533. "Silo" => "Silo",
  534. "Silugen" => "Silugen",
  535. "Sketch" => "Sketch",
  536. "SketchApp" => "Sketch App",
  537. "SketchBookPro" => "SketchBook Pro",
  538. "SketchClub" => "SketchClub",
  539. "SketchUp" => "SketchUp",
  540. "Sketchable" => "Sketchable",
  541. "Sketchfab" => "Sketchfab",
  542. "Skyshop" => "Skyshop",
  543. "Snapseed" => "Snapseed",
  544. "Snowdrop" => "Snowdrop",
  545. "Softimage" => "Softimage",
  546. "SolidWorks" => "SolidWorks",
  547. "SonySketch" => "Sony Sketch",
  548. "Soundbooth" => "Soundbooth",
  549. "Source2" => "Source 2",
  550. "SourceControl" => "Source Control",
  551. "SourceFilmmaker" => "Source Filmmaker",
  552. "SpeedTree" => "SpeedTree",
  553. "Speedgrade" => "Speedgrade",
  554. "SpeedyPainter" => "SpeedyPainter",
  555. "Spine2D" => "Spine 2D",
  556. "Spriter" => "Spriter",
  557. "Stingray" => "Stingray",
  558. "Storyboarder" => "Storyboarder",
  559. "StoryboardPro" => "Storyboard Pro",
  560. "SublimeText" => "Sublime Text",
  561. "Substance3DDesigner" => "Substance 3D Designer",
  562. "Substance3DModeler" => "Substance 3D Modeler",
  563. "Substance3DPainter" => "Substance 3D Painter",
  564. "Substance3DSampler" => "Substance 3D Sampler",
  565. "Substance3DStager" => "Substance 3D Stager",
  566. "SubstanceB2M" => "Substance B2M",
  567. "SweetHome3D" => "Sweet Home 3D",
  568. "SynthEyes" => "SynthEyes",
  569. "TTools" => "TTools",
  570. "TVPaint" => "TVPaint",
  571. "TVPaintAnimation" => "TVPaint Animation",
  572. "TayasuiSketches" => "Tayasui Sketches",
  573. "TayasuiSketchesMobileApp" => "Tayasui Sketches Mobile App",
  574. "TayasuiSketchesPro" => "Tayasui Sketches Pro",
  575. "Terragen" => "Terragen",
  576. "Texturescom" => "Textures.com",
  577. "Texturingxyz" => "Texturingxyz",
  578. "TeyaConceptor" => "Teya Conceptor",
  579. "TheGrove3D" => "The Grove 3D",
  580. "TheaRender" => "Thea Render",
  581. "Threejs" => "Three.js",
  582. "Tiled" => "Tiled",
  583. "TiltBrush" => "Tilt Brush",
  584. "Tooll3" => "Tooll3",
  585. "ToonBoomHarmony" => "Toon Boom Harmony",
  586. "ToonBoomStudio" => "Toon Boom Studio",
  587. "ToonSquid" => "ToonSquid",
  588. "TopoGun" => "TopoGun",
  589. "TuxPaint" => "Tux Paint",
  590. "Tvori" => "Tvori",
  591. "Twinmotion" => "Twinmotion",
  592. "UNIGINEEngine" => "UNIGINE Engine",
  593. "UVLayout" => "UVLayout",
  594. "UltraFractal" => "Ultra Fractal",
  595. "uMake" => "uMake",
  596. "Unfold3D" => "Unfold 3D",
  597. "Unity" => "Unity",
  598. "UnrealEngine" => "Unreal Engine",
  599. "Vengi" => "vengi",
  600. "VRay" => "V-Ray",
  601. "VRED" => "VRED",
  602. "VTubeStudio" => "VTube Studio",
  603. "Vectary" => "Vectary",
  604. "VectorayGen" => "VectorayGen",
  605. "Vectorworks" => "Vectorworks",
  606. "VegasPro" => "Vegas Pro",
  607. "VisualDesigner3D" => "Visual Designer 3D",
  608. "VisualStudio" => "Visual Studio",
  609. "VRoidStudio" => "VRoid Studio",
  610. "Vue" => "Vue",
  611. "Vuforia" => "Vuforia",
  612. "WebGL" => "WebGL",
  613. "WhiteboardFox" => "Whiteboard Fox",
  614. "WickEditor" => "Wick Editor",
  615. "Wings3D" => "Wings 3D",
  616. "Word" => "Word",
  617. "WorldCreator" => "World Creator",
  618. "WorldMachine" => "World Machine",
  619. "XParticles" => "X-Particles",
  620. "Xfrog" => "Xfrog",
  621. "Xgen" => "Xgen",
  622. "xNormal" => "xNormal",
  623. "xTex" => "xTex",
  624. "XoliulShader" => "Xoliul Shader",
  625. "Yafaray" => "Yafaray",
  626. "Yeti" => "Yeti",
  627. "ZBrush" => "ZBrush",
  628. "ZBrushCore" => "ZBrushCore",
  629. "ZenBrush" => "Zen Brush"
  630. ]
  631. ]
  632. ];
  633. }
  634. private function get($proxy, $url, $get = [], $search){
  635. $curlproc = curl_init();
  636. if($get !== []){
  637. $get = http_build_query($get);
  638. $url .= "?" . $get;
  639. }
  640. curl_setopt($curlproc, CURLOPT_URL, $url);
  641. curl_setopt($curlproc, CURLOPT_ENCODING, ""); // default encoding
  642. curl_setopt($curlproc, CURLOPT_HTTPHEADER,
  643. ["User-Agent: " . config::USER_AGENT,
  644. "Accept: application/json, text/plain, */*",
  645. "Accept-Language: en-US,en;q=0.5",
  646. "Accept-Encoding: gzip, deflate, br, zstd",
  647. //"sentry-trace: 72b0318a7141fe18cbacbd905572eddf-a60de161b66b1e6f-1
  648. //"baggage: sentry-environment=vercel-production,sentry-release=251ff5179b4de94974f36d9b8659a487bbb8a819,sentry-public_key=2b87af2b44c84643a011838ad097735f,sentry-trace_id=72b0318a7141fe18cbacbd905572eddf,sentry-transaction=GET%20%2Fsearch,sentry-sampled=true,sentry-sample_rand=0.09967130764937493,sentry-sample_rate=0.5",
  649. "DNT: 1",
  650. "Sec-GPC: 1",
  651. "Connection: keep-alive",
  652. //"Referer: https://cara.app/search?q=jak+and+daxter&type=&sortBy=Top&filters=%7B%7D",
  653. "Referer: https://cara.app/search?q=" . urlencode($search),
  654. //"Cookie: __Host-next-auth.csrf-token=b752c4296375bccb7b480ff010e1e916c65c35c311a4a57ac6cd871468730578%7C4d3783cfb72a98f390e534abd149806432b6cf8d50555a52d00e99216a516911; __Secure-next-auth.callback-url=https%3A%2F%2Fcara.app; crumb=BV0HDt87G5+fOWE0ZDQ5MWM0ZTQ3YTZmMzM4MGU5MGNjNDNmMzY2",
  655. "Sec-Fetch-Dest: empty",
  656. "Sec-Fetch-Mode: cors",
  657. "Sec-Fetch-Site: same-origin",
  658. "TE: trailers"]
  659. );
  660. curl_setopt($curlproc, CURLOPT_RETURNTRANSFER, true);
  661. curl_setopt($curlproc, CURLOPT_SSL_VERIFYHOST, 2);
  662. curl_setopt($curlproc, CURLOPT_SSL_VERIFYPEER, true);
  663. curl_setopt($curlproc, CURLOPT_CONNECTTIMEOUT, 30);
  664. curl_setopt($curlproc, CURLOPT_TIMEOUT, 30);
  665. $this->backend->assign_proxy($curlproc, $proxy);
  666. $data = curl_exec($curlproc);
  667. if(curl_errno($curlproc)){
  668. throw new Exception(curl_error($curlproc));
  669. }
  670. curl_close($curlproc);
  671. return $data;
  672. }
  673. public function image($get){
  674. if($get["npt"]){
  675. [$npt, $proxy] =
  676. $this->backend->get(
  677. $get["npt"],
  678. "images"
  679. );
  680. $npt = json_decode($npt, true);
  681. }else{
  682. $search = $get["s"];
  683. if(strlen($search) === 0){
  684. throw new Exception("Search term is empty!");
  685. }
  686. $proxy = $this->backend->get_ip();
  687. $npt = [
  688. "q" => $get["s"],
  689. "sortBy" => $get["sort"],
  690. "take" => 24,
  691. "skip" => 0,
  692. "filters" => []
  693. ];
  694. // parse filters
  695. if($get["type"] != "any"){
  696. $npt["filters"]["posts"] = [$get["type"]];
  697. }
  698. if($get["fields"] != "any"){
  699. $npt["filters"]["fields"] = [$get["fields"]];
  700. }
  701. if($get["category"] != "any"){
  702. $npt["filters"]["categories"] = [$get["category"]];
  703. }
  704. if($get["software"] != "any"){
  705. $npt["filters"]["softwares"] = [$get["software"]];
  706. }
  707. if($npt["filters"] == []){
  708. $npt["filters"] = "{}";
  709. }else{
  710. $npt["filters"] = json_encode($npt["filters"]);
  711. }
  712. }
  713. $out = [
  714. "status" => "ok",
  715. "npt" => null,
  716. "image" => []
  717. ];
  718. // https://cara.app/api/search/portfolio-posts?q=jak+and+daxter&sortBy=Top&take=24&skip=0&filters=%7B%7D
  719. try{
  720. $json =
  721. $this->get(
  722. $proxy,
  723. "https://cara.app/api/search/posts",
  724. $npt,
  725. $npt["q"]
  726. );
  727. }catch(Exception $error){
  728. throw new Exception("Failed to fetch JSON");
  729. }
  730. $json = json_decode($json, true);
  731. if($json === null){
  732. throw new Exception("Failed to decode JSON");
  733. }
  734. $imagecount = 0;
  735. foreach($json as $image){
  736. if(count($image["images"]) === 0){
  737. // sometimes the api returns no images for an object
  738. $imagecount++;
  739. continue;
  740. }
  741. $cover = null;
  742. $sources = [];
  743. foreach($image["images"] as $source){
  744. if($source["isCoverImg"]){
  745. $cover = [
  746. "url" => "https://images.cara.app/" . $this->fix_url($source["src"]),
  747. "width" => 500,
  748. "height" => 500
  749. ];
  750. }else{
  751. $sources[] = [
  752. "url" => "https://images.cara.app/" . $this->fix_url($source["src"]),
  753. "width" => null,
  754. "height" => null
  755. ];
  756. }
  757. }
  758. if($cover !== null){
  759. $sources[] = $cover;
  760. }
  761. $out["image"][] = [
  762. "title" => str_replace("\n", " ", $image["content"]),
  763. "source" => $sources,
  764. "url" => "https://cara.app/post/" . $image["id"]
  765. ];
  766. $imagecount++;
  767. }
  768. if($imagecount === 24){
  769. $npt["skip"] += 24;
  770. $out["npt"] =
  771. $this->backend->store(
  772. json_encode($npt),
  773. "images",
  774. $proxy
  775. );
  776. }
  777. return $out;
  778. }
  779. private function fix_url($url){
  780. return
  781. str_replace(
  782. [" "],
  783. ["%20"],
  784. $url
  785. );
  786. }
  787. }