Re: [osg-users] OpenSceneGraph-3.6.4-rc6 tagged

2019-07-22 Thread Thomas Hogarth
Hey Robert

I have just checked in fix based on the above added handling of ANDROID:
>
>
> https://github.com/openscenegraph/OpenSceneGraph/commit/ccbc632afc240113aa7c8cffb37ce69fed45edd5
>
> Could you test and let me know if this works fine. Once I have positive
> feedback I'll make the new 3.6 rc.
>

I was just about to send the exact same as a pull request. I've just
updated my branch to the latest 3.6 and CMake ran fine. It's just building
now but I don't see there being any issues.

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


Re: [osg-users] OpenSceneGraph-3.6.4-rc6 tagged

2019-07-17 Thread Thomas Hogarth
Hey Robert

I'v tested on iOS and have run into an issue with FontConfig.
It's automatically find the macOS version of FontConfig that comes
installed by default on the OS.

I've done a hack fix for iOS you can see here

https://github.com/tomhog/OpenSceneGraph/commit/4d803e53120d3312d354fb4c53d9bd8f6410bae1

But looking you can actually build FontConfig for iOS so users may want to
use it.
This issue will probably affect Android users too. We can either put the
same kind of road block up for Android builds or we need a more elegegant
way of finding the FontConfig package for the platform you're building for.

For other dependancies like Freetypes etc I usually directly pass the CMake
values required via
the command like. So maybe that's another option to force it to not found?

Tom

PS
Tried to post via the forum but it was playing up
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Announcement: VulkanSceneGraph and SceneGraphTestBed!

2018-06-08 Thread Thomas Hogarth
Add my two cents

I'd by up for making a small unit test application framework. This is also a 
problem for osg examples at the mo. They only run in console/desktop 
environments.

I could develop a simple DemoBase class or whatever, examples and Unit tests 
inherit from that and then for each platform (desktop, iOS, Android etc) make a 
simple launcher frame work. 


Regarding the actual VulkanSceneGraph. I like the idea of keeping it as just a 
pure scenegraph and renderer then having node kits. It's not just about 
dependencies for me but speedy building and testing.

An issue for me with osg at the moment isn't the dependancies for the plugins. 
You can do a lot with zero third party libs. The issue is that there are just 
so many plugins it's a blessing and a curse. A system which when I 
generated my project let me select the plugins I wanted would be awesome. A 
full build of osg on mobile platforms can take well over an hour but it's 
mainly the plugins users will probably never use that take all the time.

I know that's really just an issue when you build osg but it really puts me off 
doing tests for releases.

Regarding macOS not currently supporting Vulkan. The same will be true of UWP 
apps, but hopefully a similar solution to Angle will be available. Most of the 
changes in the UWP port aren't related to using Angle, that's pretty much just 
using different headers and libs. The changes were mostly for UWP itself, file 
access etc.

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





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


Re: [osg-users] ANGLE/UWP support checked into OSG github

2018-06-07 Thread Thomas Hogarth
Yeah Holo lens and I'm not 100% sure but I think if you want to put your app on 
the windows store it needs to use Angle.

Still keep meaning to test it on XBox.

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





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


[osg-users] Crash in latest osg used in osgearth on iOS (possibly other platforms)

2017-06-23 Thread Thomas Hogarth
Hi

So I've run into an issue with recent versions/commits of osg. I've been
working on a GLES3 port of osgearth and everything was going smoothly. Then
recently I started experiencing an extremely intermittent crash. The
debugger would never return any useful information (tried all sorts of
things) and it only seemed to occur if osgearth was paging stuff in with
the database pager.

After a lot of fiddling around I eventually had to roll back my osg version
to this one

Rolled back to this commit in osg
https://github.com/tomhog/OpenSceneGraph/commit/
2ce5238cf7fe78a64af18a62e036fe9e0e29d721
2ce5238cf7fe78a64af18a62e036fe9e0e29d721

Which also required a revert on osgearth as they had made changes to
support the new linesegment intersection stuff.

That's about all the information there is, not much I know but all I can
say is between that commit above and the current head (well head as of
about 2 weeks ago, i did roll back a few commits first up to the point that
the linesegment triangle functor stuff was added but it was still crashing)
a crash has started occurring with no reliable way of reproducing it.

Is there anything that might spring to mind that could be the cause?

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


Re: [osg-users] iOS build guide locked/checked out on osg website

2017-04-22 Thread Thomas Hogarth
I thought the name rang a bell,

Thanks for doing that, it's done the trick.

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





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


Re: [osg-users] Support for Windows Universal Platform

2017-04-21 Thread Thomas Hogarth
Yes it should support Windows phone, still need to test that though, but no 
reason it shouldn't.

No example at the moment, but i just used the Angle template example from 
Visual Studio 2015. Then setup a viewer as embedded and call viewer frame in 
the main render function, pretty straight forward.

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





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


[osg-users] Support for Windows Universal Platform

2017-04-21 Thread Thomas Hogarth
Hi

So I've been tasked to add UWP/Angle support to OSG working with Chris Hanson. 
I have it pretty much working, it's rendering a cube, and just wanted a little 
guidance on a few issues before I submit any changes.

So firstly to the main CMakeLists.txt file I've added a OSG_BUILD_PLATFORM_UWP 
flag, this only does one thing on the CMake side. It adds a preprocessor define 
to all targets 'OSG_UWP' this is used in the code to hash def out a few 
unsupported features.

Also in the osgViewer CMake I have added support to Win32 path to set the 
Window System type, it defaults to Win32 which will behave as usual and any 
other value just doesn't add the Win32 graphics window implementation files. 
Maybe later we could add an EGL implementation but for now we just don't want 
the Win32 version and then we use setupViewerAsEmbedded.

I've hash defed out the plugin loading code on Win32 for now and have built osg 
as static as it uses a few functions not available on UWP, however later we 
could get that working I think as I've got GLExtensions code to work with a 
different function for loading the dll module.

OpenThreads had a few functions not available but none of them are show 
stoppers. The micoSleep function used some stuff not available so I made it 
fall back on standard sleep just as older windows versions do. You can't set 
process affinity on UWP so that function call does nothing, and you can't force 
terminate a thread, but you can cancel them so the fail safe terminate is just 
excluded.

The real issue at the moment is the use of getenv. That's used in a lot of 
places and is a handy bit of code for config type stuff so I didn't really want 
to add hash defs all over the place where ever it's used. So for now I made a 
dummy implementation that just returns 0, but the only place I could find to 
put it that is included globally was in the Notify header which is far from 
ideal. Does anyone have any thoughts or feedback on where I could place a dummy 
function like that that kind of needs to be used anywhere without people having 
to add a new include?

Here's an example CMake command that will generate a UWP visual studio project

"C:/Program Files/CMake/bin/cmake.exe" ./ -G "Visual Studio 14 2015 Win64" 
-DCMAKE_SYSTEM_NAME:STRING="WindowsStore" -DCMAKE_SYSTEM_VERSION:STRING="10.0" ^
-DOSG_BUILD_PLATFORM_UWP:BOOL=ON ^
-DOPENGL_PROFILE:STRING=GLES2 ^
-DOSG_WINDOWING_SYSTEM:STRING=NONE ^
-DOSG_USE_UTF8_FILENAME:BOOL=ON ^
-DDYNAMIC_OPENSCENEGRAPH:BOOL=OFF ^
-DDYNAMIC_OPENTHREADS:BOOL=OFF ^
-DBUILD_OSG_APPLICATIONS:BOOL=OFF ^
-DBUILD_OSG_EXAMPLES:BOOL=OFF ^
-DOPENGL_INCLUDE_DIR:PATH="C:/Work/AlphaPixel/osgUWP-Port/angle/include" ^
-DOPENGL_HEADER1:STRING="#include " ^
-DOPENGL_gl_LIBRARY:STRING="C:/Work/AlphaPixel/osgUWP-Port/angle/winrt/10/src/Release_x64/lib/libGLESv2.lib"
 ^
-DEGL_INCLUDE_DIR:PATH="C:/Work/AlphaPixel/osgUWP-Port/angle/include" ^
-DEGL_LIBRARY:STRING="C:/Work/AlphaPixel/osgUWP-Port/angle/winrt/10/src/Release_x64/lib/libEGL.lib"


Once I have a solution to this getenv thing and done some more testing I'll 
look at doing a pull request.

Thanks
Tom

PS
It's currently in a private repo

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





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


[osg-users] iOS build guide locked/checked out on osg website

2017-04-21 Thread Thomas Hogarth
Hi All

Not sure who can do what about this. A little while back i was going to update 
the build guide for osg on iOS, but the document/article was checked out and 
locked by another user. Since 2014 haha. Says it's been checked out by Ulrich 
Hertlein. If you're still around could you unlock it?

http://www.openscenegraph.com/index.php/documentation/platform-specifics/ios/23-configuring-cmake-for-ios

I made a new one here

http://www.openscenegraph.com/index.php/documentation/platform-specifics/ios/216-generating-an-ios-xcode-project-2017

But I think we should get rid of the old one.

Thanks
Tom

PS
I sent this by email, but think I didn't type the address properly, apologise 
if it's duplicated.

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





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


Re: [osg-users] Problem with current OSG and OSX

2017-01-02 Thread Thomas Hogarth
Are you using GL3?

If so you need to enable VertexArrayObjects 

osg::DisplaySettings::instance()->setVertexBufferHint(osg::DisplaySettings::VertexBufferHint::VERTEX_ARRAY_OBJECT);

Hope that helps

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





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


Re: [osg-users] Why isn't OpenSceneGraph used in games?

2016-04-22 Thread Thomas Hogarth
I've made a few games in OSG and in Unity.

