Re: [osg-users] Shaders with multiple views, possible?

2018-01-19 Thread Julien Valentin
Heu Why don't you use different uniform for your differents cameras? arennuit wrote: > Dear OSG forum, > > I am having trouble using shaders in the context of multiple views (either > several Viewer objects or a CompositeViewer). When using shaders (either > vertex or fragment), you most

[osg-users] Shaders with multiple views, possible?

2018-01-19 Thread Antoine Rennuit
Dear OSG forum, I am having trouble using shaders in the context of multiple views (either several Viewer objects or a CompositeViewer). When using shaders (either vertex or fragment), you most often need to let the shaders know about the camera configuration. In the case where a single view

Re: [osg-users] Why are my shaders not being used?

2018-01-19 Thread Antoine Rennuit
Hi Julien, Thanks for getting back to me, your post seems relevant but I am having another (unrelated) issue before I can fully test the fix code. I will post a separate issue. Thanks a lot, Antoine -- Read this topic online here:

Re: [osg-users] Help! New to OSG

2018-01-19 Thread Julien Valentin
You attachment seamed to fail Jmccart wrote: > Thanks so much for replying! I tried to animate and export a cylinder from > 3ds max exported out as a 3ds file, and I can see it in my osgviewer but not > the animation part. > > see attached. > > I'm using an osg viewer where I have to enter

Re: [osg-users] Why are my shaders not being used?

2018-01-19 Thread Julien Valentin
look command line results Code: 0(2) : error C7616: global function ftransform is removed after version 140 arennuit wrote: > Hi all, > > The following code renders the square in red (fixed pipeline) rather green > (shaders), I guess the shaders are not used. > > > Code: > > #define

Re: [osg-users] Straight lines are broken during rotation

2018-01-19 Thread Adrian Jelffs
Hi, I am pretty new to OSG but have been working on it for the past few weeks. I have an application that is rendering a 2D terrain with a constant width. When I rotate my display the line sometime appears broken. There are no other layers present. I have attached an example. This terrain

[osg-users] Why are my shaders not being used?

2018-01-19 Thread Antoine Rennuit
Hi all, The following code renders the square in red (fixed pipeline) rather green (shaders), I guess the shaders are not used. Code: #define GLSL330(program) "#version 150\n" #program const char* vertSource = GLSL330 ( void main(void) { gl_Position = ftransform(); } );

Re: [osg-users] Help! New to OSG

2018-01-19 Thread Julie McCartney
Thanks so much for replying! I tried to animate and export a cylinder from 3ds max exported out as a 3ds file, and I can see it in my osgviewer but not the animation part. see attached. I'm using an osg viewer where I have to enter everything through the command prompt. could that be messing

Re: [osg-users] disabled lighting after migration

2018-01-19 Thread Robert Osfield
Hi Sebastian, This suggest to me that an osg::TexEnv is needed somewhere in your scene graph to make sure the state is the one you intend. Robert. On 19 January 2018 at 15:45, Sebastian Schmidt wrote: > Found a dirty solution. Had nothing to with lighting. > It was

Re: [osg-users] How to get height above terrain in lat/long location?

2018-01-19 Thread shayne.tueller
Does your terrain display correctly in osgviewer? Make sure elevation data exists for the given lat lon... Shayne Sent via the Samsung Galaxy S7 active, an AT 4G LTE smartphone Original message From: Siyamak Mohammadinejad Date: 12/28/17 5:25 AM

Re: [osg-users] disabled lighting after migration

2018-01-19 Thread Sebastian Schmidt
Found a dirty solution. Had nothing to with lighting. It was easier for me to check for specific opengl calls inside drawable's drawImplementation(). I had to reset this: Code: glTexEnvf(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_REPLACE); with: > glTexEnvf(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE,

Re: [osg-users] Help! New to OSG

2018-01-19 Thread Julien Valentin
Hi No tutorial required here I think: AFAIK the only (working) interface between 3DS and osg is the FBXPlugin. If 3DS features are correctly translated to osganimation you can use it as it is in osg. ex: Code: osganimationviewer your3DS.fbx if there's a problem (in playing animation or or

Re: [osg-users] Hardware skinning computeBound() calculation

2018-01-19 Thread Julien Valentin
Hi Steve, I hope it's the last time i explain that: -Do you know how hardware skinning work? If it's the case you know that transformation are managed through vertex shader, so you can't expect osg to keep track of correctly transformed bounds -Have you look at RigGeometry constuctor? in

Re: [osg-users] [osgPlugins] Unable to load texture in the same folder as the scene file

2018-01-19 Thread Alessandro Terenzi
Hi, if you open the FBX file with a text editor you will see that, for each texture, the corresponding path is stored to refer to the absolute path in your computer file system... try to modify those paths by removing all the paths components but the filename of the texture (if you want the

Re: [osg-users] [osgPlugins] iOS/OSX: avfoundation plugin not reporting correct media duration

2018-01-19 Thread Alessandro Terenzi
Hi Robert, as far as I know the issue was present already with OSG version 3.4.0. According to the AVFoundation documentation it seems that when one wants to access 'static' aspects of a media, such as the duration it is safe to rely on the AVAsset reference while when actually playing the

[osg-users] [build] CMake fails to find latest FBX SDK for iOS

2018-01-19 Thread Alessandro Terenzi
Hi, found out that current version of FindFBX.cmake does not manage to find the FBX SDK version 2018.1.1 specifically for iOS. To my understanding the reasons are: 1) the FBX_LIBDIR is not set to any of the real folders used for the iOS/simulator distribution, which are "ios-armv7" and

[osg-users] [build] CMake fails to generate project for iOS

2018-01-19 Thread Alessandro Terenzi
Hi, when trying to generate a valid Xcode project to build OSG for iOS I noticed that even if we follow the platform specific instructions available on the OSG website, one has to manually modify the path to many iOS frameworks that are not set correctly by CMake using the current version of

[osg-users] How to get height above terrain in lat/long location?

2018-01-19 Thread Siyamak Mohammadinejad
Hi, I have problem to get height above terrain with this code: Code: double X; double Y; double Z; double maxElevationInDatabase = 8848; // meters, Mount Everest osgTerrain::Terrain* t = dynamic_cast(terrainNode_.get()); osg::CoordinateSystemNode* csn =

Re: [osg-users] [osgPlugins] iOS/OSX: avfoundation plugin not reporting correct media duration

2018-01-19 Thread Robert Osfield
HI Alessandro, Has AVFoundation changed? Or do you think that the original code was likely wrong all along? If there is chance that different versions work slightly different then making your suggested change could break older versions so we might need to put some version handling around it.

[osg-users] [osgPlugins] iOS/OSX: avfoundation plugin not reporting correct media duration

2018-01-19 Thread Alessandro Terenzi
Hi, I found out that when you want to know the duration of a media file, specifically a movie, the instruction: Code: _videoDuration = CMTimeGetSeconds([_data->avplayer.currentItem duration]); returns 0, I tried to use the following instead: Code: _videoDuration =