Walters.Robert Posted October 10, 2018 Posted October 10, 2018 I'm trying to set up projection onto a cylindrical screen. I'm having trouble setting up the displays according to the app projection plugin . My warp correction software, immersive display pro , outputs the camera field of view, frustums, and angular offsets. It is possible to use this directly to set up the cameras instead of trying to translate the values into flat 'displays' within the app projection plugin? A forum search shows some asymetric frustum posts from several years ago but the documentation seems to be inaccessible. Should I be using the BoundFrustum() or WorldBoundFrustum() classes in conjunction with setting up my cameras? Here is an example of what the output looks like. <Camera Identity="1" Row="1" Column="1"> <FieldOfView AspectRatio="1.77778" VerticalFOV="59" HorizontalFOV="90.3325"/> <Frustum left="-0.0100582" right="0.0100582" bottom="-0.00565773" top="0.00565773" near="0.01" far="100"/> <!-- Right-hand coordinate system X-Axis(m)=Left, Y-Axis(m)=Up Z-Axis(m)=FromScreen RotateX(Pitch deg) Positive angle pitch up RotateY(Yaw deg) Positive angle yaw left RotateZ(Bank deg) Positive angle bank left --> <TransformRH> <Translate x="0" y="0" z="0"/> <Rotate x="1.82345" y="102.521" z="0"/> </TransformRH> <!-- Left-hand coordinate system X-Axis(m)=Left, Y-Axis(m)=Up Z-Axis(m)=ToScreen RotateX(Pitch deg) Positive angle pitch down RotateY(Yaw deg) Positive angle yaw right RotateZ(Bank deg) Positive angle bank left --> <TransformLH> <Translate x="0" y="0" z="0"/> <Rotate x="-1.82345" y="-102.521" z="0"/> </TransformLH> <PixelUtilization Percentage="56.052"/> </Camera>
Walters.Robert Posted October 11, 2018 Author Posted October 11, 2018 Here is a picture of the type of image errors I'm getting when trying to set up the views as external displays.
alexander Posted October 12, 2018 Posted October 12, 2018 Hi, Robert! Short answer: you can modify Syncker and AppProjection to fit your needs. The source of these plugins is in your SDK. It is possible to use this directly to set up the cameras instead of trying to translate the values into flat 'displays' within the app projection plugin?In order to set up projection onto a cylindrical screen, you need to have:1) Offset position and camera rotation2) Asymmetric frustum (aspect ratio, FOV, znear, zfar, angular offsets)3) Warping information (depends on projector's position, rotation, inner settings and type of the surface)4) Blending information (depends on projector's overlaps)The first two points are performed via Syncker. The second two works through AppProjection.In your example above, I see that you have the first two points. But I don’t see the second two.Should I be using the BoundFrustum() or WorldBoundFrustum() classes in conjunction with setting up my cameras?Not. They don't affect the rendering.Here is a picture of the type of image errors I'm getting when trying to set up the views as external displays. It looks like you just only need to rotate and pull away the display in the Syncker Configurator. Best regards, Alexander
Walters.Robert Posted October 12, 2018 Author Posted October 12, 2018 Alexander, Thanks I'll take a look at modifying the two apps. With respect to the warping and blending information the immersive display pro handles that automatically (see attached picture of a calibration image running in their calibration software). I can calculate the overlap from from the first two bullet points.
Walters.Robert Posted October 13, 2018 Author Posted October 13, 2018 Alexander, It looks there is a built in function in CIGI to do this automatically: https://developer.unigine.com/en/docs/2.7.2/api/library/plugins/cigiclient/api/iview_class?rlang=cpp#setDefinition_float_float_float_float_float_float_void Any reason this function wouldn't work?
silent Posted October 15, 2018 Posted October 15, 2018 Hi Robert, What do you mean by not working function? Could you please provide a small test code that you are using or a small test scene? Thanks! How to submit a good bug report --- FTP server for test scenes and user uploads: ftp://files.unigine.com user: upload password: 6xYkd6vLYWjpW6SN
Walters.Robert Posted October 15, 2018 Author Posted October 15, 2018 Poor wording on my part. It appears that the above function should do exactly what I want, I just wanted to know if I was misinterpreting what the function does since using it seems much easier than modifying the other two plug ins. I didn't mean to imply that the function was broken in any way. I'll test it out today.
silent Posted October 15, 2018 Posted October 15, 2018 Hi Robert, Oh, that makes sense :) Yep, CIGI has own method to control the viewing frustums and it should work. How to submit a good bug report --- FTP server for test scenes and user uploads: ftp://files.unigine.com user: upload password: 6xYkd6vLYWjpW6SN
Walters.Robert Posted October 15, 2018 Author Posted October 15, 2018 Yup, the cigi IView::setDefinition() function works like a charm. Here are two screenshots using different fields of view as defined by the above function. One has a horizontal FOV of 100° and a vertical FOV of 60° while the second has a horizontal FOV of 120° and a vertical of 80°.
Recommended Posts