In my experience OSG blows Unity out of the water then it comes to render 
performance. Also with unity and game engines in general you have to learn a 
lot of quirks. Like learning that in unity turning objects on and off is 
actually really expensive (well if you're doing it to dozens of them per frame)

I think tools like Unity come into their own for prototyping and allowing non 
technical people to try out assets in a real world test environment. The issues 
I've had using osg for games is the assets designers often struggle to 
understand the dos and don't and you find you have to write them little 
standalone test apps.

Personally if I was making a simple little game I'd use unity. If I was 
planning some galactic scale simulation I'd use osg as a foundation.

The other big difference and one I think a lot of games developers don;t like 
is it's a lot of work to set up additional renders. Say I just want to quickly 
render a model as an icon. In a scene graph I need to set up a new camera, 
attach it to the graph, render a frame, deactivate the camera etc. In a game 
engine I can often just say redner this model with this camera to a texture 
right now.

Anyway that's my two cents.

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





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


[osg-users] [ANN] Graft a cross platform batch conversion tool

2015-07-07 Thread Thomas Hogarth
Hi Everyone

In my spare time I've been working on a little project called Graft. It's a 
batch conversion tool a lot like osgConv but also uses Qt for a GUI.

It also adds the powerful feature of treating individual conversions (i.e. a 
visitor or image resize) as Actions that can be added as to a queue and applied 
one after the other. The queues can then be saved and shared with others (if 
you've ever used automator on OS X it's a bit like that)

Actions can also be added via plugins with the hope that eventually they'll be 
an action for every possibility. For this initial release I've added as many 
basic actions as I can and would now like to see what others think and any 
ideas for new Actions.

I've provided Windows (x64), OS X (x64) and Linux (x32) builds on my website

http://hogbox.com/index.php/graft

I've only tested them on Windows 7, OS X 10.9.5, Ubuntu 12.04

On linux you need to make Graft.sh executable and run that so the libraries are 
found and possibly also run

apt-get build-dep openscenegraph

As I haven't included 3rdParty dependancies other than osg and Qt in the linux 
build.

The source code is available here

https://github.com/tomhog/Graft

Anyway, if anyone would like to have a try please let me know how you get on 
and any possible ideas for new actions.

Thanks
Tom

PS
Quick tutorial as I've not written anything up yet
Add inputs via the + button or drag and drop files onto the window
Actions are applied to inputs when 'process' is clicked.
Selected input file is shown in preview with all actions applied from last 
process
Export will save out the currently selected input
To save out all Inputs add an Save File action

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





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


Re: [osg-users] [osgPlugins] DESPERATE!! Tried everything to get JPEGS TO LOAD!

2015-05-16 Thread Thomas Hogarth
Hi Gregory

First try whacking you notify level to debug_fp

osg::setNotifyLevel(osg::DEBUG_FP);

That will show you where osg is looking for the plugin.

Also unless you changed where osg is looking for plugins you have them in the 
wrong place. Osg on windows will usually have a osgPlugins-xxx folder in the 
bin folder with all the plugins in it, that's where it looks for them.

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





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


Re: [osg-users] Importing Animations from 3ds Max 2015

2014-11-17 Thread Thomas Hogarth
Hi Chris

I think FBX is a good way to go if you can, that was the pipeline I was working 
on (I can't even remember why now), but essentially the difference is this.

OSGExp for 3DS Max exports animations as osg::AnimationPath, FBX plugin will 
load them as osgAnimation::Animations (or whatever).

As osgAnimation is what you need for skinning I chose the fbx route and wrote 
that bit of code for the splitting.

If you use tools like Unity it's common to have some kind of meta data with 
your model that defines keyframe ranges.

Cheers
Tom

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





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


Re: [osg-users] fbx animation

2014-11-17 Thread Thomas Hogarth
Nice one.

My plan at some point is to integrate this into an all singing all dancing 
middlware tool to prep files for use in OSG (one day anyway), but nice to have 
it somewhere being used and hopefully iron out any bugs in it.

Seem to remember the main problem at the moment is if you don't have a key per 
frame and one of your new frames lands between keys the easing curves won't be 
correct on that frame.

Cheers
Tom

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





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


Re: [osg-users] [3rdparty] Animated 3d-models for OSG

2014-09-23 Thread Thomas Hogarth
Hi

This has been discussed before.

http://forum.openscenegraph.org/viewtopic.php?t=8161view=next

I made a little tool to split the long animation into sub animations using an 
xml config file. Worked well when I needed it, but not been tested in a while

Tom

PS
With some work maybe this could be included into osgconv as this topic has come 
up a few times

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





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


Re: [osg-users] [3rdparty] Animated 3d-models for OSG

2014-09-23 Thread Thomas Hogarth
PPS

3DS max itself does not understand multiple animations in a single file, which 
is why nothing exports from it properly.

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





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


Re: [osg-users] Hi all, The OpenSceneGraph3.3.2 DEV Running in D3D9 mode's full sourcecode version is uploaded and can be downloaded, Happy a good weekend!

2014-06-27 Thread Thomas Hogarth
Ok I got it downloaded

Looks like it's using some Mesa lib gldirect5 that uses DirectX to handle 
OpenGL calls.

Kind of interesting, though other then XBox, Windows Phone and the normal 
Surface all environments with DirectX have OpenGL anyway.

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





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


Re: [osg-users] Hi all, The OpenSceneGraph3.3.2 DEV Running in D3D9 mode's full sourcecode version is uploaded and can be downloaded, Happy a good weekend!

2014-06-27 Thread Thomas Hogarth
It's all the binaries and build files for osg the mesa lib, even a cmake exe in 
there.

It's using this

http://sourceforge.net/projects/gldirect/

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





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


Re: [osg-users] Hi all, The OpenSceneGraph3.3.2 DEV Running in D3D9 mode's full sourcecode version is uploaded and can be downloaded, Happy a good weekend!

2014-06-27 Thread Thomas Hogarth
I've deleted the binaries and am uploading the binaries.

It's just osg built with all the example etc again that mesa lib.

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





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


Re: [osg-users] Hello Robert OSGERS all, OSG DEMOS SITE is not a trojan!

2014-06-26 Thread Thomas Hogarth
This guy has been keeping me entertained for days.

Sometimes I wonder if some bot somewhere has gained a small amount of self 
awareness and is trying to make friends on the osg mailing list.

Maybe we have a Turing test winner in our midst.

lol

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





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


Re: [osg-users] New scheme for configuring the OSG for building against different versions of the OpenGL/OpenGL ES

2014-06-24 Thread Thomas Hogarth
Hi All

Small bug when configuring for Android on OS X, at the the moment i think the 
fact I'm on iOS is overriding everything

We end up with this in GL header file

#include TargetConditionals.h
#include OpenGLES/ES2/gl.h

We need this

//#include TargetConditionals.h
#include GLES2/gl2.h

I'll try properly fix it asap but if anyone else has missing header issues, 
that's the problem.

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





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


Re: [osg-users] Definding against aggressive domain

2014-04-15 Thread Thomas Hogarth
Hi

I hate these types of people.

I've had some troll sitting on hogbox.com for years now. I brought
hogbox.co.uk when I was a student and couldn't afford .com at the time.

Then someone brought .com and occasionally sends me emails saying they will
sell it to me for a price in the hundreds of dollars. I just reply saying
they're a troll and I will never pay them over the odds for a hobby url.

Anyhow, frustration vented. As we have the decent URLs I agree it doesn't
really matter, especially as there is no money changing hands on these
urls. The worst that might happen is someone gets there forum login pinched
when they go to openschemegraph.com ;)

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


Re: [osg-users] 3.2.1 test results

2013-12-20 Thread Thomas Hogarth
Hi

Did you edit the Android.mk file in osgAndroidExampleGLES2/jni

In there is a line like so

OSG_ANDROID_DIR :=  type your install directory 

I think 'type' may be coming from there.

Tom

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





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


Re: [osg-users] iOS OSG

2013-12-20 Thread Thomas Hogarth
Hi Guys

The code needed for deprecated and new osg formats is

//depreceated osg format
USE_OSGPLUGIN(osg)
USE_DOTOSGWRAPPER_LIBRARY(osg)


//new osg format
USE_OSGPLUGIN(osg2)
USE_SERIALIZER_WRAPPER_LIBRARY(osg)
USE_SERIALIZER_WRAPPER_LIBRARY(osgAnimation)

Tom

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





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


Re: [osg-users] Dynamic Texture Upload affecting frame rates drastically

2013-12-20 Thread Thomas Hogarth
Hi

So you might be generating mip maps for the texture.
Also some older cards hate TextureRectangle, you are better off subloading a 
non power of two texture into a larger power of two texture.

Check this code for example

https://code.google.com/p/hogbox/source/browse/trunk/src/hogbox/NPOTResizeCallback.cpp

Newer cards handle it fine though so check the mip maps


Code:
texture2D-setFilter(osg::Texture2D::MIN_FILTER, osg::Texture2D::NEAREST);
texture2D-setFilter(osg::Texture2D::MAG_FILTER, 
osg::Texture2D::NEAREST);



Tom

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





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


Re: [osg-users] META_OBJECT

2013-04-28 Thread Thomas Hogarth
hi 

Posting what META_OBJECT defines will help, but the clue is here

/home/sajjad/Downloads/OpenSceneGraph/osgCompute/osgCompute/include/osgOpenCL/osgOpenCLContext:23:4:
 error: cannot declare parameter ?anonymous? to be of abstract type 
?osgOpenCL::osgOpenCLContext?
/home/sajjad/Downloads/OpenSceneGraph/osgCompute/osgCompute/include/osgOpenCL/osgOpenCLContext:18:23:
 note:   because the following virtual functions are pure within 
?osgOpenCL::osgOpenCLContext?:

You have some pure virtual functions somewhere, then other code is trying to 
allocate an instance of a class with pure virtual functions which is not 
allowed.

Tom

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





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


Re: [osg-users] Possible to make pixel-pretty text in OSG?

2013-03-12 Thread Thomas Hogarth
A quick thing to test is setting the resolution of the font texture being used

osgText::Text setFontResolution

Like you where thinking, at the moment your font is being generated as a 
texture at a certain resolution, you are then scaling it when rendering causing 
mipmapping, multi sampling etc to effect it.

So make it the resolution you would expect to see on screen, and if you have it 
bang on you can also disable mipmapping on the font

font-setMinFilterHint(osg::Texture::NEAREST);
font-setMagFilterHint(osg::Texture::NEAREST);

Be aware though you will need a font texture per resolution you set so can 
become quite memory hungry.

Wangs suggestion will probably give beter looking results, but the above is 
pretty easy to test.

Tom

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





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


Re: [osg-users] Retrobooster playable demo

2012-12-01 Thread Thomas Hogarth
Looks and plays great,

Really like the dust clouds kicking up as you approach the ground. Glow effect 
is great too.

I'm running windows 7 on a Mac Book via Parallels.

Tom

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





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


Re: [osg-users] osg, macosx-x86_64 imageio plugin color byte swap problem

2012-09-27 Thread Thomas Hogarth
Hi Guys

Sorry to raise this again, but I'm currently having the same issue. Basically I 
am opening files, doing some bits and bobs to them and reexporting. Just for 
completeness I do alter the texture stateattributes, but not in a way I would 
think would matter. Here's what I'm doing


Code:
if(_localiseImagePaths){
std::string fileName = 
osgDB::getSimpleFileName(texture-getImage(0)-getFileName());
std::string localPath = images/+fileName;
texture-getImage(0)-setFileName(localPath);
}

//disable resize of textures
texture-setResizeNonPowerOfTwoHint(false);

//clamp to edge required for IPhone NPOT support
texture-setWrap(osg::Texture::WRAP_S, 
osg::Texture::CLAMP_TO_EDGE);
texture-setWrap(osg::Texture::WRAP_T, 
osg::Texture::CLAMP_TO_EDGE);




Then when done I export with the following options to make sure the files are 
written as external files for whatever format I'm using.


Code:
osg::ref_ptrosgDB::Options opts = new osgDB::Options();
opts-setOptionString(OutputTextureFiles noTexturesInIVEFile 
WriteImageHint=WriteOut);



But when I look at the exported images, or load the exported model file the 
image red and blue components seem to be flipped.

I've had a little dig and did start to think it was because some of my images 
don't have alpha channels, but I've tested images with alpha channels with no 
luck.

I've attached a model that will produce the problem when loaded and reexported 
with the above options (on my end at least)

I'm using osg version 3.1.3 and running on OSX 10.7.4, with OSX sdk 10.8, XCode 
4.5. I've also tried both 32 and 64 bit builds with no luck.

Any help would be greatly appreciated.

Cheers
Tom

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




Attachments: 
http://forum.openscenegraph.org//files/boxmanmodel_190.zip


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


Re: [osg-users] osg, macosx-x86_64 imageio plugin color byte swap problem

2012-09-27 Thread Thomas Hogarth
Oops

Sorry, the last attached file had a bad png that the plugin can't load. I 
copied over it with a backup after the colors got swapped and forgot to run it 
through gimp which seems to sort it.

Also I just tested embedding the image into the osgb file, which worked fine.

Thanks
Tom

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




Attachments: 
http://forum.openscenegraph.org//files/boxmanmodel2_102.zip


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


Re: [osg-users] osg, macosx-x86_64 imageio plugin color byte swap problem

2012-09-27 Thread Thomas Hogarth
Hi Again

So I've done some more digging and seems I'm hitting a case they may be known 
to not work. 

So in the function CreateCGImageFromOSGData under the case for GL_BGRA I am 
entering the else of the if statement.

if(GL_UNSIGNED_INT_8_8_8_8_REV == osg_image.getDataType()).

In there is this with the following code and comment

// FIXME: Don't know how to handle this case
bitmap_info = kCGImageAlphaPremultipliedLast;

What's weird is all my images seem to take this path even if I think they are 
pure rgb images.

I've found this function vImagePermuteChannels_ARGB, which I think can help 
me out, I just need to decide when to do it, to not break everyone else's 
functionality.

Cheers
Tom

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





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


Re: [osg-users] OpenGL ES 2 iOS 5.1 Non power of two textures

2012-09-26 Thread Thomas Hogarth
Hi Guillaume

I can confirm NPOT textures work in GLES2.

Did you try setting the wrap mode to CLAMP_TO_EDGE


Tom

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





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


[osg-users] Using a texture channel outside of OSG

2012-09-17 Thread Thomas Hogarth
Hi All

So I'm using an extension on iOS that allows me to fast draw video frames
coming from the camera in OpenGL.

The requirement though is that I bind and create the texture during a callback 
so I have to call makeCurrent on the osg context then do manual OpenGL 
commands, like below.


Code:
_viewer-getCamera()-getGraphicsContext()-makeCurrent();

[self cleanUpTextures];

// CVOpenGLESTextureCacheCreateTextureFromImage will create GLES texture
// optimally from CVImageBufferRef.

glActiveTexture(GL_TEXTURE5);
err = CVOpenGLESTextureCacheCreateTextureFromImage(kCFAllocatorDefault,
   _videoTextureCache,
   pixelBuffer,
   NULL,
   GL_TEXTURE_2D,
   GL_RGBA,
   width,
   height,
   GL_BGRA,
   GL_UNSIGNED_BYTE,
   0,
   _lumaTexture);
if (err)
{
NSLog(@Error at CVOpenGLESTextureCacheCreateTextureFromImage %d, err);
}

glBindTexture(CVOpenGLESTextureGetTarget(_lumaTexture), 
CVOpenGLESTextureGetName(_lumaTexture));
glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE);
glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE);



