Re: [osg-users] freetype build support on Windows

2016-06-03 Thread Stuart Mentzer
Hi Robert,

Here's what I found doing release and debug builds from yersterday's git master 
code with Visual C++ 2015:

freetype even using -DWITH_PNG=OFF will still try to include png.h and for some 
reason requires ftoption.h (both copies) to be modified (or overridden) to 
comment out the line:
#define FT_CONFIG_OPTION_USE_PNG
This is unfortunate and actually makes it easier to build freetype with PNG 
support. With the freetype mods OSG builds including the freetype plugin. 
Configuring freetype with or without PNG support is up to the builder but it 
would be good if the CMakeLists.txt could handle both situations without 
needing changes like I made.

The freetype build headers under include\freetype2\freetype even though 
freetype doesn't use that freetype2 layer anymore. Not a big deal since OSG 
doesn't really need to ship with freetype or other 3rd party lib headers.

The debug build is able to build freetype with the same mods but the OSG build 
doesn't find it:
-- Could NOT find Freetype (missing:  FREETYPE_LIBRARY) (found version "2.6.3")
which I assume is due to not looking for the name freetyped, as I found with my 
OSG 3.4.0 build. So the OSG build can complete but it won't build the freetype 
plugin.

The debug build fails at "Installing the project..." because it appears 
something is wrong with the new pdb installation support:
-- Installing: C:/OSG.VC.xd/bin/osgd.dll
CMake Error at src/osg/cmake_install.cmake:39 (file):
  file INSTALL cannot find
  "C:/Projects/OSG/VC.xd/OSG/src/osg/PREFIX-NOTFOUNDosgd.pdb".
Call Stack (most recent call first):
  src/cmake_install.cmake:33 (include)
  cmake_install.cmake:100 (include)
The osgd.pdb file is present and next to osgd.dll as expected.

I see that others are reporting success with the Visual C++ 2015 build but I 
don't know how they are addressing the freetype PNG issues or if they tried the 
debug build yet. It looks like there are still some issues but maybe they will 
offer some input here. I'm happy to make another pass if that helps.

Stuart

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=67406#67406





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] MSVS2015 3rdparty build

2016-06-03 Thread Carl-Gustaf Kung
Hi,

In a true necromancer fashion I would like to resurrect this thread, since I 
need some help with Björn's scripts. 

I managed to compile OSG from scratch, inclusive all 3rd party libraries. I 
have used VS2015, a x64 build, and all 3rd party libs are also compiled by me 
as 64-bit shared libraries. I have generally followed build instructions and 
methods as much as possible as provided by the respective library. In some 
cases I have cooked my own (giflib notably, zlib). Curl was really picky to get 
a dll with OpenSSL. 

Anyway, I did stumbled upon Björn's CMake files, but I couldn't got them to 
work. I am not sure if I have got it right? I am suppose to downolad 3rd party 
sources and place your cmake files in respective folder? I have tried that, but 
it didn't worked for me. It was 2 days ago I tryed it, so I don't remember the 
errors I got. 

I would like to be able to use Björn's cmakes, since it took me quite while to 
figure out each one library and build method on it's own. Havin'g those 
makefiles would also make it possible for me to write a batch file to update 
and build things automatically instead of me doing each and every manually.

I'm quite sure I just qoofed it up somewhere and I would be really helpful for 
help.

I also wonder if somebody has compiled Collada 2.4, with vs2015 for 64 bit 
arch, I am a bit stuck with it.

Best regards & thank you!

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=67329#67329





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] [build] CMake not finding many 3rd party plugins for vs2013

2016-06-03 Thread Carl-Gustaf Kung
I have built OSG yesterday, and I have build all 3rd party manually. I also 
have all 3rd party libs in a custom build tree where I have other libraries and 
code I use.

After the prerequisites are built, what I did was to generate OSG vs project 
files as described on webpage. Then I opened VS solution and just changed paths 
to reflect my build tree.

I don't think you should try pre-build libs from some place on the web. 
Security aside, there is still question of compiler flags, runtime, what 
libraries the pre-compiled code is link to etc etc. You wan't to compile all 
libraries you use by same compiler and for same runtime to ensure for ABI 
compatibility.

For the record, I have my custom little sdk placed in c:\x64, where I have 
typical (unix-like) structure with bin, lib & include where I put accordingly 
dlls, libs and headers for stuff I compile and use.

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=67331#67331





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] MSVS2015 3rdparty build

2016-06-03 Thread Carl-Gustaf Kung
I have also forgot to ask: is there a reason to prefer ijg's libjpeg instead of 
libjpeg-turbo and glut instead of freeglut?

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=67330#67330





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] OpenSceneGraph-3.5.3 developer release tagged

2016-06-03 Thread Robert Osfield
Hi All,

I have tagged the OpenSceneGraph-3.5.3 developer release, a
significant milestone towards the stable 3.6.0 that I'll make this
summer.

The github tag is:

https://github.com/openscenegraph/OpenSceneGraph/tree/OpenSceneGraph-3.5.3

I haven't had a chance to update the website yet, it's evening here
and have a busy weekend so won't have a chance to update it so this
will have to wait till next week.

Changes?  Well lots, mostly minor though, things like build, runtime
and warning/coverity fixes.  Can't think of any major features off the
top of my head but then I'm tired and have lots of other things to get
on with this evening so you'll have to read the ChangeLog.  Oh support
for glMultiDrawArrays/osg::MultiDrawArrays will be one for those who
want to squeeze that extra bit of performance out.

Thanks to all those who've contributed to testing, fixes and new features.

Cheers,
Robert.


Fri, 3 Jun 2016 17:57:04 +0100
Checked in by : Julien Valentin
Fixed little bug in DrawArraysLength (instancing not supported).
Corrected PrimitiveSet.cpp in order DrawArraysLength can be instanced.
It's the only pr missing code if (_numInstances>=1)
glDrawXXXInstanced(...,_numInstances); else glDrawXXX();

Fri, 3 Jun 2016 17:38:32 +0100
Checked in by : Robert Osfield
Added -Wno-deprecated-register for Clang build to quieten warnings
related to lex/yacc generated files

Fri, 3 Jun 2016 17:33:45 +0100
Checked in by : Björn Blissing
Last two files with fixes to the virtual inheritance warnings...I have
also attached the fix to the type shadowing problem in
ConvexPolyhedron.cpp


Fri, 3 Jun 2016 17:30:12 +0100
Checked in by : Björn Blissing
fix for the rest of the VS2015 virtual inheritance warnings. Same as
for issues as for the Operation class.

Fri, 3 Jun 2016 17:22:28 +0100
Checked in by : Björn Blissing
VS2015 build fix

Fri, 3 Jun 2016 11:30:48 +0100
Checked in by : Björn Blissing
Fixed VS2015 compiler warnings

Fri, 3 Jun 2016 11:28:10 +0100
Checked in by : Robert Osfield
Added float variants of osg::PI etc. in the form osg::PIf Converted
osg::PI usage to osg::PIf in ShapeDrawable.cpp to address Windows
build errors

Fri, 3 Jun 2016 10:18:41 +0100
Checked in by : Robert Osfield
Fixed Clang warnings related to external dependencies

Fri, 3 Jun 2016 09:33:47 +0100
Checked in by : Robert Osfield
Fixed clang warnings

Thu, 2 Jun 2016 20:00:42 +0100
Checked in by : Robert Osfield
Added check against GCC version when adding the -Wshadow warning to
OSG_AGGRESSIVE_WARNING_FLAGS so that it's only used in versions later
than 4.9.

Thu, 2 Jun 2016 17:54:24 +0100
Checked in by : Robert Osfield
Moved the REGISTER_WINDOWINGSYSTEMINTERFACE macro into the osgViewer namespace

Thu, 2 Jun 2016 17:50:53 +0100
Checked in by : Robert Osfield
Removed osgViewer:: prefix to addres build error

Thu, 2 Jun 2016 16:04:06 +0100
Checked in by : Juan Hernando Vieites
The current implementation of readImageFromCurrentTexture doesn't
consider the texture rectangle mode. Find attached a version of the
file that corrects this issue

Thu, 2 Jun 2016 15:43:31 +0100
Checked in by : Robert Osfield
Fixed potential memory leak

Thu, 2 Jun 2016 15:41:15 +0100
Checked in by : Robert Osfield
Fixed uninitialized variable.

Thu, 2 Jun 2016 15:35:47 +0100
Checked in by : Robert Osfield
Added handling of failure to create ElementBufferObject.

Thu, 2 Jun 2016 15:23:38 +0100
Checked in by : Robert Osfield
Removed debugging code

Thu, 2 Jun 2016 14:56:43 +0100
Checked in by : Robert Osfield
Moved status check to quieten coverity warning

Thu, 2 Jun 2016 14:53:11 +0100
Checked in by : Robert Osfield
Added missing break

Thu, 2 Jun 2016 14:38:23 +0100
Checked in by : Robert Osfield
Removed debug message

Thu, 2 Jun 2016 14:36:38 +0100
Checked in by : Robert Osfield
Fixed redundent checks and clean up clone usage

Thu, 2 Jun 2016 14:33:32 +0100
Checked in by : Robert Osfield
Added missing break

Thu, 2 Jun 2016 14:31:44 +0100
Checked in by : Robert Osfield
Fixed method to match parent class.

Thu, 2 Jun 2016 14:30:58 +0100
Checked in by : Robert Osfield
Fixed method to match parent class.

Thu, 2 Jun 2016 14:22:25 +0100
Checked in by : Robert Osfield
Removed redudent codepaths, standardizing on the most portable Texture2D path.

Thu, 2 Jun 2016 14:18:12 +0100
Checked in by : Robert Osfield
Removed redudent code paths

Thu, 2 Jun 2016 13:51:46 +0100
Checked in by : Robert Osfield
Cleaned up the cloning usage

Thu, 2 Jun 2016 13:23:34 +0100
Checked in by : Robert Osfield
Fixed unitialized variables

Thu, 2 Jun 2016 13:03:07 +0100
Checked in by : Robert Osfield
Set default value of OSG_USE_REF_PTR_SAFE_DEREFERENCE of OFF to avoid
the check overhead polutting all OSG applications.

Thu, 2 Jun 2016 12:43:09 +0100
Checked in by : Robert Osfield
Fixed typo

Thu, 2 Jun 2016 12:22:51 +0100
Checked in by : Robert Osfield
Fixed build issues when OSG_USE_REF_PTR_IMPLICIT_OUTPUT_CONVERSION is set to OFF

Thu, 2 Jun 2016 11:25:40 +0100
Checked in by : Robert Osfield

Re: [osg-users] PagedLOD and page in/out detection

2016-06-03 Thread Trajce Nikolov NICK
Hi Robert,

thanks for the *hints* :) ... Reading the code is always the best option
:-). I found the thing while reading the code you pointed me to. It is this
thing that when set up properly per the database, then it works nicely ..

viewer->getDatabasePager()->setTargetMaximumNumberOfPageLOD(...);

Thanks again!

Cheers,
Nick

p.s. I still like my simple hack :-). I will keep it and not do it the
proper way this time ;-)

On Fri, Jun 3, 2016 at 7:51 PM, Robert Osfield 
wrote:

