CVB - Dalsa Genie Nano C4020 - Python

Hi
I’m not very familiar with machine vision cameras, and beginner level at Python. Completely new to CVB!
My requirements are quite simple, I wish to write a very simple program to retrieve still images from the camera, and write them to the PC, where they will be processed by another application.
I’ve managed to do some simple things in CVB like changing the camera attributes etc, but seem to be struggling with copying the images from the camera. Is there some code I can adapt anywhere?
Any help would be appreciated!

1 Like

Hi @Noton :slight_smile:

There ist a simple save function for the image.
Please have a look at this Geting Started Guide

Hi
Thanks for your reply. I have seen the getting started guide, but it doesn’t really seem to answer my question. I don’t see how to copy the images from the device.

You don’t need to explicitly copy the image to your PC.
After acquiring the image like in the following listing (taken form here)…

image, status = stream.wait_for(1000)

…the image is already in the RAM of your PC, so copying is completely done for you in the background. If you now want to write the image to your harddisk, you can do so by calling the save function:

image.save("C:/somewhere/on/my/harddisk/myImage.bmp")

I hope this answers your question :slight_smile:

1 Like

Apologies, I forgot to respond to this. Thank you for your assistance, your suggestion worked perfectly! :slight_smile:

1 Like