I then use a uniform to tell osg where to look for the texture, in this case 
channel 5 and everything works fine. The problems start when I introduce models 
loaded and rendered with osg. All the models only use textures in channel 0, 
but as soon as I start using them the video quad goes black and other textures 
start flickering.

My guess is osg is is doing something to my texture, is there a way to tell osg 
to leave a certain channel alone, or some other sort of magic?

Thanks
Tom

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





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


Re: [osg-users] Using a texture channel outside of OSG

2012-09-17 Thread Thomas Hogarth
Thanks for that

calling glActiveTexture(GL_TEXTURE0); at the end has worked, I'll 
try a more elegant solution later, but at least this has proved it can work.

Pretty obvious solution, think I'd just been working on it too long. 


Thanks for the help
Tom

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





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


Re: [osg-users] Using OSG Embedded in an Existing OpenGL Project

2012-09-17 Thread Thomas Hogarth
Hi

So I've done this when working with the QCAR sdk as it seems
to insist on having ownership of the GL Context. 

What you want is first setup the emmbeded viewer


Code:
osg::ref_ptrosgViewer::Viewer viewer = new osgViewer::Viewer();
osg::ref_ptrosgViewer::GraphicsWindowEmbedded embeddedWindow
embeddedWindow = viewer-setUpViewerAsEmbeddedInWindow(0, 0, w,h);
osg::ref_ptrosg::StateSet m_lastStateSet = new osg::StateSet();
viewer-getCamera()-getGraphicsContext()-getState()-captureCurrentState(*m_lastStateSet.get());
 




Then in your OpenGL apps render function after you have done your raw OpenGL 
stuff you want something like

osg::State *osgState = _viewer-getCamera()-getGraphicsContext()-getState(); 
osgState-reset(); 
osgState-apply(m_lastStateSet.get()); 

//render your osg frame here
viewer-frame();

//now get the state so you can restore next frame
viewer-getCamera()-getGraphicsContext()-getState()-captureCurrentState(*m_lastStateSet.get());
 


Hope that helps
Tom

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





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


[osg-users] RigGeometry setRigTransformImplementation, Update stops being called

2012-09-12 Thread Thomas Hogarth
Hi All   

I'm doing some hardware accelerated skinning which I've done a few times 
before, but i'm hitting a strange issue. So I do the below to in a visitor to 
add my HardwareRigTransform to the RigGeometry.


Code:

osgAnimation::RigGeometry* rig = 
dynamic_castosgAnimation::RigGeometry*(drawable);
if (rig){
//apply the HardwareRigTransform
rig-setRigTransformImplementation(new HardwareRigTransform);
stateMask |= GLES2ShaderGenCache::RIGGED;
}




However, once I do this RigGeometry::update() stops being called entirely 
(added some console output to it). So in turn my hardware rig transforms 
operator isn't being called. 

Like I say I've done this before and as far as I can tell the code is the same, 
so was wondering if someone might have run into a similar issue.

If I don't add the hardware rig transform I can see the rigged model (from fbx) 
animating as expected.


Cheers
Tom

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





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


Re: [osg-users] RigGeometry setRigTransformImplementation, Update stops being called

2012-09-12 Thread Thomas Hogarth
Hi Again

No worries I solved this, turns out my ShaderGen stuff was applying it's own 
drawable updatecallback, which was booting something off that osgAnimation was 
using. 

I just moved my callback up to the parent geode and everything seems cool.

Hope this helps someone in the future.
Tom

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





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


Re: [osg-users] [forum] Site web down

2012-08-28 Thread Thomas Hogarth
Hi Jordi

Did you get a chance to reboot the server?, i have a few clients that have
been trying to access with no joy.

Also looks like google may have cached the downed version

This is Google's cache of http://www.openscenegraph.org/. It is a snapshot
of the page as it appeared on 22 Aug 2012 15:45:17 GMT.

I know there is the effort to get the new site up and running, but things
have stalled on it lately (I've been pretty busy). Could we do anything like
copy the content of the old server somewhere for instances like this. I
have some webspace we could use for it.

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


Re: [osg-users] [forum] Site web down

2012-08-28 Thread Thomas Hogarth
Hi Jordi,

Thanks for that, will be a load off your mind when the new site is up ay :).

Regarding that I did make a few pages in the Platform specifics section which 
i've set to 'Awaiting Review'. If you flag them as ok I'll try set aside some 
time to start migrating more pages.

Thanks again
Tom

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





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


[osg-users] ETC1 Compressed textures

2012-08-17 Thread Thomas Hogarth
Hi All

So I've written an app for iOS that uses pvrtc format for a couple of big 
glyphmap textures 2048x2048. This works fine with the pvr plugin.

I'm now porting to Android and have stubbled across the problem of not all 
devices supporting pvrtc. However supposedly all of them support etc1 format.

Looking at the pvr plugin it seems to also support etc1 format, but when I try 
and load one I get the following error


Failed to verify pvr header: 1, 0, 0, 0


I used PVRTexToolGui v3.33 to convert the image using the ETC1 setting. Does 
anyone know of a better tool to use.

Cheers
Tom

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





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


Re: [osg-users] ETC1 Compressed textures

2012-08-17 Thread Thomas Hogarth
Bit more info, I also used the 'Fast Perceptual' encoding method, if that is of 
any relevance.

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





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


Re: [osg-users] Building a slimmed down static version of OSG

2012-05-31 Thread Thomas Hogarth
Hi Preet

Not too sure what exactly your issue is but the error

(.rodata._ZTVN9osgViewer22GraphicsWindowEmbeddedE[_ZTVN9osgViewer22GraphicsWindowEmbeddedE]+0xcc):-1:
 