> Hi Nick,
>
> It's *really* inefficient to use an update callback to do this type of
> task, I can not recommend going this path, it's waste of both our time
> trying to coax it to do something useful.
>
> The right way of doing it is by overriding the
> DatabasePager::updateSceneGraph() method or implementing you own
> equivalent method in the Viewer::updateTraversak() in place of current
> calls to updateceneSceneGraph().
>
> Robert.
>
> On 3 June 2016 at 18:28, Trajce Nikolov NICK
>  wrote:
> > Hi Robert,
> >
> > this is my update callback .. And I know for sure it was working. I just
> did
> > a clean app (modified osgviewer with only this callback installed in the
> > root PagedLODs) and I never see a Paged Out tile ... I am limited to not
> > having the possibility to make a custom DatabasePager or it will go
> really
> > complicated. The root PagedLOD can have only one or zero children (that
> is
> > the test database I am testing it against)
> >
> > struct UpdateCallback : public osg::NodeCallback
> > {
> > UpdateCallback()
> > : _numChildren(0)
> > {
> >
> > }
> > virtual void operator()(osg::Node* node, osg::NodeVisitor* nv)
> > {
> > osg::PagedLOD* plod = dynamic_cast(node);
> > if (plod)
> > {
> > if (plod->getNumChildren() != _numChildren)
> > {
> > _numChildren = plod->getNumChildren();
> >
> > if (_numChildren)
> > std::cout << "Paged in" << std::endl;
> > else
> > std::cout << "Paged out" << std::endl;
> >
> > }
> > }
> > traverse(node, nv);
> > }
> > protected:
> > int _numChildren;
> > };
> >
> > On Fri, Jun 3, 2016 at 6:49 PM, Robert Osfield  >
> > wrote:
> >>
> >> Hi Nick,
> >>
> >> There isn't a feature directly built into osg::PageLOD or
> >> DatabasePager for this.
> >>
> >> What you could do is look at the  creating a custom DatabasePager that
> >> overrides the following method:
> >>
> >>/** Merge the changes to the scene graph by calling calling
> >> removeExpiredSubgraphs then addLoadedDataToSceneGraph.
> >>   * Note, must only be called from single thread update phase.
> */
> >> virtual void updateSceneGraph(const osg::FrameStamp&
> frameStamp);
> >>
> >> Within this you could add your own tracking of when things are merge or
> >> removed.
> >>
> >> Robert.
> >>
> >>
> >>
> >> On 3 June 2016 at 17:15, Trajce Nikolov NICK
> >>  wrote:
> >> > Hi Community,
> >> >
> >> > I was looking for a way to detect when PagedLOD gets its children
> paged
> >> > in/out. So I installed an update callback and based on a difference in
> >> > the
> >> > children number I was able to know when such change occurred. And this
> >> > was
> >> > working with a code an year ago.
> >> >
> >> > Now it doesn't .. Any clue or hint how to detect such changes?
> >> >
> >> > Thanks a bunch as always!
> >> >
> >> > Cheers,
> >> > Nick
> >> >
> >> > --
> >> > trajce nikolov nick
> >> >
> >> > ___
> >> > osg-users mailing list
> >> > osg-users@lists.openscenegraph.org
> >> >
> >> >
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
> >> >
> >> ___
> >> osg-users mailing list
> >> osg-users@lists.openscenegraph.org
> >>
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
> >
> >
> >
> >
> > --
> > trajce nikolov nick
> >
> > ___
> > osg-users mailing list
> > osg-users@lists.openscenegraph.org
> >
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
> >
> ___
> osg-users mailing list
> osg-users@lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>



-- 
trajce nikolov nick
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] PagedLOD and page in/out detection

2016-06-03 Thread Robert Osfield
Hi Nick,

It's *really* inefficient to use an update callback to do this type of
task, I can not recommend going this path, it's waste of both our time
trying to coax it to do something useful.

The right way of doing it is by overriding the
DatabasePager::updateSceneGraph() method or implementing you own
equivalent method in the Viewer::updateTraversak() in place of current
calls to updateceneSceneGraph().

Robert.

On 3 June 2016 at 18:28, Trajce Nikolov NICK
 wrote:
> Hi Robert,
>
> this is my update callback .. And I know for sure it was working. I just did
> a clean app (modified osgviewer with only this callback installed in the
> root PagedLODs) and I never see a Paged Out tile ... I am limited to not
> having the possibility to make a custom DatabasePager or it will go really
> complicated. The root PagedLOD can have only one or zero children (that is
> the test database I am testing it against)
>
> struct UpdateCallback : public osg::NodeCallback
> {
> UpdateCallback()
> : _numChildren(0)
> {
>
> }
> virtual void operator()(osg::Node* node, osg::NodeVisitor* nv)
> {
> osg::PagedLOD* plod = dynamic_cast(node);
> if (plod)
> {
> if (plod->getNumChildren() != _numChildren)
> {
> _numChildren = plod->getNumChildren();
>
> if (_numChildren)
> std::cout << "Paged in" << std::endl;
> else
> std::cout << "Paged out" << std::endl;
>
> }
> }
> traverse(node, nv);
> }
> protected:
> int _numChildren;
> };
>
> On Fri, Jun 3, 2016 at 6:49 PM, Robert Osfield 
> wrote:
>>
>> Hi Nick,
>>
>> There isn't a feature directly built into osg::PageLOD or
>> DatabasePager for this.
>>
>> What you could do is look at the  creating a custom DatabasePager that
>> overrides the following method:
>>
>>/** Merge the changes to the scene graph by calling calling
>> removeExpiredSubgraphs then addLoadedDataToSceneGraph.
>>   * Note, must only be called from single thread update phase. */
>> virtual void updateSceneGraph(const osg::FrameStamp& frameStamp);
>>
>> Within this you could add your own tracking of when things are merge or
>> removed.
>>
>> Robert.
>>
>>
>>
>> On 3 June 2016 at 17:15, Trajce Nikolov NICK
>>  wrote:
>> > Hi Community,
>> >
>> > I was looking for a way to detect when PagedLOD gets its children paged
>> > in/out. So I installed an update callback and based on a difference in
>> > the
>> > children number I was able to know when such change occurred. And this
>> > was
>> > working with a code an year ago.
>> >
>> > Now it doesn't .. Any clue or hint how to detect such changes?
>> >
>> > Thanks a bunch as always!
>> >
>> > Cheers,
>> > Nick
>> >
>> > --
>> > trajce nikolov nick
>> >
>> > ___
>> > osg-users mailing list
>> > osg-users@lists.openscenegraph.org
>> >
>> > http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>> >
>> ___
>> osg-users mailing list
>> osg-users@lists.openscenegraph.org
>> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
>
>
>
> --
> trajce nikolov nick
>
> ___
> osg-users mailing list
> osg-users@lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] PagedLOD and page in/out detection

2016-06-03 Thread Trajce Nikolov NICK
Hi Robert,

this is my update callback .. And I know for sure it was working. I just
did a clean app (modified osgviewer with only this callback installed in
the root PagedLODs) and I never see a Paged Out tile ... I am limited to
not having the possibility to make a custom DatabasePager or it will go
really complicated. The root PagedLOD can have only one or zero children
(that is the test database I am testing it against)

struct UpdateCallback : public osg::NodeCallback
{
UpdateCallback()
: _numChildren(0)
{

}
virtual void operator()(osg::Node* node, osg::NodeVisitor* nv)
{
osg::PagedLOD* plod = dynamic_cast(node);
if (plod)
{
if (plod->getNumChildren() != _numChildren)
{
_numChildren = plod->getNumChildren();

if (_numChildren)
std::cout << "Paged in" << std::endl;
else
std::cout << "Paged out" << std::endl;

}
}
traverse(node, nv);
}
protected:
int _numChildren;
};

On Fri, Jun 3, 2016 at 6:49 PM, Robert Osfield 
wrote:

> Hi Nick,
>
> There isn't a feature directly built into osg::PageLOD or
> DatabasePager for this.
>
> What you could do is look at the  creating a custom DatabasePager that
> overrides the following method:
>
>/** Merge the changes to the scene graph by calling calling
> removeExpiredSubgraphs then addLoadedDataToSceneGraph.
>   * Note, must only be called from single thread update phase. */
> virtual void updateSceneGraph(const osg::FrameStamp& frameStamp);
>
> Within this you could add your own tracking of when things are merge or
> removed.
>
> Robert.
>
>
>
> On 3 June 2016 at 17:15, Trajce Nikolov NICK
>  wrote:
> > Hi Community,
> >
> > I was looking for a way to detect when PagedLOD gets its children paged
> > in/out. So I installed an update callback and based on a difference in
> the
> > children number I was able to know when such change occurred. And this
> was
> > working with a code an year ago.
> >
> > Now it doesn't .. Any clue or hint how to detect such changes?
> >
> > Thanks a bunch as always!
> >
> > Cheers,
> > Nick
> >
> > --
> > trajce nikolov nick
> >
> > ___
> > osg-users mailing list
> > osg-users@lists.openscenegraph.org
> >
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
> >
> ___
> osg-users mailing list
> osg-users@lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>



-- 
trajce nikolov nick
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] PagedLOD and page in/out detection

2016-06-03 Thread Robert Osfield
Hi Nick,

There isn't a feature directly built into osg::PageLOD or
DatabasePager for this.

What you could do is look at the  creating a custom DatabasePager that
overrides the following method:

   /** Merge the changes to the scene graph by calling calling
removeExpiredSubgraphs then addLoadedDataToSceneGraph.
  * Note, must only be called from single thread update phase. */
virtual void updateSceneGraph(const osg::FrameStamp& frameStamp);

Within this you could add your own tracking of when things are merge or removed.

Robert.



On 3 June 2016 at 17:15, Trajce Nikolov NICK
 wrote:
> Hi Community,
>
> I was looking for a way to detect when PagedLOD gets its children paged
> in/out. So I installed an update callback and based on a difference in the
> children number I was able to know when such change occurred. And this was
> working with a code an year ago.
>
> Now it doesn't .. Any clue or hint how to detect such changes?
>
> Thanks a bunch as always!
>
> Cheers,
> Nick
>
> --
> trajce nikolov nick
>
> ___
> osg-users mailing list
> osg-users@lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Preparing to make 3.5.3 dev release, please test

2016-06-03 Thread Robert Osfield
Hi François,


On 3 June 2016 at 17:13, François Bérard  wrote:
>> I can seen anywhere where the OSG Cmake build system is adding
>> -Wdeprecated-register.  Are you adding this manually?
>
>
> nope. unzip, cmake, make. This must be a new default on my Clang (Apple LLVM
> version 7.3.0 (clang-703.0.29))
>
> I silenced the warnings by adding:
>
> add_compile_options(-Wno-deprecated-register)

Rather than add this to the root CMakeLists.txt file I have added a
Clang specific section to the src/osgPlugins/cfg/CMakeLists.txt thus:

# lex/yacc generated files use register that causes warnings with
CLang under OSX so disable this warnings.
IF(${CMAKE_CXX_COMPILER_ID} STREQUAL "Clang")
   SET(CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS} -Wno-deprecated-register)
ENDIF()

This is now checked into master.  Could remove you your own mds and test this?

> Doing so, the only warnings that remain are calls to deprecated OSX
> functions on 2 modules:
>

I will have to defer to yourself and other members of the OSG/OSX
community to suggest ways to resolve this warnings.

The two routes would seem to be to update the API usage so it's not
deprecated, this would the cleanest but could break backwards
compatibility if the new API's only exist in modern versions of the
OSX - we would need to check how far new API usage goes and decide as
a community whether this is far enough back.  The other approach is to
see if we can disable these warnings, this is a bit hacky though...

For the OSG-3.5.3 dev release I'm happy to leave these deprecated
warnings in place and let the OSG/OSX community tackle the deprecated
warnings.  The OSG/OSX isn't a large contingent so those who do use
the platform will be engage to make sure we don't end up breaking
things on certain OSX/iOS combinations.

Cheers,
Robert.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Preparing to make 3.5.3 dev release, please test

