Ogre v14.6 v3 - #15
Conversation
|
Everything works so far. Some GUIs look bad, tons of layout bugs, some robustness problems (like sometimes failing to start single player game because tcp port is busy, which is strange). It is at very least usable. Feel free to send feedback via github. |
|
This PR depends on tomluchowski/cegui#1 |
|
tcp port issue is fixed for me now, too |
|
I don't understand much about game itself but it seems that game play is working. |
Upabjojr
left a comment
There was a problem hiding this comment.
Thanks for taking this on — getting the tree onto a current Ogre is a big job and the bulk of the port looks right. I read the diff on its own terms (against its own merge base, not against the tip of shaders-improvement) and left inline notes below.
I've pushed the fixes for everything in the "should fix" list to a branch so you can take them or ignore them as you like: Upabjojr:ogre-v14.6-v3-review-fixes, three commits on top of ff63881.
Caveat on my end: I only have Ogre 1.12 here and this needs 14.6 plus tomluchowski/cegui#1, so I could not build or run any of it. Everything below is from reading; treat the runtime claims as "needs checking" rather than "observed".
Should fix
-
ODSocketServer::mActualPortis never initialised. The new member isn't in the constructor's init list, and it's only assigned insidecreateServer().ODServer::getNetworkPort()now callsgetActualPort()unconditionally, so any call before the server starts reads an indeterminate value and can return a garbage port. One-word fix. -
renderQueueStarted()dereferences a pointer that starts null.mCameraManager.getActiveCamera()is initialised tonullptrand stays that way untilcreateCamera()runs, but the new condition calls->getName()on it before thequeueGroupIdtest can short-circuit anything useful. -
ReflMetal.materialis deleted but still referenced.models/Roundshield.mesh,models/Sabre.meshandmodels/Wyvern.meshall name theReflMetalmaterial, so they'll fall back to the default material.shaders/ReflMetal.vert,shaders/ReflMetal.fragandmaterials/textures/EnvmapMetal.pngare also left orphaned. Either keep the script or retarget those three meshes and delete the rest — right now it's half-removed. -
Seven materials got their braces reflowed. See the inline note on
T2HammerGood.material; the same shape appears inT2ShieldEvil,T2ShieldGood,T2SwordGood,T3HammerGood,T3ShieldEvilandT3ShieldGood. It's brace-balanced so Ogre will parse it, but the nesting no longer reads as what it is. -
Leftover debug instrumentation.
dumpWindowTree()writes a line per widget tostd::cerron every settings-window open, andMenuModeMain::activate()logs the root geometry every time you enter the main menu. -
Two competing C++ standard mechanisms.
set(CMAKE_CXX_STANDARD 14)was added at the top, but line 213 still prepends-std=c++11from theOD_CXX11_FLAGSprobe intoCMAKE_CXX_FLAGS. The standard flag currently wins by position, which is not something to rely on.CMAKE_CXX_STANDARD_REQUIREDalso isn't set, so an old compiler silently degrades rather than failing.
Worth discussing (I have not changed these)
-
The ephemeral-port fallback changes multiplayer semantics. Falling back to port 0 when the configured port is busy turns a loud failure into a silent one. It fixes single-player, but a LAN host whose port is taken now binds somewhere random while remote clients still dial the advertised port and just fail to connect. Would it be better to scope the fallback to the single-player/local case, and keep the hard error when hosting?
-
x11_mouse_hideflipped from"false"to"true". Unrelated to the Ogre upgrade and unmentioned in the description. If it's needed because CEGUI now draws the cursor itself, a comment saying so would help; if it's a leftover experiment, it should probably come out. -
The
SettingsWindowscaling helpers. Two structural issues:centerAndScaleWindow()rewrites the area into pure pixel offsets, so the window stops tracking display resizes entirely; and the whole thing runs once in the constructor, so after you change resolution from that very window the scale is stale until restart. Recomputing on a display-size-changed event would fix both. -
Vendoring
SGXLib_NormalMap.glslandRTSLib_Colour.glslfrom Ogre. These are Ogre's own RTShaderLib files, andresources.cfglists both@RTSHADER_DIR@and the in-treematerials/RTShaderLib— so which copy wins depends on resource group ordering, and the local copy will drift from whatever Ogre is installed. They also use theOgreUnifiedShader.hmacros (f32vec2,mtxFromCols,vec3_splat), which have to match the installed Ogre. If the intent was to work around the resource path not being found, theresources.cfg.inchange already covers that and these could go. -
194 re-serialised
.meshfiles. The diff is a two-byte header rewrite each —[MeshSerializer_v1.8]→[MeshSerializer_v1.100], no geometry change. Ogre 14 still loads v1.8 meshes (with a deprecation warning), so this looks optional, and it's what makes the PR 297 files instead of ~100. Could it be split into its own commit or PR? It would make the actual port reviewable, and it's a one-way step for anyone still on an older Ogre.
Nits
#include <fstream>inODPacket.cppandConfigManager.cppduplicates one already present a few lines down.- The new includes across the
renderscene/andcreaturemood/files sit above each file's own header, which defeats the self-containedness check that ordering exists for. - Five statements next to the new
buildTangentVectorsIfNeeded()calls inRenderManager.cppended up in column 0. buildTangentVectorsIfNeeded()takesOgre::MeshPtrby value, copying a shared pointer per call.*oldMaterial.get()—*oldMaterialdoes the same thing.- Three
#if OGRE_VERSION < 0x10A00 / #elseblocks inRenderManager.cppnow have identical branches.MovableTextOverlay.cppcorrectly deletes the whole thing; these should match. resources.cfg.inends up with[Graphics]twice and@OGRE_MEDIA_DIR@/Mainlisted under two groups.- Both new
.glslfiles are missing a trailing newline. Gui.cpphardcodes"LiberationSans-10"as the default font and will throwUnknownObjectExceptionif that font ever goes away — a check or a named constant would be kinder.SettingsWindow.cpp:251:if (tabControl)never fires, since CEGUI'sgetChild()throws rather than returning null.
| sf::TcpListener mSockListener; | ||
| sf::SocketSelector mSockSelector; | ||
| sf::Clock mClockMainTask; | ||
| int32_t mActualPort; |
There was a problem hiding this comment.
mActualPort isn't in the constructor's init list — ODSocketServer::ODSocketServer(): mThread(nullptr), mIsConnected(false) {} — and it's only assigned inside createServer().
So any read before the server starts is indeterminate. That matters because ODServer::getNetworkPort() now calls getActualPort() unconditionally:
int32_t actualPort = getActualPort();
if(actualPort != 0)
return actualPort;which means it can return a garbage port instead of falling through to ConfigManager::getNetworkPort(). Adding mActualPort(0), to the init list fixes it.
| bool&) | ||
| { | ||
| if(queueGroupId == RenderManager::OD_RENDER_QUEUE_ID_GUI && invocation.empty()) | ||
| if(queueGroupId == RenderManager::OD_RENDER_QUEUE_ID_GUI && cameraName == mCameraManager.getActiveCamera()->getName()) |
There was a problem hiding this comment.
getActiveCamera() can be null here. CameraManager initialises mActiveCamera(nullptr) and only assigns it in setActiveCamera(), so between this listener being registered and the camera being created, ->getName() dereferences null.
const Ogre::Camera* activeCamera = mCameraManager.getActiveCamera();
if(queueGroupId == RenderManager::OD_RENDER_QUEUE_ID_GUI &&
activeCamera != nullptr && cameraName == activeCamera->getName())Separately — renaming the parameter from invocation to cameraName is a real semantic claim about what Ogre passes here, and it silently decides whether CEGUI ever gets drawn. Worth a comment naming the Ogre version this depends on, since the signature itself doesn't say.
| rtshader_system | ||
| { | ||
| normal_map } | ||
| } |
There was a problem hiding this comment.
The braces got reflowed here. As written:
pass lighting
{
texture_unit
{
texture T2HammerGoodNormal.png
rtshader_system
{
normal_map } <- closes rtshader_system
} <- closes texture_unit
} <- closes pass lighting
It's balanced, so Ogre will parse it, but the closing brace for pass lighting now looks like it belongs to texture_unit. Compare Anvil.material in this same PR, which came out correctly.
Also worth spelling the space out as normal_map tangent_space — the pre-conversion line was lighting_stage normal_map T2HammerGoodNormal.png with no space argument, so tangent space was the implicit default, and every other converted material in this PR states its space explicitly.
Same shape in T2ShieldEvil, T2ShieldGood, T2SwordGood, T3HammerGood, T3ShieldEvil, T3ShieldGood.
|
|
||
| namespace | ||
| { | ||
| void dumpWindowTree(CEGUI::Window* window, int depth = 0) |
There was a problem hiding this comment.
This looks like instrumentation from chasing the layout bugs rather than something to ship — it walks the entire widget tree and writes a line per widget straight to std::cerr (not through LogManager) every time the settings window is opened.
| } | ||
| } | ||
|
|
||
| void centerAndScaleWindow(CEGUI::Window* window, float scale, const CEGUI::Sizef& displaySize) |
There was a problem hiding this comment.
Two things about this helper, beyond it being a workaround:
It rewrites the area as pure pixel offsets (UDim(0.0f, newLeft) etc.), discarding the scale components. After this runs the window no longer tracks display resizes at all — it's pinned to whatever the resolution was at construction time.
And the whole scaling block runs once, in the constructor. Since this is the window you change resolution from, applying a new resolution leaves the settings window scaled for the old one until restart.
Hooking this to a display-size-changed event and recomputing would address both.
| @@ -0,0 +1,125 @@ | |||
| /* | |||
There was a problem hiding this comment.
Vendoring Ogre's own RTShaderLib into the tree is worth a second look.
resources.cfg.in now lists both @RTSHADER_DIR@ (Ogre's copy) and the in-tree materials/RTShaderLib, so which of the two Ogre picks depends on resource group ordering — and this copy will drift from whatever Ogre version is actually installed. It also depends on the OgreUnifiedShader.h macros (f32vec2, f32vec3, mtxFromCols, mul, vec3_splat), which have to match that installed version.
If the reason these were added is that the RTShaderLib path wasn't being found, the resources.cfg.in change in this same PR already fixes that, and these two files could be dropped.
(Missing trailing newline on both, incidentally.)
There was a problem hiding this comment.
It was a quick way to make Ogre RTSS work. I did not think too much about it. Needs to be tested separately. As it is internal shader library I guess that is correct thing to do.
| [OgreInternal] | ||
| FileSystem=@OGRE_MEDIA_DIR@/Main | ||
|
|
||
| [Graphics] |
There was a problem hiding this comment.
[Graphics] is now declared twice, with [OgreInternal] in between, and @OGRE_MEDIA_DIR@/Main is listed under both groups. Ogre's config parser will merge the two [Graphics] blocks so it works, but it reads as an accident.
The six hardcoded @CMAKE_INSTALL_PREFIX@/share/OGRE/Media/RTShaderLib* lines above are also redundant now that @RTSHADER_DIR@ is expanded — RTSHADER_DIR is set to ${OGRE_MEDIA_DIR}/RTShaderLib in CMakeLists.txt:530, pointing at the same place but resolved properly instead of guessed from the install prefix.
There was a problem hiding this comment.
Fixed that with followup commit as latest Ogre update showed the problem.
|
|
||
| namespace | ||
| { | ||
| void buildTangentVectorsIfNeeded(Ogre::MeshPtr meshPtr) |
There was a problem hiding this comment.
Good consolidation — this was four copies of the same block. Three small things:
Take the mesh by const Ogre::MeshPtr& rather than by value; each call currently copies a shared pointer (atomic refcount) for no reason.
A null check would help: getByName() returns a null MeshPtr when the mesh isn't in the group, and several call sites pass its result straight in without checking, so a missing mesh crashes here instead of logging.
And the five statements immediately following the new calls (lines 607, 996, 1127, 1335, 1442) lost their indentation and sit in column 0.
| // If this texture has been copied and colourized, we can return | ||
| #if defined(OGRE_VERSION) && OGRE_VERSION < 0x10A00 | ||
| if (!requestedMaterial.isNull()) | ||
| if (requestedMaterial) |
There was a problem hiding this comment.
Both branches of this #if are now identical:
#if defined(OGRE_VERSION) && OGRE_VERSION < 0x10A00
if (requestedMaterial)
#else
if (requestedMaterial)
#endifSince MaterialPtr::isNull() is gone in the versions this PR targets, the conditional has no purpose left — it should go the way MovableTextOverlay.cpp handled the same situation in this PR, which deletes the #if outright. Same pattern at lines 2341 and 2448.
| * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
| */ | ||
|
|
||
| #include <fstream> |
There was a problem hiding this comment.
#include <fstream> is already there three lines further down, so this one is a duplicate and can just be dropped. (ConfigManager.cpp has the same thing.)
More generally, the new includes across renderscene/ and creaturemood/ are placed above each file's own header. Putting the file's own header first is what proves it's self-contained; an include above it hides a missing include in the header.
|
Opened the fix branch as a PR against this branch so it stacks cleanly rather than duplicating your work: slapin#1 ( It covers the six "should fix" items from the review above and nothing else — the five discussion points are left untouched for you to decide on. Not compile-verified, as noted. Happy to retarget it at |
|
Went back and checked my review against the Ogre source rather than leaving it at "looks like" — cloned OGRECave/ogre master ( Confirmed — Confirmed — the mesh re-serialisation is optional. Upgraded — the two vendored Correction to my own fix PR. I had moved While confirming that, I also verified the path expansion holds: New, and not something I fixed: I have not added it — pulling a binary out of Ogre's sample media into this tree is your call, and the sample media licensing is not obviously the same as Ogre core's MIT. Flagging it because it looks like half of a fix you already started. Still not compile-verified — no Ogre 14 packages exist for this distro, so a real build means building Ogre 14 and the CEGUI fork from source. Everything above is read from upstream source with file and line references so you can check it quickly. |
|
Built it. Ogre 14.6.0 (OGRECave/ogre master The port builds and runs
Correction 1 — you were right to delete ReflMetal.materialI asked you to restore it. That was wrong, and restoring it makes things actively worse.
Meanwhile the cost of deleting it is nil: What actually remains is only the orphans: Correction 2 — the duplicated resources.cfg entries were load-bearingI called the repeated Your hand-written shaders live in the Graphics group and And the symmetric trap, which I walked straight into while fixing that: RTShaderLib must appear only under The part that does still stand: the six Confirmed — the seven T2*/T3* materials are a real bug, not cosmeticI under-called this one. I said it was brace-balanced so Ogre would parse it. It does not: ...and the same for Net resultDiffing the Ogre log of my branch against this PR head, after the corrections:
Startup error count goes 27 → 20. The remaining 20 are pre-existing and outside this PR's scope — mostly Everything in the earlier reviews other than the two corrections above stands — in particular the uninitialised |
|
Chased down the missing sliders in OPTIONS -> AUDIO / GAMEPLAY. Reproduced it, found the cause, and fixed it — pushed as CauseBoth sliders carry this in <Property name="AutoRenderingSurface" value="True" />That asks CEGUI to render the widget subtree into its own RenderingSurface. The Ogre renderer in the CEGUI fork never composites those nested surfaces, so the slider draws nothing at all. Worth correcting one detail in the report: it is not just the thumb that goes missing — the entire slider does, track included. It only looks like the thumb because the The widget is not broken in any other sense. Dumping the tree at runtime shows it alive, visible and correctly positioned the whole time: Thumb at 0.975 of the track, which is right for 100% volume. Layout is fine; it simply never reaches the screen. That is also why it "gets lost in transition" with no error anywhere — CEGUI logs nothing, because as far as it is concerned everything worked. FixDrop the property. Two things worth flaggingThis is not your bug. The underlying CEGUI bug is still there. Removing the property fixes OpenDungeons because nothing else in |
f2a1006 to
cb8084f
Compare
|
I rebased the patches to the latest shaders-improvement branch. Will look into remaining things later. |
|
@Upabjojr Thanks a lot for review and PR! Could you please check which things still stand and I will add TODO-style summary to track things. There are still some UI problems I observe on YES/NO dialogues where buttons are displayed above text, but I am not very good with CEGUI layouts (not good at all I would say). I have very little time these days, but would like to see this going somewhere. |
|
You guys really showed your heart for this project , lots of respect then .... |
|
Hmm 14.5.2 works as it works , but with the newest version of ogre, from master branch gives : "An exception has occurred: InvalidParametersException: The shared parameter set 'OgreFroxels' already exists! in GpuProgramManager::createSharedParameters at /home/tom/Downloads/ogre-14.6/OgreMain/src/OgreGpuProgramManager.cpp " Froxels ? are they cousins of Pixels and Vortexes ? |
|
After puling the newest commits. it works even on master branch. But CEGUI window problems remains... |
|
Hmm and it turns out the Wyvern needs the material ReflMetal badly ... :D |
|
@Upabjojr @tomluchowski If anybody has time, please close threads which are considered done and summarize what is left to do in form of task list, i.e.
which would help to continue working on this without being overwhelmed. |
|
Added RefMetal back but not in a nice way. |
|
Still the mechanism for ambient is this : when creature is being marked by mouse cursor or hand , a loop enters all materials So reflMetal.material should have at least " param_named ambient float3 1.0 1.0 1.0 " line somewhere .... without that when you mark your Wyvern with cursor an exception is thrown: I will try my luck in the shaders alchemy then ... EDIT : adding 'param_named ambient float3 1.0 1.0 1.0' does not change this material shader config ( ReflMaterial.material) |
|
Please try to mark the Wywern , - the Legacy Test Level -- down from the main base ( they leave somewhere there -- flying creatures in the shinning armors ... ;) |
|
Fixed highlighting for creatures using ReflMaterial (Wyvern). |
|
Well, for some reason I don't see much armor on the Wyvern either, but at least no crash. Need to debug this more... |
|
@tomluchowski F4 skill tree — reproduced and fixed: slapin#5. The window wasn't broken by the research code; it's a casualty of the titlebar fix. The layout sizes the window 610x392 and arranges the three skill columns for a client area that big — which is what the old skin's broken @slapin thanks for confirming — nothing in the log means the ReflMetal GLSL compiles and links clean on your driver, so the armor is being drawn invisible rather than rejected, which narrows it usefully. When you get a chance (no rush on the pre-port check), here's a two-minute bisection that would tell us exactly which half to chase — replace the last line of color = vec4(mix(lighting, reflection, 0.5), 1.0);with color = vec4(1.0, 0.0, 0.0, 1.0);
Together with the pre-port answer (did the armor ever show on that laptop before 14.x?) that should pin it down without me needing NVIDIA hardware. |
ODSocketServer::mActualPort was declared but never initialised, so ODServer::getNetworkPort() read an indeterminate value whenever it ran before createServer() and could hand out a garbage port. ODFrameListener::renderQueueStarted() dereferenced CameraManager::getActiveCamera() unconditionally, but that pointer starts as nullptr and stays null until createCamera() runs. ReflMetal.material was deleted while Roundshield.mesh, Sabre.mesh and Wyvern.mesh still name the ReflMetal material, and shaders/ReflMetal.vert, shaders/ReflMetal.frag and materials/textures/EnvmapMetal.png were all left in the tree. Restore the script rather than leave those meshes falling back to the default material. Seven of the converted normal-map materials had their braces reflowed so that "normal_map }" closed the rtshader_system block on the same line and the pass lighting block lost its own closing brace line. It still parses, but the nesting no longer reads correctly. Restore the structure the other materials use and spell the mapping space explicitly as tangent_space, matching the pre-conversion default. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
dumpWindowTree() walked the whole widget tree and wrote a line per widget straight to std::cerr every time the settings window was opened, and MenuModeMain::activate() logged the root window geometry on every entry to the main menu. Both look like instrumentation kept from tracking down the layout problems, not something to ship. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Move the newly added <iostream>/<fstream> includes below each file's own header so the headers stay self-contained, and drop the two that merely duplicated an include already present further down. Restore the indentation on the five statements that ended up in column 0 next to the new buildTangentVectorsIfNeeded() calls, take the MeshPtr by const reference instead of copying the shared pointer, and guard against a null mesh. Drop the redundant .get() calls and the three "#if OGRE_VERSION < 0x10A00 / #else" blocks whose branches are now identical. Let CMAKE_CXX_STANDARD drive the language standard on its own: the -std=c++11 flag the OD_CXX11_FLAGS probe injected into CMAKE_CXX_FLAGS contradicted the newly requested C++14, and nothing asked CMake to treat the standard as required. Fold the duplicated [Graphics] section in resources.cfg.in into one, and drop the hardcoded share/OGRE/Media/RTShaderLib paths now that @RTSHADER_DIR@ and @OGRE_MEDIA_DIR@ point at the same place. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Ogre ships CMake/Templates/resources.cfg.in with both Main and RTShaderLib
under [OgreInternal]; putting RTShaderLib under [Graphics] instead leaves
the RTSS shader library in a different group from the Main headers it
includes.
Verified against OGRECave/ogre master: OGREConfig.cmake does
set_and_check(OGRE_MEDIA_DIR ...), so @OGRE_MEDIA_DIR@ and @RTSHADER_DIR@
both expand for consumers using find_package(OGRE CONFIG) as we do. The
share/OGRE/Media/RTShaderLib/{GLSL,HLSL,HLSL_Cg,materials} paths dropped in
the previous commit no longer exist at all -- RTShaderLib is flat since the
1.x layout was collapsed.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Built Ogre 14.6.0 and the CEGUI fork from source and ran the game; both of these were wrong and the runtime proved it. Restoring ReflMetal.material was a mistake. Its shaders do not compile against Ogre 14 at all: ReflMetal.vert/.frag include FFPLib_Texturing.glsl, which calls the ENABLE_LINEAR_COLOUR macro that only RTSLib_Colour.glsl defines, and adding that include just exposes the next layer -- FFP_Transform has a different signature and SGX_Light_Point_DiffuseSpecular no longer exists. Meanwhile Roundshield.material and Wyvern.material exist in their own right and Ogre logs nothing at all about the missing material. Deleting it was correct; restoring it traded a silent fallback for two hard shader compile errors. Reverted. (What remains is only the orphaned shaders/ReflMetal.* and materials/textures/EnvmapMetal.png.) The duplicated resources.cfg entries were load-bearing, not an accident. Our hand-written shaders live in the Graphics group and #include OgreUnifiedShader.h and the RTShaderLib sources; Ogre resolves those includes within the same resource group, so Media/Main genuinely has to appear under [Graphics] as well as [OgreInternal]. Removing it cost five shader programs. RTShaderLib, in contrast, must appear ONLY under [Graphics] -- listing it in both groups makes RTSSamplers.material parse twice and Ogre throws "Sampler 'Ogre/ShadowSampler' already exists" during startup, which killed the game before it reached the menu. Documented both constraints in the file so the next person does not tidy them away again. Dropping the six @CMAKE_INSTALL_PREFIX@/share/OGRE/Media/RTShaderLib* paths still stands: they point into OUR install prefix, not Ogre's, and the GLSL/HLSL/HLSL_Cg/materials subdirectories no longer exist now that RTShaderLib is flat. Verified: no new Ogre errors versus the PR head, and the seven T2*/T3* material errors this branch fixes are real ScriptCompiler failures. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Both sliders carried AutoRenderingSurface="True", which asks CEGUI to render
that widget subtree into its own RenderingSurface. The Ogre renderer in the
CEGUI fork never composites those nested surfaces, so the slider drew
nothing at all -- no track, no thumb -- while still reporting itself as
visible and correctly positioned. The label above it ("Music: 100%",
"Ambient Light: +184%") kept rendering, which is what makes it look like
only the thumb went missing.
The property is not part of the Ogre 14 port; it predates it and happened to
work with the CEGUI and Ogre the game used before. Nothing else in gui/ sets
it, so these two sliders were the only widgets affected -- which matches the
report that only OPTIONS -> AUDIO and OPTIONS -> GAMEPLAY are broken.
False is the CEGUI default, so the property is simply dropped rather than
set. Verified by screenshotting both tabs with the property on and off,
against Ogre 14.6.0 and the CEGUI fork built from source.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
- Removeg Ogre/Main from OgreInternal group. That breaks startup in latest Ogre master. - Removed unused variable.
Restored the material and updated it to recent Ogre with help of DeepSeek. Not sure it works as intended, but it does not crash. Please note that it replaces shaders/ReflMetal.frag and shaders/ReflMetal.vert with OpenGL 3.3 core versions instead of RTSS versions requiring OpenGL 4.60. This change should unify these with most shaders using OpenGL 3.3 core as base. The better fix would use unified shader header for render system compatibility.
Added 'ambient' parameter to ReflMetal material to make highlighting of creatures using this material work.
Ogre 14 dropped the normalise_normals pass token and rejects a bare illumination_stage with no argument; the ten blender2ogre-exported materials (MysteryBox, TrollRock, Boulder, SmallSpider, KnightStatue, KnightStatue2, KnightCoffin, Spiketrap, Skull_Monster, AdventurerBed) carried both lines and produced twenty ScriptCompiler errors at startup. Both lines restated defaults (normalise_normals off is the default), so deleting them changes nothing else. DungeonTemple's Stacheln spikes were the one remaining user of env_map spherical + colour_op_ex blend_manual, both removed in 14.x. They get the same treatment ReflMetal already got: a GL 3.3 shader pair reproducing the spherical reflection and the 0.3 manual blend over the alpha-blended decal, with the surface colours still driven by the pass via surface_* auto params. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
materials/RTShaderLib/GLSL appears in no resources.cfg group and Ogre 14 ships both files itself at @RTSHADER_DIR@ (Media/RTShaderLib), which the Graphics group already lists. The in-tree copies were installed with the rest of materials/ but never reachable by the resource system, and they would silently drift from whatever Ogre version is actually installed. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The ephemeral-port fallback in createServer() made single player robust, but it also applied while hosting: if a LAN host's configured port was busy the server silently bound another port, remote clients kept dialing the advertised one, and the host got a connection that never establishes instead of an error. Local modes (skirmish, editor, loaded saves) still fall back — their client reaches the server through getNetworkPort(), which reports the port actually bound. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
RTShaderSystem.material references Panels_Diffuse.png in both RTSS/PerPixel_SinglePass (the base of Bed.material and Cannonball.material) and RTSS/NormalMapping_MultiPass, but the texture only ships in Ogre's sample media, which stock Ogre installs leave out. Panels_Normal_Tangent.png was already vendored for the same reason — this adds its diffuse companion, byte-for-byte from OGRECave/ogre Samples/Media/materials/textures (MIT), and credits both in CREDITS. Also drops the CREDITS entry for the RTShaderLib copies deleted earlier. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The one-shot scaling in the constructor pinned the settings and apply-changes windows to pixel offsets computed for the resolution at construction time — and this is the very window resolutions are applied from, so after a resolution change it stayed sized for the old one until restart. Scaling is now redone on System::EventDisplaySizeChanged (ODFrameListener::windowResized already fires it): child widgets move between scales by plain offset ratio, and the top-level window is re-centered from its designed area each time. This also fixes a mixed-scale bug: initConfig() recreates the extra video-option widgets after applying settings, and they were laid out in unscaled design pixels inside an already-scaled window. They are now brought to the current UI scale on creation. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The port gave OD/FrameWindow a proper ClientWithTitleWithFrame area (it used to be an empty <Area/>, i.e. the whole window). Correct, but the quit, load-confirm and apply-changes dialogs were laid out against the old full-window coordinates, so in the shrunken client area their buttons landed on top of the text and bottom widgets (the save-replay checkbox) fell below the clipped edge. Anchor the button rows to the client area's bottom edge and let the text own the space above them, so the dialogs lay out correctly whatever room the titlebar and frame take. Also fixes ApplyText's VertFormatting property, which was spelled with capitalized XML attributes (Name=/ Value=) and therefore silently ignored. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The rename from 'invocation' to 'cameraName' is a semantic claim about what Ogre passes here, and it silently decides whether CEGUI ever gets drawn. Name the Ogre version and upstream source so the next reader does not have to re-do the archaeology. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The creature stats text has ~22 lines nowadays and the frame's client area no longer includes the titlebar, so the tail of the text (the mood lines) was clipped at the frame's bottom edge. Give the text pane the whole client area, enable the vertical scrollbar OD/StaticText already supports, and make the creature window a bit taller. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The explanatory comment and the FIXME left from debugging contradicted each other. State plainly why the X11 cursor is hidden unconditionally (CEGUI draws its own cursor; with grabbing, OIS warping makes the system cursor drift) and what the trade-off is. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Runtime-verified against Ogre 14.6 + the CEGUI fork: the OD/FrameWindow titlebar is ~45px tall, so the 139px quit dialog left only ~55px of client area — not enough for the button row plus the replay checkbox, and the buttons overlapped the title text. Make the quit and apply-changes dialogs 190px tall; with the bottom-anchored rows the dialogs now render with the full question in the titlebar, the buttons in a clean row and the checkbox below. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The titlebar (and close button) auto-widgets were positioned relative to the frame's client area — but the client area starts below the titlebar, so the titlebar rendered its own height too low, leaving a strip of bare background between it and the window's top border and wasting the same amount of client space. That is the 'titlebar is misplaced' from the PR discussion. Mark both auto-widgets NonClient so they resolve against the window's outer rect: the titlebar sits at the top edge, stably, and the client area computed from its bottom edge is correct. Verified in-game against Ogre 14.6 + the CEGUI fork on the settings window and the apply-changes dialog. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
An Ogre built against its bundled dependencies but installed with OGRE_INSTALL_DEPENDENCIES left OFF (the default outside Windows and Apple) exports the OgreBullet component with an include/bullet directory that does not exist. CMake refuses to generate for any target linking such an imported target, and OGRE_LIBRARIES drags OgreBullet into every OGRE consumer, so configuring the game against such an install dies with "Imported target OgreBullet includes non-existent path". The game never touches a Bullet header, so the only harm the missing directory can do is make CMake stop. Filter the dead entries out of the imported target after find_package and move on. Building Ogre with -DOGRE_INSTALL_DEPENDENCIES=ON (or without the Bullet component) avoids the problem at the source; this just keeps a common configuration of an upstream package from breaking our configure. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_014hrk8PiEUMgjYJnTxLF2PU
The F4 skill tree laid its three columns and button bar out for a 610x392 window whose client area was the whole window, which is what the broken ClientWithTitleWithFrame area in the old skin gave it. With the skin's client area fixed to sit inside the frame and below the titlebar, the same window only has 538x329 to offer, and the content no longer fits: the magic column loses its right half and the fourth row of skills is cut through the middle, with nothing to scroll by. The content needs 610x380; with 36px of frame a side and a 27px titlebar that means a 690x450 window, which still fits the 800x600 design minimum. Same class of fix as the Yes/No dialogs that needed height for the titlebar the skin actually draws. Verified in a single-player game at 1920x1200: all three skill columns show every row, and the Auto Fill / Unselect All / Cancel / Apply bar sits clear below them. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_014hrk8PiEUMgjYJnTxLF2PU
|
Merged slapin#5 |
|
Will look into ReflMaterial as I have time later. |

Updates to make work in Ogre 14.5+ (master branch).
Created in association with Kimi Code v2.7.