Re: [osg-users] readPixels return blank image

2010-01-11 Thread Ismail Pazarbasi
2010/1/11 forest fores...@163.com: hi all, I want to capture the screen ,what I have done is to add a eventhandler in which I add code like this     osg::ref_ptrosg::Image image = new osg::Image;     image-readPixels(0,0,m_iWidth,m_iHeight, GL_RGB,GL_UNSIGNED_BYTE);    

Re: [osg-users] Snow Leopard stl issues? (osg 2.9.5)

2009-10-07 Thread Ismail Pazarbasi
2009/10/7 Chip Collier pho...@gmail.com: Hi again! :) So it's just a problem with OSG in general it seems. I've tried building and linking in many different ways, all end in segfaults when trying to get the name of a node. I haven't tried much else because that's a pretty basic first

Re: [osg-users] Derived classes and ref_ptr

2009-09-04 Thread Ismail Pazarbasi
2009/9/5 Martin Beckett m...@mgbeckett.com: [quote=Paul Martz]If you can (obviously) change your code to understand instances of your new custom class, then I don't understand why you can't change your code to understand instances of ref_ptrs to your new custom class. Please explain this

Re: [osg-users] Derived classes and ref_ptr

2009-09-04 Thread Ismail Pazarbasi
Hi Martin, 2009/9/5 Martin Beckett m...@mgbeckett.com: Thanks but not really - then I can't use the new class in the scene graph. Yes, you can, can't you? Pass your objects to constructor. I wouldn't do it, but you want if you want to. class MyAdapter { typedef osg::ref_ptrosg::PAT

Re: [osg-users] Derived classes and ref_ptr