2016-06-03 Thread Robert Osfield
Thanks Bjorn, final three files now merged and pushed to master.
Great to hear that VS2015 is now compiling cleanly.

On 3 June 2016 at 15:02, Björn Blissing  wrote:
> Hi again,
>
> Forgot to attach the last two files with fixes to the virtual inheritance 
> warnings...
>
> I have also attached the fix to the type shadowing problem in 
> ConvexPolyhedron.cpp
>
> With this I think that the OSG Core group of projects compiles without 
> warnings on Visual Studio 2015.
>
> Regards
> Björn
>
>>-Original Message-
>>From: osg-users [mailto:osg-users-boun...@lists.openscenegraph.org] On
>>Behalf Of Björn Blissing
>>Sent: Friday, June 3, 2016 3:35 PM
>>To: OpenSceneGraph Users 
>>Subject: Re: [osg-users] Preparing to make 3.5.3 dev release, please test
>>
>>Hi again,
>>
>>This is the fix for the rest of the virtual inheritance warnings. Same as for
>>issues as for the Operation class.
>>
>>Regards
>>Björn
>>
>>>-Original Message-
>>>From: osg-users [mailto:osg-users-boun...@lists.openscenegraph.org] On
>>>Behalf Of Björn Blissing
>>>Sent: Friday, June 3, 2016 2:39 PM
>>>To: OpenSceneGraph Users 
>>>Subject: Re: [osg-users] Preparing to make 3.5.3 dev release, please test
>>>
>>>Hi Robert,
>>>
>>>The warnings relating the Operation class comes from the two protected
>>>constructors. Since the class uses virtual inheritance it is initialized by 
>>>the
>>most
>>>derived class. So the initializer for the virtual base class is ignored.
>>>
>>>So just removing the base class initializer for Operation will remove this
>>>warning. I do not think this will have any negative side effects, since base
>>class
>>>initializer should be ignored by all compliant compilers anyway.
>>>
>>>I have attached the changed file.
>>>
>>>Regards
>>>Björn
>>>
-Original Message-
From: osg-users [mailto:osg-users-boun...@lists.openscenegraph.org] On
Behalf Of Robert Osfield
Sent: Friday, June 3, 2016 1:46 PM
To: OpenSceneGraph Users 
Subject: Re: [osg-users] Preparing to make 3.5.3 dev release, please test

Hi Bjorn,

On 3 June 2016 at 09:48, Björn Blissing  wrote:
>
> I compiled the latest master with Visual Studio 2015.
>
> I got a couple of warnings.  First of all I got a ton of these, which all
>>>originates
from the same origin:
>
>
> Code:
>
> ...
> OpenSceneGraph\include\osg/OperationThread(80): warning C4589:
Constructor of abstract class 'osg::Operation' ignores initializer for 
virtual
>>>base
class 'osg::Referenced' (compiling source file
D:\github\OpenSceneGraph\src\osg\AnimationPath.cpp)
>   OpenSceneGraph\include\osg/OperationThread(80): note: virtual base
classes are only initialized by the most-derived type (compiling source file
D:\github\OpenSceneGraph\src\osg\AnimationPath.cpp)
> ...
>
>
>
>
> And the same warnings for the following classes:
>
>
> Code:
>
> OpenSceneGraph\src\osgGA\CameraManipulator.cpp(24): warning
>>C4589:
Constructor of abstract class 'osgGA::CameraManipulator' ignores initializer
>>>for
virtual base class 'osg::Callback'
>   OpenSceneGraph\src\osgGA\CameraManipulator.cpp(24): note: virtual
base classes are only initialized by the most-derived type
> OpenSceneGraph\src\osgGA\StandardManipulator.cpp(51): warning
>>>C4589:
Constructor of abstract class 'osgGA::StandardManipulator' ignores
>>initializer
for virtual base class 'osg::Callback'
>   OpenSceneGraph\src\osgGA\StandardManipulator.cpp(51): note:
>>virtual
base classes are only initialized by the most-derived type
> OpenSceneGraph\src\osgViewer\ViewerBase.cpp(44): warning C4589:
Constructor of abstract class 'osgViewer::ViewerBase' ignores initializer 
for
virtual base class 'osg::Object'
>   OpenSceneGraph\src\osgViewer\ViewerBase.cpp(44): note: virtual
>>base
classes are only initialized by the most-derived type
> OpenSceneGraph\src\osgViewer\ViewerBase.cpp(50): warning C4589:
Constructor of abstract class 'osgViewer::ViewerBase' ignores initializer 
for
virtual base class 'osg::Object'
>   OpenSceneGraph\src\osgViewer\ViewerBase.cpp(50): note: virtual
>>base
classes are only initialized by the most-derived type
> OpenSceneGraph\src\osgAnimation\AnimationManagerBase.cpp(65):
warning C4589: Constructor of abstract class
'osgAnimation::AnimationManagerBase' ignores initializer for virtual base
>>>class
'osg::Callback'
>   OpenSceneGraph\src\osgAnimation\AnimationManagerBase.cpp(65):
note: virtual base classes are only initialized by the most-derived type

Unfortunately I don't see these warnings with the compiler I have
available with the settings that are currently available.  Do you know
of what 

Re: [osg-users] Preparing to make 3.5.3 dev release, please test

2016-06-03 Thread Robert Osfield
Thanks Bjorn, both files now merged and pushed to master.

On 3 June 2016 at 14:34, Björn Blissing  wrote:
> Hi again,
>
> This is the fix for the rest of the virtual inheritance warnings. Same as for 
> issues as for the Operation class.
>
> Regards
> Björn
>
>>-Original Message-
>>From: osg-users [mailto:osg-users-boun...@lists.openscenegraph.org] On
>>Behalf Of Björn Blissing
>>Sent: Friday, June 3, 2016 2:39 PM
>>To: OpenSceneGraph Users 
>>Subject: Re: [osg-users] Preparing to make 3.5.3 dev release, please test
>>
>>Hi Robert,
>>
>>The warnings relating the Operation class comes from the two protected
>>constructors. Since the class uses virtual inheritance it is initialized by 
>>the most
>>derived class. So the initializer for the virtual base class is ignored.
>>
>>So just removing the base class initializer for Operation will remove this
>>warning. I do not think this will have any negative side effects, since base 
>>class
>>initializer should be ignored by all compliant compilers anyway.
>>
>>I have attached the changed file.
>>
>>Regards
>>Björn
>>
>>>-Original Message-
>>>From: osg-users [mailto:osg-users-boun...@lists.openscenegraph.org] On
>>>Behalf Of Robert Osfield
>>>Sent: Friday, June 3, 2016 1:46 PM
>>>To: OpenSceneGraph Users 
>>>Subject: Re: [osg-users] Preparing to make 3.5.3 dev release, please test
>>>
>>>Hi Bjorn,
>>>
>>>On 3 June 2016 at 09:48, Björn Blissing  wrote:

 I compiled the latest master with Visual Studio 2015.

 I got a couple of warnings.  First of all I got a ton of these, which all
>>originates
>>>from the same origin:


 Code:

 ...
 OpenSceneGraph\include\osg/OperationThread(80): warning C4589:
>>>Constructor of abstract class 'osg::Operation' ignores initializer for 
>>>virtual
>>base
>>>class 'osg::Referenced' (compiling source file
>>>D:\github\OpenSceneGraph\src\osg\AnimationPath.cpp)
   OpenSceneGraph\include\osg/OperationThread(80): note: virtual base
>>>classes are only initialized by the most-derived type (compiling source file
>>>D:\github\OpenSceneGraph\src\osg\AnimationPath.cpp)
 ...




 And the same warnings for the following classes:


 Code:

 OpenSceneGraph\src\osgGA\CameraManipulator.cpp(24): warning C4589:
>>>Constructor of abstract class 'osgGA::CameraManipulator' ignores initializer
>>for
>>>virtual base class 'osg::Callback'
   OpenSceneGraph\src\osgGA\CameraManipulator.cpp(24): note: virtual
>>>base classes are only initialized by the most-derived type
 OpenSceneGraph\src\osgGA\StandardManipulator.cpp(51): warning
>>C4589:
>>>Constructor of abstract class 'osgGA::StandardManipulator' ignores 
>>>initializer
>>>for virtual base class 'osg::Callback'
   OpenSceneGraph\src\osgGA\StandardManipulator.cpp(51): note: virtual
>>>base classes are only initialized by the most-derived type
 OpenSceneGraph\src\osgViewer\ViewerBase.cpp(44): warning C4589:
>>>Constructor of abstract class 'osgViewer::ViewerBase' ignores initializer for
>>>virtual base class 'osg::Object'
   OpenSceneGraph\src\osgViewer\ViewerBase.cpp(44): note: virtual base
>>>classes are only initialized by the most-derived type
 OpenSceneGraph\src\osgViewer\ViewerBase.cpp(50): warning C4589:
>>>Constructor of abstract class 'osgViewer::ViewerBase' ignores initializer for
>>>virtual base class 'osg::Object'
   OpenSceneGraph\src\osgViewer\ViewerBase.cpp(50): note: virtual base
>>>classes are only initialized by the most-derived type
 OpenSceneGraph\src\osgAnimation\AnimationManagerBase.cpp(65):
>>>warning C4589: Constructor of abstract class
>>>'osgAnimation::AnimationManagerBase' ignores initializer for virtual base
>>class
>>>'osg::Callback'
   OpenSceneGraph\src\osgAnimation\AnimationManagerBase.cpp(65):
>>>note: virtual base classes are only initialized by the most-derived type
>>>
>>>Unfortunately I don't see these warnings with the compiler I have
>>>available with the settings that are currently available.  Do you know
>>>of what to enable these warnings in gcc or Clang?
>>>
>>>The nature of these warnings are such that I really need to be able to
>>>see the warning first hand and attempt a local fix to see the affect.
>>>
>>>Cheers,
>>>Robert.
>>>___
>>>osg-users mailing list
>>>osg-users@lists.openscenegraph.org
>>>http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
> ___
> osg-users mailing list
> osg-users@lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Preparing to make 3.5.3 dev release, please test

2016-06-03 Thread Robert Osfield
Hi Bjorn,

Thanks for the fix, works just fine under Linux w.r.t build and
testing.  Now merged and checked into git master.

Next on to the others...

Robert.

