Jump to content

Search the Community

Showing results for tags 'win64'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Delphi Questions and Answers
    • Algorithms, Data Structures and Class Design
    • VCL
    • FMX
    • RTL and Delphi Object Pascal
    • Databases
    • Network, Cloud and Web
    • Windows API
    • Cross-platform
    • Delphi IDE and APIs
    • General Help
    • Delphi Third-Party
  • C++Builder Questions and Answers
    • General Help
  • General Discussions
    • Embarcadero Lounge
    • Tips / Blogs / Tutorials / Videos
    • Job Opportunities / Coder for Hire
    • I made this
  • Software Development
    • Project Planning and -Management
    • Software Testing and Quality Assurance
  • Community
    • Community Management

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Delphi-Version

Found 7 results

  1. tinyBigGAMES

    CPas - C for Delphi

    Overview What if you were able to load and use C99 sources directly from Delphi? There is a vast quantity of C libraries out there and being able to take advantage of them, without being a pain would be nice. You could even compile a bunch of sources and save them as a library file, then load them back in from disk, a resource or even from a stream. You can get the symbols, map to a C routine, and execute from the Delphi side all from a simple API. Downloads Releases - These are the official release versions. Features Free for commercial use. Allow C integration with Delphi at run-time. Support Windows 64-bit platform. Support for C99. Fast run-time compilation. Can run C sources directly or compile to (.LIB, .EXE, .DLL). Library files can be loaded and used at run-time from a file, a resource or stream. Import symbols directly from a dynamic linked library (.DLL) or module-definition (.DEF) file. You can reference the symbols from Delphi and directly access their value (mapping to a routine and data). Your application can dynamically or statically link to CPas. Direct access to the vast quantity of C99 libraries inside Delphi. Minimum System Requirements Delphi 10 (Win64 target only) FreePascal 3.3.3 (Win64 target only) Microsoft Windows 10, 64-bits 20MB of free hard drive space How to use in Delphi Unzip the archive to a desired location. Add installdir\sources, folder to Delphi's library path so the CPas source files can be found for any project or for a specific project add to its search path. Add installdir\bin, folder to Windows path so that CPas.dll file can be found for any project or place beside project executable. See examples in installdir\examples for more information about usage. You must include CPas.dll in your project distribution when dynamically linked to CPas. See CPAS_STATIC define in the CPas unit file. See installdir\docs for documentation. A Tour of CPas CPas API You access the easy to use API in Delphi from the CPas unit. {.$DEFINE CPAS_STATIC} //<-- define for static distribution type { TCPas } TCPas = type Pointer; { TCPasOutput } TCPasOutput = (cpMemory, cpLib); { TCPasExe } TCPasExe = (cpConsole, cpGUI); { TCPasErrorMessageEvent } TCPasErrorEvent = procedure(aSender: Pointer; const aMsg: WideString); { Misc } function cpVersion: WideString; { State management } function cpNew: TCPas; procedure cpFree(var aCPas: TCPas); procedure cpReset(aCPas: TCPas); { Error handling } procedure cpSetErrorHandler(aCPas: TCPas; aSender: Pointer; aHandler: TCPasErrorEvent); procedure cpGetErrorHandler(aCPas: TCPas; var aSender: Pointer; var aHandler: TCPasErrorEvent); { Preprocessing } procedure cpDefineSymbol(aCPas: TCPas; const aName: WideString; const aValue: WideString); procedure cpUndefineSymbol(aCPas: TCPas; const aName: WideString); function cpAddIncludePath(aCPas: TCPas; const aPath: WideString): Boolean; function cpAddLibraryPath(aCPas: TCPas; const aPath: WideString): Boolean; { Compiling } procedure cpSetOuput(aCPas: TCPas; aOutput: TCPasOutput); function cpGetOutput(aCPas: TCPas): TCPasOutput; procedure cpSetExe(aCPas: TCPas; aExe: TCPasExe); function cpGetExe(aCPas: TCPas): TCPasExe; function cpAddLibrary(aCPas: TCPas; const aName: WideString): Boolean; function cpAddFile(aCPas: TCPas; const aFilename: WideString): Boolean; function cpCompileString(aCPas: TCPas; const aBuffer: string): Boolean; procedure cpAddSymbol(aCPas: TCPas; const aName: WideString; aValue: Pointer); function cpLoadLibFromFile(aCPas: TCPas; const aFilename: WideString): Boolean; function cpLoadLibFromResource(aCPas: TCPas; const aResName: WideString): Boolean; function cpLoadLibFromStream(aCPas: TCPas; aStream: TStream): Boolean; function cpSaveOutputFile(aCPas: TCPas; const aFilename: WideString): Boolean; function cpRelocate(aCPas: TCPas): Boolean; function cpRun(aCPas: TCPas): Boolean; function cpGetSymbol(aCPas: TCPas; const aName: WideString): Pointer; { Stats } procedure cpStartStats(aCPas: TCPas); function cpEndStats(aCPas: TCPas; aShow: Boolean): WideString; If you want CPas to be statically bound to your application, enable the {$CPAS_STATIC} define in the CPas unit. How to use A minimal implementation example: uses System.SysUtils, CPas; var c: TCPas; // CPas error handler procedure ErrorHandler(aSender: Pointer; const aMsg: WideString); begin WriteLn(aMsg); end; begin // create a CPas instance c := cpNew; try // setup the error handler cpSetErrorHandler(c, nil, ErrorHandler); // add source file cpAddFile(cp, 'test1.c'); // link and call main cpRun(cp); finally // destroy CPas instance cpFree(c); end; end. Compatibility These are some libraries that I've tested. If you have tried more, let me know and I can add them to the list. miniaudio (https://github.com/mackron/miniaudio) raylib (https://github.com/raysan5/raylib) sfml (https://github.com/SFML/CSFML) stb_image (https://github.com/nothings/stb) stb_image_write (https://github.com/nothings/stb) stb_truetype (https://github.com/nothings/stb) stb_vorbis (https://github.com/nothings/stb) Media ❤ Made in Delphi
  2. Dllama, a simple and easy to use library for doing local LLM inference directly from Delphi (any language with bindings). It can load GGUF formatted LLMs into CPU or GPU memory. Uses Vulkan back end for acceleration. Simple Example uses System.SysUtils, Dllama, Dllama.Ext; var LResponse: string; LTokenInputSpeed: Single; LTokenOutputSpeed: Single; LInputTokens: Integer; LOutputTokens: Integer; LTotalTokens: Integer; begin // init config Dllama_InitConfig('C:\LLM\gguf', -1, False, VK_ESCAPE); // add model Dllama_AddModel('Meta-Llama-3-8B-Instruct-Q6_K', 'llama3', 1024*8, '<|start_header_id|>%s %s<|end_header_id|>', '\n assistant:\n', ['<|eot_id|>', 'assistant']); // add messages Dllama_AddMessage(ROLE_SYSTEM, 'you are Dllama, a helpful AI assistant.'); Dllama_AddMessage(ROLE_USER, 'who are you?'); // display the user prompt Dllama_Console_PrintLn(Dllama_GetLastUserMessage(), [], DARKGREEN); // do inference if Dllama_Inference('llama3', LResponse) then begin // display usage Dllama_Console_PrintLn(CRLF, [], WHITE); Dllama_GetInferenceUsage(@LTokenInputSpeed, @LTokenOutputSpeed, @LInputTokens, @LOutputTokens, @LTotalTokens); Dllama_Console_PrintLn('Tokens :: Input: %d, Output: %d, Total: %d, Speed: %3.1f t/s', [LInputTokens, LOutputTokens, LTotalTokens, LTokenOutputSpeed], BRIGHTYELLOW); end else begin Dllama_Console_PrintLn('Error: %s', [Dllama_GetError()], RED); end; Dllama_UnloadModel(); end.
  3. We are having problems with Delphi 12 to debug projects with Runtime Packages and the Win64 platform. This example reproduces an issue when debugging projects that use Rumtime Packages on the Win64 platform. Steps to reproduce the issue: 1 - Open the project group: BPTEST.groupproj; 2 - Select the debug configuration and the win64 platform for all projects in the group; 3 - Make a Build; 4 - In the App.exe project in App.dpr, place a breakpoint on the line: Application.Initialize; 5 - Press F9, and we will see that the breakpoint was ignored. If we repeat the process with the win32 configuration, the breakpoint works correctly; If in App.dpr we remove the MyUnit unit from uses, which is part of TrPartUnits.bpl, the breakpoint also works correctly even in win64; I also made the example available at: https://github.com/giorgiobazzo/RtPkgSample BPTEST.zip
  4. tinyBigGAMES

    SDL3 for Pascal

    SDL3 for Pascal If you want to get your hands dirty and directly use the new SDL3, I got you covered. 😎 Add SDL3 to your uses statement and it will be linked into your executable with direct access, no DLLs to maintain. You also get miniaudio (for audio), Nuklear (for GUI), pl_mpeg (for video) and stb (for images & fonts) and more. Added a contrib folder and accepting PRs, if you wish to add a contribution. To start the ball rolling, I added ziparc archive utility for making standard password protected zip archives, using zlib/minzip from SDL3pas only. Enjoy! https://github.com/tinyBigGAMES/SDL3
  5. tinyBigGAMES

    Luna Game Toolkit

    New update. Now using SDL backend. Free and open source. Enjoy! https://github.com/tinyBigGAMES/Luna
  6. KodeZwerg

    Windows Ini File Helper Unit

    Hi there, i made a small unit to handle Ini Files on Windows Systems. A Full Demo is included, build with D2010, should be compatible to any Version, may need other "Uses" Namespace. Whats the point? It read or write from/to Ini file. Will automatic use "X:\Users\LoginName\AppData\Local\ExeName\" as folder to save to. Foldername has a override feature. ATM one problem occur when you use my try of implementing a crypt method, writing to file is good but decryption i made somewhere something wrong. Have fun with it. IniHelper.7z
  7. Hi there, i know a few ways to play with files but never really compared them. classical way with FindFirst() FindNext(), easy handling but slow if searching with '*.*' mask 🙂 PIDL if you know how to deal with em, my opinion very fast but a bit harder to play with. and IOUtils offer TPath, where i have less experience. Wich way should a modern application go if Windows is target? And if speed would be an aspect, what you think might be fastest? as proto code without any code at all // function that retrive a list with matching filenames "FileMask" function FindFiles( const StartPath: String = ''; const FileMask: String = '*.*'; const SubFolder: Boolean = False ): TStrings; var AStrings: TStrings; begin AStrings := TStrings.Create(); try AStrings := CollectData( StartPath, FileMask, SubFolder ); finally Result := AStrings; AStrings.Free; end; end;
×