2009-09-04 Thread Ismail Pazarbasi
It appears that I forgot comments in constructors. 2009/9/5 Ismail Pazarbasi pazarb...@gmail.com: [snip] class MyAdapter {  typedef osg::ref_ptrosg::PAT osg_pat_type;  osg_pat_type m_sppat; public: // here is missing part  // you will use this constructor to pass a osg::ref_ptrosg::PAT

Re: [osg-users] Reference count catcher?

2009-08-19 Thread Ismail Pazarbasi
2009/8/19 Ufuk ufuk@gmail.com: i have an osg::Geometry. i store it in a class with ref_ptr when i delete it, i expect it to be deleted. in debug, i saw that the reference count is 2 before this destructor. even if i set this value to null, there reference count remains 1. so it is not

Re: [osg-users] how to compile openscenegraph in 64 bit archytecture

2009-08-16 Thread Ismail Pazarbasi
2009/8/16 lucas Grijander dev_crisa...@hotmail.com: Hi everybody, i am trying to compile openscenegraph in our new server (64 bit double quad processor), but I get some errors with the dependencies, which are pre-compiled (in 32bits I suppose). Does anybody have the dependencies pre-compiled

Re: [osg-users] how to compile openscenegraph in 64 bit archytecture

2009-08-16 Thread Ismail Pazarbasi
2009/8/16 lucas Grijander dev_crisa...@hotmail.com: Hi, actually I also want to compile 2.8.0. The platform will be Windows Server 2003. So you recommend to download the sources of 3rdparty and re-compile everything in 64? J. Date: Sun, 16 Aug 2009 15:39:03 +0200 From: pazarb...@gmail.com

Re: [osg-users] how to compile openscenegraph in 64 bit archytecture

2009-08-16 Thread Ismail Pazarbasi
2009/8/16 lucas Grijander dev_crisa...@hotmail.com: I'm sorry but I don't have a lot of experience in compilation. I downloaded the required libs from gnuwin32 (tiff, png, gif, jpg, freetype), and now they say to use this to compile it: nmake /f makefile.vc but where do I have to change the

Re: [osg-users] how to compile openscenegraph in 64 bit archytecture

2009-08-16 Thread Ismail Pazarbasi
2009/8/16 lucas Grijander dev_crisa...@hotmail.com: thanks! I suppose that I should change something in the nmake.opt file? J. Date: Sun, 16 Aug 2009 17:21:05 +0200 From: pazarb...@gmail.com To: osg-users@lists.openscenegraph.org Subject: Re: [osg-users] how to compile openscenegraph in

Re: [osg-users] ref_ptr question

2009-06-24 Thread Ismail Pazarbasi
On Wed, Jun 24, 2009 at 10:12 PM, Judd Tracyj...@thetracys.net wrote: You could always attach a create your own DeleteHandler and attach it to the node, but I don't know if that will help you other then letting you know it is going to be deleted. On Wed, Jun 24, 2009 at 11:58 AM,

Re: [osg-users] CPU usage

2009-06-08 Thread Ismail Pazarbasi
On Mon, Jun 8, 2009 at 3:59 PM, Cory Riddellc...@codeware.com wrote: Hi Robert, On Fri, Jun 5, 2009 at 8:21 PM, Cory Riddellc...@codeware.com wrote: Does anybody see less than 100% CPU utilization when running osgviewer cow.osg on an ATI card? I had just been accepting that as normal.

Re: [osg-users] maxium children count

2009-06-06 Thread Ismail Pazarbasi
2009/6/6 Rabbi Robinson longa...@gmail.com: Hi, I am doing a PDB (protein data base) file importer. The number of atoms in a typical database is about 4000 to 6000, I organize them in to groups with positionattitudetransform. I noticed if the number of atoms exceeds certain number, the

Re: [osg-users] osg::ref_ptr used anymore

2009-05-31 Thread Ismail Pazarbasi
2009/5/31 Ulrich Hertlein u.hertl...@sandbox.de: On 31/5/09 7:07 PM, James Killian wrote: Not ALL pointers need a reference count like those which are private (not intended to be shared), that's one reason why boost created the scoped pointer... too bad all the c++ programmers I know never

Re: [osg-users] osg::ref_ptr used anymore

2009-05-31 Thread Ismail Pazarbasi
2009/5/31 Ulrich Hertlein u.hertl...@sandbox.de: On 31/5/09 9:06 PM, Ismail Pazarbasi wrote: 2009/5/31 Ulrich Hertleinu.hertl...@sandbox.de: Maybe because boost isn't exactly a light dependency to carry around? ... sorry but what's so heavy about boost to carry around? Do you use signal

Re: [osg-users] osg::ref_ptr used anymore

2009-05-28 Thread Ismail Pazarbasi
2009/5/28 Jason Daly jd...@ist.ucf.edu: Rabbi Robinson wrote: [snip] If later I call, ptr = NULL, it doesn't seem that there is anyway to tell node to decrement the reference count in node. This will decrement the reference count in node.  If the reference count goes to zero, it will be

Re: [osg-users] Access vertices and faces after load the model

2009-05-28 Thread Ismail Pazarbasi
2009/5/28 Xin Chen chenxi...@hotmail.com: Hi,    I'm new to OSG. I use the following code to load my model, which is successful.  How can I access the vertices and faces of the model? Thank you. nNode = osgDB::readNodeFile(D:/Livingroom.3DS); Thank you! Cheers, xinchen

Re: [osg-users] MFC or Win32 based viewer

2009-05-28 Thread Ismail Pazarbasi
2009/5/28 Clay, Bruce bc...@ball.com: I have tried all of the ones except for osgWin32Demo (the link is nonresponsive) in the windowing Toolkit section and can not get them to compile with the current version of OSG for various reasons.  One uses a CameraManipulator which doe4s not seem to be

Re: [osg-users] Access vertices and faces after load the model

2009-05-28 Thread Ismail Pazarbasi
2009/5/28 Xin Chen osgfo...@tevs.eu: Hello Ismail,       Thanks for your reply. I did look at the source code to load .stl models. I found that there are _vertices and _normal variables in the source code. That's why I'm asking if there is a way to access those parameters. Any idea or

Re: [osg-users] Dynamically generating smooth camera rides?

2009-05-26 Thread Ismail Pazarbasi
2009/5/25 Christian Buchner christian.buch...@gmail.com: Forgive my laziness - are there any utility classes within OSG that let the camera go on a smooth ride to a specific location and eyepoint vector from the current location?   I mean smooth in the sense of the camera accelerating and

Re: [osg-users] OSG_OpenCV Help

2009-05-18 Thread Ismail Pazarbasi
Hi Ugras, Did you try to run your code in single threaded mode? This could give you a hint whether problem is a race. It's difficult to guess what's going on, but did you try to lock mutex while you read data as well? This might effectively make your program serial during those phases (which

Re: [osg-users] OSG and QT integration problem

2009-05-13 Thread Ismail Pazarbasi
On Wed, May 13, 2009 at 9:02 AM, Максим Гаммер maxgam...@gmail.com wrote: Hi. There is a problem of my program and QT integration. Problem occurs when I'm trying to use OSG ModularEmitter for particle creation. In process of compilation I get the following: ... /usr/local/include/

Re: [osg-users] Makefile question

2009-05-13 Thread Ismail Pazarbasi
On Wed, May 13, 2009 at 11:25 PM, Wyatt Earp wyattbsearp1...@gmail.com wrote: I am writing my own make files for my osg app... when I link to GL, or GLUT, I use -lGL or -lGLUT... what is the equivalent for osg libraries?  Would it be something like -losgViewer for libosgViewer.so? W.E.

Re: [osg-users] Visual Studio Setup Woes

2009-05-12 Thread Ismail Pazarbasi
Hi Dwight, I don't know whether there is tuturial about CMake but those red lines indicate some variables that are required/suggested. If you are familiar with configure scripts on linux/unix, red lines are analogous to --with-PKG=path_to_dependency or --enable-FEATURE (if I recall correctly).

Re: [osg-users] isVertexBufferObjectSupported() ?

2009-05-05 Thread Ismail Pazarbasi
Ufuk, bool isVertexBufferObjectSupported() const { return _isVertexBufferObjectSupportResolved?_isVertexBufferObjectSupported:computeVertexBufferObjectSupported(); } If you have seen the code that checks whether extension is supported: bool State::computeVertexBufferObjectSupported() const {

Re: [osg-users] build problem on Mac OS/X 10.5.6

2009-04-26 Thread Ismail Pazarbasi
On Sun, Apr 26, 2009 at 6:09 PM, Stephan Huber ratzf...@digitalmind.de wrote: Hi, please don't hijack old threads for starting new threads. Start a new one instead. This will help people following and reading your post. It seems, that the inventor-framework is not universal build (ppc +

Re: [osg-users] OSG begginer question - osg crush on run-time

2009-04-19 Thread Ismail Pazarbasi
Hi Sh Ha, If I recall correctly, similar use case worked for me on Mac OS X, but crashed on Windows (Vista). I simply did: osg::ref_ptrosgViewer::Viewer spViewer = new osgViewer::Viewer; ... return spViewer-run(); I have no access to source code (I am on vacation). I think what you see could be

Re: [osg-users] OsgSwig on mac osx 10.5.6 (xcode 3.1)

2009-04-16 Thread Ismail Pazarbasi
Hi Massimo, I am not on my Mac right now, but I can quickly suggest you to add osg, osgText, osgIntrospection (and few more) frameworks to your executable to get you started as quick as possible. I may not recall all dependencies' names, as I am not on my development Mac; sorry! Adding frameworks

Re: [osg-users] OsgSwig on mac osx 10.5.6 (xcode 3.1)

2009-04-16 Thread Ismail Pazarbasi
Stefano massimodisa...@yahoo.it wrote: Ismail Pazarbasi wrote: Hi Massimo, I am not on my Mac right now, but I can quickly suggest you to add osg, osgText, osgIntrospection (and few more) frameworks to your executable to get you started as quick as possible. I tried to build osg2.4 using

Re: [osg-users] Turning the main viewer camera on and off (when taking high-res camera screenshots).

2009-04-15 Thread Ismail Pazarbasi
Jesper, 2 days ago, I was doing the same thing, same problem, but with composite viewer. Here is what I did... I create my screenshot camera while I create my main CompositeViewer and its children Viewers. When I create this screenshot viewer, I set its nodemask to 0 - by default, it won't

Re: [osg-users] Problem of points showing

2009-04-15 Thread Ismail Pazarbasi
memory. 2009/4/15 Lingyun Yu lingyun.yu...@gmail.com: Hi, Ismail, I don't understand how the expanding happen? I read all dataset into an array of P, then when it expands? and why? and what's old array? On Tue, Apr 14, 2009 at 2:27 PM, Ismail Pazarbasi pazarb...@gmail.com wrote: Hi Lingyun

Re: [osg-users] Problem of points showing

2009-04-15 Thread Ismail Pazarbasi
the expanding happen? I read all dataset into an array of P, then when it expands? and why? and what's old array? On Tue, Apr 14, 2009 at 2:27 PM, Ismail Pazarbasi pazarb...@gmail.com wrote: Hi Lingyun, std::bad_alloc is thrown when operator new cannot allocate memory, which indicates

Re: [osg-users] Problem of points showing

2009-04-15 Thread Ismail Pazarbasi
Hi Martin, ISO 14882:2003 (the C++03) standard doesn't clearly specify how containers must swap its contents. It's clearly specified in C++0x drafts. Most implementations simply exchange internal block (pointers) and capacity, if allocators are the same. Otherwise, each element will be copied.

Re: [osg-users] [build] Postbuild error with ot11-OpenThreads??

2009-04-14 Thread Ismail Pazarbasi
Hi John, could it be a permission problem? Can you see other files written into that folder? On Vista, one may need adminisrative priviliges to write into program files folder. You may try to run Visual C++ as Administrator. I am using Vista Business with VC9 on my secondary laptop as well, but

Re: [osg-users] Problem of points showing

2009-04-14 Thread Ismail Pazarbasi
Hi Lingyun, std::bad_alloc is thrown when operator new cannot allocate memory, which indicates there is not enough memory. You may reserve your array before hand, as Paul mentioned, but it may throw as well. This could reduce, if nothing, copy operations. It may also prevent exception, because

Re: [osg-users] Rotation of object

2009-04-12 Thread Ismail Pazarbasi
Hi Sergey, use osg::Quat to rotate your object. Trans-setAttitude(osg::Quat(osg::DegreesToRadians(rotation_degree), fX, fY, fZ)); where fX, fY and fZ indicates axis to rotate. Trans-setAttitude(osg::Quat(osg::DegreesToRadians(rotation_degree), 1.0, 0.0, 0.0)); will rotate object around X axis.

Re: [osg-users] Rotation of object

2009-04-12 Thread Ismail Pazarbasi
I meant the latter overload. I didn't have access to any osg stuff and no compiler. Sorry for overload confusion, but it's good that you found how to use osg::Quat. On Sun, Apr 12, 2009 at 9:59 PM, Sergey osgfo...@tevs.eu wrote: You have a little mistake: THIS :

Re: [osg-users] Build of svn head, OGR plugin issues

2009-04-10 Thread Ismail Pazarbasi
Hi Robert, although Apple doesn't sell PPC machines anymore, there are hardcore devs still using PPC. Mach-O binary can have all architectures you mentioned. Therefore, passing -arch i386 -arch x86_64 and so on should generate a binary that contains a Mach-O binary for all listed architecture.

Re: [osg-users] Light Manager

2009-04-09 Thread Ismail Pazarbasi
Sajjad, Although you refer to Brian's message, I would like to explain what he meant briefly. dynamic_castT allows casting both down and up in inheritance hierarchy. If object's dynamic type isn't Switch, then you cannot cast a Group pointer to Switch with dynamic cast. That is: osg::Group*

Re: [osg-users] plugin to read .jpg files

2009-04-09 Thread Ismail Pazarbasi
through the process of making the plug-in for OpenSceneGraph, or creating a new project to make osgdb_jpeg.dll. (I did try to open CMake for OpenSceneGraph project, but didn't know how to set JPEG lib) Thanks a bunch, Dat On Wed, Apr 8, 2009 at 7:35 PM, Ismail Pazarbasi pazarb...@gmail.com wrote

Re: [osg-users] plugin to read .jpg files

2009-04-08 Thread Ismail Pazarbasi
Hi Dat, check whether osgdb_jpeg library is present in osg's bin or plugins directory. If it is present, then ensure that it's accessible by your application (as a matter of fact, by your operating system's dynamic linker; good starting point could be copying osgdb_jpeg library into your