On 3/25/20 12:41 PM, Michael Beil wrote:
after more testing yesterday I can describe more precisely:
I send an image from pix_video to a rectangle and I use a gemwin with the same resolution. pix_video = 1280*720 gemwin = 1280*720 I use facetime (builtin), external webcam (logitech) and blackmagic intensity interface (USB3/HDMI) I get a proper image and I can switch the cams. THAT’S GREAT !!!! :)
but
- when I change the resolution of pix_video I have to recreate gemwin to see the effect
oops. that should not be necessary.
- when I send create, 1 to gemwin I get the bogus errors and I have to wait for them popping up (more for facetime, less for external cams)
only when re-creating the gemwin, or also when creating it for the first time?
do those errors stop eventually? (might be, that the camera takes some time to start streaming images; and Gem complains that it doesn't get any images).
- real issue: the border 0 message to gemwin creates a black gap where the border was and changes the image frame (part of the image at the left side vanishes by an x-zoom, the window-size remains the same)
not sure i understand what you are saying. could you post a screenshot? also, does the problem persist if you send the [border 0( *before* you create the Gem-windows (for the first time)? or are you doing that anyhow.
- the rectangle object needs weird numbers like 7.5 and 4 to get the image fitting to a gemwin, the original image is very small in the gemwin without scaling and adapting
this is expected behaviour. a [rectangle] is not some space on the screen to be occupied by whatever incoming video you have; but instead it is a representation of a 3d-dimensional object (without depth :-)) in a 3d-world, and you just happen to look at it. the closer you (or the camera) is to the object, the larger it gets. it's the same as with your TV, really :-)
in the default camera position, the upper window border is Y=+4 and the lower window border is Y=-4; since [square] (and [rectangle]) really expand from -size to +size, a [square] of size=4 will cover the entire height of the screen. depending on the aspect ration of your video (or your gemwindow/screen, if you want to show the video fullscreen, even if you are distorting it), you have to adjust the width of your [rectangle]. if the aspect ratio is 1:1, then an object that covers X=-4 thru X=+4 will cover the entire width of the window (as in [square 4]). if the aspect ratio is 2:1, then you need a [rectangle 8 4].
if your aspect ratio is 1280/720 (which, after doing some maths is the same as 1.777777/1 or (if we multiply by 4) 7.1111111/4), then you need to use a [rectangle 7.111111111 4].
you can automate this with
| [pix_info] | | | ||| | [/] | | | [* 4] | | [rectangle 0 4] |
I found the help-file for pix_video in the Max folder. But when I open it in the patch it is blank.
Max-folder? do you get some Tcl/Tk error in the Pd-console?
gfmdsar IOhannes