On 3 June 2016 at 13:39, Björn Blissing  wrote:
> Hi Robert,
>
> The warnings relating the Operation class comes from the two protected 
> constructors. Since the class uses virtual inheritance it is initialized by 
> the most derived class. So the initializer for the virtual base class is 
> ignored.
>
> So just removing the base class initializer for Operation will remove this 
> warning. I do not think this will have any negative side effects, since base 
> class initializer should be ignored by all compliant compilers anyway.
>
> I have attached the changed file.
>
> Regards
> Björn
>
>>-Original Message-
>>From: osg-users [mailto:osg-users-boun...@lists.openscenegraph.org] On
>>Behalf Of Robert Osfield
>>Sent: Friday, June 3, 2016 1:46 PM
>>To: OpenSceneGraph Users 
>>Subject: Re: [osg-users] Preparing to make 3.5.3 dev release, please test
>>
>>Hi Bjorn,
>>
>>On 3 June 2016 at 09:48, Björn Blissing  wrote:
>>>
>>> I compiled the latest master with Visual Studio 2015.
>>>
>>> I got a couple of warnings.  First of all I got a ton of these, which all 
>>> originates
>>from the same origin:
>>>
>>>
>>> Code:
>>>
>>> ...
>>> OpenSceneGraph\include\osg/OperationThread(80): warning C4589:
>>Constructor of abstract class 'osg::Operation' ignores initializer for 
>>virtual base
>>class 'osg::Referenced' (compiling source file
>>D:\github\OpenSceneGraph\src\osg\AnimationPath.cpp)
>>>   OpenSceneGraph\include\osg/OperationThread(80): note: virtual base
>>classes are only initialized by the most-derived type (compiling source file
>>D:\github\OpenSceneGraph\src\osg\AnimationPath.cpp)
>>> ...
>>>
>>>
>>>
>>>
>>> And the same warnings for the following classes:
>>>
>>>
>>> Code:
>>>
>>> OpenSceneGraph\src\osgGA\CameraManipulator.cpp(24): warning C4589:
>>Constructor of abstract class 'osgGA::CameraManipulator' ignores initializer 
>>for
>>virtual base class 'osg::Callback'
>>>   OpenSceneGraph\src\osgGA\CameraManipulator.cpp(24): note: virtual
>>base classes are only initialized by the most-derived type
>>> OpenSceneGraph\src\osgGA\StandardManipulator.cpp(51): warning C4589:
>>Constructor of abstract class 'osgGA::StandardManipulator' ignores initializer
>>for virtual base class 'osg::Callback'
>>>   OpenSceneGraph\src\osgGA\StandardManipulator.cpp(51): note: virtual
>>base classes are only initialized by the most-derived type
>>> OpenSceneGraph\src\osgViewer\ViewerBase.cpp(44): warning C4589:
>>Constructor of abstract class 'osgViewer::ViewerBase' ignores initializer for
>>virtual base class 'osg::Object'
>>>   OpenSceneGraph\src\osgViewer\ViewerBase.cpp(44): note: virtual base
>>classes are only initialized by the most-derived type
>>> OpenSceneGraph\src\osgViewer\ViewerBase.cpp(50): warning C4589:
>>Constructor of abstract class 'osgViewer::ViewerBase' ignores initializer for
>>virtual base class 'osg::Object'
>>>   OpenSceneGraph\src\osgViewer\ViewerBase.cpp(50): note: virtual base
>>classes are only initialized by the most-derived type
>>> OpenSceneGraph\src\osgAnimation\AnimationManagerBase.cpp(65):
>>warning C4589: Constructor of abstract class
>>'osgAnimation::AnimationManagerBase' ignores initializer for virtual base 
>>class
>>'osg::Callback'
>>>   OpenSceneGraph\src\osgAnimation\AnimationManagerBase.cpp(65):
>>note: virtual base classes are only initialized by the most-derived type
>>
>>Unfortunately I don't see these warnings with the compiler I have
>>available with the settings that are currently available.  Do you know
>>of what to enable these warnings in gcc or Clang?
>>
>>The nature of these warnings are such that I really need to be able to
>>see the warning first hand and attempt a local fix to see the affect.
>>
>>Cheers,
>>Robert.
>>___
>>osg-users mailing list
>>osg-users@lists.openscenegraph.org
>>http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
> ___
> osg-users mailing list
> osg-users@lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] PagedLOD and page in/out detection

2016-06-03 Thread Alberto Luaces
Trajce Nikolov NICK writes:

> Now it doesn't .. Any clue or hint how to detect such changes?

git bisect?  It is very useful for that kind of "it does work / now it
doesn't"...

-- 
Alberto

___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] PagedLOD and page in/out detection

2016-06-03 Thread Trajce Nikolov NICK
Hi Community,

I was looking for a way to detect when PagedLOD gets its children paged
in/out. So I installed an update callback and based on a difference in the
children number I was able to know when such change occurred. And this was
working with a code an year ago.

Now it doesn't .. Any clue or hint how to detect such changes?

Thanks a bunch as always!

Cheers,
Nick

-- 
trajce nikolov nick
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Preparing to make 3.5.3 dev release, please test

2016-06-03 Thread François Bérard

Hi Robert,

On 03/06/16 12:43, Robert Osfield wrote:

Hi François,

I have installed Clang 3.8 on my Linux dev machine and got it to
reproduce the same typeid error.  As far as I can tell this warning is
pretty bogus, effectively enforcing a personal preference of the
compiler developers rather than highlighting anything that is
ambiguous or unsupported.  Lots of other projects seem to be affected
by the same error, what the OSG is doing with typeid is pretty
standard.  The workaround seems to be to just create a local variable
which does the dereferences and then passes this on to the typeid,
I've applied this and it fixes the Clang error.  Having to write extra
code to quieten a stupid warning is pretty bad programming practice as
it can risks introducing bugs so I'm not happy doing this type of
stuff.


I agree. But it did silence the warnings on my setup too.


Despite using Clang 3.8 I don't see the second set of warnings:

[ 85%] Building CXX object
applications/osgviewer/CMakeFiles/application_osgviewer.dir/osgviewer.cpp.o
ConfigLexer.cpp:827:2: warning: 'register' storage class specifier is
deprecated [-Wdeprecated-register]
 register yy_state_type yy_current_state;

I can seen anywhere where the OSG Cmake build system is adding
-Wdeprecated-register.  Are you adding this manually?


nope. unzip, cmake, make. This must be a new default on my Clang (Apple 
LLVM version 7.3.0 (clang-703.0.29))


I silenced the warnings by adding:

add_compile_options(-Wno-deprecated-register)

...at line 9 of the main CMakeLists.txt file, i.e. within the first 
IF(APPLE) block.


Doing so, the only warnings that remain are calls to deprecated OSX 
functions on 2 modules:



[ 62%] Building CXX object 
src/osgViewer/CMakeFiles/osgViewer.dir/PixelBufferCocoa.mm.o
/Users/fberard/Downloads/osg_git/distrib/src/osgViewer/GraphicsWindowCocoa.mm:1715:14: 
warning: 'GetCurrentProcess' is deprecated: first deprecated in OS X 
10.9 [-Wdeprecated-declarations]