error: undefined reference to `non-virtual thunk to 
osgViewer::GraphicsWindow::requestRedraw()' 

Suggests that your osgViewer lib isn't linked or GraphicsWindow.cpp wasn't 
compiled into your lib.

Setting the windowing system to None is correct but it may be that it needs 
to be set before you run cmake. Look at osgViewers CMakeLists.txt and see how 
it's done on Android.

Cheers
Tom

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





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


Re: [osg-users] Building a slimmed down static version of OSG

2012-05-29 Thread Thomas Hogarth
Hi Preet

Good to hear you're working on a Blackberry port.

In regard to the libs you need your main aim is to get osgViewer compiling.
If that compiles then you can setup a viewer a render your scenegraph.

You'll have two options for this, you can either create your own implementation 
of osgViewer::GraphicsWindow to handle setting up an OpenGL context, window 
etc. Or you can just use the OpenGL example you have and setup the viewer using 
the setupViewerAsEmbeded function which will allow you to draw the osg 
scenegraph into your example OpenGL view.

Probably easiest to try setupViewerAsEmbeded first to test osg itself is 
working, then you can try and create your own viewer.

With regard to OpenThreads it's probably related to the actual operating system 
you are using to build the libs. For example if you are on windows then CMake 
is probably selecting the windows threading stuff because it's not aware your 
trying to build for blackberry.

If you take a look at src/OpenThreads/CMakeLists.txt near the bottom you'll 
find this


Code:
IF(NOT ANDROID)
# Use our modified version of FindThreads.cmake which has Sproc hacks.
FIND_PACKAGE(Threads)
ENDIF()
# Do we have sproc?
IF(CMAKE_SYSTEM MATCHES IRIX)
IF(CMAKE_USE_SPROC_INIT)
# In this case, only Sproc exists, so no option.
SET(OPENTHREADS_USE_SPROC_INSTEAD_OF_PTHREADS 1)
ELSE()
IF(CMAKE_HAVE_SPROC_H)
OPTION(OPENTHREADS_USE_SPROC_INSTEAD_OF_PTHREADS Set to ON to 
build OpenThreads against sproc instead of pthreads OFF)
ENDIF()
ENDIF()
ENDIF(CMAKE_SYSTEM MATCHES IRIX)

# Add support for using Qt threads
IF(QT4_FOUND)
OPTION(BUILD_OPENTHREADS_WITH_QT Build OpenThreads with Qt threading 
support. OFF)
ENDIF()

# Maybe we should be using the FindThreads.cmake module?
IF(ANDROID)
SUBDIRS(pthreads)
ELSEIF(QT4_FOUND AND BUILD_OPENTHREADS_WITH_QT)
SUBDIRS(qt)
ELSEIF(WIN32)
# So I think Cygwin wants to use pthreads
IF(CYGWIN)
SUBDIRS(pthreads)
ELSE()
# Everybody else including Msys should probably go here
SUBDIRS(win32) 
# examples)
ENDIF()
ELSE()
IF(UNIX)
IF(OPENTHREADS_USE_SPROC_INSTEAD_OF_PTHREADS)
SUBDIRS(sproc)
ELSE()
SUBDIRS(pthreads)
ENDIF()
ELSE()
MESSAGE(Sorry, OpenThreads may not support your platform)
ENDIF()
ENDIF()




In there it is selecting the correct  threading module for the platform. For a 
temporary fix you can just force the use of pthreads.

Regarding plugins, cmake will only generate build targets for pulgins for which 
it has found the dependancies. Be careful though that it doesn't find your 
operating system versions. For good asset support you'll need at least
libpng for loading of png images, and freetypes for fonts.

The osg format plugins themselves have no external dependancies so should build 
as long as osg does.

Cheers
Tom

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





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


Re: [osg-users] [build] Up to date OS X / iPhone build

2012-05-25 Thread Thomas Hogarth
Hi Mathieu

There are updated instructions for iOS on the new openscenegraph.com site

http://www.openscenegraph.com/index.php/documentation/platform-specifics/ios/23-configuring-cmake-for-ios

The process should be pretty similar to generating for OSX, just don't edit
the cmakelists file first.

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


[osg-users] [ANN] My first IPhone/IPad app (it's free)

2012-05-20 Thread Thomas Hogarth
Hi All

Well I've been very busy lately and have finally managed to release my own app 
on the iOS appstore.

http://itunes.apple.com/us/app/stereomagic/id495427905?mt=8

It called StereoMagic and uses Render to texture to render interactive 
stereogram images (magiceyes) in realtime.

You get 8 scenes free with the app and can use in app purchase to unlock an 
additional 12.

An android port will be coming soon.

Thanks 
Tom

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





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


Re: [osg-users] Building new website, assistance appreciated!

2012-05-16 Thread Thomas Hogarth
Hi Jordi

I had meant to ask about code highlighting/formatting. Thanks for the heads up.

An authors guide would be good let me know when you've got one. I'm already 
wondering about heading formats, link colours etc.

Cheers
Tom

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





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


[osg-users] [ANN] OSG Based Android Game Released (it's free)

2012-05-16 Thread Thomas Hogarth
Hi All

A game I developed originally on iOS for AppToyz has now been successfully 
ported to Android and is available on GooglePlay

https://play.google.com/store/apps/details?id=com.AppToyz.AlienAttackfeature=nav_result#?t=W251bGwsMSwyLDNd

It uses your phones camera and gyro for basic video overlay style augmented 
reality.


Hope you enjoy it.
Tom

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





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


Re: [osg-users] Building new website, assistance appreciated!

2012-05-16 Thread Thomas Hogarth
Hi Again

I've started work on the Windows/Visual Studio side of the platform specifics 
section.

http://www.openscenegraph.com/index.php/documentation/platform-specifics/windows/37-visual-studio

Just wondered if you'd take a look at the few pages I've done to confirm style 
etc before I move on.

Also I think the main Visual Studio page needs a bit of refactoring, but the 
pages it links too seem good.

Cheers
Tom

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





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


Re: [osg-users] Building new website, assistance appreciated!

2012-05-14 Thread Thomas Hogarth
Hi Guys

I have had a chance to finish the IOS CMake doc 

http://www.openscenegraph.com/index.php/documentation/platform-specifics/ios/23-configuring-cmake-for-ios

I went along with it as I wrote it (Robert I've submitted a small change to 
CMakeLists.txt to make the tutorial simpler).

I'll make a start moving the other platform specific sections to the new site 
and update the migration tasks as I go.

Cheers
Tom

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





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


Re: [osg-users] Building new website, assistance appreciated!

2012-05-09 Thread Thomas Hogarth
Hi Jordi

Thanks for setting up the Code Repositries stuff, I really like the added
Git and Mercurial links,

I've been away away on a stag do (well more recovering), but should get
back at it this weekend.

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


Re: [osg-users] Building new website, assistance appreciated!

2012-05-02 Thread Thomas Hogarth
Hi Guys

@Jordi, thanks for the list of pages, wow that is quite a bit to move.

I'm fine with you assigning me a bunch of content to port over, if we limit it 
to say 5-10 pages at a time, so I don't fall too far behind.

Could we perhaps use a google doc with all page titles added with current 
status of porting etc?

Cheers
Tom

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





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


Re: [osg-users] Building new website, assistance appreciated!

2012-05-01 Thread Thomas Hogarth
Hi Jordi,

Yes openscenegraph.org is working for me again,

What a dummy, of course I could get the svn url from my existing repos. I'll 
try get some more content added this week now I can do the practical side as I 
go along.

I'm happy with joomla, seems pretty simple to me.

Once i get my IOS pages done, do you want me to start moving existing things 
over?

If we are happy with breaking getting start down into a start page with 
-Get the trunk info
-Then link to platform specific info for CMake/Project creating

I can move over existing windows and OSX info and confirm it's correct, I have 
a little experience with linux, but I tend to use the CMake GUI and I'm not 
sure how common that is on linux distros.

From what i've seen of the new template I think it's good and we need to start 
populating it.

Cheers
Tom

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





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


Re: [osg-users] Building new website, assistance appreciated!

2012-04-29 Thread Thomas Hogarth
Hi guys

So I've caught up on what's been going on, I'm liking the new template being 
used on www.openscenegraph.com

I've had a bash at publishing an article

http://www.openscenegraph.com/index.php/documentation/platform-specifics/ios/23-configuring-cmake-for-ios

I'll finish it up as soon as I can download a fresh svn trunk but 
openscenegraph.org is down and I don't know the svn url. (On a side note 
there's no section on the new site for the source control/svn url)

Once I get a trunk I'll step through a few build configs for iOS to confirm 
everything is working as the document states and maybe grab a few screen shots.

I also wanted to get peoples opinions on the break down I'm aiming for for 
getting started section. For iOS at least I was thinking

-How to configure CMake for iOS/Generating an iOS XCode Project

-Building the libraries for iOS and linking to own project (what ones are 
really needed + the static macro stuff)

-Setting up an OSG view in an iOS application (maybe cover some stuff about 
assets)


I guess then all platforms can share a  Get the code page, then move to 
platform specific CMake page.

What do you guys think?

Cheers
Tom

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





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


Re: [osg-users] Highland fling!

2012-04-28 Thread Thomas Hogarth
Hope you made it back in one piece, that's a serious run.

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





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


Re: [osg-users] Why no games with OSG?

2012-04-24 Thread Thomas Hogarth
Hi Micheal

I've completed a few games with OSG

http://itunes.apple.com/gb/app/apptoyz-alien-attack/id412615924?mt=8

http://itunes.apple.com/us/app/apptoyz-tin-can-alley/id457520117?mt=8

I find no problem using osg for games, if you just treat osg as a wrapper 
around OpenGL and not a game engine.

There's also the osgbullet lib to handle physics and collisions.

The main difference you'll find is that rather then calling a specific draw 
fuction to render your model you need to make sure it can be attached to the 
scene graph in some way,

I tend to have a level class with a osg::MatrixTransform, then all level 
entities are attached to that etc.

Hope that helps
Tom

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





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


Re: [osg-users] Current state of GLES2

2012-04-23 Thread Thomas Hogarth
Hi Guys

Yes I have a GLES2 version of shader gen. At the moment it only supports a 
fixed hardcoded light position, which isn't great but it does support, 
texturing, lighting etc.

I've attached it and we can look at including into core osg, but I think 
support for at least the initial position of one light source would be good. 
Also we need to either test for backward compatibility with GL2 or have two 
versions of ShaderGen in the core. 

I know Roberts long term goal is to introduce a Shader Composer system (bits 
and pieces already exist), but this can work as an aid to new developers until 
then.

Let me know how you get on with it.
Tom

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




Attachments: 
http://forum.openscenegraph.org//files/gles2shadergen_157.zip


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


Re: [osg-users] Rewind the scene

2012-04-23 Thread Thomas Hogarth
Hi Guys

i've done this in the past, I do have a little class to handle it but it's 
quite a mess so I won't share the whole thing.

Essentially the best thing to do is to get hold of the original animation path 
then split it into the sub animation you require.

Then when you want to play a specific one you set it as the current for the 
AnimationPathCallback

Here's the basic code I use to do that


Code:
void SplitAni::ReSampleSubAni(int subID, int from, int to)
{
if(subID0 || subID=(int)_splitAnis.size())
{return;}
//check the original path is good
if(!_originalAni)
{return;}

//clear the current path
_splitAnis[subID]-getTimeControlPointMap().clear();

//find the number of frames in the original animation
osg::AnimationPath::TimeControlPointMap timeMap = 
_originalAni-getTimeControlPointMap();

//seconds per rame
//int totalFrames = (int)timeMap.size();
double secsPerFrame = (double)1.0f/_fps;

//get start end frames as times
double frameT = from*secsPerFrame;
double endT = to*secsPerFrame;

int newCount=0;

while(frameTendT)
{
osg::AnimationPath::ControlPoint cp;
_originalAni-getInterpolatedControlPoint(frameT, cp);   

//insert into the subanimation starting from time 0
_splitAnis[subID]-insert(newCount*secsPerFrame, cp);

//step to nxt time
frameT+=secsPerFrame;

//increase new frame count
newCount++;
}
}



_splitAnis is just an array of osg::AnimationPath and _fps is the frame rate of 
the original animation path.


Hope that helps
Tom

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





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


Re: [osg-users] osg-users Digest, Vol 58, Issue 29

2012-04-22 Thread Thomas Hogarth
Hi Eduardo

I think you may need to use

USE_OSGPLUGIN(osg2)

as well as USE_SERIALIZER_WRAPPER_LIBRARY)

USE_OSGPLUGIN(osg2) is saying import the plugin

USE_SERIALIZER_WRAPPER_LIBRARY is saying add all the sub components.
i.e. you can either use that or add just the ones you need like

USE_SERIALIZER_WRAPPER(AlphaFunc)
USE_SERIALIZER_WRAPPER(AnimationPath)
USE_SERIALIZER_WRAPPER(AnimationPathCallback)

I've used osgb format before for skinning so can confirm it has worked

Cheers
Tom


 Hello,

 For iOS, is it necessary to use dotosg wrappers
 (USE_DOTOSGWRAPPER_LIBRARY(osg)) instead of the newer serializer?

 I tried to use USE_SERIALIZER_WRAPPER_LIBRARY(osg) without success.

 Thanks
 Eduardo


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


[osg-users] iOS and wrappers

2012-04-22 Thread Thomas Hogarth
Whops, forgot to change the subject, orignal message below

-

Hi Eduardo

I think you may need to use

USE_OSGPLUGIN(osg2)

as well as USE_SERIALIZER_WRAPPER_LIBRARY)

USE_OSGPLUGIN(osg2) is saying import the plugin

USE_SERIALIZER_WRAPPER_LIBRARY is saying add all the sub components.
i.e. you can either use that or add just the ones you need like

USE_SERIALIZER_WRAPPER(AlphaFunc)
USE_SERIALIZER_WRAPPER(AnimationPath)
USE_SERIALIZER_WRAPPER(AnimationPathCallback)

I've used osgb format before for skinning so can confirm it has worked

Cheers
Tom



 Hello,

 For iOS, is it necessary to use dotosg wrappers
 (USE_DOTOSGWRAPPER_LIBRARY(osg)) instead of the newer serializer?

 I tried to use USE_SERIALIZER_WRAPPER_LIBRARY(osg) without success.

 Thanks
 Eduardo


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


Re: [osg-users] Posts with subject lines like osg-users Digest, Vol 58, Issue 29

2012-04-22 Thread Thomas Hogarth
I agree that would be a good idea. (Rejecting unaltered subjects)

I just made that mistake myself :(

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





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


Re: [osg-users] Building new website, assistance appreciated!

2012-04-17 Thread Thomas Hogarth
Hi Robert

So I had a quick stab at porting the Getting Started page to Joomla. I still 
don't have any kind of admin rights on the osg.com site so for now I did it on 
my website

http://www.hogbox.co.uk/joomla/index.php?option=com_contentview=articleid=47:getting-startedcatid=31:generalItemid=46

That was a straight copy and pate from the osg site (rendered in browser, not 
viewing source), into the joomla editor.

Worked quite well as it only took about 30 seconds.

So transfering stuff as is is easy enough. So I think we just need to think a 
little about re aranging.

Cheers
Tom

PS
Something weird about the url I've given, If I add the [url] tags round it it 
just sends me to the root of my site. So just copy and pate into url bar

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





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


Re: [osg-users] Building new website, assistance appreciated!

2012-04-12 Thread Thomas Hogarth
Hi Robert

So I installed joomla on my server and have had a little play with it, seems 
easy enough to edit stuff

Thanks for doing the experimentation. Could you try and put together 
a test tutorial on any subject that you feel able, iOS for instance. 
Your experience with this will give us an idea of how they might look 
and how quickly/easily they can be put together. It might also be 
useful to attempt to copy the contents over as a straight joomla 
article to see how easily one can do the equivalent in joomla. 

Sure I can do this, I think I will do it in Joomla if you could give me editor 
(or is it publisher) rights.

I can start it on my server just for testing purposes.

In terms of quick copying over I guess copying from the Trac editor (assuming 
it has one) will work best. Or trying to copy html into the joomla html editor. 
Just to make copying of URLs easier.

So I will start with a Getting Started IOS document, and see what plugins 
joolma has to offer for Syntax highlighting etc.

Cheers
Tom

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





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


[osg-users] Robert Osfield robert.osfi...@gmail.com, Building new website, assistance appreciated!

2012-04-11 Thread Thomas Hogarth
Hi Robert,

So I have been looking at other options like dropal (or whatever it was
called), I think you're right that we should just stick with Joomla, as I
like you don't really know enough to make an educated decision.

I have a web server of my own with these one click installs so I am going
to try setting something similar up just to get a better feel.

I just tried to make a Joomla account on the OSG website
but haven't received my confirmation email yet (been around 10 mins so not
the end of the world).

So I take it the joolma part would have more polished content like news,
downloads etc, then we will link to MediaWiki for part or all of the
documentation?

As I've said I'm up for helping out, and will certainly maintain IOS
specific stuff, but can help out in other areas. Although my emails don't
show it (lazy email typing) I
can serve well as a proof reader etc.

Let me know something you might like me to work on first and I'll get stuck
in.

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


Re: [osg-users] Building new website, assistance appreciated!

2012-04-11 Thread Thomas Hogarth
My Account had been activated

It got classed as spam by gmail. Found this about it

http://forum.joomla.org/viewtopic.php?p=2602821

Says this could be a solution

http://support.google.com/a/bin/answer.py?hl=enhlrm=enanswer=33786

Also on the subject of accounts, are we planning to use the joomla accounts
to login to MediaWiki?

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


Re: [osg-users] Building new website, assistance appreciated!

2012-04-11 Thread Thomas Hogarth
Hi Again

So I've been playing a bit more with mediawiki, seems pretty good.

http://wiki.openscenegraph.com/index.php?title=File:Stereomagic-screenshot01.png

Not much but adding the links and image was very easy.

I've also been having a look at features that could make the tutorials easier 
to follow. Found this plugin for syntax highlighting.

http://www.mediawiki.org/wiki/Extension:Syntax_Highlighting

So is the plan to flesh out what you have on Joomla site (downloads, about, 
screen shots, pr etc), then move everything in the documentation section of the 
current site over to mediawiki?

Cheers
Tom

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





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


Re: [osg-users] [build] Cmake - The C compiler /usr/bin/gcc is not able to compile a simple test program.

2012-04-04 Thread Thomas Hogarth
Hi Guys

I have just run into this myself, the issue is caused by CMake looking for 
XCode in the old /Developer folder. The very latest xcode installed from the 
app store (4.3.2) now stores xcode and all it's SDKs etc in an app bundle in 
the /Applications folder.

I've found a fix for cmake which requires building from source,

https://github.com/Kitware/CMake/pull/15

I think it is applied the latest master branch of the CMake git repository. 
I've downloaded and built it but I'm still getting the error.

I'm going to keep digging as this as just put a halt to my project.

(Why oh why did I update XCode :( )

Cheers
Tom

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





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


Re: [osg-users] OSG + PhysX + Havok demos

2012-04-04 Thread Thomas Hogarth
Building the latest version of CMake did fix my issue, I just needed to start 
the process from scratch.

Here's hoping they release a new stable version soon.

I also ran into a separate issue using latest IOS sdk 5.1.  A few of the unused 
sampler defines have been removed. I'll submit my fix later

Cheers
Tom

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





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


[osg-users] IOS SK 5.1, XCode 4.3.2 and CMake

2012-04-04 Thread Thomas Hogarth
Hi All

Just sharing an issue I have had with latest version of XCode 4.3.2. XCode
and all it's libs etc
are now installed into an app bundle in the applications folder.

When trying to run the current stable version of cmake 2.8.7, you receive
an error stating the
gcc compiler is not working.

Downloading the latest nightly build of CMake fixes the issue

http://www.cmake.org/files/dev/

There are also a few compile errors using the 5.1 IOS sdk, a fix has been
submitted and is also
attached.

Cheers
Tom


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


Re: [osg-users] Website, Version control and Server migration

2012-04-03 Thread Thomas Hogarth
Hi Robert

I've had a quick go at creating an account on the new MediaWiki system, was
very straight forward. I don't have much experience with web backends but
am very interested in helping out with content and general admin of the new
site.

I've been meaning to create some more detailed information about IOS
specific stuff and the new website is a good time to start I think.

Only comments so far are that I couldn't find how to add images, I think
you need to enable user uploads but I guess this creates the issue with how
much do you allow to be uploaded etc.

In terms of ideas for the new site I always liked the simple layout of the
openframeworks site

http://www.openframeworks.cc/

I especially like the feeds at the bottom with information about the latest
commits etc, helps people keep up with what's going on. Although their
tutorials are difficult to find.

I think the main downfall of the current OpenSceneGraph site is that too
many topics are presented in a single view. e.g. the Getting Started page
has info about multiple platforms, instead we should break things down so
it's more like

-Getting Started
   -Linux
   -Windows
   -OSX
   -Android
   -IOS

So that users are getting the information relevant to them, quicker and not
posting the same old questions on the forum as much.

Perhaps people should design there suggestions for how we categorise and
access the content then we can compare ideas.

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


Re: [osg-users] Website, Version control and Server migration

2012-04-03 Thread Thomas Hogarth
Hi Robert

I do wonder if with having a new and more powerful wiki would open the
door to better community content and hopefully... documentation.  I'm
wondering whether we can push much of the documentation onto the wiki
and then have the main website act as a place holder for
downloads/gallery and as gateway to forum/mailing list/wiki.

I do like the idea of a using the wiki for all tutorials and documentation,
having a simpler system will make users more inclined to contribute
and correct information.

Then as you say, the main site can be a more polished portal for
downloads, forum, release news etc. Joomla should help make this
quite easy to keep updated from what I've been reading.

Having a wiki with it's log in user account, and potentially CMS like
Joomla with it's own user accounts, and the forum and mailing list
both with their own user accounts will be rather messy.  So I wonder
if it might be possible to have just one account on the main site and
then have options for enabling wiki/forum/mailing list activation.
Is this possible?

Linking of all the accounts sounds like a good feature too. I found these
regarding MediaWiki, Joomla and phpBB

http://www.mediawiki.org/wiki/Extension:AuthJoomla

http://www.mediawiki.org/wiki/Extension:PHPBB/Users_Integration

They seem to show it's doable but will probably require some work.

I'll keep reading up on this stuff, and think about layouts etc.

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


Re: [osg-users] Retrobooster - OSG-based game

2012-03-21 Thread Thomas Hogarth
Hi Terry

This looks great, love the lighting. Crazy to get a hobby project looking
so polished.

Any plans for a release, a port to IOS or Android would be cool.

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


Re: [osg-users] Testing of OpenSceneGraph svn/trunk in prep for 3.1 dev release

2012-02-27 Thread Thomas Hogarth
Hi Robert

I've had a few compile errors on IOS with everything configured for Float,
nothing major. Fixes have been submitted.

With fixes I successfully built with XCode 4.2.1 for IOS SDK 5.0, GLES2,
run on IPad and IPhone. Also compiled with Apples newer LLVM compiler and
everything seems to work fine.

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


Re: [osg-users] IOS 5 - Scene does not get rendered after switch from iOS 4 SDK to iOS 5 SDK

2012-02-10 Thread Thomas Hogarth
Hi Jan

I have released apps using OSG on IOS 5. The fact you are still seeing 
something is quite odd. Have you rebuilt osg against IOS 5?

Only thing off the top of my head is, if you are using shaders perhaps the 
scene shaders are no longer compiling (although I haven't experienced that 
myself). Make sure your osg notify level is set to at least INFO to see shader 
compile errors.

Cheers
Tom

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





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


Re: [osg-users] Reading osg files with images and xml files from archives on Android

2011-12-13 Thread Thomas Hogarth
Hi J-S

Thanks for the heads up on the Virtual File System thread, just spotted it on 
the Submissions thread. I'll read through and add my two cents as I think this 
will be really important for android developers.

I may still use the ReadFileCallback as a temp fix as I am doing a proof of 
concept port of an iOS game. 

On the whole though everything has gone smoothly.

Thanks again for the help
Tom

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





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


Re: [osg-users] Reading osg files with images and xml files from archives on Android

2011-12-12 Thread Thomas Hogarth
Hi Again

2. I use osgDB XmlPasser quite a bit for simple meta data stuff. Is there a 
way to read an xml file from and archive?  I usually read my xml files like 
so 


So I solved one of my problems, I used the present 3d plugin as inspiration to 
write a simple plugin to wrap loading xmlinput into an osg object wrapper.

I now just have the issue that images referenced by .osg files are not loaded 
from the archive, anyone have any advice? The images are referenced relative to 
the .osg e.g. image\\diffuse.png

Loading pngs directly is working fine.

Cheers
Tom

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





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


[osg-users] Reading osg files with images and xml files from archives on Android

2011-12-11 Thread Thomas Hogarth
Hi All

I've been playing around with the zip plugin in order to read files from my
apk file on Android. Apk is basically a zipped up version of your app with
all the assets etc inside.

This is now working fine while directly reading images, .osg files and
fonts, however I have two issues.

1. Images referenced by the .osg are not loaded, for example if my model is
in 'pkg.apk/assets/Models/model1.osg' and it references
'images\\diffuse.png' then the image is not loaded. I have tried moving the
image to the root of the archive in/not in an images folder but it never
seems to load.

2. I use osgDB XmlPasser quite a bit for simple meta data stuff. Is there a
way to read an xml file from and archive?  I usually read my xml files like
so

osgDB::XmlNode::Input input;
input.open(foundFile);
input.readAllDataIntoBuffer();
osg::ref_ptrosgDB::XmlNode root = new osgDB::XmlNode;
root-read(input);

 osgDB::XmlNode::Input has stream reading methods, but is it possible to
get access to an archive file as a stream?


Cheers
Tom

PS

For those interested here is how I get the zip plugin to read the apk

osgDB::Registry::instance()-addFileExtensionAlias(apk , zip);
osgDB::ReaderWriter* zipReader =
osgDB::Registry::instance()-getReaderWriterForExtension(zip);

if(zipReader)
{
zipReader-supportsExtension(apk, Android package);
if(zipReader-acceptsExtension(apk))
{
OSG_FATAL  ZIP Plugin supports apk  std::endl;
}else{
OSG_FATAL  ZIP Plugin does not support apk!  std::endl;
}
}else{
OSG_FATAL  No ZIP Plugin!  std::endl;
}


osg::ref_ptrosgDB::Archive_archive = osgDB::openArchive(pathToApk,
osgDB::Archive::READ);


To get the path to the apk use this in java and pass to c++ via jni stuff.

Context context = getApplicationContext(); // or other way of
getting current contex
String dir = context.getFilesDir().getPath();
String pathToApk = context.getPackageResourcePath();
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] osgText and GLES2

2011-11-29 Thread Thomas Hogarth
Hi Robert

Made some progress in the end, the subload errors were a red herring. Seems
perhaps some of the glyphs for the particular font I was using didn't load
properly, but the rest worked fine. So after a little digging I realised
mipmapping was probably the issue and that's when I remembered this post
from way back

http://forum.openscenegraph.org/viewtopic.php?t=6482

That has fixed the issue for me and I now have text rendering with drop
shadows in gles2 on IOS. I will give the fix a little more testing then
submit, as it seems the original poster rti didn't get round to sending the
fix for inclusion.

Thanks for popping your head in, thought I was all alone on this one :)

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


Re: [osg-users] osgText and GLES2

2011-11-18 Thread Thomas Hogarth
Any takers ;)

I should be able to implement any fix needed, just need a bit of guidance as 
I'm not too familiar with the internals of osgText.

Thanks
Tom

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





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


[osg-users] osgText and GLES2

2011-11-16 Thread Thomas Hogarth
Hi All

I've been using osgText on GLES1 with some good results, I'm now moving to
gles2 and am having some issues. I've attached a basic shader to get things
started which looks like the following

uniform sampler2D diffuseTexture;\n
varying mediump vec2 texCoord0;\n
void main(void) {\n
  gl_FragColor = texture2D(diffuseTexture, texCoord0).;\n
}\n

This has worked in the past on windows and i've seen it mentioned in this
post

http://forum.openscenegraph.org/viewtopic.php?t=5340

However on GLES 2 I'm getting just solid white quads at the location of
each texture quad. I've found this in my log output


Created new 0x8e5e410 TextureObject, _numOfTextureObjects 1
glGetString(GL_RENDERER)==PowerVR SGX 535
before Glyph::subload(): detected OpenGL error: invalid enumerant
after Glyph::subload() : detected OpenGL error: invalid enumerant
glTexSubImage2D(0xde1 ,0
1 ,1
18 ,22
0x1906
0x1401
0x8e21fa0);
Glyph::subload(): texture sub-image width and/or height of 0, ignoring
operation.
Glyph::subload(): texture sub-image width and/or height of 0, ignoring
operation.


The width and height look to be 18 and 22 to me, does anyone know what the
issue might be.

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


[osg-users] Texture upload on separate thread/context

2011-10-06 Thread Thomas Hogarth
Hi Guys

I'm looking for ways to speed up my live camera feed on IOS. I've read that
uploading the texture on a separate thread/context (linked as shared I
guess) will help speed things up. Could anyone point me to an example that
might do something like this. Would be a lot of help.

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


Re: [osg-users] osganimationhardware example osg 3.0.1

2011-09-29 Thread Thomas Hogarth
Hi Robert,

Yup, that seems to have done the trick. Now onward to no fixed
functionality, yippee (i.e. use osg_vertex etc in shader)

Thanks Again
Tom



On 29 September 2011 09:40, Robert Osfield robert.osfi...@gmail.com wrote:

 Hi Thomas.

 Could it be that you are hitting up against the NVidia driver issue
 relating to the handing of uniform arrarys.  The svn/trunk version of
 the OSG has a workaround for this issue so would recommend trying
 this.

 Robert.

 On Thu, Sep 29, 2011 at 3:30 AM, Thomas Hogarth
 thomas.hoga...@gmail.com wrote:
  Hi Guys
  I've been trying to run the osganimationhardware example for osg 3.0.1 on
  windows7 32bit with Geforce GTX 560 and latest drivers 280.26 . In the
 past
  I have had this running (not on this machine or osg version), I simply
  downloaded the osgData collection with the nathan.osg and skinning.vert
  shader file.
  However now when I'm running it, anything that is skinned does not
 render. I
  have altered the shader to just use the gl_Vertex position rather then
 the
  weighted position and then the object renders (so verts are fine). I have
  also used the boneWeight0 uniforms to colour the mesh and they seem to
 have
  decent values.
  The only thing that doesn't seem to have good values is
  uniform mat4 matrixPalette[MAX_MATRIX];
  When I checked the converted shader the value of MAX_MATRIX seems to be
 set
  correctly, but if I used the first line of the first matrix as the colour
  value, like
  gl_FrontColor = matrixPalette[0][0];
  It is always black,
  Looking at the uniform attached to the geoms stateset I can see roughly
 the
  following in the debugger
  _uniformList = [2]((matrixPalette, ({_ptr=0x0d0bfb58 },
  0)),(nbBonesPerVertex, ({_ptr=0x0d0bf3b8 }, 0)))
  _ptr = 0x0d0bfb58 {_parents=[1](0x0d0bfed8 {_parents=[1](0x00df9bf8
  {_name= _dataVariance=DYNAMIC _userDataContainer=0x })
  _modeList=[0]() _attributeList=[1](((PROGRAM, 0), ({_ptr=0x0d0bc9c0 },
 0)))
  ...}) _type=FLOAT_MAT4 _numElements=3 ...}
  osg::MixinVectorfloat =
 
 {_impl=[48](1.000,0.,0.,0.,0.,1.000,0.,0.,0.,0.,1.000,0.,0.,0.,0.,1.000,0.8939,0.0046100151,0.,0.,-0.0046100151,0.8939,0
 
  So if the colour is the first vec4 of the matrixPalette uniform it should
  be 1.000,0.,0.,0., but it's just black.
  Can anyone confirm the osganimationhardware example is currently working
  with these assets
  http://www.openscenegraph.org/projects/osg/wiki/Downloads/SampleDatasets
 
  Any help would be awesome
  Tom
  PS
  My config looks like this
  #ifndef OSG_CONFIG
  #define OSG_CONFIG 1
  /* #undef OSG_NOTIFY_DISABLED */
  /*#define OSG_USE_FLOAT_MATRIX
  #define OSG_USE_FLOAT_PLANE
  #define OSG_USE_FLOAT_BOUNDINGSPHERE
  #define OSG_USE_FLOAT_BOUNDINGBOX*/
  #define OSG_USE_REF_PTR_IMPLICIT_OUTPUT_CONVERSION
  /* #undef OSG_USE_UTF8_FILENAME */
  #define OSG_DISABLE_MSVC_WARNINGS
  #define OSG_GL1_AVAILABLE
  #define OSG_GL2_AVAILABLE
  /* #undef OSG_GL3_AVAILABLE */
  /* #undef OSG_GLES1_AVAILABLE */
  /* #undef OSG_GLES2_AVAILABLE */
  /* #undef OSG_GL_LIBRARY_STATIC */
   #define OSG_GL_DISPLAYLISTS_AVAILABLE
   #define OSG_GL_MATRICES_AVAILABLE
   #define OSG_GL_VERTEX_FUNCS_AVAILABLE
   #define OSG_GL_VERTEX_ARRAY_FUNCS_AVAILABLE
   #define OSG_GL_FIXED_FUNCTION_AVAILABLE
  #endif
  I mention it as originally I dived straight into trying it without any
 fixed
  functionality essentially emulating gles2, but had this same issue. I've
  then gone for the more standard build above, but the result is the same
  (although now I see objects that aren't skinned) If I can get this
 working
  again on desktop then I don't think getting it working on gles2 will be
 too
  much hassle (unless I hit some shader variable length limit).
  Also standard osgAnimationViewer works fine
  ___
  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] osganimationhardware example osg 3.0.1

2011-09-29 Thread Thomas Hogarth
Hi Again

I've now moved over to IOS and am having the same issue (with the same
version 3.0.1). I'm just now building the latest svn, but you mentioned the
issue was Nvidia related. Do you think the fix might help my IOS build?

Many thanks
Tom

On 29 September 2011 13:32, Thomas Hogarth thomas.hoga...@gmail.com wrote:

 Hi Robert,

 Yup, that seems to have done the trick. Now onward to no fixed
 functionality, yippee (i.e. use osg_vertex etc in shader)

 Thanks Again
 Tom



 On 29 September 2011 09:40, Robert Osfield robert.osfi...@gmail.comwrote:

 Hi Thomas.

 Could it be that you are hitting up against the NVidia driver issue
 relating to the handing of uniform arrarys.  The svn/trunk version of
 the OSG has a workaround for this issue so would recommend trying
 this.

 Robert.

 On Thu, Sep 29, 2011 at 3:30 AM, Thomas Hogarth
 thomas.hoga...@gmail.com wrote:
  Hi Guys
  I've been trying to run the osganimationhardware example for osg 3.0.1
 on
  windows7 32bit with Geforce GTX 560 and latest drivers 280.26 . In the
 past
  I have had this running (not on this machine or osg version), I simply
  downloaded the osgData collection with the nathan.osg and skinning.vert
  shader file.
  However now when I'm running it, anything that is skinned does not
 render. I
  have altered the shader to just use the gl_Vertex position rather then
 the
  weighted position and then the object renders (so verts are fine). I
 have
  also used the boneWeight0 uniforms to colour the mesh and they seem to
 have
  decent values.
  The only thing that doesn't seem to have good values is
  uniform mat4 matrixPalette[MAX_MATRIX];
  When I checked the converted shader the value of MAX_MATRIX seems to be
 set
  correctly, but if I used the first line of the first matrix as the
 colour
  value, like
  gl_FrontColor = matrixPalette[0][0];
  It is always black,
  Looking at the uniform attached to the geoms stateset I can see roughly
 the
  following in the debugger
  _uniformList = [2]((matrixPalette, ({_ptr=0x0d0bfb58 },
  0)),(nbBonesPerVertex, ({_ptr=0x0d0bf3b8 }, 0)))
  _ptr = 0x0d0bfb58 {_parents=[1](0x0d0bfed8 {_parents=[1](0x00df9bf8
  {_name= _dataVariance=DYNAMIC _userDataContainer=0x })
  _modeList=[0]() _attributeList=[1](((PROGRAM, 0), ({_ptr=0x0d0bc9c0 },
 0)))
  ...}) _type=FLOAT_MAT4 _numElements=3 ...}
  osg::MixinVectorfloat =
 
 {_impl=[48](1.000,0.,0.,0.,0.,1.000,0.,0.,0.,0.,1.000,0.,0.,0.,0.,1.000,0.8939,0.0046100151,0.,0.,-0.0046100151,0.8939,0
 
  So if the colour is the first vec4 of the matrixPalette uniform it
 should
  be 1.000,0.,0.,0., but it's just black.
  Can anyone confirm the osganimationhardware example is currently working
  with these assets
 
 http://www.openscenegraph.org/projects/osg/wiki/Downloads/SampleDatasets
 
  Any help would be awesome
  Tom
  PS
  My config looks like this
  #ifndef OSG_CONFIG
  #define OSG_CONFIG 1
  /* #undef OSG_NOTIFY_DISABLED */
  /*#define OSG_USE_FLOAT_MATRIX
  #define OSG_USE_FLOAT_PLANE
  #define OSG_USE_FLOAT_BOUNDINGSPHERE
  #define OSG_USE_FLOAT_BOUNDINGBOX*/
  #define OSG_USE_REF_PTR_IMPLICIT_OUTPUT_CONVERSION
  /* #undef OSG_USE_UTF8_FILENAME */
  #define OSG_DISABLE_MSVC_WARNINGS
  #define OSG_GL1_AVAILABLE
  #define OSG_GL2_AVAILABLE
  /* #undef OSG_GL3_AVAILABLE */
  /* #undef OSG_GLES1_AVAILABLE */
  /* #undef OSG_GLES2_AVAILABLE */
  /* #undef OSG_GL_LIBRARY_STATIC */
   #define OSG_GL_DISPLAYLISTS_AVAILABLE
   #define OSG_GL_MATRICES_AVAILABLE
   #define OSG_GL_VERTEX_FUNCS_AVAILABLE
   #define OSG_GL_VERTEX_ARRAY_FUNCS_AVAILABLE
   #define OSG_GL_FIXED_FUNCTION_AVAILABLE
  #endif
  I mention it as originally I dived straight into trying it without any
 fixed
  functionality essentially emulating gles2, but had this same issue. I've
  then gone for the more standard build above, but the result is the same
  (although now I see objects that aren't skinned) If I can get this
 working
  again on desktop then I don't think getting it working on gles2 will be
 too
  much hassle (unless I hit some shader variable length limit).
  Also standard osgAnimationViewer works fine
  ___
  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] osganimationhardware example osg 3.0.1

2011-09-29 Thread Thomas Hogarth
Hi Robert

Not sure how relevant to you this is, but as I reported I had the same
uniform mat4 array issue on IOS gles2. I've downloaded and linked to the
latest trunk just now and that has fixed the problem. Was the issue you
mentioned Nvidia specific or OpenGL in general.

I guess it doesn't matter either way, I now have the osganimationhardware
example running on my iPod Touch 4th gen.

Now to try and make it look pretty :)

Cheers
Tom

PS

Only change needed was to attach a fragment shader and change a few variable
names, shaders are attached.


skinning.frag
Description: Binary data


skinning.vert
Description: Binary data
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] osganimationhardware example osg 3.0.1

2011-09-28 Thread Thomas Hogarth
Hi Guys

I've been trying to run the osganimationhardware example for osg 3.0.1 on
windows7 32bit with Geforce GTX 560 and latest drivers 280.26 . In the past
I have had this running (not on this machine or osg version), I simply
downloaded the osgData collection with the nathan.osg and skinning.vert
shader file.

However now when I'm running it, anything that is skinned does not render. I
have altered the shader to just use the gl_Vertex position rather then the
weighted position and then the object renders (so verts are fine). I have
also used the boneWeight0 uniforms to colour the mesh and they seem to have
decent values.

The only thing that doesn't seem to have good values is

uniform mat4 matrixPalette[MAX_MATRIX];

When I checked the converted shader the value of MAX_MATRIX seems to be set
correctly, but if I used the first line of the first matrix as the colour
value, like

gl_FrontColor = matrixPalette[0][0];

It is always black,

Looking at the uniform attached to the geoms stateset I can see roughly the
following in the debugger

_uniformList = [2]((matrixPalette, ({_ptr=0x0d0bfb58 },
0)),(nbBonesPerVertex, ({_ptr=0x0d0bf3b8 }, 0)))

_ptr = 0x0d0bfb58 {_parents=[1](0x0d0bfed8 {_parents=[1](0x00df9bf8
{_name= _dataVariance=DYNAMIC _userDataContainer=0x })
_modeList=[0]() _attributeList=[1](((PROGRAM, 0), ({_ptr=0x0d0bc9c0 }, 0)))
...}) _type=FLOAT_MAT4 _numElements=3 ...}

osg::MixinVectorfloat =
{_impl=[48](1.000,0.,0.,0.,0.,1.000,0.,0.,0.,0.,1.000,0.,0.,0.,0.,1.000,0.8939,0.0046100151,0.,0.,-0.0046100151,0.8939,0


So if the colour is the first vec4 of the matrixPalette uniform it should
be 1.000,0.,0.,0., but it's just black.

Can anyone confirm the osganimationhardware example is currently working
with these assets

http://www.openscenegraph.org/projects/osg/wiki/Downloads/SampleDatasets


Any help would be awesome
Tom

PS
My config looks like this
#ifndef OSG_CONFIG
#define OSG_CONFIG 1

/* #undef OSG_NOTIFY_DISABLED */
/*#define OSG_USE_FLOAT_MATRIX
#define OSG_USE_FLOAT_PLANE
#define OSG_USE_FLOAT_BOUNDINGSPHERE
#define OSG_USE_FLOAT_BOUNDINGBOX*/
#define OSG_USE_REF_PTR_IMPLICIT_OUTPUT_CONVERSION
/* #undef OSG_USE_UTF8_FILENAME */
#define OSG_DISABLE_MSVC_WARNINGS

#define OSG_GL1_AVAILABLE
#define OSG_GL2_AVAILABLE
/* #undef OSG_GL3_AVAILABLE */
/* #undef OSG_GLES1_AVAILABLE */
/* #undef OSG_GLES2_AVAILABLE */
/* #undef OSG_GL_LIBRARY_STATIC */
 #define OSG_GL_DISPLAYLISTS_AVAILABLE
 #define OSG_GL_MATRICES_AVAILABLE
 #define OSG_GL_VERTEX_FUNCS_AVAILABLE
 #define OSG_GL_VERTEX_ARRAY_FUNCS_AVAILABLE
 #define OSG_GL_FIXED_FUNCTION_AVAILABLE

#endif

I mention it as originally I dived straight into trying it without any fixed
functionality essentially emulating gles2, but had this same issue. I've
then gone for the more standard build above, but the result is the same
(although now I see objects that aren't skinned) If I can get this working
again on desktop then I don't think getting it working on gles2 will be too
much hassle (unless I hit some shader variable length limit).

Also standard osgAnimationViewer works fine
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Render to Depth Texture GLES 2 IOS

2011-08-05 Thread Thomas Hogarth
I fixed it,

Well I found out what you have to do to make it work. You have to also
attach a color texture to the camera, else you get the incomplete attachment
error.

Hope it helps anyone else trying this

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


[osg-users] Render to Depth Texture GLES 2 IOS

2011-08-04 Thread Thomas Hogarth
Hi Guys

I've been tasked with getting shadow mapping running on IOS using gles2.
I've run into a stumbling block in that the the rtt camera FBO is failing to
init, output below

Setting up osg::Camera::FRAME_BUFFER_OBJECT
RenderStage::runCameraSetUp(), FBO setup failed, FBO status= 0x8cd6
OpenGL extension 'WGL_ARB_render_texture' is not supported. -- might be
relavent



 My rtt texture and camera is setup as follows

_shadowMap = new osg::Texture2D();
_shadowMap-setTextureSize(shadowMapRes.x(), shadowMapRes.y());
_shadowMap-setInternalFormat(GL_DEPTH_COMPONENT);
_shadowMap-setShadowComparison(true);
_shadowMap-setShadowTextureMode(osg::Texture::LUMINANCE);

_shadowMap-setFilter(osg::Texture2D::MIN_FILTER,osg::Texture2D::LINEAR);

_shadowMap-setFilter(osg::Texture2D::MAG_FILTER,osg::Texture2D::LINEAR);

//create prerender camera to render into the shadowmap texture
_shadowMapRenderCamera = new osg::Camera();
// set viewport

_shadowMapRenderCamera-setViewport(0,0,shadowMapRes.x(),shadowMapRes.y());
_shadowMapRenderCamera-setClearMask(GL_DEPTH_BUFFER_BIT |
GL_COLOR_BUFFER_BIT);

_shadowMapRenderCamera-setClearColor(osg::Vec4(1.0f,1.0f,1.0f,1.0f));

_shadowMapRenderCamera-setComputeNearFarMode(osg::Camera::DO_NOT_COMPUTE_NEAR_FAR);
_shadowMapRenderCamera-setRenderOrder(osg::Camera::PRE_RENDER);

_shadowMapRenderCamera-setRenderTargetImplementation(osg::Camera::FRAME_BUFFER_OBJECT);
_shadowMapRenderCamera-attach(osg::Camera::DEPTH_BUFFER,
_shadowMap.get());
//_shadowMapRenderCamera-attach(osg::Camera::COLOR_BUFFER0,
_shadowMap.get());

I took the above from some old code using CameraNode  and was wondering
if GL_DEPTH_COMPONENT was correct, changing to GL_RGBA, GL_LUMINANCE
produces the correct results, only depth maps have the issue. I did a quick
search and found a supported depth texture extension,info below.

http://www.khronos.org/registry/gles/extensions/OES/OES_depth_texture.txt

If you read the above it states under issue 3 that 24 bit depth is not
supported. I've setup my context with 16 bit depth but still no luck.

Anyone have any advice
Cheers
Tom
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Render to Depth Texture GLES 2 IOS

2011-08-04 Thread Thomas Hogarth
Hi Again

A bit more information to go on. I ran a test with the OpenGL
ES Analyser and it reports two issues

glTexImage2D(GL_TEXTURE_2D, 0, GL_DEPTH_COMPONENT, 512, 512, 0,
GL_DEPTH_COMPONENT, GL_UNSIGNED_BYTE, NULL)
: (invalid enum=0x1902): Invalid enum for argument 'internalformat'

glRenderbufferStorage(GL_RENDERBUFFER, GL_RGB, 512, 512)
: (invalid enum=0x1907): Invalid enum for argument 'internalformat'

I've also tried setting the texture format to GL_DEPTH_COMPONENT16, but no
luck. To make things a little clearer below is the DEBUG_FP output for the
FBO setup

--

OpenGL extension '' is not supported.
Adding parent0x808160
Adding parent0x808160
cull()
cull() got SceneView 0x839330
ShaderComposer::~ShaderComposer() 0x83a860
Uniform Adding parent
Uniform Adding parent
Uniform Adding parent
Uniform Adding parent
Uniform Adding parent
Uniform Adding parent
Uniform Adding parent
end cull() 0x838eb0

OpenGL extension 'GL_EXT_packed_depth_stencil' is not supported.
Setting up osg::Camera::FRAME_BUFFER_OBJECT
RenderStage::runCameraSetUp(), FBO setup failed, FBO status= 0x8cd6
OpenGL extension 'WGL_ARB_render_texture' is not supported.
Failed to acquire Graphics Context

Setting up osg::Camera::FRAME_BUFFER
Warning: detected OpenGL error 'invalid enumerant' at after
RenderBin::draw(..)

Setting up osg::Camera::FRAME_BUFFER
Warning: detected OpenGL error 'invalid operation' at after
RenderBin::draw(..)
Setting up osg::Camera::FRAME_BUFFER
Warning: detected OpenGL error 'invalid enumerant' at after
RenderBin::draw(..)
end draw() 0x838eb0
draw() 0x838eb0
draw() got SceneView 0x839330

--

The 'Failed to acquire Graphics Context' seem a little concerning but again
the RGBA version works.

Cheers
Tom

PS
The FBO status error is GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] OpenSceneGraph-3.0.1-rc3 tagged, please test

2011-07-30 Thread Thomas Hogarth
Hi Robert

IOS armv7 build working fine.

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


Re: [osg-users] Video playback on Mac via Imagestream.

2011-07-29 Thread Thomas Hogarth
I remember using ARVideo on Mac once and finding that the path to the video is 
different to windows. Well not exactly, I think ARVideo sees the current 
directory as the path to the actual binary in the bundle not the resources 
folder. Try putting your file in a few different places, bundle root, MacOS 
folder etc. Think that will fix it.

But also Stephans point is very valid, just use OSGs native video support 
rather than ARTKs

Cheers
Tom

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





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


[osg-users] Adding an offset to an animation path

2011-07-19 Thread Thomas Hogarth
Hi All

I have what seems like a straight forward problem, but my solution does not
seem to work. I want to add a world offset to all osg animation paths in a
graph so that the animation can be used for a kinematic object with
osgBullet, which requires the object be in absolute world coords (which
leaves just adding a transform above out of the question). I tried this
simple loop over the TimeControlPointMap but when the app runs the animated
object is still in the same place.

//if animation update callback is found add the
rigid body animate callback

osg::AnimationPathCallback* apc = dynamic_cast
osg::AnimationPathCallback*(osgTrans-getUpdateCallback());

if(apc){

osgbBullet::RigidBodyAnimation* rba =
newosgbBullet::RigidBodyAnimation;

apc-setNestedCallback(rba);



//add the world offset to the

osg::AnimationPath* aniPath = apc-
getAnimationPath();

//osg::AnimationPath* newPath = new
osg::AnimationPath();



//osg::AnimationPath::TimeControlPointMap
timeMap = aniPath-getTimeControlPointMap();

osg::AnimationPath::TimeControlPointMap tcpm =
aniPath-getTimeControlPointMap();


for(osg::AnimationPath::TimeControlPointMap::iterator
tcpmitr=tcpm.begin();

tcpmitr!=tcpm.end();

++tcpmitr)

{

//add world offset

osg::Vec3 cpPos = tcpmitr-second.
getPosition();

OSG_FATAL  PRE  POS   cpPos.x()  ,
  cpPos.y()  ,   cpPos.z()  std::endl;

tcpmitr-second.setPosition(cpPos+
_worldOffset);

cpPos = tcpmitr-second.getPosition();

OSG_FATAL  POST POS   cpPos.x()  ,
  cpPos.y()  ,   cpPos.z()  std::endl;


}

}

As you can see in the loop I get the current Position value, then set it
with the addition of the world offset. The Pre and Pos Pos message show that
the two values are different but when I run the object is atill in the same
place, not offset in any way.

Am I missing a step in changing te control points (dirty or something) ?


Many thanks

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


Re: [osg-users] Video textures on iOS (and audio)

2011-07-19 Thread Thomas Hogarth
Hi

I have code for a video camera feed and from what I can remember the docs said 
the same sort of technique could be used to create a callback for video file 
frames also.

Might be worth checking out the latest osgArt, they have added support for IOS 
and all other platforms have video file support.

Cheers
Tom

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





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


Re: [osg-users] Adding an offset to an animation path

2011-07-19 Thread Thomas Hogarth
No Worries

Fixed this by creating a new animation path with the offset and swapping
with the original. Code now looks like this

 //if animation update callback is found add the rigid body animate callback

osg::AnimationPathCallback* apc = dynamic_cast
osg::AnimationPathCallback*(osgTrans-getUpdateCallback());

if(apc){

osgbBullet::RigidBodyAnimation* rba =
newosgbBullet::RigidBodyAnimation;

apc-setNestedCallback(rba);



//add the world offset to the

osg::AnimationPath* aniPath = apc-
getAnimationPath();

osg::AnimationPath* newPath =
newosg::AnimationPath();

float time = 0.0f;

osg::AnimationPath::TimeControlPointMap tcpm =
aniPath-getTimeControlPointMap();


for(osg::AnimationPath::TimeControlPointMap::iterator
tcpmitr=tcpm.begin();

tcpmitr!=tcpm.end();

++tcpmitr)

{

//add world offset

osg::AnimationPath::ControlPoint cp(tcpmitr
-second.getPosition()+_worldOffset, tcpmitr-second.getRotation(), tcpmitr
-second.getScale());

newPath-insert(time, cp);

time += (1.0f/30.0f);

}

apc-setAnimationPath(newPath);

}

}


I'm still a little confused as to why the original didn't work?

Cheers

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


Re: [osg-users] Load and control multiple animations saved in a single OSG/IVE file

2011-07-12 Thread Thomas Hogarth
Hi Guys

No, it's not possible to export multiple takes to an FBX from 3DS Max. Motion 
builder is the only app that i know of which can do this.

I had the same issue and in the end wrote a tool to load the FBX with a single 
long take containing all my sub animations. Then split it into individual sub 
animations and export as a native osg file.

It's a bit of work but well worth the effort.

I seem to think I posted an old version of it on here once. Search my name 
(tomhog or Thomas Hogarth) and the attachment might still be active.

Cheers
Tom

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





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


Re: [osg-users] Texture2D subload callback gone mad

2011-07-02 Thread Thomas Hogarth
Hi Chris

Yes Robert sorted a solution for this in the end, I think in subloadcallback
there is now an extra function

textureObjectValid

You need to override this then always return true. That should sort your
issue.

Let me know how it works out
Tom
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Good new for IOS developers

2011-06-22 Thread Thomas Hogarth
Thanks Alessandro

It's called Alien Attack, it's actually been made for a client AppToyz to go
with there AppBlaster gun attachment for iphones. It should actually
be released in the next week or so. I'll give you a shout when it is.

Tom
PS
It's also free!

On 21 June 2011 21:19, Alessandro Terenzi a.tere...@gmail.com wrote:

 Congratulation Thomas!
 what's your app's name? I look forward to trying it...

 Alessandro

 PS: hope it's free ;)

 On Tue, Jun 21, 2011 at 1:41 PM, Thomas Hogarth 
 thomas.hoga...@gmail.comwrote:

 Hi All,

 This might have been discussed in the past but it's the
 first confirmation I have personally had. My first IOS app using
 OpenSceneGraph was approved for the app store today. I was using 2.9.15, so
 a pretty recent version (not recent enough to be a test of the 3.0
 rc1). OpenSceneGraph was also built statically and was using the depreciated
 osg and imageio plugins.


 Thought other would be interested.
 Tom

 PS
 If other have submitted apps, please let me know your experience


 ___
 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] Good new for IOS developers

2011-06-21 Thread Thomas Hogarth
Hi All,

This might have been discussed in the past but it's the first confirmation I
have personally had. My first IOS app using OpenSceneGraph was approved for
the app store today. I was using 2.9.15, so a pretty recent version (not
recent enough to be a test of the 3.0 rc1). OpenSceneGraph was also
built statically and was using the depreciated osg and imageio plugins.


Thought other would be interested.
Tom

PS
If other have submitted apps, please let me know your experience
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] osgBullet on IOS

2011-06-09 Thread Thomas Hogarth
Hi All

I've been working on getting osgBullet compiled for IOS, all seems to have
gone well and i got the basic demo with the glider running. I did run into
one compiler error from where I had compiled osg to use floats. I had to
change asBtTransform to the following

btTransform osgbBullet::asBtTransform( const osg::Matrix m )
{
const osg::Matrix::value_type* oPtr = m.ptr();
btScalar bPtr[ 16 ];
int idx;
for (idx=0; idx16; idx++)
bPtr[ idx ] = oPtr[ idx ];
btTransform t;
t.setFromOpenGLMatrix( bPtr );
return t;
}

The line

const osg::Matrix::value_type* oPtr = m.ptr();

was

const osg::Matrixd::value_type* oPtr = m.ptr();

Other then that all went well. Lets see how it performs.


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


Re: [osg-users] osgBullet on IOS

2011-06-09 Thread Thomas Hogarth
Hi Doug

Raised it as an issue, it made me enter a branch path but I had in fact
download the trunk.

Cheers
Tom

PS
I'll join the osgBullet users list and post there from now on.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] OpenSceneGraph hello

2011-05-31 Thread Thomas Hogarth
Wow what an amazing douche this person is

Block him, before I'm tempted by his amazing offers.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


  1   2   3   >