Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Edge lists silently not exported with Ogre > 1.9 #135

Closed
shedatc opened this issue Mar 23, 2022 · 6 comments
Closed

Edge lists silently not exported with Ogre > 1.9 #135

shedatc opened this issue Mar 23, 2022 · 6 comments

Comments

@shedatc
Copy link

shedatc commented Mar 23, 2022

I'm trying to render a basic scene using Ogre 13.3.1 but shadows are missing:

No call to buildEdgeList

The scene is built using Blender 3.0.1 and exported with the Edge lists box checked:

export-mesh-setup

Ogre's shadow technique is set to SHADOWTYPE_STENCIL_ADDITIVE (see setupShadows in sandbox/src/Bootstrap.cpp).

Explicitly calling buildEdgeList (see setupScene in sandbox/src/Bootstrap.cpp) trigger shadow rendering:

With call to buildEdgeList

What did I miss?

Source code and material: sandbox.tar.gz

@paroj
Copy link
Member

paroj commented Mar 24, 2022

this is currently not implemented for Ogre > 1.9. This functionality was removed from OgreXMLConverter and we would need to call OgreMeshUpgrader separately to generate the edge-lists.

@shedatc
Copy link
Author

shedatc commented Mar 26, 2022

IIUC, the Edge Lists checkbox silently do nothing when OgreXMLConverter is taken from Ogre > 1.9, right? And manually using OgreMeshUpgrader will add the edge lists to the mesh, preventing me from having call buildEdgeList, still right?

@shedatc
Copy link
Author

shedatc commented Mar 26, 2022

And manually using OgreMeshUpgrader will add the edge lists to the mesh, preventing me from having call buildEdgeList, still right?

Replying to myself: manually calling OgreMeshUpgrader on the .mesh file properly generate the edge lists:

…
Generating edge lists...
Generating edge lists... success
MeshSerializer writing mesh data to stream Grid.001.mesh...
…
Exporting edge lists...
Edge lists exported
…

@shedatc shedatc changed the title Edge lists not (properly?) exported Edge lists silently not exported with Ogre > 1.9 Mar 26, 2022
@shedatc
Copy link
Author

shedatc commented Mar 26, 2022

Also note that the Use OgreMesh Tools checkbox (under the LOD panel) was checked. So I'll investigate the possibility blender2ogre just didn't call OgreMeshUpgrader.

@sercero
Copy link
Collaborator

sercero commented Feb 18, 2023

@shedatc blender2ogre calls OgreMeshUpgrader when that box is ticked, but with the unintuitive -e option (DON'T generate edge lists).

# Edge lists should be generated (or not) by mesh.py, not OgreMeshUpgrader
cmd.append('-e')

It seems that at some point blender2ogre created the Edge Lists directly from mesh.py, but I can't find that kind of code anywhere in mesh.py

@sercero
Copy link
Collaborator

sercero commented Feb 25, 2023

This is solved by #162

@sercero sercero closed this as completed Feb 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants