Re: [osg-users] [osgPlugins] How to add Animations stored in Fbx to another Fbx model

2013-06-18 Thread Sergey Polischuk
Hi You can do this trick only with animations applied to identical models: vertices, bones and transforms names\hierarchy etc. should be same in both models, just animation is different. You can't hotswap animation from different model. Cheers. 18.06.2013, 11:08, Sebastian Messerschmidt

Re: [osg-users] [osgPlugins] How to add Animations stored in Fbx to another Fbx model

2013-05-28 Thread Sergey Polischuk
void mergeAnimation(osg::Node* mainModel, osg::Node* mergeModel) { FindAnimationManagerVisitor famvMain; mainModel-accept(famvMain); osgAnimation::AnimationManagerBase* animationManagerMain = famvMain.getAnimationManager(); if (animationManagerMain == 0)

Re: [osg-users] [osgPlugins] How to add Animations stored in Fbx to another Fbx model

2013-05-27 Thread Sergey Polischuk
Hi idk, for me it worked out of the box :) Cheers. 27.05.2013, 11:32, Michael Borst mich...@jborst.de: Hi, if i do that, the programm shows me that it is playing the correct animation with every detail correct (Playtime, currently Playing, name etc) but i don't see anything, the model

Re: [osg-users] [OT] Is it legal to collect video card information?

2013-05-24 Thread Sergey Polischuk
Hi you can just give user option or warning about what info is collected Cheers. 24.05.2013, 16:28, "michael kapelko" korn...@gmail.com:Hi.Sorry for off-topic question, but I'm curious if it's legal to collect user video card information like GL_VENDOR, GL_MAX_TEXTURE_UNITS and such to create some

Re: [osg-users] osgParticle::ExplosionEffect: assistance needed

2013-05-16 Thread Sergey Polischuk
Hi, Mike 1) you can't load from QT resources via osg out of the box. You can write osgDB::ReadFileCallback (and register it via osgDB::Registry) which will open QFile from path specified, read data from it into stream and load object from that stream with correct osgDB plugins. 2) matrix

Re: [osg-users] [osgPlugins] How to add Animations stored in Fbx to another Fbx model

2013-05-05 Thread Sergey Polischuk
Hi if models are same besides animation, you can just grab osgAnimation::Animation pointer from animation manager of one model and register it in animation manager from another model 22.04.2013, 23:42, Michael Borst mich...@jborst.de: Hi, we bought severall Models in .fbx with Animations.

[osg-users] indexing model - loss of data

2013-04-25 Thread Sergey Polischuk
Hi all once i've wrote small utility to optimize models with rig geometry, which, among other things, apply INDEX_MESH, VERTEX_PRETRANSFORM, VERTEX_POSTTRANSFORM optimizations and remaps vertex influences of rig geometry to new vertex indices. Now it suddenly dont work any more. Problem is

Re: [osg-users] indexing model - loss of data

2013-04-25 Thread Sergey Polischuk
Glenn Waldron" gwald...@gmail.com:Sergey,I believe the IndexMeshVisitor attempts to detect and remove duplicate vertices. Could that be the reason? Glenn Waldron / @glennwaldronOn Thu, Apr 25, 2013 at 11:16 AM, Sergey Polischuk pol...@yandex.ru wrote:Hi all once i've wrote small utility to optim

Re: [osg-users] culling and vertex shaders still a problem

2013-04-23 Thread Sergey Polischuk
Hi if you dont need camera view matrix in shaders (i believe you need only projection matrix for your task): you can place this geode under matrix transform with reference frame set to ABSOLUTE_RF, and position it somewhere in front of camera with identity view matrix, this should solve

Re: [osg-users] osgParticle restart...

2013-04-04 Thread Sergey Polischuk
Hi Peter if i understand you correctly: there are interfaces to control some particle related objects in such a way (to be exact - all objects that inherited from ParticleProcessor - emitters and particle programs) all they have methods to get\set startTime, currentTime, endTime and resetTime,

Re: [osg-users] lightmap generated from lightcone geometry

2013-04-04 Thread Sergey Polischuk
Hi you can do this in a way similar to shadows for this you can use prebaked texture of light cone shape in section perpendicular to axis knowing cone angle and position you can set up transformation matrix to calculate texture coords to mentioned prebaked light spot texture (kind of

Re: [osg-users] Reflection cube map with shader

2013-03-27 Thread Sergey Polischuk
Hi environment-set(cubemap.get()); should be environment-set(int(unit)); Cheers 27.03.2013, 18:45, Andrea Martini martini.and...@gmail.com: Hi, i'm trying to apply a reflection effect on a sphere, using a cube map. I'm using as vertex shader dthe following : Code: #version 400

Re: [osg-users] Reflection cube map with shader

2013-03-27 Thread Sergey Polischuk
in vertex shader add line ReflectDir = (osg_ViewMatrixInverse * vec4(ReflectDir,0)).xyz; after ReflectDir = reflect(eyeDir, normal); 27.03.2013, 20:27, Andrea Martini martini.and...@gmail.com: Hi hybr(), thank you. Now it works! I have to change something to update the

Re: [osg-users] Animation control with AnimationPathCallback

2013-03-25 Thread Sergey Polischuk
Hi i think for fine-grained control it's better to write your own callback for controlling animation, and query interpolated matrices from animation path at desired position Cheers. 25.03.2013, 15:44, Joseph Sahexmeier sar...@gmail.com: Hi, I have loaded a model with animation frames on

Re: [osg-users] [osgPlugins] FBX only Black Texture shown

2013-03-25 Thread Sergey Polischuk
Hi it can be down to your osg build dont have tga plugin, or some materials that osg fbx plugin dont know how to interpret correctly. You can convert your model to .osg or .osgt and check if there are textures etc. IIRC current osg fbx plugin have support for diffuse, reflection, opacity,

Re: [osg-users] Notify OSG when OpenGL state gets modified externally (e.g. by SFML)

2013-03-25 Thread Sergey Polischuk
Hi have a look at osg::State interface, there are functions to tell osg that something was changed in gl state externally. Cheers. 25.03.2013, 15:28, Peter Klosowski klo...@gmail.com: Hi, I am working on a small application that uses SFML and OSG. Getting a simple viewer up and running

Re: [osg-users] Problem with uniform array

2013-03-19 Thread Sergey Polischuk
Hi try to declare array as Intensity[0] in uniform description like: osg::Uniform* arrayIntensity=new osg::Uniform(osg::Uniform::Type::FLOAT_VEC3,Intensity[0],2); it should work either way, but there've been some drivers problems with those on nvidia cards. Cheers. 19.03.2013,

Re: [osg-users] Texture coordinates on trianglestrips

2013-03-18 Thread Sergey Polischuk
Hi Looks like your geometry does not have any texture coordinates, and you not using texgen. TexMat just transforms texture coordinates, not generate them. Cheers. 18.03.2013, 12:04, "Elistain" solee.li...@gmail.com:Hi,I'm trying to texture a triangle strip based terrain by a tif image, I use the

Re: [osg-users] PRE_RENDER ignores depth buffer?

2013-03-11 Thread Sergey Polischuk
Hi i've used prerender cameras with depth texture attached without any problems. Cheers. 11.03.2013, 11:24, "Daniel Schmid" daniel.sch...@swiss-simtec.ch:Hi all I have a NESTED_RENDER camera that 3 RTTs plus a Depth texture. Works fine. Now I added a PRE_RENDER camera rendering part of geometry  

Re: [osg-users] Modern OpenGL (4.0+), GLSL and VBOs

2013-03-11 Thread Sergey Polischuk
teAliasing? It seems that otherwise OSG is trying to call glVertexAttribPointer with a raw pointer rather than a VBO offset, ultimately failing to render the object ('invalid framebuffer operation' and the object does not show up). Cheers,PeterOn Tue, Mar 5, 2013 at 9:55 AM, Sergey Polischuk pol...

Re: [osg-users] transparent geometry refuses to write to depth buffer

2013-03-11 Thread Sergey Polischuk
Hi if you are talking about fully transparent geometry (alpha = 0) - try to disable alpha test with setMode(GL_ALPHA_TEST, osg::StateAttribute::OFF | osg::StateAttribute::OVERRIDE) 11.03.2013, 19:19, "Daniel Schmid" daniel.sch...@swiss-simtec.ch:Lets put it this way round: my pre-render camera has

Re: [osg-users] How to set a node invisible but not its children?

2013-03-06 Thread Sergey Polischuk
Hi What you mean? afaik, any node which have childrens dont have any visible geometry itself, it's either group or transfrom of some sort, it just show it's childrens Cheers 06.03.2013, 14:42, Lv Qing donlvq...@msn.com: Hi, ... It sounds strange,but sometimes I want to use setNodemask(0)

Re: [osg-users] Modern OpenGL (4.0+), GLSL and VBOs

2013-03-05 Thread Sergey Polischuk
Hi you can use osgUtil::GLObjectsVisitor, it have option to enable vbos on drawables. Cheers. 05.03.2013, 04:07, "peter klosowski" klo...@gmail.com:Hi, In order to use modern shaders (without built-in OpenGL uniforms/attributes) it is necessary call State::setUseModelViewAndProjectionUniforms and

Re: [osg-users] [osgPPU] Rendering scene geometry in PPU

2013-03-04 Thread Sergey Polischuk
Hi I believe it's easier to do with postrender camera - disable clear color, attach input texture as color attachment, set view and projection matrices, add your cones with shaders and you are done. You can also draw result into another texture with prerender camera and mix together inside

Re: [osg-users] [osgPPU] osgPPU with GL3

2013-02-25 Thread Sergey Polischuk
Hi It is usable with fixed function pipeline available, this does not prevent you from using gl 3.2+ in any way i mean why would you disable fixed finction on pc app if it is still useful for a whole lot of stuff? (apart from mobile apps with gles) Wang Rui was working on alternative to osgPPU

Re: [osg-users] Geometry Merging Problem

2013-02-20 Thread Sergey Polischuk
Hi if you are using osgconv at any stage to convert your model, it implicitly invokes optimizer. you can control this with env var OSG_OPTIMIZER, to turn optimizer off you can pass OSG_OPTIMIZER=OFF Cheers. 19.02.2013, 20:38, "Adam Stambler" ada...@gmail.com:Hi All,I believe I am having trouble

Re: [osg-users] osgdepthpeeling or osgoit

2013-02-20 Thread Sergey Polischuk
Hi iirc you can use just integer uniform for any sampler, specific sampler type matters only inside glsl shader Cheers. 20.02.2013, 13:25, "Christian Buchner" christian.buch...@gmail.com: I am currently stuck with OSG 3.0.1 (latest stable release) not being able to provide an osg::Uniform

Re: [osg-users] osgdepthpeeling or osgoit

2013-02-20 Thread Sergey Polischuk
Hi i think this can be fixed with just sending resize even manually after viewer have been realized and event handlers set up:     osgGA::GUIEventAdapter * event = viewer.getEventQueue()-createEvent();        event-setEventType(osgGA::GUIEventAdapter::RESIZE);       

Re: [osg-users] Callback for resize events

2013-02-19 Thread Sergey Polischuk
Hi yes, if you write such event handler, which will filter out RESIZE events and change appropriate uniform value :) you can also get current viewport inside cull callback or may be in some other place Cheers. 19.02.2013, 02:41, Alexandre Valdetaro osgfo...@tevs.eu: Hi, I currently have a

Re: [osg-users] Low frame rate for one animated character.

2013-02-17 Thread Sergey Polischuk
Hi With software transform it's slow if you use heavy model with a lot of bones per vertex. Hardware transform is much faster but require limitation on maximum bones influencing single vertex You should try to reduce bones-per-vertex count to some reasonable value like 4-8, use indexed mesh to

Re: [osg-users] basic texturing

2013-02-14 Thread Sergey Polischuk
Hi for cube you have 8 vertices, and you provide only 4 tex coord values. Besides that, to do what you want, you need to duplicate vertices for different faces, as you need different tex coord values for same vertex position on different faces. Easy way is to not use indexed DrawElements for

Re: [osg-users] basic texturing

2013-02-14 Thread Sergey Polischuk
you can make it with redundant data, and give a try to osgUtil::Optimizer with INDEX_MESH | VERTEX_PRETRANSFORM | VERTEX_POSTTRANSFORM, it will index vertices and remove excess redundancies. But in general case you still need 3 sets of texture coordinates for each vertex of cube, but this

Re: [osg-users] Beginner's Help: Problem setting up a shadowed scene

2013-02-13 Thread Sergey Polischuk
Hi, just a guess: looks like with shadows - black parts are the ones which does not have diffuse texture assigned and shadow technique you are using might require it to work correctly. Cheers, Sergey -- Read this topic online here:

Re: [osg-users] Disabling shaders on LightPointNodes

2013-02-13 Thread Sergey Polischuk
Hi The thing is osg::StateAttributes can not be turned ON or OFF with flags like that, if you have attribute in stateset it always ON (if you look at source, StateSet even dont save ON-OFF flags for state attributes, only PROTECTED and OVERRIDE bits). You can control if they have any effect with

Re: [osg-users] Beginner's Help: Problem setting up a shadowed scene

2013-02-13 Thread Sergey Polischuk
[quote=Marten]Actually, the .mtl file of the model seems to have the diffuse value specified quite correctly, feel free to take a look a the model yourself, I have added the URL to it.[/quote] i'm talking about diffuse texture, not material color. -- Read this topic online

Re: [osg-users] Beginner's Help: Problem setting up a shadowed scene

2013-02-13 Thread Sergey Polischuk
Hi, i'm pretty sure that there are shadow technique implementations that work on models without textures, you should look shadows related osg examples and check related classes interfaces/implementations to get better grip on these things. Or wait for another answer :) Cheers, Sergey

Re: [osg-users] TriMeshVisitor possible bug?

2013-02-13 Thread Sergey Polischuk
 Hi Looks ok to meas it written in comment, code converts DrawArrays to DrawElements, and if primitive set is already indexed it is not DrawArrays any more, and there should not be duplicate vertices in first place (besides ones with same vertex position but different other vertex attributes like

Re: [osg-users] [forum] Self Illumination export from 3ds max 2010

2013-02-12 Thread Sergey Polischuk
Hi osg max exporter does export all kind of maps but it does not preserve semantics on most of them so they does not work correctly. IIRC diffuse, reflections and opacity maps are correctly exported. You should either write shader or change osg::TexEnvCombine on stateset in question so that

Re: [osg-users] Intersections with Scenes shown in pre-rendered textures

2013-02-12 Thread Sergey Polischuk
Hi i believe you can get normal in point of intersection with mirror with getWorldIntersectNormal() method of intersection, calculate reflected ray and start new intersection query with new ray Cheers. 11.02.2013, 22:16, Julian Schindler julian.schind...@dlr.de: Hi all, In my scene I am

Re: [osg-users] loading of a large number of files

2013-02-11 Thread Sergey Polischuk
Hi what size of models are we talking about? there are chances that you run out of memory in the process and getting std::bad_alloc Cheers. 11.02.2013, 17:30, lucie lemonnier lucielemonn...@hotmail.fr: Hi, I created an application with WPF and osgViewer which load multiples 3D models (up

Re: [osg-users] loading of a large number of files

2013-02-11 Thread Sergey Polischuk
Hi guessing is not very helpful in debugging application crashes debugger is your best friend in this situation :) Cheers. 11.02.2013, 18:11, lucie lemonnier lucielemonn...@hotmail.fr: Hi, My folder of 3D models contains 26.5 megabytes. it does not seem to be much though! What do you

Re: [osg-users] Higher render precision in render camera.

2013-02-10 Thread Sergey Polischuk
Hi you can get it drawn to texture in 32bit per channel, but what you see on screen is 8bit\channel max. Cheers. 11.02.2013, 05:00, Peterakos hay...@gmail.com: Hello. I use a shader to write the depth value of a model as color in screen using  gl_FragColor = vec4(depth, depth, depth , 1).

Re: [osg-users] Failure in casting to osg::AnimationPathCallback*

2013-02-07 Thread Sergey Polischuk
Hi I've one run into similar issue when was compiling some sample under linux, in my case it was solved by adding -rdynamic flag to gcc, i think there are some similar option to your compiler about exporting symbols. Cheers. 07.02.2013, 08:35, "Philip Lamb" p...@eden.net.nz:Hi all, I'm running

Re: [osg-users] How to Keep model color aven if shaders are applied

2013-01-30 Thread Sergey Polischuk
Hi material colors are available in gl_FrontMaterial struct in fragment shader there are vec4's gl_FrontMaterial.diffuse, .specular, .ambient, .emission, and float .shininess there are also material params premultiplied with lightsource params in gl_FrontLightProduct struct (.diffuse =

Re: [osg-users] Retrieve Wold matrix while animating

2013-01-30 Thread Sergey Polischuk
Hi you can create your own uniform and assign correct value each frame from correct camera or, if in cull callback, you can get current camera from cullvisitor and ask view matrix there. Cheers. 31.01.2013, 00:08, Peterakos hay...@gmail.com: Hello. Thank you for your answer, but there is a

Re: [osg-users] R: Multisampling

2013-01-29 Thread Sergey Polischuk
, once set, multisampling seems not to be controllable. Did I miss something? Does it depend on OSG? Or driver bug? Thanks, Gianluca -Messaggio originale- Da: osg-users-boun...@lists.openscenegraph.org [mailto:osg-users-boun...@lists.openscenegraph.org] Per conto di Sergey

Re: [osg-users] Multisampling

2013-01-28 Thread Sergey Polischuk
Hi, Filip you can create MSAA context and enable\disable multisampling at runtime with GL_MULTISAMPLE mode on camera or scene stateset. Note that with disabled multisampling you will get lower fps than with non-MSAA context. Cheers, Sergey. 28.01.2013, 20:24, Filip Arlet fili...@seznam.cz:

Re: [osg-users] position list

2013-01-25 Thread Sergey Polischuk
Hi you can add several drawables to billboard with different positions, and setPosition is there to change position of previously added drawable. Cheers. 25.01.2013, 13:30, DavidHornung horn...@googlemail.com: Hi, I just saw setPosition() from OSG Billboard, what is the _positionList for?

Re: [osg-users] Forcing OSG to create VBO

2013-01-24 Thread Sergey Polischuk
Hi There are osgUtil::GLObjectsVisitor which can do such thing with option COMPILE_DISPLAY_LISTS (it compiles vbo's too). You should traverse your tree with such visitor in a thread which have valid graphics context, i.e. inside cull callback. Cheers,Sergey.  24.01.2013, 14:02, "Carlos Reig Matut"

Re: [osg-users] osgFX::outline: unable to change outline color

2013-01-24 Thread Sergey Polischuk
Hi default osgFX implementation of mentioned effect seems to not use any shaders at all, and color applied through emissive color of material, so i think problem is somehere down in drivers. You can try different versions of them or rewrite outline effect to use some other way of coloring

Re: [osg-users] Retrieve Wold matrix while animating

2013-01-22 Thread Sergey Polischuk
Hi most straightforward way is to use gl_ModelViewMatrix * osg_ViewMatrixInverse Cheers. 22.01.2013, 13:16, Peterakos hay...@gmail.com: Hello. I try to create a multi pass algorithm and i am stuck. I use my own view and projection matrix for an absoluted positioned camera. But i cant

Re: [osg-users] how to keep the camera from being below the terrain?

2013-01-14 Thread Sergey Polischuk
Hi there is no collision detection in osg. You can use intersectors in osgUtil and trace rays from camera downwards to check distance from ground, or use some physics engine to get proper collision detection. Cheers. 13.01.2013, 20:51, "Yansi Yao" yaoyans...@yahoo.com.cn:Hi all,I'm going to attach

Re: [osg-users] 回复: how to keep the camera from being below the terrain?

2013-01-14 Thread Sergey Polischuk
on between the camera frustum and the terrain. So, is there any way to detect the intersection between a bounding sphere(or box) and the terrain in OSG?  Cheersyaoyansi 发件人: Sergey Polischuk pol...@yandex.ru 收件人: OpenSceneGraph Users osg-users@lists.openscenegraph.org 发送日期: 2013年1月14日, 星期一, 4:34 下午 主题: Re:

Re: [osg-users] How to get node rotation in world coordinates?

2013-01-11 Thread Sergey Polischuk
Hi attitude is osg::Quat, and it does not have routines to transform it with matrix. You can use something like this: osg::Matrix world(osg::computeLocalToWorld(node-getParentalNodePaths()[0]));//world.setTrans(osg::Vec3()); - not sure if this makes any

Re: [osg-users] mapping to video koordinate system

2013-01-11 Thread Sergey Polischuk
Hi best thing is to get real camera parameters f.e. calibrating it with opencv routines, so you can built correct projection matrix. other than that all you can is just guessing and trying different projections to see which will fit best. Cheers. 07.01.2013, 18:51, DavidHornung

Re: [osg-users] Loading an osgb file from a statically linked application

2013-01-09 Thread Sergey Polischuk
Hi just in case someone stuck with similar problem - i've got same with ComputeBoundingBoxCallback's, i believe (either osg fbx plugin added those while reading model, or they are created in some osgAnimation classes). dont know if there are some way of solving this with use of similar macro,

Re: [osg-users] Coursera Classes Coming Up!

2013-01-04 Thread Sergey Polischuk
Hi there are great courses, but dont overestimate your time and capability, some courses are quite time consuming... last time i simultaneously started two courses with four weeks delay, and it was hard to catch up between work and stuff. 02.01.2013, 20:49, Jeremy Moles cubic...@gmail.com:

Re: [osg-users] Texture internal and source format questions

2012-12-31 Thread Sergey Polischuk
Hi kind of late response here :) that's just how opengl texture works in order to use texture, you need need to allocate memory storage for it with glTexImage2D call, and for this call you should provide internal format(GL_DEPTH_COMPONENT16), format(GL_DEPTH_COMPONENT), and type

Re: [osg-users] Render multiple osgText nodes with the same drawcall

2012-12-28 Thread Sergey Polischuk
Hi my suggestion is not about text, but anyway, if your models contain tristripped geometry, they issue single draw call per primitiveSet (mean for each triangle strip) and they usually not so lenthy at all, about 7-10 vertices on average. With display lists this dont matter, but on gles it can

Re: [osg-users] osgAnimation

2012-12-28 Thread Sergey Polischuk
Hi iirc osgAnimation animation is not get started by default when viewer starts, you should start it in code. You can use osganimationviewer binary from osg examples or write your own utility for your purpose. Also osg and ive file formats lacks some support of osgAnimation, try using osgb or

Re: [osg-users] What can I do to improve rendering performance for a bunch of billboarded nodes?

2012-12-28 Thread Sergey Polischuk
Hi you can use point sprites for this purpose instead of billboards\autotransforms, it should be much faster as you need only one drawable per single geometry type(triangles, squares, ngons, etc). you can shape them either in fragment shader based on point coords, or apply small texture. Cheers. 

Re: [osg-users] [forum] Understanding osg Image packing

2012-12-27 Thread Sergey Polischuk
Hi what pixel format and type you have passed to osg::Image::computeRowWidthInBytes(...) call? Cheers, Sergey. 26.12.2012, 21:48, Claus Steuer claus...@googlemail.com: Hi, i try to understand the packing parameter of osg::Image::allocateImage. My current understanding is that packing

Re: [osg-users] osgFX::outline: unable to change outline color

2012-12-27 Thread Sergey Polischuk
Hi If you are using shaders in your implementation, make sure you declared shader version with #version directive and check compilation log on warnings Cheers. 26.12.2012, 22:02, Mike Metcalf metcalfnos...@mac.com: We've been attempting to implement an osgFX::outline node for highlighting

Re: [osg-users] Projective multitexturing save/export

2012-12-27 Thread Sergey Polischuk
Hi how would you include glsl shaders in 3ds file, for example? model formats support some limited set of features, and not all of those supported by osg writer plugins. 26.12.2012, 21:24, Mateo Gasparovic mateo.gasparo...@gmail.com: Hi, I've made projecting textures on the STL model. To

Re: [osg-users] How can I call a vector method on a generic array type?

2012-12-27 Thread Sergey Polischuk
Hi if you have only osg::Array pointer then all you can get directly is array size : array-getNumElements()as for others - you can get to them only with exact type (which you can get computed with help of array-getDataType() and array-getType() return values) Cheers  28.12.2012, 08:59, "Preet"

Re: [osg-users] projection matrix calculating problem

2012-12-22 Thread Sergey Polischuk
Hi You can set projection matrix directly with camera-setProjectionMatrix(...)Also there are osg::Projection, which is a node modifying projection matrix for subgraph under it.Also note, that osg by default calculates near and far projection values by itself using bounding volumes (check

Re: [osg-users] Model Matrix in Vertex Shader

2012-12-21 Thread Sergey Polischuk
Hi this is correct, camera position is osg_ViewMatrixInverse[3].xyz Cheers. 21.12.2012, 17:25, Ethan Fahy ethanf...@gmail.com: I looked around the web to try to figure out how to also get the camera XYZ in world space.  According to sources I should be able to get the camera world

Re: [osg-users] Model Matrix in Vertex Shader

2012-12-20 Thread Sergey Polischuk
Hi Not sure if it is still true, but last time i used this stuff with stereo setups (not sure but it can hold for any offset-based slave cameras setup) osg_ViewMatrix and it's inverse was containing main camera view (and inverse) matrix and was same for both eyes. Cheers,Sergey. 20.12.2012, 00:12,

Re: [osg-users] RigTransformHardware skinning on DAE models

2012-12-12 Thread Sergey Polischuk
Hi default implementation uses vertex attribs from slot 11 upwards for bone weights, and most implementations have GL_MAX_VERTEX_ATTRIBS = 16, so with more than 4 attributes you are probably hitting hardware limits on vertex attributes count, i think gl error comes from this too. Cheers.

Re: [osg-users] Rendering sets of objects in layers/passes

2012-12-12 Thread Sergey Polischuk
Hi using separate renderbin ID for each set of objects should do exactly what you want, as they should be sorted by depth inside each set, and sets rendered in order of renderbin ID's. How you assigning render bin ids? You may need to set RenderBinMode to USE_RENDERBIN_DETAILS or

Re: [osg-users] Skinning with osg / osgAnimation

2012-12-12 Thread Sergey Polischuk
Hi fbx plugin support skinning animation. Cheers. 12.12.2012, 21:05, Janna Terde brja...@gmail.com: Hi, I am looking into doing hardware skinning (such as animating some cables for a example). I will provide transformation matrices for bones. So far I've found that osgAnimation provides

Re: [osg-users] questions on simple skeletal animation for crowd simulation

2012-11-23 Thread Sergey Polischuk
Hi You can use any .fbx model with skinned character, as osg can read those just fine. I think you should be able to find some of those in the web. Cheers. 22.11.2012, 03:41, "Bruno Fanini" phoeni...@gmail.com:Hello Jan and Christian,Thanks for your hintsThe simulation has to run on medium-sized

Re: [osg-users] Problem with high detailed model with skinning.

2012-11-22 Thread Sergey Polischuk
Hi, Peterakos If you load model from fbx format, osg optimizer can screw up some things, dont use optimizations that change drawable arrays, like INDEX_MESH, VERTEX_PRETRANSFORM, VERTEX_POSTTRANSFORM, TRISTRIP_GEOMETRY, as it will broke vertex attribute binding to bones etc. Try to open your

Re: [osg-users] Streaming world and integer limits

2012-10-30 Thread Sergey Polischuk
Hi Where did you found anything about node positions being stored as integers in OSG? Nodes are positioned with osg::Transform derived classes which use floating point (single or double precision, depending on build configuration) matrices\vectors\quaternions for transformations. Cheers.

Re: [osg-users] [osgPlugins] DDS Texture vanish with LINEAR_MIPMAP_LINEAR

2012-10-30 Thread Sergey Polischuk
Hi it seems like osg dds plugin cant (correctly) read your mipmaps from dds file. You can use file without mipmaps or try to dive in and find exact reason for this behaviour. Cheers. 30.10.2012, 14:19, Tim Rambau tim.ram...@dlr.de: Hi, I have a terrain model with 1024x1024 DXT1 textures.

Re: [osg-users] dead locking problem of osgDB::DatabasePager::DatabaseThread under QT/linux

2012-10-29 Thread Sergey Polischuk
Hi at first try to update osg, may be you find this problem solved. Cheers. 27.10.2012, 17:39, Lv Qing donlvq...@msn.com: Hi, My osg2.9.11 app is working under QT/Linux.Occasionally it suffers a dead lock as follows:    #0 in _kernel_vsyscall()    #1 in

Re: [osg-users] custom vertex attribut, using BIND_OVERALL

2012-10-24 Thread Sergey Polischuk
Hi wouldnt it be better to use uniform in this case? Cheers. 24.10.2012, 13:28, "Daniel Schmid" daniel.sch...@swiss-simtec.ch:Hi all I want to pass a custom vertex attribute (lets say a material code) to my vertex shader. For the moment I use BIND_PER_VERTEX: [code]int l_SMC = 1027; // some

Re: [osg-users] custom vertex attribut, using BIND_OVERALL

2012-10-24 Thread Sergey Polischuk
Hi As you say, setting Uniforms requires a state change, while with an attribute the rendering is done at the GPU completely. it is kind of same both ways... here you need glUniform* call, there you need to bind vertex attrib and call glVertexAttribPointer* and rendering is done at the GPU

Re: [osg-users] Help: does the time difference between two successive update callback of one osg::node imply FPS?

2012-10-16 Thread Sergey Polischuk
Hi one node callback can be called multiple times per frame if node is shared in several graph paths (and iirc event callbacks can be called once per event happened between frames). If you just need to know framerate - there are osgViewer::StatsHandler. Other than that - you should track frame

Re: [osg-users] FBX 2012.1?

2012-10-16 Thread Sergey Polischuk
Hi you can just change 2012.1 version check to 2012.2 in osg fbx plugin code, it will compile just fine, and 2012.2 sdk is googlable Cheers. 16.10.2012, 04:14, Brad Colbert bcolb...@rscusa.com: Hi Folks, Does anyone know of a source for getting the FBX 2012.1+ SDK?  Autodesk has released

Re: [osg-users] How to change the text with osg::Text?

2012-10-15 Thread Sergey Polischuk
Hi call textLabel-setText(strTmp); instead of update() Cheers. 15.10.2012, 13:42, Eungil slwa...@naver.com: Hi, I am a very new, and i got a problem with using osg::Text. I set the text like this blow. osg::Geode* textGeode = new osg::Geode(); osgText::Text* textLabel = new

[osg-users] fbx plugin, option to read animation channels as quats instead of euler angles

2012-10-12 Thread Sergey Polischuk
Hello there I want to add read option to use quaternions for stacked rotation elements and animation tracks instead of euler angles on fbx import, as they often works better and cut down model size (and i have couple of models which just dont work with euler angles for whatever reason, after

Re: [osg-users] sampler shader texture

2012-10-12 Thread Sergey Polischuk
Hi use setTextureMode(id, GL_TEXTURE_2D, osg::StateAttribute::OFF) on your group stateset, with id set to texture unit you binded your texture to. It prevents fixed function from using your texture, and dont have any effect on rendering with shaders. Cheers. 12.10.2012, 16:20, Filip Arlet

Re: [osg-users] multipass transparency

2012-10-10 Thread Sergey Polischuk
Hi For such complex transparent models you need some proper order-independent transparency algorithm Cheers. 09.10.2012, 23:22, Tina Guo guoyiting1...@gmail.com: Hi, Thanks for reply. Now the code is like virtual void define_passes() { osg::ref_ptrosg::StateSet ss = new

Re: [osg-users] Texture coords in osgmultiplerenderingtargets.

2012-10-10 Thread Sergey Polischuk
Hi most likely, it uses a texture rectangle instead of texture2d, it uses texture coords in pixels. Cheers. 10.10.2012, 16:46, "Peterakos" hay...@gmail.com:Hello.in the example  osgmultiplerenderingtargets, why are the texture coordinates initialized as:0,0tex_width, 

Re: [osg-users] Difference between osgFX and osgPPU

2012-10-09 Thread Sergey Polischuk
Hi They are completely different. osgFX have support for multipass rendering of geometry, osgPPU purpuse is to do postprocessing on camera output. Cheers.08.10.2012, 22:01, "Peterakos" hay...@gmail.com:Hello.Is there any difference between these 2 or are they different implementations for the same

Re: [osg-users] Memory issues when using uniform shader variables on Intel HD graphics

2012-10-09 Thread Sergey Polischuk
Hi What exactly makes memory usage increase? What if you attach shader without uniform, or without adding uniform to stateset? Try to add #version 110 directive as first line of your shaders, does it make any difference? I think you'd better send bugreport to intel, best if you can reproduce

Re: [osg-users] multipass transparency

2012-10-09 Thread Sergey Polischuk
Hi If you need to blend all visible layers - try to change order of passes, and set colormask to all false's (so first will be only color, second only depth). If you dont need depth from transparent geometry - you can get by with only first pass. If you need only closest single layer - you

Re: [osg-users] Normalmap with osgPPU

2012-10-09 Thread Sergey Polischuk
Hi osgppu drawing screen aligned quad with each pass, using texture data you've provided as input. It does not have access to your scene in any way except of mentioned textures.vertex shader process vertices of this quadnormals you are getting is normals of this quad (so they are all the same, and

Re: [osg-users] Help:why does renderbin affect the display of textures ?

2012-10-08 Thread Sergey Polischuk
Hi Seems like you are messing with opengl state, and osg dont know about it. You should either: a) when you draw something with pure gl - after you finished, return all state you modified to values being before you started drawing b) use osg::State interface members to let osg know what state

Re: [osg-users] How can I get the viewer's camera to 'ignore' a node's geometry?

2012-10-06 Thread Sergey Polischuk
Hi I believe this caused by small features culling (which is culling away objects which cover less space on screen than some pixel threshold). With compute near far enabled - when camera far enough objects on earth surface gets culled away, and as there are no objects on earth surface get's

Re: [osg-users] How can I get the viewer's camera to 'ignore' a node's geometry?

2012-10-05 Thread Sergey Polischuk
Hi You can set ComputeBoundingBoxCallback on a geometry to specify whatever bounds you want. In your case to ignore earth geometry bound you can set its bound to uninitialized bounding box, and it will not make any difference to near\far calculations. Note that this thing completely disable

Re: [osg-users] osg::PPU texel 0,0 in depthbuffer is wrong

2012-10-05 Thread Sergey Polischuk
Hi Check texture wrap mode, it can be set to clamp_to_border, with some border color. Does it work okay when sampling other texture areas? Dont know if it can cause problem, but texture(...) call returns vec4, and you are sampling single component texture. I believe it returns (depth, 0, 0, 1),

Re: [osg-users] How can I get the viewer's camera to 'ignore' a node's geometry?

2012-10-05 Thread Sergey Polischuk
ane closer and give you the z-buffer resolution you need in order to visualize surface features. In addition, you can decrease the Camera's near/far ratio; this will give you a little more near clip space if you still need it.Glenn Waldron / @glennwaldron On Fri, Oct 5, 2012 at 7:28 AM, Sergey Pol

Re: [osg-users] osg::PPU , Texture unit associated with depth buffer

2012-10-04 Thread Sergey Polischuk
Hi There are not only explicit texture bindings, but also implicit ones, which passed from units parents. If your unit added to other ppu units, it uses theirs output as input textures in order. There are also interfaces to bind other unit output to uniform IIRC setInputToUniform call Cheers.

Re: [osg-users] glslDevil

2012-10-04 Thread Sergey Polischuk
Hi. It used to be great tool at a time, but now is quite outdated, it would be great to see this project being developed further, as IIRC there are no crossplatform analogs with same functionality. Wish you best luck. Does anyone here on the list know any of the folks involved in the glslDevil

Re: [osg-users] osgPPU::Processor and other root's children traversing order

2012-10-03 Thread Sergey Polischuk
Hiiirc ppu stuff does it things at a renderbin 100. Cheers. 03.10.2012, 23:42, "Peterakos" hay...@gmail.com:Hello.I am working on osgPPU but there are some things i haven't completely understood yet.I add 2 children in root's group.A cow model and the osgPPU::Processor.In processor i have added 1

Re: [osg-users] Fixed size

2012-10-02 Thread Sergey Polischuk
Hi, Anders  Take a look at osg::Billboard and\or osg::AutoTransform Cheers,Sergey. 02.10.2012, 11:34, "Anders Backman" ande...@cs.umu.se:Hi all.Anyone got a reference to code/example illustrating how to get an object being rendered to the screen with a fixed size, no matter the distance to the

Re: [osg-users] Mipmapping for downsampling

2012-09-28 Thread Sergey Polischuk
Hi looks like you was hitting NaN's somewhere, as they propagate in such fashion. Cheers. 28.09.2012, 18:11, Kenzo Lespagnol kenzo.lespag...@cm-labs.com: Hi Sebastian, Ok, I've displayed the different mipmap in my application and I realized that a black square is propagated along the

Re: [osg-users] FBO and mipmaps

2012-09-27 Thread Sergey Polischuk
Hi in camera interfaces there are attach method which have parameter to specify either to generate mipmaps or not for texture rendertarget attachmant, it does not behave correctly? Cheers, Sergey. 27.09.2012, 01:55, Kenzo Lespagnol kenzo.lespag...@cm-labs.com: Hi Aurelien, I'm also using

  1   2   3   4   5   >