OpenCV is capturing frame when no camera is connected

I am trying to get video from external camera (Port 1). OpenCV is capturing frames when no camera is connected to port 1.

isOpened() is returning true, frame is not empty. Not sure which device is acting as a camera in my case.

Kindly help with the possible root cause.

Thank You

all the debugging details are missing. please review [how-to-ask] and [mre]. you didn’t even say what operating system you use… or what you yourself did to investigate.