Jump to content

Search the Community

Showing results for tags 'delphi4python'.



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 2 results

  1. Hi all, I'm using DelphiVCL + PyScripter to develop a Python windows application.I've created and "pyd" extension module in which perform some critical time operations or add support functions missing in DelphiVCL. - In python script I create an Image - now I would like to send a bytes array to cnc_vision_ext module (made with Delphi): import delphivcl import cnc_vision_ext as ext .... my_Image = delphivcl.Image(Form1) ext.update_image_from_bytes(my_image, 1024, 768, 3) Now in the wrapper CncVisionUpdateImageFromBytesArray_Wrapper I need to extract the TImage instance contained in PPyObject of args. I was not able to find the right way.... { generic functions wrappers } function CncVisionUpdateImageFromBytesArray_Wrapper(pself, args: PPyObject): PPyObject; cdecl; var Image: TImage; Width: Integer; Height: Integer; Channels: Integer; Bytes: TByteArray; ImagePyObj: PPyObject; begin with GetPythonEngine do begin if PyArg_ParseTuple(args, 'Oiii:update_image_from_bytes', @ImagePyObj, @Width, @Height, @Channels) <> 0 then begin // ??? HOW TO GET BACK wrapped TImage from Image() object created with my_image = delphivcl.Image(owner) ??? Image := TImage((PythonToDelphi(ImagePyObj) as TPyDelphiObject).DelphiObject); Result := PyUnicodeFromString ( Format('%s %d %d %d', [Image.Name, Width, Height, Channels]) ); end else Result := nil; end; end; { TPyExtensionManager } procedure TPyExtensionManager.WrapperInitializationEvent(Sender: TObject); begin FWrapper.RegisterDelphiWrapper(TPyCncVisionVideoCapturePxc_Wrapper); FWrapper.RegisterFunction ( PAnsiChar('update_image_from_bytes'), CncVisionUpdateImageFromBytesArray_Wrapper, PAnsiChar('update delphivcl Image object from bytes array with width, height & channels') ); FWrapper.RegisterFunction ( PAnsiChar('get_usb_camera_device_list'), CncVisionGetUSBCameraDeviceList_Wrapper, PAnsiChar('get list of available usb camera devices') ); end; Thanks in advance for the suggestions.... Best Regards Silverio
  2. shineworld

    Syndney 10.4.1 missing NumberBox

    Hi all. There is a way to detect if compile phase is in Delphi 10.4.1 or 10.4.2 ? At Embarcadero documentation they notice only VER340 and compiler 34.0 for either: https://docwiki.embarcadero.com/RADStudio/Alexandria/en/Compiler_Versions but VCL from 10.4.1 and 10.4.2 is different and in 10.4.1 NumberBox is not available. This block 10.4.1 users to compile PythonVCL design package or force them, at any pull, to manually remove any reference to NumberBox where present in check: {$IFDEF DELPHI10_4_OR_HIGHER} ... {$ENDIF DELPHI10_4_OR_HIGHER}.
×