if (!GetCurrentProcess()) {
 ^
/System/Library/Frameworks/ApplicationServices.framework/Frameworks/HIServices.framework/Headers/Processes.h:415:1: 
note: 'GetCurrentProcess' has been explicitly marked deprecated here
MacGetCurrentProcess(ProcessSerialNumber * PSN) 
AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_9;

^
/System/Library/Frameworks/ApplicationServices.framework/Frameworks/HIServices.framework/Headers/Processes.h:412:34: 
note: expanded from macro 'MacGetCurrentProcess'

#define MacGetCurrentProcess GetCurrentProcess
 ^
/Users/fberard/Downloads/osg_git/distrib/src/osgViewer/GraphicsWindowCocoa.mm:1717:13: 
warning: 'SetFrontProcess' is deprecated: first deprecated in OS X 10.9 
[-Wdeprecated-declarations]

SetFrontProcess();
^
/System/Library/Frameworks/ApplicationServices.framework/Frameworks/HIServices.framework/Headers/Processes.h:603:1: 
note: 'SetFrontProcess' has been explicitly marked deprecated here
SetFrontProcess(const ProcessSerialNumber * PSN) 
AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_9;

^
/Users/fberard/Downloads/osg_git/distrib/src/osgViewer/GraphicsWindowCocoa.mm:1726:29: 
warning: incompatible pointer types sending 'CocoaAppDelegate *' to 
parameter of type 'id _Nullable'

  [-Wincompatible-pointer-types]
[NSApp setDelegate: [[CocoaAppDelegate alloc] init] ];
^~~
/usr/include/objc/NSObject.h:60:1: note: instance method 'init' is 
assumed to return an instance of its receiver type ('CocoaAppDelegate *')

- (instancetype)init
^
/Users/fberard/Downloads/osg_git/distrib/src/osgViewer/DarwinUtils.mm:111:26: 
warning: 'CGDisplayModeCopyPixelEncoding' is deprecated: first 
deprecated in OS X 10.11 [-Wdeprecated-declarations]

CFStringRef pixEnc = CGDisplayModeCopyPixelEncoding(mode);
 ^
/System/Library/Frameworks/CoreGraphics.framework/Headers/CGDirectDisplay.h:174:34: 
note: 'CGDisplayModeCopyPixelEncoding' has been explicitly marked 
deprecated here

CG_EXTERN CFStringRef __nullable CGDisplayModeCopyPixelEncoding(
 ^
/Users/fberard/Downloads/osg_git/distrib/src/osgViewer/DarwinUtils.mm:421:5: 
warning: 'SetFrontProcess' is deprecated: first deprecated in OS X 10.9 
[-Wdeprecated-declarations]

SetFrontProcess();
^
/System/Library/Frameworks/ApplicationServices.framework/Frameworks/HIServices.framework/Headers/Processes.h:603:1: 
note: 'SetFrontProcess' has been explicitly marked deprecated here
SetFrontProcess(const ProcessSerialNumber * PSN) 
AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_9;

^




[ 62%] Building CXX object 
src/osgWrappers/deprecated-dotosg/osgParticle/CMakeFiles/osgdb_deprecated_osgparticle.dir/IO_DomainOperator.cpp.o

Re: [osg-users] Preparing to make 3.5.3 dev release, please test

2016-06-03 Thread Björn Blissing

robertosfield wrote:
> Hi Bjorn,
> Unfortunately I don't see these warnings with the compiler I have
> available with the settings that are currently available.  Do you know
> of what to enable these warnings in gcc or Clang?
> 
> The nature of these warnings are such that I really need to be able to
> see the warning first hand and attempt a local fix to see the affect.
> 
> Cheers,
> Robert.
> 


Hi Robert,

I have made a small example which shows the problem with these types of 
constructors:

https://gist.github.com/bjornblissing/1895b168b2e90762ebee065adb3d3c65

It emits compilation warnings in Visual Studio 2015, but I have been unable to 
reproduce the warning in neither GCC nor Clang. Although the output of the 
executable are identical.

Regards
Björn

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=67391#67391





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Preparing to make 3.5.3 dev release, please test

2016-06-03 Thread Björn Blissing
Hi again, 

Forgot to attach the last two files with fixes to the virtual inheritance 
warnings...

I have also attached the fix to the type shadowing problem in 
ConvexPolyhedron.cpp

With this I think that the OSG Core group of projects compiles without warnings 
on Visual Studio 2015.

Regards
Björn

>-Original Message-
>From: osg-users [mailto:osg-users-boun...@lists.openscenegraph.org] On
>Behalf Of Björn Blissing
>Sent: Friday, June 3, 2016 3:35 PM
>To: OpenSceneGraph Users 
>Subject: Re: [osg-users] Preparing to make 3.5.3 dev release, please test
>
>Hi again,
>
>This is the fix for the rest of the virtual inheritance warnings. Same as for
>issues as for the Operation class.
>
>Regards
>Björn
>
>>-Original Message-
>>From: osg-users [mailto:osg-users-boun...@lists.openscenegraph.org] On
>>Behalf Of Björn Blissing
>>Sent: Friday, June 3, 2016 2:39 PM
>>To: OpenSceneGraph Users 
>>Subject: Re: [osg-users] Preparing to make 3.5.3 dev release, please test
>>
>>Hi Robert,
>>
>>The warnings relating the Operation class comes from the two protected
>>constructors. Since the class uses virtual inheritance it is initialized by 
>>the
>most
>>derived class. So the initializer for the virtual base class is ignored.
>>
>>So just removing the base class initializer for Operation will remove this
>>warning. I do not think this will have any negative side effects, since base
>class
>>initializer should be ignored by all compliant compilers anyway.
>>
>>I have attached the changed file.
>>
>>Regards
>>Björn
>>
>>>-Original Message-
>>>From: osg-users [mailto:osg-users-boun...@lists.openscenegraph.org] On
>>>Behalf Of Robert Osfield
>>>Sent: Friday, June 3, 2016 1:46 PM
>>>To: OpenSceneGraph Users 
>>>Subject: Re: [osg-users] Preparing to make 3.5.3 dev release, please test
>>>
>>>Hi Bjorn,
>>>
>>>On 3 June 2016 at 09:48, Björn Blissing  wrote:

 I compiled the latest master with Visual Studio 2015.

 I got a couple of warnings.  First of all I got a ton of these, which all
>>originates
>>>from the same origin:


 Code:

 ...
 OpenSceneGraph\include\osg/OperationThread(80): warning C4589:
>>>Constructor of abstract class 'osg::Operation' ignores initializer for 
>>>virtual
>>base
>>>class 'osg::Referenced' (compiling source file
>>>D:\github\OpenSceneGraph\src\osg\AnimationPath.cpp)
   OpenSceneGraph\include\osg/OperationThread(80): note: virtual base
>>>classes are only initialized by the most-derived type (compiling source file
>>>D:\github\OpenSceneGraph\src\osg\AnimationPath.cpp)
 ...




 And the same warnings for the following classes:


 Code:

 OpenSceneGraph\src\osgGA\CameraManipulator.cpp(24): warning
>C4589:
>>>Constructor of abstract class 'osgGA::CameraManipulator' ignores initializer
>>for
>>>virtual base class 'osg::Callback'
   OpenSceneGraph\src\osgGA\CameraManipulator.cpp(24): note: virtual
>>>base classes are only initialized by the most-derived type
 OpenSceneGraph\src\osgGA\StandardManipulator.cpp(51): warning
>>C4589:
>>>Constructor of abstract class 'osgGA::StandardManipulator' ignores
>initializer
>>>for virtual base class 'osg::Callback'
   OpenSceneGraph\src\osgGA\StandardManipulator.cpp(51): note:
>virtual
>>>base classes are only initialized by the most-derived type
 OpenSceneGraph\src\osgViewer\ViewerBase.cpp(44): warning C4589:
>>>Constructor of abstract class 'osgViewer::ViewerBase' ignores initializer for
>>>virtual base class 'osg::Object'
   OpenSceneGraph\src\osgViewer\ViewerBase.cpp(44): note: virtual
>base
>>>classes are only initialized by the most-derived type
 OpenSceneGraph\src\osgViewer\ViewerBase.cpp(50): warning C4589:
>>>Constructor of abstract class 'osgViewer::ViewerBase' ignores initializer for
>>>virtual base class 'osg::Object'
   OpenSceneGraph\src\osgViewer\ViewerBase.cpp(50): note: virtual
>base
>>>classes are only initialized by the most-derived type
 OpenSceneGraph\src\osgAnimation\AnimationManagerBase.cpp(65):
>>>warning C4589: Constructor of abstract class
>>>'osgAnimation::AnimationManagerBase' ignores initializer for virtual base
>>class
>>>'osg::Callback'
   OpenSceneGraph\src\osgAnimation\AnimationManagerBase.cpp(65):
>>>note: virtual base classes are only initialized by the most-derived type
>>>
>>>Unfortunately I don't see these warnings with the compiler I have
>>>available with the settings that are currently available.  Do you know
>>>of what to enable these warnings in gcc or Clang?
>>>
>>>The nature of these warnings are such that I really need to be able to
>>>see the warning first hand and attempt a local fix to see the affect.
>>>
>>>Cheers,
>>>Robert.
>>>___
>>>osg-users mailing list
>>>osg-users@lists.openscenegraph.org

Re: [osg-users] Preparing to make 3.5.3 dev release, please test

2016-06-03 Thread Björn Blissing
Hi again,

This is the fix for the rest of the virtual inheritance warnings. Same as for 
issues as for the Operation class.

Regards
Björn

>-Original Message-
>From: osg-users [mailto:osg-users-boun...@lists.openscenegraph.org] On
>Behalf Of Björn Blissing
>Sent: Friday, June 3, 2016 2:39 PM
>To: OpenSceneGraph Users 
>Subject: Re: [osg-users] Preparing to make 3.5.3 dev release, please test
>
>Hi Robert,
>
>The warnings relating the Operation class comes from the two protected
>constructors. Since the class uses virtual inheritance it is initialized by 
>the most
>derived class. So the initializer for the virtual base class is ignored.
>
>So just removing the base class initializer for Operation will remove this
>warning. I do not think this will have any negative side effects, since base 
>class
>initializer should be ignored by all compliant compilers anyway.
>
>I have attached the changed file.
>
>Regards
>Björn
>
>>-Original Message-
>>From: osg-users [mailto:osg-users-boun...@lists.openscenegraph.org] On
>>Behalf Of Robert Osfield
>>Sent: Friday, June 3, 2016 1:46 PM
>>To: OpenSceneGraph Users 
>>Subject: Re: [osg-users] Preparing to make 3.5.3 dev release, please test
>>
>>Hi Bjorn,
>>
>>On 3 June 2016 at 09:48, Björn Blissing  wrote:
>>>
>>> I compiled the latest master with Visual Studio 2015.
>>>
>>> I got a couple of warnings.  First of all I got a ton of these, which all
>originates
>>from the same origin:
>>>
>>>
>>> Code:
>>>
>>> ...
>>> OpenSceneGraph\include\osg/OperationThread(80): warning C4589:
>>Constructor of abstract class 'osg::Operation' ignores initializer for virtual
>base
>>class 'osg::Referenced' (compiling source file
>>D:\github\OpenSceneGraph\src\osg\AnimationPath.cpp)
>>>   OpenSceneGraph\include\osg/OperationThread(80): note: virtual base
>>classes are only initialized by the most-derived type (compiling source file
>>D:\github\OpenSceneGraph\src\osg\AnimationPath.cpp)
>>> ...
>>>
>>>
>>>
>>>
>>> And the same warnings for the following classes:
>>>
>>>
>>> Code:
>>>
>>> OpenSceneGraph\src\osgGA\CameraManipulator.cpp(24): warning C4589:
>>Constructor of abstract class 'osgGA::CameraManipulator' ignores initializer
>for
>>virtual base class 'osg::Callback'
>>>   OpenSceneGraph\src\osgGA\CameraManipulator.cpp(24): note: virtual
>>base classes are only initialized by the most-derived type
>>> OpenSceneGraph\src\osgGA\StandardManipulator.cpp(51): warning
>C4589:
>>Constructor of abstract class 'osgGA::StandardManipulator' ignores initializer
>>for virtual base class 'osg::Callback'
>>>   OpenSceneGraph\src\osgGA\StandardManipulator.cpp(51): note: virtual
>>base classes are only initialized by the most-derived type
>>> OpenSceneGraph\src\osgViewer\ViewerBase.cpp(44): warning C4589:
>>Constructor of abstract class 'osgViewer::ViewerBase' ignores initializer for
>>virtual base class 'osg::Object'
>>>   OpenSceneGraph\src\osgViewer\ViewerBase.cpp(44): note: virtual base
>>classes are only initialized by the most-derived type
>>> OpenSceneGraph\src\osgViewer\ViewerBase.cpp(50): warning C4589:
>>Constructor of abstract class 'osgViewer::ViewerBase' ignores initializer for
>>virtual base class 'osg::Object'
>>>   OpenSceneGraph\src\osgViewer\ViewerBase.cpp(50): note: virtual base
>>classes are only initialized by the most-derived type
>>> OpenSceneGraph\src\osgAnimation\AnimationManagerBase.cpp(65):
>>warning C4589: Constructor of abstract class
>>'osgAnimation::AnimationManagerBase' ignores initializer for virtual base
>class
>>'osg::Callback'
>>>   OpenSceneGraph\src\osgAnimation\AnimationManagerBase.cpp(65):
>>note: virtual base classes are only initialized by the most-derived type
>>
>>Unfortunately I don't see these warnings with the compiler I have
>>available with the settings that are currently available.  Do you know
>>of what to enable these warnings in gcc or Clang?
>>
>>The nature of these warnings are such that I really need to be able to
>>see the warning first hand and attempt a local fix to see the affect.
>>
>>Cheers,
>>Robert.
>>___
>>osg-users mailing list
>>osg-users@lists.openscenegraph.org
>>http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
#include 
#include 
#include 
#include 
#include 
#include 

using namespace osg;
using namespace osgGA;

CameraManipulator::CameraManipulator()
{
_intersectTraversalMask = 0x;

_autoComputeHomePosition = true;

_homeEye.set(0.0,-1.0,0.0);
_homeCenter.set(0.0,0.0,0.0);
_homeUp.set(0.0,0.0,1.0);
}


CameraManipulator::CameraManipulator(const CameraManipulator& mm, const CopyOp& 
copyOp)
   : inherited(mm, copyOp),
 _intersectTraversalMask(mm._intersectTraversalMask),
 _autoComputeHomePosition(mm._autoComputeHomePosition),
 _homeEye(mm._homeEye),
 _homeCenter(mm._homeCenter),
 _homeUp(mm._homeUp),
 

Re: [osg-users] Preparing to make 3.5.3 dev release, please test

2016-06-03 Thread Björn Blissing
Hi Robert,

The warnings relating the Operation class comes from the two protected 
constructors. Since the class uses virtual inheritance it is initialized by the 
most derived class. So the initializer for the virtual base class is ignored.

So just removing the base class initializer for Operation will remove this 
warning. I do not think this will have any negative side effects, since base 
class initializer should be ignored by all compliant compilers anyway.

I have attached the changed file.

Regards
Björn

>-Original Message-
>From: osg-users [mailto:osg-users-boun...@lists.openscenegraph.org] On
>Behalf Of Robert Osfield
>Sent: Friday, June 3, 2016 1:46 PM
>To: OpenSceneGraph Users 
>Subject: Re: [osg-users] Preparing to make 3.5.3 dev release, please test
>
>Hi Bjorn,
>
>On 3 June 2016 at 09:48, Björn Blissing  wrote:
>>
>> I compiled the latest master with Visual Studio 2015.
>>
>> I got a couple of warnings.  First of all I got a ton of these, which all 
>> originates
>from the same origin:
>>
>>
>> Code:
>>
>> ...
>> OpenSceneGraph\include\osg/OperationThread(80): warning C4589:
>Constructor of abstract class 'osg::Operation' ignores initializer for virtual 
>base
>class 'osg::Referenced' (compiling source file
>D:\github\OpenSceneGraph\src\osg\AnimationPath.cpp)
>>   OpenSceneGraph\include\osg/OperationThread(80): note: virtual base
>classes are only initialized by the most-derived type (compiling source file
>D:\github\OpenSceneGraph\src\osg\AnimationPath.cpp)
>> ...
>>
>>
>>
>>
>> And the same warnings for the following classes:
>>
>>
>> Code:
>>
>> OpenSceneGraph\src\osgGA\CameraManipulator.cpp(24): warning C4589:
>Constructor of abstract class 'osgGA::CameraManipulator' ignores initializer 
>for
>virtual base class 'osg::Callback'
>>   OpenSceneGraph\src\osgGA\CameraManipulator.cpp(24): note: virtual
>base classes are only initialized by the most-derived type
>> OpenSceneGraph\src\osgGA\StandardManipulator.cpp(51): warning C4589:
>Constructor of abstract class 'osgGA::StandardManipulator' ignores initializer
>for virtual base class 'osg::Callback'
>>   OpenSceneGraph\src\osgGA\StandardManipulator.cpp(51): note: virtual
>base classes are only initialized by the most-derived type
>> OpenSceneGraph\src\osgViewer\ViewerBase.cpp(44): warning C4589:
>Constructor of abstract class 'osgViewer::ViewerBase' ignores initializer for
>virtual base class 'osg::Object'
>>   OpenSceneGraph\src\osgViewer\ViewerBase.cpp(44): note: virtual base
>classes are only initialized by the most-derived type
>> OpenSceneGraph\src\osgViewer\ViewerBase.cpp(50): warning C4589:
>Constructor of abstract class 'osgViewer::ViewerBase' ignores initializer for
>virtual base class 'osg::Object'
>>   OpenSceneGraph\src\osgViewer\ViewerBase.cpp(50): note: virtual base
>classes are only initialized by the most-derived type
>> OpenSceneGraph\src\osgAnimation\AnimationManagerBase.cpp(65):
>warning C4589: Constructor of abstract class
>'osgAnimation::AnimationManagerBase' ignores initializer for virtual base class
>'osg::Callback'
>>   OpenSceneGraph\src\osgAnimation\AnimationManagerBase.cpp(65):
>note: virtual base classes are only initialized by the most-derived type
>
>Unfortunately I don't see these warnings with the compiler I have
>available with the settings that are currently available.  Do you know
>of what to enable these warnings in gcc or Clang?
>
>The nature of these warnings are such that I really need to be able to
>see the warning first hand and attempt a local fix to see the affect.
>
>Cheers,
>Robert.
>___
>osg-users mailing list
>osg-users@lists.openscenegraph.org
>http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


OperationThread
Description: OperationThread
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Setting up travis for OSG in github

2016-06-03 Thread Jordi Torres
Hi Robert,

I just sent a PR for adding travis for trusty and OSX builds. It could be
improved adding missing dependencies like gdal, etc. to the apt/brew
section.
Once you logged in to travis and set it up for the osg github repo ( it's
only a few steps ), it will automatically search for the .travis.yml file
and start to make builds on each pull request or push.

You can also add a status label to the repo website to know if the build is
passing (https://docs.travis-ci.com/user/status-images/).

Cheers.


2016-05-23 14:23 GMT+02:00 Jordi Torres :

> Hey John,
>
> Sorry for the late reply. I don't have any experience with travis and C++.
> I was thinking in setting it up in my own github fork, but probably you
> will do it faster than me. If you want to do it yourself let me know so we
> don't duplicate efforts.
>
> Thanks!
>
> 2016-05-20 17:02 GMT+02:00 John Hughes :
>
>> Hi Jordi,
>>
>> I was actually just thinking this morning about this.
>>
>> Most modern software development teams these days use a continuous
>> integration solution like Travis, along with an automated regression suite.
>>
>> I've had plenty experience maintaining both, so let me know if I can be
>> of help.
>>
>> Cheers,
>> John
>>
>> --
>> Read this topic online here:
>> http://forum.openscenegraph.org/viewtopic.php?p=67179#67179
>>
>>
>>
>>
>>
>> ___
>> osg-users mailing list
>> osg-users@lists.openscenegraph.org
>> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>>
>
>
>
> --
> Jordi Torres
>
>
>


-- 
Jordi Torres
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Preparing to make 3.5.3 dev release, please test

2016-06-03 Thread Robert Osfield
Hi Bjorn,

On 3 June 2016 at 09:48, Björn Blissing  wrote:
>
> I compiled the latest master with Visual Studio 2015.
>
> I got a couple of warnings.  First of all I got a ton of these, which all 
> originates from the same origin:
>
>
> Code:
>
> ...
> OpenSceneGraph\include\osg/OperationThread(80): warning C4589: Constructor of 
> abstract class 'osg::Operation' ignores initializer for virtual base class 
> 'osg::Referenced' (compiling source file 
> D:\github\OpenSceneGraph\src\osg\AnimationPath.cpp)
>   OpenSceneGraph\include\osg/OperationThread(80): note: virtual base classes 
> are only initialized by the most-derived type (compiling source file 
> D:\github\OpenSceneGraph\src\osg\AnimationPath.cpp)
> ...
>
>
>
>
> And the same warnings for the following classes:
>
>
> Code:
>
> OpenSceneGraph\src\osgGA\CameraManipulator.cpp(24): warning C4589: 
> Constructor of abstract class 'osgGA::CameraManipulator' ignores initializer 
> for virtual base class 'osg::Callback'
>   OpenSceneGraph\src\osgGA\CameraManipulator.cpp(24): note: virtual base 
> classes are only initialized by the most-derived type
> OpenSceneGraph\src\osgGA\StandardManipulator.cpp(51): warning C4589: 
> Constructor of abstract class 'osgGA::StandardManipulator' ignores 
> initializer for virtual base class 'osg::Callback'
>   OpenSceneGraph\src\osgGA\StandardManipulator.cpp(51): note: virtual base 
> classes are only initialized by the most-derived type
> OpenSceneGraph\src\osgViewer\ViewerBase.cpp(44): warning C4589: Constructor 
> of abstract class 'osgViewer::ViewerBase' ignores initializer for virtual 
> base class 'osg::Object'
>   OpenSceneGraph\src\osgViewer\ViewerBase.cpp(44): note: virtual base classes 
> are only initialized by the most-derived type
> OpenSceneGraph\src\osgViewer\ViewerBase.cpp(50): warning C4589: Constructor 
> of abstract class 'osgViewer::ViewerBase' ignores initializer for virtual 
> base class 'osg::Object'
>   OpenSceneGraph\src\osgViewer\ViewerBase.cpp(50): note: virtual base classes 
> are only initialized by the most-derived type
> OpenSceneGraph\src\osgAnimation\AnimationManagerBase.cpp(65): warning C4589: 
> Constructor of abstract class 'osgAnimation::AnimationManagerBase' ignores 
> initializer for virtual base class 'osg::Callback'
>   OpenSceneGraph\src\osgAnimation\AnimationManagerBase.cpp(65): note: virtual 
> base classes are only initialized by the most-derived type

Unfortunately I don't see these warnings with the compiler I have
available with the settings that are currently available.  Do you know
of what to enable these warnings in gcc or Clang?

The nature of these warnings are such that I really need to be able to
see the warning first hand and attempt a local fix to see the affect.

Cheers,
Robert.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Preparing to make 3.5.3 dev release, please test

2016-06-03 Thread Robert Osfield
Hi François,

I have installed Clang 3.8 on my Linux dev machine and got it to
reproduce the same typeid error.  As far as I can tell this warning is
pretty bogus, effectively enforcing a personal preference of the
compiler developers rather than highlighting anything that is
ambiguous or unsupported.  Lots of other projects seem to be affected
by the same error, what the OSG is doing with typeid is pretty
standard.  The workaround seems to be to just create a local variable
which does the dereferences and then passes this on to the typeid,
I've applied this and it fixes the Clang error.  Having to write extra
code to quieten a stupid warning is pretty bad programming practice as
it can risks introducing bugs so I'm not happy doing this type of
stuff.

Despite using Clang 3.8 I don't see the second set of warnings:

[ 85%] Building CXX object
applications/osgviewer/CMakeFiles/application_osgviewer.dir/osgviewer.cpp.o
ConfigLexer.cpp:827:2: warning: 'register' storage class specifier is
deprecated [-Wdeprecated-register]
register yy_state_type yy_current_state;

I can seen anywhere where the OSG Cmake build system is adding
-Wdeprecated-register.  Are you adding this manually?

Robert.


On 3 June 2016 at 06:01, François Bérard  wrote:
> Yup, compiles and executes fine now. But:
>
> There are tons of warnings such as:
>
> In file included from
> /Users/fberard/Downloads/osg_git/OpenSceneGraph-master/include/osg/NodeVisitor:21:
> /Users/fberard/Downloads/osg_git/OpenSceneGraph-master/include/osg/ValueMap:53:51:
> warning: expression with side effects will be evaluated despite being used
> as an operand to 'typeid'
>   [-Wpotentially-evaluated-expression]
> if (itr!=_keyValueMap.end() &&
> typeid(*(itr->second))==typeid(UserValueObject))
>   ^
> (I guess this is due to NodeVisitor being used everywhere).
>
> And also a bit of:
>
> [ 85%] Building CXX object
> applications/osgviewer/CMakeFiles/application_osgviewer.dir/osgviewer.cpp.o
> ConfigLexer.cpp:827:2: warning: 'register' storage class specifier is
> deprecated [-Wdeprecated-register]
> register yy_state_type yy_current_state;
> ^
>
> Also, I did a build in a temporary location (CMAKE_INSTALL_PREFIX to some
> place), but the build did not put the path or some relative paths in the
> binaries:
>
> [Downloads/osg_git] % otool -L ./bin/osgviewer
> ./bin/osgviewer:
> libosgViewer.144.dylib (compatibility version 144.0.0, current
> version 3.5.3)
> libosgText.144.dylib (compatibility version 144.0.0, current version
> 3.5.3)
> libosgGA.144.dylib (compatibility version 144.0.0, current version
> 3.5.3)
> libosgDB.144.dylib (compatibility version 144.0.0, current version
> 3.5.3)
> /System/Library/Frameworks/Carbon.framework/Versions/A/Carbon
> (compatibility version 2.0.0, current version 157.0.0)
> /opt/local/lib/libz.1.dylib (compatibility version 1.0.0, current
> version 1.2.8)
> libosgUtil.144.dylib (compatibility version 144.0.0, current version
> 3.5.3)
> libosg.144.dylib (compatibility version 144.0.0, current version
> 3.5.3)
> libOpenThreads.20.dylib (compatibility version 20.0.0, current
> version 3.3.0)
> /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current
> version 1226.10.1)
> /System/Library/Frameworks/Cocoa.framework/Versions/A/Cocoa
> (compatibility version 1.0.0, current version 22.0.0)
> /System/Library/Frameworks/OpenGL.framework/Versions/A/OpenGL
> (compatibility version 1.0.0, current version 1.0.0)
> /usr/lib/libc++.1.dylib (compatibility version 1.0.0, current
> version 120.1.0)
>
> So, "./osgviewer" did not work out of the box, I had to set
> DYLD_LIBRARY_PATH to point to the libraries.
>
> ccmake did warn about something that is probably related:
>
> CMake Warning (dev):
>Policy CMP0042 is not set: MACOSX_RPATH is enabled by default.  Run
> "cmake
>--help-policy CMP0042" for policy details.  Use the cmake_policy command
> to
>set the policy and suppress this warning.
>
>MACOSX_RPATH is not specified for the following targets:
>
> OpenThreads
> osg
> osgAnimation
> osgDB
> osgFX
> osgGA
> osgManipulator
> osgParticle
> osgPresentation
> osgShadow
> osgSim
> osgTerrain
> osgText
> osgUI
> osgUtil
> osgViewer
> osgVolume
> osgWidget
>
>  This warning is for project developers.  Use -Wno-dev to suppress it.
>
>
>
>
>
> On 2/6/16 18:53, Robert Osfield wrote:
>>
>> Hi François,
>>
>> I suspect the build error is down to the osgViewer:: in the
>> REGISTER_WINDOWINGSYSTEMINTERFACE line that is affecting the macro
>> expansion.  I have just checked in removal of the osgViewer:: so the
>> line now looks like:
>>
>> REGISTER_WINDOWINGSYSTEMINTERFACE(IOS,
>> ConcreteIOSWindowingSystemInterface)
>>
>> This is now checked into 

Re: [osg-users] Preparing to make 3.5.3 dev release, please test

2016-06-03 Thread Björn Blissing
Hi Robert,

Since you introduced the osg::PI_2f value, maybe you should replace the two 
osg::PIf*0.5f found in ShapeDrawable at line 1405 and 1479.

Regards
Björn

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=67380#67380





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Preparing to make 3.5.3 dev release, please test

2016-06-03 Thread Robert Osfield
Hi Laurens,

I've merged Bjorn's changes to GraphicsWindowWin32.cpp.  Also rather
than merge your changes to ShapeDrawable I have added to the
include/osg/Math header float variants to osg::PI etc. in the form
osg::PIf.  I then replaced the osg::PI usage in ShapeDrawable.cpp to
osg::PIf which should in theory fix the warnings.

I have checked all these changes in to git master.

Robert.

On 3 June 2016 at 10:06, Voerman, L.  wrote:
> Hi all,
> After updating to visual studio 2015 I fixed a few of those (minor)
> warnings,
> attached are the modified versions I use for
> src\osg\ShapeDrawable.cpp
> src\osgViewer\GraphicsWindowWin32.cpp
>
> Regards, Laurens.
>
> On Fri, Jun 3, 2016 at 10:48 AM, Björn Blissing 
> wrote:
>>
>> Hi,
>>
>> I compiled the latest master with Visual Studio 2015.
>>
>> I got a couple of warnings.  First of all I got a ton of these, which all
>> originates from the same origin:
>>
>>
>> Code:
>>
>> ...
>> OpenSceneGraph\include\osg/OperationThread(80): warning C4589: Constructor
>> of abstract class 'osg::Operation' ignores initializer for virtual base
>> class 'osg::Referenced' (compiling source file
>> D:\github\OpenSceneGraph\src\osg\AnimationPath.cpp)
>>   OpenSceneGraph\include\osg/OperationThread(80): note: virtual base
>> classes are only initialized by the most-derived type (compiling source file
>> D:\github\OpenSceneGraph\src\osg\AnimationPath.cpp)
>> ...
>>
>>
>>
>>
>> And the same warnings for the following classes:
>>
>>
>> Code:
>>
>> OpenSceneGraph\src\osgGA\CameraManipulator.cpp(24): warning C4589:
>> Constructor of abstract class 'osgGA::CameraManipulator' ignores initializer
>> for virtual base class 'osg::Callback'
>>   OpenSceneGraph\src\osgGA\CameraManipulator.cpp(24): note: virtual base
>> classes are only initialized by the most-derived type
>> OpenSceneGraph\src\osgGA\StandardManipulator.cpp(51): warning C4589:
>> Constructor of abstract class 'osgGA::StandardManipulator' ignores
>> initializer for virtual base class 'osg::Callback'
>>   OpenSceneGraph\src\osgGA\StandardManipulator.cpp(51): note: virtual base
>> classes are only initialized by the most-derived type
>> OpenSceneGraph\src\osgViewer\ViewerBase.cpp(44): warning C4589:
>> Constructor of abstract class 'osgViewer::ViewerBase' ignores initializer
>> for virtual base class 'osg::Object'
>>   OpenSceneGraph\src\osgViewer\ViewerBase.cpp(44): note: virtual base
>> classes are only initialized by the most-derived type
>> OpenSceneGraph\src\osgViewer\ViewerBase.cpp(50): warning C4589:
>> Constructor of abstract class 'osgViewer::ViewerBase' ignores initializer
>> for virtual base class 'osg::Object'
>>   OpenSceneGraph\src\osgViewer\ViewerBase.cpp(50): note: virtual base
>> classes are only initialized by the most-derived type
>> OpenSceneGraph\src\osgAnimation\AnimationManagerBase.cpp(65): warning
>> C4589: Constructor of abstract class 'osgAnimation::AnimationManagerBase'
>> ignores initializer for virtual base class 'osg::Callback'
>>   OpenSceneGraph\src\osgAnimation\AnimationManagerBase.cpp(65): note:
>> virtual base classes are only initialized by the most-derived type
>>
>>
>>
>>
>> The I get a couple of warnings due to osg::PI being used with floats:
>>
>>
>> Code:
>>
>> OpenSceneGraph\src\osg\ShapeDrawable.cpp(311): warning C4305:
>> 'initializing': truncation from 'double' to 'float'
>> OpenSceneGraph\src\osg\ShapeDrawable.cpp(381): warning C4305:
>> 'initializing': truncation from 'double' to 'float'
>> OpenSceneGraph\src\osg\ShapeDrawable.cpp(669): warning C4305: '=':
>> truncation from 'double' to 'float'
>> OpenSceneGraph\src\osg\ShapeDrawable.cpp(776): warning C4305: '=':
>> truncation from 'double' to 'float'
>> OpenSceneGraph\src\osg\ShapeDrawable.cpp(1479): warning C4305:
>> 'initializing': truncation from 'double' to 'float'
>> OpenSceneGraph\src\osg\ShapeDrawable.cpp(1697): warning C4305: '=':
>> truncation from 'double' to 'float'
>> OpenSceneGraph\src\osg\ShapeDrawable.cpp(1783): warning C4305: '=':
>> truncation from 'double' to 'float'
>>
>>
>>
>>
>>
>> Then some warnings about narrowing conversions:
>>
>>
>> Code:
>> OpenSceneGraph\src\osgViewer\GraphicsWindowWin32.cpp(1693): warning C4838:
>> conversion from 'int' to 'DWORD' requires a narrowing conversion
>> OpenSceneGraph\src\osgViewer\GraphicsWindowWin32.cpp(1693): warning C4838:
>> conversion from 'unsigned int' to 'BYTE' requires a narrowing conversion
>>
>>
>>
>> And finally some shadowed variable warnings:
>>
>>
>> Code:
>> OpenSceneGraph\src\osgShadow\ConvexPolyhedron.cpp(820): warning C4459:
>> declaration of 'Points' hides global declaration
>>   OpenSceneGraph\src\osgShadow\ConvexPolyhedron.cpp(88): note: see
>> declaration of '`anonymous-namespace'::Points'
>> OpenSceneGraph\src\osgViewer\GraphicsWindowWin32.cpp(2739): warning C4457:
>> declaration of 'lParam' hides function parameter
>>   OpenSceneGraph\src\osgViewer\GraphicsWindowWin32.cpp(2511): note: see
>> declaration of 

Re: [osg-users] Preparing to make 3.5.3 dev release, please test

2016-06-03 Thread Robert Osfield
Thanks Laurens, fix merged and checked into git master.

On 3 June 2016 at 10:23, Björn Blissing  wrote:
> Hi Laurens,
>
>
>
> Your changes to the src\osgViewer\GraphicsWindowWin32.cpp did not fix the
> narrowing warnings for me.
>
>
>
> I have attached my changes, which solves all warnings for this file for me.
>
>
>
> Regards
>
> Björn
>
>
>
> From: osg-users [mailto:osg-users-boun...@lists.openscenegraph.org] On
> Behalf Of Voerman, L.
> Sent: Friday, June 3, 2016 11:07 AM
> To: OpenSceneGraph Users 
> Subject: Re: [osg-users] Preparing to make 3.5.3 dev release, please test
>
>
>
> Hi all,
>
> After updating to visual studio 2015 I fixed a few of those (minor)
> warnings,
>
> attached are the modified versions I use for
>
> src\osg\ShapeDrawable.cpp
>
> src\osgViewer\GraphicsWindowWin32.cpp
>
>
>
> Regards, Laurens.
>
>
>
> On Fri, Jun 3, 2016 at 10:48 AM, Björn Blissing 
> wrote:
>
> Hi,
>
> I compiled the latest master with Visual Studio 2015.
>
> I got a couple of warnings.  First of all I got a ton of these, which all
> originates from the same origin:
>
>
> Code:
>
> ...
> OpenSceneGraph\include\osg/OperationThread(80): warning C4589: Constructor
> of abstract class 'osg::Operation' ignores initializer for virtual base
> class 'osg::Referenced' (compiling source file
> D:\github\OpenSceneGraph\src\osg\AnimationPath.cpp)
>   OpenSceneGraph\include\osg/OperationThread(80): note: virtual base classes
> are only initialized by the most-derived type (compiling source file
> D:\github\OpenSceneGraph\src\osg\AnimationPath.cpp)
> ...
>
>
>
>
> And the same warnings for the following classes:
>
>
> Code:
>
> OpenSceneGraph\src\osgGA\CameraManipulator.cpp(24): warning C4589:
> Constructor of abstract class 'osgGA::CameraManipulator' ignores initializer
> for virtual base class 'osg::Callback'
>   OpenSceneGraph\src\osgGA\CameraManipulator.cpp(24): note: virtual base
> classes are only initialized by the most-derived type
> OpenSceneGraph\src\osgGA\StandardManipulator.cpp(51): warning C4589:
> Constructor of abstract class 'osgGA::StandardManipulator' ignores
> initializer for virtual base class 'osg::Callback'
>   OpenSceneGraph\src\osgGA\StandardManipulator.cpp(51): note: virtual base
> classes are only initialized by the most-derived type
> OpenSceneGraph\src\osgViewer\ViewerBase.cpp(44): warning C4589: Constructor
> of abstract class 'osgViewer::ViewerBase' ignores initializer for virtual
> base class 'osg::Object'
>   OpenSceneGraph\src\osgViewer\ViewerBase.cpp(44): note: virtual base
> classes are only initialized by the most-derived type
> OpenSceneGraph\src\osgViewer\ViewerBase.cpp(50): warning C4589: Constructor
> of abstract class 'osgViewer::ViewerBase' ignores initializer for virtual
> base class 'osg::Object'
>   OpenSceneGraph\src\osgViewer\ViewerBase.cpp(50): note: virtual base
> classes are only initialized by the most-derived type
> OpenSceneGraph\src\osgAnimation\AnimationManagerBase.cpp(65): warning C4589:
> Constructor of abstract class 'osgAnimation::AnimationManagerBase' ignores
> initializer for virtual base class 'osg::Callback'
>   OpenSceneGraph\src\osgAnimation\AnimationManagerBase.cpp(65): note:
> virtual base classes are only initialized by the most-derived type
>
>
>
>
> The I get a couple of warnings due to osg::PI being used with floats:
>
>
> Code:
>
> OpenSceneGraph\src\osg\ShapeDrawable.cpp(311): warning C4305:
> 'initializing': truncation from 'double' to 'float'
> OpenSceneGraph\src\osg\ShapeDrawable.cpp(381): warning C4305:
> 'initializing': truncation from 'double' to 'float'
> OpenSceneGraph\src\osg\ShapeDrawable.cpp(669): warning C4305: '=':
> truncation from 'double' to 'float'
> OpenSceneGraph\src\osg\ShapeDrawable.cpp(776): warning C4305: '=':
> truncation from 'double' to 'float'
> OpenSceneGraph\src\osg\ShapeDrawable.cpp(1479): warning C4305:
> 'initializing': truncation from 'double' to 'float'
> OpenSceneGraph\src\osg\ShapeDrawable.cpp(1697): warning C4305: '=':
> truncation from 'double' to 'float'
> OpenSceneGraph\src\osg\ShapeDrawable.cpp(1783): warning C4305: '=':
> truncation from 'double' to 'float'
>
>
>
>
>
> Then some warnings about narrowing conversions:
>
>
> Code:
> OpenSceneGraph\src\osgViewer\GraphicsWindowWin32.cpp(1693): warning C4838:
> conversion from 'int' to 'DWORD' requires a narrowing conversion
> OpenSceneGraph\src\osgViewer\GraphicsWindowWin32.cpp(1693): warning C4838:
> conversion from 'unsigned int' to 'BYTE' requires a narrowing conversion
>
>
>
> And finally some shadowed variable warnings:
>
>
> Code:
> OpenSceneGraph\src\osgShadow\ConvexPolyhedron.cpp(820): warning C4459:
> declaration of 'Points' hides global declaration
>   OpenSceneGraph\src\osgShadow\ConvexPolyhedron.cpp(88): note: see
> declaration of '`anonymous-namespace'::Points'
> OpenSceneGraph\src\osgViewer\GraphicsWindowWin32.cpp(2739): warning C4457:
> declaration of 'lParam' hides 

Re: [osg-users] Preparing to make 3.5.3 dev release, please test

2016-06-03 Thread Björn Blissing
Hi,

I compiled the latest master with Visual Studio 2015.

I got a couple of warnings.  First of all I got a ton of these, which all 
originates from the same origin:


Code:

...
OpenSceneGraph\include\osg/OperationThread(80): warning C4589: Constructor of 
abstract class 'osg::Operation' ignores initializer for virtual base class 
'osg::Referenced' (compiling source file 
D:\github\OpenSceneGraph\src\osg\AnimationPath.cpp)
  OpenSceneGraph\include\osg/OperationThread(80): note: virtual base classes 
are only initialized by the most-derived type (compiling source file 
D:\github\OpenSceneGraph\src\osg\AnimationPath.cpp)
...




And the same warnings for the following classes:


Code:

OpenSceneGraph\src\osgGA\CameraManipulator.cpp(24): warning C4589: Constructor 
of abstract class 'osgGA::CameraManipulator' ignores initializer for virtual 
base class 'osg::Callback'
  OpenSceneGraph\src\osgGA\CameraManipulator.cpp(24): note: virtual base 
classes are only initialized by the most-derived type
OpenSceneGraph\src\osgGA\StandardManipulator.cpp(51): warning C4589: 
Constructor of abstract class 'osgGA::StandardManipulator' ignores initializer 
for virtual base class 'osg::Callback'
  OpenSceneGraph\src\osgGA\StandardManipulator.cpp(51): note: virtual base 
classes are only initialized by the most-derived type
OpenSceneGraph\src\osgViewer\ViewerBase.cpp(44): warning C4589: Constructor of 
abstract class 'osgViewer::ViewerBase' ignores initializer for virtual base 
class 'osg::Object'
  OpenSceneGraph\src\osgViewer\ViewerBase.cpp(44): note: virtual base classes 
are only initialized by the most-derived type
OpenSceneGraph\src\osgViewer\ViewerBase.cpp(50): warning C4589: Constructor of 
abstract class 'osgViewer::ViewerBase' ignores initializer for virtual base 
class 'osg::Object'
  OpenSceneGraph\src\osgViewer\ViewerBase.cpp(50): note: virtual base classes 
are only initialized by the most-derived type
OpenSceneGraph\src\osgAnimation\AnimationManagerBase.cpp(65): warning C4589: 
Constructor of abstract class 'osgAnimation::AnimationManagerBase' ignores 
initializer for virtual base class 'osg::Callback'
  OpenSceneGraph\src\osgAnimation\AnimationManagerBase.cpp(65): note: virtual 
base classes are only initialized by the most-derived type




The I get a couple of warnings due to osg::PI being used with floats:


Code:

OpenSceneGraph\src\osg\ShapeDrawable.cpp(311): warning C4305: 'initializing': 
truncation from 'double' to 'float'
OpenSceneGraph\src\osg\ShapeDrawable.cpp(381): warning C4305: 'initializing': 
truncation from 'double' to 'float'
OpenSceneGraph\src\osg\ShapeDrawable.cpp(669): warning C4305: '=': truncation 
from 'double' to 'float'
OpenSceneGraph\src\osg\ShapeDrawable.cpp(776): warning C4305: '=': truncation 
from 'double' to 'float'
OpenSceneGraph\src\osg\ShapeDrawable.cpp(1479): warning C4305: 'initializing': 
truncation from 'double' to 'float'
OpenSceneGraph\src\osg\ShapeDrawable.cpp(1697): warning C4305: '=': truncation 
from 'double' to 'float'
OpenSceneGraph\src\osg\ShapeDrawable.cpp(1783): warning C4305: '=': truncation 
from 'double' to 'float'





Then some warnings about narrowing conversions:


Code:
OpenSceneGraph\src\osgViewer\GraphicsWindowWin32.cpp(1693): warning C4838: 
conversion from 'int' to 'DWORD' requires a narrowing conversion
OpenSceneGraph\src\osgViewer\GraphicsWindowWin32.cpp(1693): warning C4838: 
conversion from 'unsigned int' to 'BYTE' requires a narrowing conversion



And finally some shadowed variable warnings:


Code:
OpenSceneGraph\src\osgShadow\ConvexPolyhedron.cpp(820): warning C4459: 
declaration of 'Points' hides global declaration
  OpenSceneGraph\src\osgShadow\ConvexPolyhedron.cpp(88): note: see declaration 
of '`anonymous-namespace'::Points'
OpenSceneGraph\src\osgViewer\GraphicsWindowWin32.cpp(2739): warning C4457: 
declaration of 'lParam' hides function parameter
  OpenSceneGraph\src\osgViewer\GraphicsWindowWin32.cpp(2511): note: see 
declaration of 'lParam'



There was also a lot of (+100) shadow warnings in the 3ds library. As well as 
one shadow warning each for the fbx and txp library.

Regards

Björn

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=67374#67374





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] PolytopeIntersection with LINE_STRIP_ADJACENCY

2016-06-03 Thread Robert Osfield
Hi Jethro,

If you have a fix could you please post whole modified files to the
osg-submissions list, along with a link to a github commit if you have
one.

Thanks,
Robert.

On 3 June 2016 at 07:14, Jethro Leevers  wrote:
> Hi,
>
> I seem to have it working...
>
> I modified a few functions in osg/TemplatePromativeFunctor
>
>
> Code:
>
> virtual void drawArrays(GLenum mode,GLint first,GLsizei count)
> ...
> case(GL_LINE_STRIP_ADJACENCY_EXT): {
> const Vec3* vlast = &_vertexArrayPtr[first+count-2];
> const Vec3* vptr=&_vertexArrayPtr[first];
> vptr+=1;
> for(;vptr this->operator()(*(vptr),*(vptr+1),_treatVertexDataAsTemporary);
> break;
> }
>
>
>
>
>
> Code:
>
> template
> void drawElementsTemplate(GLenum mode,GLsizei count,const IndexType* indices)
> ...
> case(GL_LINE_STRIP_ADJACENCY_EXT): {
> IndexPointer ilast = [count-2];
> IndexPointer iptr=indices;
> iptr+=1;
> for(;iptr < ilast;iptr+=1)
> {
> this->operator()(_vertexArrayPtr[*iptr],_vertexArrayPtr[*(iptr+1)],_treatVertexDataAsTemporary);
> }
> break;
> }
>
>
>
>
> Thank you!
>
> Cheers,
> Jethro
>
> PS. Code formatting is terrible[/code]
>
> --
> Read this topic online here:
> http://forum.openscenegraph.org/viewtopic.php?p=67370#67370
>
>
>
>
>
> ___
> osg-users mailing list
> osg-users@lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Preparing to make 3.5.3 dev release, please test

2016-06-03 Thread Robert Osfield
Hi François,

On 3 June 2016 at 06:01, François Bérard  wrote:
> There are tons of warnings such as:
>
> In file included from
> /Users/fberard/Downloads/osg_git/OpenSceneGraph-master/include/osg/NodeVisitor:21:
> /Users/fberard/Downloads/osg_git/OpenSceneGraph-master/include/osg/ValueMap:53:51:
> warning: expression with side effects will be evaluated despite being used
> as an operand to 'typeid'
>   [-Wpotentially-evaluated-expression]
> if (itr!=_keyValueMap.end() &&
> typeid(*(itr->second))==typeid(UserValueObject))
>   ^
> (I guess this is due to NodeVisitor being used everywhere).

I am clueless to what this warning actually means or how to resolve
it.  The code looks fine to me.



>
> And also a bit of:
>
> [ 85%] Building CXX object
> applications/osgviewer/CMakeFiles/application_osgviewer.dir/osgviewer.cpp.o
> ConfigLexer.cpp:827:2: warning: 'register' storage class specifier is
> deprecated [-Wdeprecated-register]
> register yy_state_type yy_current_state;
> ^

This is from old Producer Lex and yacc code, I wonder if regenerating
it would fix it.


> Also, I did a build in a temporary location (CMAKE_INSTALL_PREFIX to some
> place), but the build did not put the path or some relative paths in the
> binaries:
>
> [Downloads/osg_git] % otool -L ./bin/osgviewer
> ./bin/osgviewer:
> libosgViewer.144.dylib (compatibility version 144.0.0, current
> version 3.5.3)
> libosgText.144.dylib (compatibility version 144.0.0, current version
> 3.5.3)
> libosgGA.144.dylib (compatibility version 144.0.0, current version
> 3.5.3)
> libosgDB.144.dylib (compatibility version 144.0.0, current version
> 3.5.3)
> /System/Library/Frameworks/Carbon.framework/Versions/A/Carbon
> (compatibility version 2.0.0, current version 157.0.0)
> /opt/local/lib/libz.1.dylib (compatibility version 1.0.0, current
> version 1.2.8)
> libosgUtil.144.dylib (compatibility version 144.0.0, current version
> 3.5.3)
> libosg.144.dylib (compatibility version 144.0.0, current version
> 3.5.3)
> libOpenThreads.20.dylib (compatibility version 20.0.0, current
> version 3.3.0)
> /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current
> version 1226.10.1)
> /System/Library/Frameworks/Cocoa.framework/Versions/A/Cocoa
> (compatibility version 1.0.0, current version 22.0.0)
> /System/Library/Frameworks/OpenGL.framework/Versions/A/OpenGL
> (compatibility version 1.0.0, current version 1.0.0)
> /usr/lib/libc++.1.dylib (compatibility version 1.0.0, current
> version 120.1.0)
>
> So, "./osgviewer" did not work out of the box, I had to set
> DYLD_LIBRARY_PATH to point to the libraries.
>
> ccmake did warn about something that is probably related:
>
> CMake Warning (dev):
>Policy CMP0042 is not set: MACOSX_RPATH is enabled by default.  Run
> "cmake
>--help-policy CMP0042" for policy details.  Use the cmake_policy command
> to
>set the policy and suppress this warning.
>
>MACOSX_RPATH is not specified for the following targets:

I don't have an OSX system or OSX expertise so have to defer to
members of the OSG/OSX community to judge what is appropriate and what
is an actual issue and if so how to resolve it.

A general note putting libraries on a library path when the libs are
in a custom place seems normal to me.  This is what will happen on all
other platforms so would expect this to be the same under OSX as well.

Robert.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] PolytopeIntersection with LINE_STRIP_ADJACENCY

2016-06-03 Thread Jethro Leevers
Hi,

I seem to have it working...

I modified a few functions in osg/TemplatePromativeFunctor


Code:

virtual void drawArrays(GLenum mode,GLint first,GLsizei count)
...
case(GL_LINE_STRIP_ADJACENCY_EXT): {
const Vec3* vlast = &_vertexArrayPtr[first+count-2];
const Vec3* vptr=&_vertexArrayPtr[first];
vptr+=1;
for(;vptroperator()(*(vptr),*(vptr+1),_treatVertexDataAsTemporary);
break;
}





Code:

template
void drawElementsTemplate(GLenum mode,GLsizei count,const IndexType* indices)
...
case(GL_LINE_STRIP_ADJACENCY_EXT): {
IndexPointer ilast = [count-2];
IndexPointer iptr=indices;
iptr+=1;
for(;iptr < ilast;iptr+=1)
{
this->operator()(_vertexArrayPtr[*iptr],_vertexArrayPtr[*(iptr+1)],_treatVertexDataAsTemporary);
}
break;
}




Thank you!

Cheers,
Jethro

PS. Code formatting is terrible[/code]

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=67370#67370





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org