Overlighted model #1429
-
Beta Was this translation helpful? Give feedback.
Replies: 4 comments 7 replies
-
I suspect this is a gamma correction issue in older VSG versions being affected by changes to recent versions that default to sRGB. Was your .vsgt model created before VulkanSceneGraph v.1.1.10? The topic of Gamma correction and sRGB textures/framebuffers is covered in the thread: |
Beta Was this translation helpful? Give feedback.
-
AnyOldName3/vsgExamples@a5331a8#diff-28321ebb550c3b8760e1cd86bdf0ce617c7d577d9f7560e658f08f5da947e6d6 shows some of the things you might need to do to adapt to make a non-gamma-correct That said, most of the time, I'd recommend storing models as glTF if possible. When something in the VSG changes, we can update the glTF loader to do the right thing, but with a |
Beta Was this translation helpful? Give feedback.
-
How/why does .osgt fit in here?
…On Tue, 1 Apr 2025, 08:10 avilkinnick, ***@***.***> wrote:
@robertosfield <https://github.com/robertosfield> from .osgt to .gltf for
easier editing in 3d editors and consistency with new models that will be
made in blender and exported in .gltf
—
Reply to this email directly, view it on GitHub
<#1429 (reply in thread)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAKEGUGFPFGPGDYL5IZSR532XI3WRAVCNFSM6AAAAABZ7RBH6SVHI2DSMVQWIX3LMV43URDJONRXK43TNFXW4Q3PNVWWK3TUHMYTENRYGQ4DIMA>
.
You are receiving this because you were mentioned.Message ID:
***@***.***
com>
|
Beta Was this translation helpful? Give feedback.
-
With the .osgt files osg2vsg will currently convert to VSG but will implement it's own set of shaders, not any of the new vsg::ShaderSet that are built-in and have support for lighting and shadows. Longer term I'd like to see a rewrite of osg2vsg which addresses this. The .osgt to .obj to Blender to GLTF route sounds a bit painful, but would at least allow vsgXchange::assimp to build the scene graph with modern vsg::ShaderSets and have full support for lighting and shadows. But... .obj is such a feature poor format you are loosing too much info. I am not familiar with osgReciplies but I believe it might have a GLTF loader, if it also has a GLTF writer then perhaps this would be a solution. Another route would be to bypass osg2vsg and write a custom OSG converter that loads .osgt and converts to .vsgb/.vsgt, using ShaderSet/GraphicsPipelineConfigurator as vsgXchange::assimp does. Or just rewrite osg2vsg itself. One thing to be aware of though is that the OSG isn't at all sRGB aware, so just assumed everything as linear RGB, but in fact the source images were almost always sRGB and there was an implicit sRGB conversion being done on the framebuffer. By fluke this "kinda" worked, but once you put the data into a scene graph that actually handles sRGB source data and sRGB frame buffers correctly you see issues. I go into this in depth in this topic in the thread #1379. The OSG will be loading sRGB images as RGB so setting the format to RGB, whereas it really should be setting them to sRGB, the thread discusses this, so it might be enough to just go through the the image data and change the format from a RGB/RGBA to a sRGB equivalent. |
Beta Was this translation helpful? Give feedback.
I suspect this is a gamma correction issue in older VSG versions being affected by changes to recent versions that default to sRGB. Was your .vsgt model created before VulkanSceneGraph v.1.1.10?
The topic of Gamma correction and sRGB textures/framebuffers is covered in the thread:
#1379