Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 14 Feb 2020 23:12:11 +0000 (UTC)
From:      Dmitry Marakasov <amdmi3@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r526186 - in head/games/openmw: . files
Message-ID:  <202002142312.01ENCB3d066952@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: amdmi3
Date: Fri Feb 14 23:12:10 2020
New Revision: 526186
URL: https://svnweb.freebsd.org/changeset/ports/526186

Log:
  - Bump revision after graphics/osg update, add patches to fix build with newer mygui and osg

Added:
  head/games/openmw/files/patch-components_esm_custommarkerstate.hpp   (contents, props changed)
  head/games/openmw/files/patch-osg3.6.5   (contents, props changed)
Modified:
  head/games/openmw/Makefile

Modified: head/games/openmw/Makefile
==============================================================================
--- head/games/openmw/Makefile	Fri Feb 14 23:11:56 2020	(r526185)
+++ head/games/openmw/Makefile	Fri Feb 14 23:12:10 2020	(r526186)
@@ -4,7 +4,7 @@
 PORTNAME=	openmw
 DISTVERSIONPREFIX=	openmw-
 DISTVERSION=	0.45.0
-PORTREVISION=	8
+PORTREVISION=	9
 CATEGORIES=	games
 
 PATCH_SITES=	https://github.com/${GH_ACCOUNT}/${GH_PROJECT}/commit/

Added: head/games/openmw/files/patch-components_esm_custommarkerstate.hpp
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/games/openmw/files/patch-components_esm_custommarkerstate.hpp	Fri Feb 14 23:12:10 2020	(r526186)
@@ -0,0 +1,11 @@
+--- components/esm/custommarkerstate.hpp.orig	2019-03-10 10:50:29 UTC
++++ components/esm/custommarkerstate.hpp
+@@ -16,7 +16,7 @@ struct CustomMarker
+ 
+     std::string mNote;
+ 
+-    bool operator == (const CustomMarker& other)
++    bool operator == (const CustomMarker& other) const
+     {
+         return mNote == other.mNote && mCell == other.mCell && mWorldX == other.mWorldX && mWorldY == other.mWorldY;
+     }

Added: head/games/openmw/files/patch-osg3.6.5
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/games/openmw/files/patch-osg3.6.5	Fri Feb 14 23:12:10 2020	(r526186)
@@ -0,0 +1,62 @@
+See https://github.com/OpenMW/openmw/pull/2676
+
+From 4eb330b4ed794fd6201f7954a517dec29678c285 Mon Sep 17 00:00:00 2001
+From: Julien Valentin <julienvalentin51@gmail.Com>
+Date: Mon, 27 Jan 2020 23:44:22 +0100
+Subject: [PATCH] comply with new OQN API
+
+---
+ apps/openmw/mwrender/sky.cpp | 17 ++++++++++++-----
+ 1 file changed, 12 insertions(+), 5 deletions(-)
+
+diff --git a/apps/openmw/mwrender/sky.cpp b/apps/openmw/mwrender/sky.cpp
+index 3996f472c2..009b9d935f 100644
+--- apps/openmw/mwrender/sky.cpp
++++ apps/openmw/mwrender/sky.cpp
+@@ -2,6 +2,7 @@
+ 
+ #include <cmath>
+ 
++#include <osg/Version>
+ #include <osg/ClipPlane>
+ #include <osg/Fog>
+ #include <osg/Transform>
+@@ -557,27 +558,33 @@ class Sun : public CelestialBody
+     {
+         osg::ref_ptr<osg::OcclusionQueryNode> oqn = new osg::OcclusionQueryNode;
+         oqn->setQueriesEnabled(true);
+-
++#if OSG_VERSION_LESS_THAN(3,6,5)
++        osg::Geometry* queryGeom = oqn->getQueryGeometry();
++#else
++        osg::ref_ptr<osg::QueryGeometry> queryGeom(new osg::QueryGeometry());
++#endif
+         // Make it fast! A DYNAMIC query geometry means we can't break frame until the flare is rendered (which is rendered after all the other geometry,
+         // so that would be pretty bad). STATIC should be safe, since our node's local bounds are static, thus computeBounds() which modifies the queryGeometry
+         // is only called once.
+         // Note the debug geometry setDebugDisplay(true) is always DYNAMIC and that can't be changed, not a big deal.
+-        oqn->getQueryGeometry()->setDataVariance(osg::Object::STATIC);
++        queryGeom->setDataVariance(osg::Object::STATIC);
+ 
+         // Set up the query geometry to match the actual sun's rendering shape. osg::OcclusionQueryNode wasn't originally intended to allow this,
+         // normally it would automatically adjust the query geometry to match the sub graph's bounding box. The below hack is needed to
+         // circumvent this.
+-        osg::Geometry* queryGeom = oqn->getQueryGeometry();
+         queryGeom->setVertexArray(mGeom->getVertexArray());
+         queryGeom->setTexCoordArray(0, mGeom->getTexCoordArray(0), osg::Array::BIND_PER_VERTEX);
+-        queryGeom->removePrimitiveSet(0, oqn->getQueryGeometry()->getNumPrimitiveSets());
++        queryGeom->removePrimitiveSet(0, queryGeom->getNumPrimitiveSets());
+         queryGeom->addPrimitiveSet(mGeom->getPrimitiveSet(0));
+ 
++#if OSG_VERSION_LESS_THAN(3,6,5)
+         // Hack to disable unwanted awful code inside OcclusionQueryNode::computeBound.
+         oqn->setComputeBoundingSphereCallback(new DummyComputeBoundCallback);
+         // Still need a proper bounding sphere.
+         oqn->setInitialBound(queryGeom->getBound());
+-
++#else
++        oqn->setQueryGeometry(queryGeom);
++#endif
+         osg::StateSet* queryStateSet = new osg::StateSet;
+         if (queryVisible)
+         {



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202002142312.01ENCB3d066952>