video and sound pins by type rather than searching for them by name
since the names of the pins can change based on what kind of file you
are opening. This also removes the need for an explicit check to see
if the file is a .wmv file.
Also changes to the directshow plugin's CMakeLists.txt.
It is not necessary to link against d3dx9 to build the plugin.
"
Now we can use ffmpeg to render webcam video (using the vfwcap device) under Windows:
osgmovie 0 -e ffmpeg -O "format=vfwcap frame_rate=25"
The number 0 just indicates a default device number in ffmpeg.
I think this can work under Linux, too, and should be a bit better than comparing the filename with a '/dev/' string. Just type:
./osgmovie /dev/yourcam -e ffmpeg -O "format=video4linux2 frame_rate=30 size=320x240""
The user calls statsHandler->addUserStatsLine() providing:
- the label they want for that line in the graph
- the text and bar colors they want in the graph
- the stats names they want queried (one for time taken, one for begin and one for end time) and a few settings for how these will be displayed.
Then all they have to do is call viewer->getViewerStats()->setAttribute(framenumber, name, value) for their three attributes each frame and they'll have their stats in the graph.
They can also give only a time taken attribute (or some other numerical value they want printed, which can be averaged or not), or only begin+end attributes, and the graph will accordingly display only the (average or not) numerical value or only the bars.
Along the way I cleaned up the existing code a bit:
* Each time the setUpScene() or createCameraTimeStats() methods added a line to the graph, they did pretty much the same thing, so I moved that into a separate method called createTimeStatsLine() which is called by setUpScene() and createCameraTimeStats().
* I moved the font, characterSize, startBlocks and leftPos variables to member variables, since they were being passed around everywhere but were set only once at the beginning.
* The geode on which stats lines are added is also kept in a member variable, and createCameraTimeStats() adds the per-camera lines to this geode instead of returning a new Group with a new Geode. This further reduces the number of variables the createCameraTimeStats() method needs as input.
"
In osg::isGLExtensionOrVersionSupported in src/osg/GLExtensions.cpp when
using indirect X11 rendering,
glGetIntegerv( GL_NUM_EXTENSIONS, &numExt );
is leaving numExt uninitilized causing the following glGetStringi to
return NULL when the extension number isn't present. Passing NULL to
std::string() then crashes. This is with the following nVidia driver.
OpenGL version string: 3.3.0 NVIDIA 256.35
I went ahead and initialized some of the other variables before
glGetInitegerv in other files as well. I don't know for sure
which ones can fail, so I don't know which are strictly required.
"
In the attached file (src/osgWrappers/deprecated-dotosg/osgParticle/IO_Particle.cpp) I have added a check for the existence of the drawable before writing it to the file.
"
- using m.getPerspective( fovy, tmp, tmp, tmp ) to get only FOV does not work.
The reason is that getPerspective is taking tmp as reference - thus all the three variables points to the same memory location. Then, zNear (third parameter) is used inside the method, while zNear content was spoiled by zFar that was written to the same place, resulting in fovy set to nan. I consider that it is the right of programmers to use 3 times tmp as parameter and I fixed the code in the method. I have done the same for getFrustum and getLookAt.
- I fixed makeFrustum to accept infinite zFar. (Some graphics techniques like shadow volumes require placing zFar to infinity to avoid visual artifacts.)"
Note from Robert Osfield, change the local near & far variable names to temp_near and temp_far MS Visual Studio has a record of using near and far names.
This problem caused because osgManipulator::Dragger uses matrices of top camera instead last
absolute Camera in NodePath.
I attached modified osgManipulator/Dragger.cpp file, where added code for finding last absolute
camera. With this changes draggers works in HUD.
Example for demonstrate this problem you can find in osg-users list [1].
Mikhail.
[1] http://thread.gmane.org/gmane.comp.graphics.openscenegraph.user/62636
"
attached. The problem was that the output files were not properly
setting the debug/release libs due to this cmake bug. What occurred was
the release lib was set in all configurations."
to download the texture object to graphics card.
Calling IncrementalCompileOperation::assignForceTextureDownloadGeometry() assigns a geometry
to the job.