How to set askew frustum camera matrix?
09 June 2016 12:16
Hi folks,
How it is possible to set the camera projection matrix to an oblique / custom frustum?
In the mat4-module is the helper function for constructing a frustum matrix, but I can not find a way to apply it to the camera projection matrix.
I would like to have control over the image render borders - a function like
In the camera module exists already a method for obtaining the camera frustum planes, but not for setting them.
Or, for now which other possibilities exist?
Please help with some hints,
Daniel
How it is possible to set the camera projection matrix to an oblique / custom frustum?
In the mat4-module is the helper function for constructing a frustum matrix, but I can not find a way to apply it to the camera projection matrix.
I would like to have control over the image render borders - a function like
m_camera.set_frustum_planes(camobj, planes)
would be much appreciated. In the camera module exists already a method for obtaining the camera frustum planes, but not for setting them.
Or, for now which other possibilities exist?
Please help with some hints,
Daniel
@ Emotional3D
09 June 2016 13:22
How it is possible to set the camera projection matrix to an oblique / custom frustum?Hello!
Unfortunately, for now there is no API method to change camera frustum planes.
Could you please specify a little bit your task?
Maybe set_fow or translate_view methods from the camera API module can be useful for you
09 June 2016 13:33
09 June 2016 13:49
09 June 2016 15:23
With a custom camera frustum it would be possible for us to generate e.g. very high-res images by tiling the original camera-frustum into a grid and render each tile separately.As far as I can see set_fov method may help, but you should make sure that canvas aspect ratio is equal to a tile's aspect ratio
29 June 2016 11:19
Hi Konstantin,
as you have mentioned in Post #10028:
and in Post #10049:
there is, unfortunately, no way "tile-based high-resolution-image-rendering" and "advanced image-cropping with control over resolution" will be possible with the Blend4Web-Engine.
Setting camera fov (and or camera-position) won't get the right perspective for a tile in a way that they could get assembled to a whole without perspective kinks in the resulting image.
We have to search for another solution, then.
Cheers, Daniel.
as you have mentioned in Post #10028:
for now there is no API method to change camera frustum planes.
and in Post #10049:
The projection matrix isn't accessible in our engine
there is, unfortunately, no way "tile-based high-resolution-image-rendering" and "advanced image-cropping with control over resolution" will be possible with the Blend4Web-Engine.
Setting camera fov (and or camera-position) won't get the right perspective for a tile in a way that they could get assembled to a whole without perspective kinks in the resulting image.
We have to search for another solution, then.
Cheers, Daniel.
@ Emotional3D
29 June 2016 11:43
16 February 2018 10:31