You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
except for Ogre::CommonTextureTypes::Diffuse which remains unaltered (as there is no Ogre::CommonTextureTypes::Emissive).
This seems to solve the issue for my projected texture png.
For my use case it seems perfect (I am simulating a laser line for laser triangulation).
However, there seems to be an issue with the png file of the example world: it shows white color in most of the transparent part:
I did not find out why, but simply opening the png in Gimp and exporting as png (without making any changes) solves the issue, so it must be some peculiarity of that specific file.
Environment
gz-rendering8
build from sourceDescription
Apart from the frustum shape, I noticed two more differences between the Ogre1 and Ogre2 implementations of the projector:
The Ogre2 projection requires a specular light in the scene to show colors.
To test:
Run the example demo world:
gz sim projector.sdf
gz sim projector.sdf --render-engine ogre
---> both show color in the projected pattern
Change the 'sun' light in the sdf and set its
<specular>
to '0 0 0 1'---> Ogre1 shows color, Ogre2 does not.
The Ogre2 projection is not emissive, in contrast to the Ogre1 projection.
To test:
Possible resolution
As a trial, I did a 'find-and-replace of all
Diffuse
intoEmissive
inOgre2Projector.cc
, e.g.becomes
except for
Ogre::CommonTextureTypes::Diffuse
which remains unaltered (as there is noOgre::CommonTextureTypes::Emissive
).This seems to solve the issue for my projected texture png.
For my use case it seems perfect (I am simulating a laser line for laser triangulation).
However, there seems to be an issue with the png file of the example world: it shows white color in most of the transparent part:
I did not find out why, but simply opening the png in Gimp and exporting as png (without making any changes) solves the issue, so it must be some peculiarity of that specific file.
In attachment both files for comparison.
pattern.zip
The text was updated successfully, but these errors were encountered: