Commit Graph

2322 Commits

Author SHA1 Message Date
Robert Osfield
6dbb6dc0ae From Gino van den Bergen, "AFAICS, OSG's OBJ loader correctly handles backslash-newlines that are used for continuation of lines. However, I recently ran into a problem with OBJs that where converted from another source using Right Hemisphere Deep Exploration. In these OBJs newlines are escaped in the following way:
f  15939/9999/16177 15941/10000/16178 15940/10001/16179\
15938/10002/16180

In the OBJ loader the newline would be interpreted as follows

f  15939/9999/16177 15941/10000/16178 15940/10001/1617915938/10002/16180

However, for correctly loading the model it should be interpreted as

f  15939/9999/16177 15941/10000/16178 15940/10001/16179 15938/10002/16180

Thus, the escaped newline should be interpreted as a space.

I tried to lookup what the correct interpretation for a backslash-newline was in the OBJ spec but did not find anything useful. Nevertheless, my suggestion would be to adopt replacing the escaped newline by a space in order to avoid problems as stated above. I cannot imagine a meaningful usage of a newline within a numerical literal so I do not foresee cases where replacing a backslash-newline by a space would be harmful. The fixed obj.cpp is zipped and attached to this mail."
2009-06-19 14:14:26 +00:00
Robert Osfield
85bb6b327d From Wojciech Lewandowski, "Here are my changes:
- osg::Texture sets GL_MAX_TEXTURE_LEVEL if image uses fewer mipmaps than
number from computeNumberOfMipmaps (and it works!)
- DDS fix to read only available mipmaps
- DDS fixes to read / save 3D textures with mipmaps ( packing == 1 is
required)
- Few cosmetic DDS modifications and comments to make code cleaner (I hope)

Added _isTextureMaxLevelSupported variable to texture extensions. It
could be removed if OSG requires OpenGL version 1.2 by default.

Added simple ComputeImageSizeInBytes function in DDSReaderWrites. In
my opinion it would be better if similar static method was defined for
Image. Then it could be used not only in DDS but other modules as well (I
noticed that Texture/Texture2D do similar computations).

Also attached is an example test.osg model with DDS without last mipmaps to
demonstrate the problem. When loaded into Viewer with current code and moved
far away, so that cube occupies 4 pixels, cube becomes red due to the issue
I described in earlier post. When you patch DDS reader writer with attched
code but no osg::Texture yet, cube becomes blank (at least on my
Windows/NVidia)  When you also merge osg::Texture patch cube will look right
and mipmaps will be correct."
2009-06-19 11:55:52 +00:00
Robert Osfield
ad8f2d8974 Changed build OSG_USE_REF_PTR_IMPLICIT_OUTPUT_CONVERSION to ON and then fixed all the resulting build errors. 2009-06-17 10:39:39 +00:00
Robert Osfield
4845fe23ae From Laurens Voerman, "there seems to be a bug in the proxynode writer introduced in svn rev 10330. It craches on a null pointer for options (on my windows system).
Fixed version of the file "src\osgPlugins\osg\ProxyNode.cpp" attached, based on svn rev 10332."
2009-06-12 09:57:45 +00:00
Robert Osfield
fac2ffecb3 From Roger James and Robert Osfield, clean up of COLLADA CMake support 2009-06-12 09:41:10 +00:00
Robert Osfield
e5a436b131 From Emmanuel Roche, "I've updated the CURL plugin to support the CURL_CONNECTTIMEOUT and CURL_TIMEOUT options.
Those two additional options can now be set using the Options::setOptionsString() function (just like the already existing OSG_CURL_PROXY & OSG_CURL_PROXYPORT options).

This is a convient solution to limit the freezing effect one may face in case the targeted server is down or too slow.

I successfully compiled and used this updated version on Windows in my application.

And by default those settings are not set (so no change in the behavior if you don't need them).
"
2009-06-10 09:24:12 +00:00
Robert Osfield
150c2e5fa1 From Gustav Happalahti, fixed filename usage 2009-06-09 08:43:13 +00:00
Robert Osfield
3171be0ff7 From Gustav Haapalahti and Robert Osfield,
First Submission email from Gustav:
"This submission adds a --cache option to osgconv and osgviewer that enables setObjectCacheHint(osgDB::Options::CACHE_ALL); It greatly reduces memory usage when a .osg file has lots of external references with ProxyNode:s that points to the same file.

Options are also added to the osg plugin. The code was already mostly implemented but there was no way to change the options.
includeExternalReferences
writeExternalReferenceFiles
A counter is added to keep track if an external file has already been written down to avoid writing the same file over and over again. If it has already been written once then it is not written again.
The counter is added to the Output class in osgDB.
"

Second Submission email from Gustav:
"This is a continuation to my previous submission.
I noticed that the same problem that I fixed in ProxyNode.cpp for the osg plugin (external files being written over and over again) also existed in the ive plugin. I attached a submission where the ive plugin remembers which external files that have already been written and do not write them again."


Changes to the above done by Robert Osfield,

    changed command line parameter to --enable-object-cache
    changed set/get methods in osgDB::Output and ive/DataOutputStream.cpp to be s/getExternalFileWritten(const std::string&)
    cleaned up set up of osgDB::Options.
2009-06-08 16:50:50 +00:00
Robert Osfield
e1b7de4b3d Martin Beckett, "Here's a first attempt at a DXF writer plugin
At the moment it outputs DXF for whatever geometry is contained in the node it would be nice to draw the model as it is rendered (points/lines/surface)

If people could also test against other apps that need to read DXF, the format is a bit of a black art and not all importers support all features so it might need some options to tweak the output.

It has some rather clever colour lookup stuff to match real colours against the limited DXF palette. I cracked the code of the Autocad indexed colours!"
2009-06-08 14:06:58 +00:00
Robert Osfield
3ec6c6a4d9 Addded .ive and .osg support for new GL_EXT_blend_equation_separate properties in osg::BlendEquation 2009-06-08 13:47:25 +00:00
Robert Osfield
0fe8084499 From Johan Nouvel, fix to handling of transparent textured objects.
Tweak from Robert Osfield, commented out disabling of depth write as this is not appropriate by default.
2009-06-08 09:47:27 +00:00
Robert Osfield
40155d59b4 Implemented updating of revision files as new data is writing to the FileCache 2009-06-04 14:07:12 +00:00
Robert Osfield
1f878303b4 Implemented DatabasePath in DatabaseBase revision classes 2009-06-02 16:54:34 +00:00
Robert Osfield
378ceebf84 From Emmanuel Roche, "I'm joining an updated version of the file daeWritter.cpp and daeWriter.h for the collada plugin compatible with the usage of double precision BoundingSphere & BoundingBox. The only change is the addition of the template specialization for osg::Vec3d object (until now only the specialization for osg::Vec3 was defined, I replaced that with osg::Vec3f to be more "precise")." 2009-06-01 11:07:07 +00:00
Robert Osfield
986fc05ac1 Added revisions plugin in support of paged database revisions. 2009-05-29 18:24:47 +00:00
Robert Osfield
2c9b4834af Fixed warning 2009-05-28 16:46:11 +00:00
Robert Osfield
07cf3ecd11 From Gregory Jaegy and Robert Osfield, added support for static linking of OpenFlight plugin 2009-05-28 13:29:20 +00:00
Robert Osfield
8e2b2031e2 From Neil Hughes, "Two changes here...
1. I've implemented an option controlled route by which users can still access the old method of extracting the zip content to the local filesystem. This is in response to Ulrich's comments about zip files encorporating files other than those that OSG knows about, but which an application may require.

To access this the user makes the following call on their options object that they pass to the reader. Without it, the plugin will extract by default to memory.

local_opt->setPluginStrData("zipextract","filesystem");


2. The second change is that I've moved the declaration of one of the variables to within the numitems loop so that if loading of a specific file within the zip fails, subsequent files still load correctly. This was the issue that Ulrich raised."
2009-05-28 12:25:35 +00:00
Robert Osfield
885a7893b8 From Jan Ciger, "I am attaching the updated VRML plugin, as promised. This version works
with OpenVRML 0.17.12 and Boost 1.38. Other versions may work too, but I
didn't test that."
2009-05-26 14:22:56 +00:00
Robert Osfield
e24dad3b71 From Ulrich Hertlein, "please find a patch for the DirectX loader to use std::istreams. This will make it usable with the zip plugin." 2009-05-26 11:00:26 +00:00
Robert Osfield
5944ddf255 From Wojciech Lewandowski, "Two fixes for LUMINANCE and ALPHA_LUMINACE pixel formats written into DDS file. Component masks were incorrect. I tested results with ultimate DDS compatibitlity tester ie Microsoft DirectX Texture tool ;-). I have also added comment with warning about possible problems when writing other than 8 bit component pixel formats.
"
2009-05-25 11:12:38 +00:00
Robert Osfield
27ae00630d Added a default value to avoid warning 2009-05-21 08:37:04 +00:00
Robert Osfield
9db74b8623 Fixed warnings 2009-05-20 12:14:45 +00:00
Robert Osfield
86479b0a73 Fixed warnings 2009-05-20 12:06:57 +00:00
Robert Osfield
ef14ed46f4 From Stephan Huber, replaced #include <malloc.h> with #include <stdlib.h> to fix build under OSX 2009-05-19 10:42:49 +00:00
Robert Osfield
37e93880e9 From Neil Hughes, intergrated support for uncompressing zip files in memory and from istreams (enabling reading from http). 2009-05-19 09:26:22 +00:00
Robert Osfield
eab39329c5 From Roland Smeenk, "Attached you will find some changes to the dae plugin to improve light support.
-Changed the addition of lights to add the lightsource directly into the scenegraph (instead of below a switch node)
-All added lights are enabled in the root stateset and replace the head- or skylight.
 (if no lights are available the head- or skylight will remain active)
-Ambient in osg::LightModel is zeroed out. All ambient now comes from separate ambient only light sources.
-Lights can now be written properly
-Replaced strings by constants defined in the Collada DOM"
2009-05-18 15:21:57 +00:00
Robert Osfield
545c52d4bb From Jean-Sebastien Guay, build fixes form Windows 2009-05-15 15:49:10 +00:00
Robert Osfield
ea7721d542 Added checks against libcurl version to decide what features are used or not 2009-05-15 15:10:59 +00:00
Robert Osfield
e94f874e54 Removed debugging code block 2009-05-15 12:31:23 +00:00
Robert Osfield
5432430fa6 Added setting of full filename to options as "filename" entry. 2009-05-14 16:06:34 +00:00
Robert Osfield
2dad77a102 Replaced tabs with spaces 2009-05-14 13:30:25 +00:00
Robert Osfield
fcfb8468cf Changed tabs to spaces 2009-05-14 13:16:05 +00:00
Robert Osfield
af7e47a79b Changed debug message to INFO notication level 2009-05-14 13:10:18 +00:00
Robert Osfield
c72124e449 Added support for read the various animaton materials/paths from http 2009-05-14 13:05:32 +00:00
Robert Osfield
3c88e59496 Added support for reading presentations and content via http, with support of the FileCache when available. 2009-05-13 19:48:02 +00:00
Robert Osfield
59ddcd08f4 Added intial cut at fileExists() implement using libcurl. Note, current implement loads the whole file and then discards it so is very in-efficient. This implementation will soon be replaced. 2009-05-13 19:47:26 +00:00
Cedric Pinson
c98466d401 from Maciej Krol:\nFixes for OSG_USE_PTR_IMPLICIT_OUTPUT_CONVERSION = OFF 2009-05-12 11:54:50 +00:00
Robert Osfield
b7b065abe3 Refactored the Registry::ReadFileCallback, WriteFileCallback and ReaderWriter::Options to they are now defined in their own header and in the osgDB namespace.
Introduced a new FindFileCallback to Registry to compliement the existing ReadFileCallback and WriteFileCallback.

Added support for assign Find, Read and WriteFileCallbacks to osdDB::Options to enable plugins/applications to override the callbacks just for that
read/write call and any nested file operations
2009-05-09 08:49:27 +00:00
Robert Osfield
426c5d4e44 Added osgGA and osgText to dependency list 2009-05-08 12:34:06 +00:00
Robert Osfield
c97d88b59c Added osgText dependency 2009-05-08 12:32:00 +00:00
Robert Osfield
1729648038 Added support for pushing handling relative paths set internally in the presentation file.
Added setting of env vars defined in presentation file.
2009-05-08 08:34:32 +00:00
Robert Osfield
0ab285a3ef From Jean-Sebastien Guay, changed the timing control for when no audio layer is supplied. 2009-05-08 07:46:46 +00:00
Robert Osfield
622e7a6611 Moved property code from ImageLayer into Layer where it belongs 2009-05-07 18:32:36 +00:00
Robert Osfield
870b1919c8 From MAthias Froehlich, "Attached is a compile fix I need on Suse 11.1 for a successful compile.
Just avoid uint8_t typed values in src/osgPlugins/ply/vertexData.cpp
if they are not needed for a particular reason ..."
2009-05-07 13:21:05 +00:00
Robert Osfield
ab5641e04e Fixed typo of POPPLER_LIBRARY_DIRS 2009-05-07 09:40:43 +00:00
Robert Osfield
c99c8826e8 Added support for osgVolume::TransferFunctionProperty 2009-05-07 09:07:34 +00:00
Robert Osfield
92afb370e8 Added .ive reading/writing support for osgVolume::Property classes 2009-05-06 13:47:08 +00:00
Robert Osfield
2b09b0dffa Added initial cut at support for osgVolume in .ive format. 2009-05-05 18:34:44 +00:00
Robert Osfield
9da4bb1387 Fixed support for reading imagery relative to the .osg being loaded 2009-05-05 12:18:24 +00:00
Robert Osfield
602d83a486 Warning fixes 2009-05-03 18:51:13 +00:00
Robert Osfield
2d97593560 Fixed warning + bug 2009-05-01 08:20:26 +00:00
Robert Osfield
bc29eab0b7 Added support for reading from streams 2009-04-30 08:50:43 +00:00
Robert Osfield
7cf721d1b5 Re-instated the code to allow event handler to run in standard viewers like osgviewer 2009-04-29 20:55:48 +00:00
Robert Osfield
590ac02859 Created a simple XmlNode parser class for reading of basic xml files, such as used by present3D.
Converted Present3D across from using libxml2 to using the new osgDB::XmlNode/XmlNode::Input classes from Xml Parsing.
This changes removes the dependency on libxml2, and allows the present3D application and p3d to work on all platforms.
2009-04-29 20:30:21 +00:00
Robert Osfield
b42706f034 Added osgFX to dependencies 2009-04-28 15:50:05 +00:00
Robert Osfield
ea65ea83a7 Added osgViewer as a dependency 2009-04-28 15:48:56 +00:00
Robert Osfield
7893293e0e Added detection of active alpha channel. 2009-04-27 15:45:52 +00:00
Robert Osfield
f0ff4afebc Further improvements in p3d plugin 2009-04-27 13:54:22 +00:00
Robert Osfield
200c9e82f3 Introduced first cut of Present3D integration with the core OSG with the introduction of a .p3d plugin. 2009-04-27 11:02:18 +00:00
Robert Osfield
d91e9db152 From Jason Daly, "Currently, the .mdl plugin loads vertices in the native DirectX order, which is the reverse of OpenGL order. This means that the back faces are currently rendered as front faces, and vice versa.
This fix reverses the vertex order and sets up proper OpenGL facing.  I didn't notice this problem until I started using the plug-in in my own code (osgviewer seems to not enable backface culling)."
2009-04-24 10:54:50 +00:00
Robert Osfield
b496d220c6 Warning fixes 2009-04-23 13:42:24 +00:00
Robert Osfield
9a072a4dc6 Refactored the subsurface PolygonOffset code so that it uses sensible values and also moves management of the PolygonOffset and Depth attribute objects into the Document object rather than using static vars. 2009-04-23 10:24:27 +00:00
Robert Osfield
4938d5687e Quitened down warnings generated by ffmpeg headers by remove -pedantic from CMAKE_CXX_FLAGS 2009-04-22 18:22:22 +00:00
Robert Osfield
009409695d Fixed warning 2009-04-22 16:50:50 +00:00
Robert Osfield
7e2b022ead Warning fixes 2009-04-22 16:47:07 +00:00
Robert Osfield
ddd3c39a17 Warning fixes 2009-04-22 16:42:16 +00:00
Robert Osfield
e8d9dd142d From Neil Hughes, converted across to use istream for reading data from file to enable reading .3ds files over http (use OSG's libcurl plugin).
From Robert Osfield, ammendments of the above to better support reading of files from local directories.
2009-04-22 15:46:24 +00:00
Robert Osfield
0c8cb4e6c9 From Bob Kuehne, "fix for failing collada builds on osx due to not being able to stringstreamify osg::Vec3 without io_utils included." 2009-04-22 13:09:33 +00:00
Robert Osfield
f5d532e54b From Neil Hughes, "here is an update to ReaderWriterCurl that makes use of the amended ReaderWriter definition to pass some plugin string data via the options object." 2009-04-21 14:15:03 +00:00
Robert Osfield
147486f57a Removed #ifdef WIN32 around #include <errno.h> to fix build under Mandrake build. 2009-04-20 19:05:59 +00:00
Robert Osfield
3fd9c6c1de Replaced #idef WIN32 with _MSC_VER to try and fix build errors under mingw 2009-04-13 09:41:22 +00:00
Robert Osfield
390be829af From Santosh Gaikwad, "I have added the exception handling in ply loader. All exceptions I am catching in VertexData::readPlyFile() and made sure that application will not crash or exit if any exception occurred. I am returning NULL from VertexData::readPlyFile() if any exception occurred.
"
2009-04-13 09:35:52 +00:00
Robert Osfield
562f84668f From Jean Sebastien Guay, added error reporting handling of wider range of video formats. 2009-04-11 06:16:37 +00:00
Robert Osfield
faa50c0962 From Santosh Gaikwad, warning fixes 2009-04-10 09:16:37 +00:00
Robert Osfield
cb3d43a575 Added ply entry 2009-04-09 18:27:11 +00:00
Robert Osfield
9a42888bdc From Santosh Gaikwad, ply plugin, based on Equalizer and other LGPL compatible sources.
"Attached is the osg-plugin for reading ply ( Stanford Triangle Format )  file. I have written  the plugin according to OSG standard and  have also added cmake build system. The plugin is working fine on both Linux and Windows and should behave similarly on other OS as well."

"I developed this plugin while working on a project based on Equalizer. So VertexData which I am using is taken from equalizer and modified to make them work as separate OSG plugin.
Before contributing this plugin to OSG community, I asked project manager of Equalizer project Stefen regarding potential licensing issues and this is what he has said

"The kd-Tree (VertexBuffer*) is LGPL-licensed, and the base ply loader (ply*) is BSD. As long as you leave the copyright notices intact, there is no issue."

so I think using these files in OSG should not be a problem.

As far as author of ReaderWriterPLY.cpp  is concerned I am the author. I am working for Darshan3d which is a subsidiary of VizExperts thats why I have put VizExperts copyright."
2009-04-09 18:26:04 +00:00
Robert Osfield
4efd7a558d From Martin Beckett, "I have fixed up the 3DC reader to handle any field separator so it can read x,y,z files and added ability to write a 3DC file."
From Robert Osfield, refactor of the above code to retain a bit more of the original funcionality, and to avoid the need to hand maintained XCode projects from being updated.
2009-04-09 16:31:31 +00:00
Robert Osfield
38b02a26a9 From Glenn Waldron, "Here is a first cut at the mime-type support we discussed a little while ago
(http://www.mail-archive.com/osg-users@lists.openscenegraph.org/msg23098.html)

Background: when you access a file over HTTP, you cannot rely on a file extension being present; instead the file's mime-type is conveyed in the HTTP Content-Type response header. This facility adds a mime-type-to-extension map to the registry to handle this.

There are two new osgDB::Registry functions which are pretty self-explanatory:

void addMimeTypeExtensionMapping( mime-type, extension )
ReaderWriter* getReaderWriterForMimeType( mime-type )

I also added the file osgDB/MimeTypes.cpp which houses a hard-coded list of built-in types. I took the list from here (http://www.webmaster-toolkit.com/mime-types.shtml) and then pared it down to include mostly image and video types, editing them to map to existing plugins where possible.

In addition, I updated the CURL plugin to a) install a set of built-in mime-type mappings, and b) use them to look up an extension in the event that the target filename does not have an extension.

Here is a test case. This URL pulls down a JPEG (without a file extension):
osgviewer --image "http://us.maps3.yimg.com/aerial.maps.yimg.com/ximg?v=1.8&s=256&t=a&r=1&x=0&y=0&z=2"
"
2009-04-09 14:00:16 +00:00
Robert Osfield
ee4e2afa76 From Philip Lowman, clean up of CMake files 2009-04-09 09:23:45 +00:00
Robert Osfield
fa27223fcd From Mike Connell, "Here are some small fixes that allow you to specify the allowable deviation when creating polylines from arcs and circles in DXF files. Changes are against 2.8.0
It adds two options:

Accuracy(x) - ensures the polyline will be within x units from the ideal arc/curve
ImproveAccuracyOnly - do not use the given accuracy 'x', if it would result in a worse curve than with the previous (2.8.0) implementation for a particular arc/curve.

As an added bonus there was a small bug in the existing implementation whereby the primitives were line strips but the vertices generated were actually suitable for GL_LINES, so the improved accuracy doesn't even have to come at a performance cost :-)"
2009-04-08 13:21:59 +00:00
Robert Osfield
beb711a2ec Reduced the default live video feed size to accomodate reading from the Minoru stereo wecam. 2009-04-08 13:03:34 +00:00
Robert Osfield
d2a0e7884d From Aric Aumann, added options for controlling the swap of the left/right handed coordinate system 2009-04-08 10:44:37 +00:00
Robert Osfield
20ad246896 Added new virtual reseveElements, setElement, getElment and addElement methods to DrawElements
to make is easier to write code that can work on DrawElementUByte, UShort or UInt.

Changed the osgTerrain::GeometryTechnique so that it automatically chooses 
the use of DrawElementUShort or DrawElementsUInt accordining to the size of the tile.
2009-03-25 11:17:21 +00:00
Robert Osfield
36b3907d79 Added support for adding .ffmpeg to filenames to force selection of ffmpeg plugin 2009-03-24 23:25:30 +00:00
Robert Osfield
3c4fc747ff From Ulrich Hertlein, "I got the following type error from gcc 4.0.1 on OS X 10.5.6:
/Users/uli/Projects/osg/OpenSceneGraph/src/osgPlugins/ffmpeg/FFmpegDecoderVideo.cpp: In member function \u2018int osgFFmpeg::FFmpegDecoderVideo::convert(AVPicture*, int, AVPicture*, int, int, int)\u2019:
/Users/uli/Projects/osg/OpenSceneGraph/src/osgPlugins/ffmpeg/FFmpegDecoderVideo.cpp:245: error: invalid conversion from \u2018int\u2019 to \u2018PixelFormat\u2019
/Users/uli/Projects/osg/OpenSceneGraph/src/osgPlugins/ffmpeg/FFmpegDecoderVideo.cpp:245: error:   initializing argument 3 of \u2018SwsContext* sws_getContext(int, int, PixelFormat, int, int, PixelFormat, int, SwsFilter*, SwsFilter*, double*)\u2019

It expects 'src_pix_fmt' and 'dst_pix_fmt' to be of type 'PixelFormat' rather than int. The attached cast fixes this (for me).

I've also added Matroska video to the list of supported extensions"
2009-03-24 11:08:40 +00:00
Robert Osfield
fb83a47d78 From Aric Aumann, fixed handling of null texture coordinates 2009-03-23 20:25:51 +00:00
Robert Osfield
73bf2a7de9 From Luc Frauciel, You'll find attached a modification in ive plugin for POLYGONSTIPPLE read/write. 2009-03-23 17:08:58 +00:00
Robert Osfield
9727321afe From Wang Rui, "Attached is a very small fix for the ffmpeg plugin, to build it without compiling errors on MSVC. The ffmpeg win32 pre-built tarball is downloaded at http://ffmpeg.arrozcru.org/builds/. Tested on Windows XP SP3 and Visual Studio 9, but don't know if it still workable for Unix and Mac users. :)
Please look at the .diff files for details. I have already enjoyed the latest Chinese *big* movie "Red Cliff" with the fixed ffmpeg plugin and osgmovie. :D"
2009-03-23 16:45:10 +00:00
Robert Osfield
1f251b4df5 From Csaba Halasz, "I have modified FltExportVisitor to use _MSC_VER instead of _WIN32 in
the condition around a #pragma warning that is specific to visual
studio as _WIN32 is also defined for mingw compile but the #pragma is
not applicable there."
2009-03-23 16:31:50 +00:00
Robert Osfield
33cdeec757 From Michael Platings, "Changed some pointers to ref_ptr which fixed the leak
"
2009-03-23 16:25:37 +00:00
Robert Osfield
f34116fa36 From Michale Platings, "Minor change to include ReaderWriterDAE.h" 2009-03-23 16:13:42 +00:00
Robert Osfield
39cecd2a72 From Philip Lowman, "Here's the promised cleanup of the OSG's CMakeLists.txt files for the src/ folder. I'll submit the others separately.
Also, there was also a small bug in osgDB's CMakeLists.txt that was causing an error when I tested with CMake 2.4.4.

IF(${OSG_DEFAULT_IMAGE_PLUGIN_FOR_OSX} STREQUAL "quicktime")
was changed to
IF(OSG_DEFAULT_IMAGE_PLUGIN_FOR_OSX STREQUAL "quicktime")
"
2009-03-23 16:01:02 +00:00
Robert Osfield
51964a2b79 From David Callu, clean up of FindFFmpeg include paths 2009-03-23 15:48:19 +00:00
Robert Osfield
26b55acf68 Fixed spacing 2009-03-19 10:56:38 +00:00
Robert Osfield
3626979bfa Added compressed to list of supported options 2009-03-19 10:55:51 +00:00
Robert Osfield
32ace364a0 Added debug message (commented out for now.) 2009-03-19 10:55:29 +00:00
Robert Osfield
1b3b69721f Added osgTerrain::Terrain support to the .osg format 2009-03-19 10:27:24 +00:00
Robert Osfield
e9d4f99409 From Adrian Egli, build fix for Win32 FFmpeg 2009-03-14 15:40:41 +00:00
Robert Osfield
628990e0a4 From Stephan Huber, clean up of Quicktime plugin 2009-03-13 15:56:19 +00:00
Robert Osfield
9a4e17b766 From Bryan Thrall, "The attached ReaderWriterGLSL.cpp conveniently sets the shader type when
the filename extension is "vert" or "frag" but still lets this be
overridden by the Options (for those crazy people who store their
fragment shaders in .vert files :) )."
2009-03-13 10:40:00 +00:00
Robert Osfield
7994ed1eb7 changed debug info to output to INFO instaed of NOTICE. 2009-03-11 17:39:08 +00:00
Robert Osfield
b6bffdd02f From Tanguy Fautre,
Clean up of the FFmpeg plugin's class API/AudioStream API. 
Implementation of isImageTransparent().
Implementation of Image:g/setPixelAspectRatio()
2009-03-11 15:12:46 +00:00
Robert Osfield
6791f65add From Neil Hughes, "I've spent the past four days playing with PNG files on 3DS objects, and I think I may have come across a small issue with the 3DS loader.
At the company where I work we model literally thousands of 3DS models for all types of objects. Most don't have transparent textures applied to them, but a few do. The issue is that a texture may have an alpha channel defined, yet its 3DS material definition is not marked as being an alpha source, or transparent. This can happen for any number of modelling reasons (so I'm told) but the net effect is that when a 3DS object is loaded with such a material applied, the stateset creation for the 3DS geometry omits to add the GL_BLEND attribute as neither of the conditions that it currently tests for are satisfied under this scenario.

However, one thing that is apparently an indication of transparency/alpha information that we do make use of when modelling, but that the 3DS reader omits to test, is that we assign to the transparent texture to the opacity_map of the 3DS material structure.

Now, having discussed with our modellers the theory behind the opacity map, it seems that it is safe to say that if an opacity map is specified, then the reader should really apply the GL_BLEND attribute as it is an indication of some form of blending being required between materials.

With this in mind, I have made a minor change to the function createStateSet below, from the ReaderWriter3DS.cpp file, that checks for an opacity map having been specified, and in such a scenario the GL_BLEND attribute is applied to the geometry. This fixed our issue, and thought it might be helpful to others."
2009-03-11 13:27:51 +00:00
Robert Osfield
a0a06c8b2a Completed support for automatic detection of plugin features.
Cleaned up debug out of various plugins to ensure a clean osgconv --formats.
2009-03-10 17:27:39 +00:00
Robert Osfield
3ec2da76e8 quitened down debug info 2009-03-10 17:13:51 +00:00
Robert Osfield
9ddb8f65b6 Added copyright + fixed typo 2009-03-10 13:46:55 +00:00
Robert Osfield
9643c15346 From David Callu, "Problem:
osgText::Text and osgText::Text3D use the same font file.
     The first really load the file and obtain an osgText::Font object,
     the second use the cache created during the first load of the
     font file, and so obtain an osgText::Font object instead of
     osgText::Font3D object. To obtain an osgText::Font3D object,
     osgText::Text3D call osgDB::readObjectFile(...) with an option
     to specify the plugin we want an osgText::Font3D instead of
     osgText::Font.

Generalised Problem:
    In osgDB::Registry, loaded file cache is referenced by the name
    of this file, so if I load a file with some options, and the cache
    already contain object for this filename, I obtain an object
    potentially not loaded with my options.

Behaviours:
    Cache management is delegate to osgDB::Registry, but cache
    coherence (load a file with option then reuse it, deactivate the
    cache when load a specific file or don't cached the loaded file)
    is user's responsibility.

Text3D solution:
    Postfix the font file name by .text3d or something similar and then have the freetype plugin return
    osgText::Font3D when it detects this.
    This operation is done by osgText::readFont3DFile() which unsure the filename have .text3d as extension.
    This is totaly transparent for user, and backward compatible.


BTW, I fix the bug about the Normal of 3D text. Currently, the front and wall face have
the same normal (0,0,1) in the Text3D object coordinate. Now the wall face have its own
normal array computed by the plugin.

BTW 2, I implement
- void Text3D::accept(osg::Drawable::ConstAttributeFunctor& af) const
- void Text3D::accept(osg::PrimitiveFunctor& pf) const
so now statistics are well reported.
"
2009-03-10 10:56:00 +00:00
Robert Osfield
e7c4cda108 From Eric Wing and Stephan Huber, ImageIO code originally wrote by Eric Wing, and then later conveted into an OSG plugin by Stephan Huber. 2009-03-10 10:30:34 +00:00
Robert Osfield
ae50d8d956 From Roland Smeenk & Cedric Pinson,
"Summary of changes:
From Roland
-Added MorphGeometry
-Bone Bindmatrix is only calculated if needed
-osgAnimation plugin now supports all available channel types (before only linear vec3 or quat channels)
-osgAnimation plugin now supports MorphGeometry
-osgAnimation plugin now supports animation and channel weights, animation playmode, duration and starttime
-removed osgAnimationManager.cpp from CMakeList

From Cedric
-fixed the last_update field (it was only updated at the first update) in BasicAnimationManager.cpp
- Refactore some part of MorphGeometry minor changes
- Add osganimationmorph as example
"
2009-03-09 17:38:39 +00:00
Robert Osfield
73c2615d17 Fixed thread exit problems 2009-03-08 16:48:48 +00:00
Robert Osfield
fa14e7d5f2 Added quick proof of concept for live video streaming under linux 2009-03-05 10:57:54 +00:00
Robert Osfield
6fd4cd4933 Removed boost reference and cleaned up debug output 2009-03-04 16:03:28 +00:00
Robert Osfield
ab82553f97 Introduced double buffering of video stream to avoid tearing of image.
Removed swapBufers call and image y inversion.
2009-03-04 14:49:39 +00:00
Robert Osfield
ac8ee3792c Fixes to non swscale code path 2009-03-04 11:59:15 +00:00
Robert Osfield
d0dabd2665 Fixed img_convert usage 2009-03-04 11:46:34 +00:00
Robert Osfield
4ffef96874 Removed reference to OpenAL plugin 2009-03-04 11:06:34 +00:00
Robert Osfield
fb54fd0a69 Added support for using libswscale 2009-03-04 11:05:55 +00:00
Robert Osfield
ac49ca81ca Improved the clean up ordering 2009-03-03 20:49:46 +00:00
Robert Osfield
e035decd95 Introduce FFmpegAudioStream implementation 2009-03-03 16:51:01 +00:00
Robert Osfield
e0959ea804 Removed redudent export 2009-03-03 14:59:04 +00:00
Robert Osfield
8419ac6975 Added LINK_DIRECTORIES 2009-03-03 11:52:26 +00:00
Robert Osfield
79e65b48fe Fixed include list 2009-03-03 11:25:31 +00:00
Robert Osfield
8a8cee05c5 From Ulrich Hertlein, build fixes for OSX. 2009-03-03 10:53:26 +00:00
Robert Osfield
ae2e2c5075 Added ffmpeg to include search paths 2009-03-03 09:50:43 +00:00
Robert Osfield
439b240abc Added ogg to accepted formats 2009-03-03 09:49:53 +00:00
Robert Osfield
1a2e6aae8e Added extern for img_convert to get round disappeance of the declaration from headers. 2009-03-02 16:01:13 +00:00
Robert Osfield
4ebd316130 Introduced osg::AudioStream class to help manage audio streams coming in from movie reading plugins 2009-02-27 20:16:08 +00:00
Robert Osfield
116655c7c5 Ported across from using boost pointers, and prepped for integration of audio interface into core OSG 2009-02-27 17:00:28 +00:00
Robert Osfield
19ee0f011e Tweaks to handle more modern version of ffmpeg compiled form source. 2009-02-25 20:52:34 +00:00
Robert Osfield
1bad5770b6 Added Cmake support for new ffmpeg plugin 2009-02-25 16:05:12 +00:00
Robert Osfield
6680ee2b10 From Tanguy Fautre (Aris Technologies), ffmpeg plugin 2009-02-25 16:04:48 +00:00
Robert Osfield
4a0e9a6ad2 From Ralf Habacker & Robert Osfield, fixed handling of file name string of the form"PG:host=localhost user=postgres dbname=osm tables=public.planet_osm_line". The patch also routes gdal debug and error message to the related osg::notify debug port - this is usefull for debugging ogr plugin. 2009-02-23 09:54:25 +00:00
Robert Osfield
ddddec2b2f From Martin Beckett, "I have added support for DXF POINTS to the dxf reader plugin
It's really just a cut-paste job from the existing LINE support.

The current dxf plugin architecture isn't very efficient, especially if you
are loading large point clouds (LIDAR)
eg. it makes multiple lookups of the layer name for each vertex.
I don't know if I can improve this for the general case or if I have to add a
special large point cloud dxf reader."
2009-02-20 11:51:47 +00:00
Robert Osfield
4a50d54d3e From Himar Carmona, "When reading a DXF file, the reader breaks at a debug assertion at vector (it breaks on release version). Inspecting the code show that the cause could be in dxfEntity.cpp.
It seems that the problem is an offending "short" used in a for loop, where it should be "int" or "long". It causes an index out of range error. "
2009-02-20 11:30:33 +00:00
Robert Osfield
e42c560223 Fixed bug in checking if numRead values. 2009-02-19 17:34:35 +00:00
Robert Osfield
c385e11aff From Riccardo Corsi, "in attach you'll find a patch to cleanup a little bit the (de)initialization code of QuickTime environment from the quickTime pluging.
It basically removes the static init() and exit() functions,and move them inside the observer class (the one that cleans everything up when the last media is unloaded).

It also add an extra check to clean up on exit if the QuickTime env is initialized, but no media is succesfully loaded / written (it might happens with streaming resources).

I tested it under WinXP with zero, one and multiple videos.

Stephan reads in copy: could you kindly check if everything runs smooth under OSX as well? Also, have you got a chance to test it with streaming media?
"
2009-02-11 17:14:53 +00:00
Robert Osfield
c9b61a63b8 From Roland Smeenk, "Attached are two small fixes:
-I changed the SET of COLLADA_BOOST_INCLUDE_DIR to use findpath, so users may override this setting if they choose not to build against to precompiled boost libraries delivered with the Collada DOM.

-Changed daeRMaterials.cpp to prevent a compiler warning about a potentially uninitialized variable."
2009-02-11 09:14:12 +00:00
Robert Osfield
81043b1028 Merged warning fix from OSG-2.8 branch:
svn merge -r 9755:9756 http://www.openscenegraph.org/svn/osg/OpenSceneGraph/branches/OpenSceneGraph-2.8
2009-02-10 20:31:50 +00:00
Robert Osfield
17da548343 From Roger James and Robert Osfield, fixes and reorganization to better support Windows dyanmic library build 2009-02-10 19:25:50 +00:00
Robert Osfield
a29b0a2f76 From Pierre Haritchabalet, "In IO_FluidProgram.cpp, FluidProgram_readLocalData() function is wrong. When density parameter is read, the function "setFluidViscosity()" is called instead of "setFluidDensity()".
This patch fixes osg plug'in FluidProgram_readLocalData. "
2009-02-10 18:56:53 +00:00
Robert Osfield
560cdf458d From Jason Beverage, "I've added a small change to the CURL plugin that allows support for HTTP redirects." 2009-02-10 13:37:16 +00:00
Robert Osfield
7de8527efd From Roland Smeenk and Robert Osfiled, tweaks to the Collada finding/linking to improve support for Collada DOM 2.1 + 2.2 across platforms. 2009-02-10 11:44:50 +00:00
Robert Osfield
1710b431a5 From Bryan Thrall, "The .osg plugin doesn't seem to support an option to write shader files
separately, so it always inlines them in the .osg file (as far as I can
tell). This change adds that ability. "
2009-02-09 21:48:30 +00:00
Robert Osfield
d307ca2dea Fixed data copy bug 2009-02-06 12:15:15 +00:00
Robert Osfield
b6d2a67651 From Alberto Luaces, "here are some minor fixes to notify warnings were the std::hex modifier was
used but never restored to the decimal notation. That made OSG print messages
like the following after some notifications:

Warning: detected OpenGL error 'invalid value' after RenderBin::draw(,)
RenderStage::drawInner(,) FBO status= 0x8cd5
[...]
Scaling image 'brick_side.JPG' from (1b4,24f) to (200,200) <--- Values in hex
because of previous error.
[...]"
2009-02-06 10:35:21 +00:00
Robert Osfield
a88f4e2f86 Added initializer and fixed indentation 2009-02-05 14:42:29 +00:00
Robert Osfield
2864a75ad2 Suppress gcc warnings emitted by external headers 2009-02-05 14:35:46 +00:00
Robert Osfield
baac534bcc From Jean-Sebastien Guay, warning fixes 2009-02-05 10:14:49 +00:00
Robert Osfield
734463fcc7 Warning fixes 2009-02-03 15:28:53 +00:00
Robert Osfield
630f5087dc From Stephan Huber, build fix for OSX XCode build 2009-02-02 16:56:46 +00:00
Robert Osfield
fa727038a4 From Cedric Pinson, "Here an update of the osgAnimation ReaderWriter, it add other NodeCallback that could be attached to a node with Bone." 2009-02-02 14:51:51 +00:00
Robert Osfield
3d1c38f5e8 From Pierre Haritchablaet, "The wind vector of osgParticle::FluidFrictionOperator has not been written and read in IO_FluidFrictionOperator. This patch fixes osg plug'in FluidFrictionOperator_readLocalData and FluidFrictionOperator_writeLocalData." 2009-02-02 14:50:19 +00:00
Robert Osfield
2d55740b3e Refactored osg::TransferFunction1D to use an std::map internally which is kept in sync with the actual osg::Image that is passed to the GPU.
Added .osg support for osg::TransferFunction1D.

Updated wrappers
2009-02-02 14:43:27 +00:00
Robert Osfield
d6b0cd64f1 Ground work for full .osg support for osg::TransferFunction* 2009-02-01 12:38:55 +00:00
Robert Osfield
b514b435f4 Added initial placeholder for .osg support for osgVolume::TransferFunctionProperty 2009-01-31 21:46:16 +00:00
Robert Osfield
eae23b01c3 From Lionel Lagarde, "this correct how the ParticleEffect are serialized :
- the texture file name is taken from the TextFileName field
- the texture file name is written using writeString
"
2009-01-30 14:54:22 +00:00
Robert Osfield
6710fbc78a Added support for osgVolume::ProperyAdjustmentCallback 2009-01-29 20:40:56 +00:00
Robert Osfield
51403143bd Added support for osgVolume::Property classes 2009-01-29 20:34:22 +00:00
Robert Osfield
4c75313ced Fixed handling of files with event callbacks on them. 2009-01-29 17:19:47 +00:00
Robert Osfield
d62c34efe8 From Jason Daly, "Somehow, one of the shaders in the bsp plugin started behaving incorrectly between the original submission and now. I suspect it has to do with a typo in the setup of the shader that was fixed at some point, or it happened during the recent warnings purge. In any case, I had to invert the usage of a parameter in the shader to make it behave properly again.
The vtf plugin wasn't working in Windows due to OS differences in the byte-packing of the header structure (on Windows, the big block read was causing a buffer overrun).  I fixed this by reading the structure from the file field by field.  It's now happy on both Linux and Windows."
2009-01-29 11:18:03 +00:00
Robert Osfield
2bf68cab53 Fixed warning 2009-01-29 11:03:38 +00:00
Robert Osfield
5ac339d7b2 Replaced -1 with ~0u to fix warning due to being written to a UInt field. Note, OpenFlight spec says -1, which is clearly an error in the spec, so we've had to guess at ~0u being an appropriate value. 2009-01-29 09:27:23 +00:00
Robert Osfield
ca1f1e5abe Fixed warnings 2009-01-28 12:51:47 +00:00
Robert Osfield
065b1d4978 Fixed warnings 2009-01-28 12:28:04 +00:00
Robert Osfield
998582e945 Added back in intializers for RenderSurface. 2009-01-28 09:06:46 +00:00
Robert Osfield
a7b057feee From Jason Beverage, "Here is a small fix that enables writing 16 bit short images in the tiff plugin.
"
2009-01-27 15:14:47 +00:00
Robert Osfield
c7bf776bcb Converted across to using ref_ptr<> to avoid memory leak/dangling pointer issues. 2009-01-26 16:55:53 +00:00
Robert Osfield
88ce4a3786 From Roland Smeenk, "attached is a small crash fix for the case that a texture is used for transparency without the availability of a diffuse texture." 2009-01-23 15:52:10 +00:00
Robert Osfield
7b598c5701 Warning fixes for VS, and removal of associated warning disables 2009-01-23 15:12:26 +00:00
Robert Osfield
aa8402ce81 Added workaround for silly posix read deprecation warning under VS. 2009-01-23 15:02:04 +00:00
Robert Osfield
1fe0f0c0d6 Added range of visual rendering properties to readNode's creation of VolumeTile/ImageLayer. 2009-01-23 11:52:18 +00:00
Robert Osfield
99313d225b From Roger James, The changes are as follows:-
1. Support for ambient occlusion maps.
2. A fix for the incorrect handling of normals on all geometries. The optimizer usually fixed this bug so it probably was not noticed very often.
3. A new option flag on the reader. "StrictTransparency"
          // Process transparent and transparency settings according to a strict interpretation of the spec
          // See https://collada.org/public_forum/viewtopic.php?f=12&t=1210
otherwise
          // Jump through various hoops to accomodate the multiplicity of different ways
          // that various people have interpreted the specification
4. Handling of texures in the transparent channel. This is allowed provided that they are the same texture that is specified in the diffuse channel. Accomodating a different texture would require use of programmable pipeline functionality which I have tried to avoid.
5. Handling of <bind_vertex_input> elements.
""
2009-01-21 18:47:55 +00:00
Robert Osfield
908432c732 Replaced readImageFile() usage with readRefImageFile() to prevent threading issues with caching of imagery in the osgDB::Registry cache. 2009-01-21 18:23:55 +00:00
Robert Osfield
a6284b0e03 Renamed ShaderTechnique to RayTracedTechnique 2009-01-21 14:27:58 +00:00
Robert Osfield
8a971d96d2 Fixed compile error when using ITK 2009-01-20 11:34:15 +00:00
Robert Osfield
b176c3a223 Removed old volume rendering scene graph code from osgvolume example.
Moved createNormalMapTexture and applyTransferFunction functions from osgvolume example into include/osgVolume/Layer.
2009-01-16 17:59:38 +00:00
Robert Osfield
5e629d1236 Added default use of osgVolume::ShaderTechnique 2009-01-16 10:34:58 +00:00
Robert Osfield
78c2f98b7a Introduced ImageLayer computeMinMax + rescaling methods, and use of rescaleToZeroToOneRange by default. 2009-01-16 10:23:17 +00:00
Robert Osfield
c28221b06f Changed setVolumeTechnique to setVolumeTechniquePrototype() 2009-01-14 20:43:21 +00:00
Robert Osfield
1a00a2ce3c Added osgVolume .osg plugin 2009-01-14 20:32:06 +00:00
Robert Osfield
d87ec7cb18 Introduced osgVolume::Property, CompositePropery and TransferFunctionPropety classes 2009-01-14 15:16:29 +00:00
Robert Osfield
c21eef7afb From Lionel Lagarde, "The last field of the LightPointAppearancePalette is only valid for > 15.8 version of
the format."
2009-01-14 10:32:20 +00:00
Robert Osfield
f260737cd8 Introduced class interfaces for FixedFunctionTechnique and ShaderTechnique volume rendering techniques. 2009-01-13 17:20:32 +00:00
Robert Osfield
7bcdaa74bf Added ZLIB_FOUND to dicom qualification 2009-01-13 10:15:04 +00:00
Robert Osfield
6a19b04d22 Added a / in front of the ${DCMTK_ROOT_INCLUDE_DIR} to workaround a CMake bug that ignores /usr/local/include directories.
Added ZLIB to include line.
2009-01-13 10:12:13 +00:00
Robert Osfield
53d99109bd Added test message 2009-01-12 17:41:25 +00:00
Robert Osfield
12a484593c Further tweak to include paths 2009-01-12 16:37:38 +00:00
Robert Osfield
ded06dc421 Restructured the include paths 2009-01-12 16:10:40 +00:00
Robert Osfield
b5a2dc4cfb Fixed warnings 2009-01-09 15:55:25 +00:00
Robert Osfield
458993fa88 Moved osgVolume::ImageUtils to osg::ImageUtils, updated wrappers, and started moving osgvolume example across to create osgVolume subgraphs 2009-01-09 15:19:25 +00:00
Robert Osfield
9b4c6e25ea Fix of warning reported on CDash 2009-01-09 15:11:15 +00:00
Robert Osfield
1289528770 From Roland Smeenk, "Attached is a fix for the Collada plugin. A PositionAttitudeTransform wrote its place elements in the wrong order." 2009-01-09 12:21:36 +00:00
Robert Osfield
fa499dc55f From Andy Skinner, fixes for Solaris build 2009-01-09 12:17:40 +00:00
Robert Osfield
418dc34776 Fixed warnings 2009-01-07 11:24:47 +00:00
Robert Osfield
dee703a6f3 From Ewe Woesnner, "the Inventor loader crashes when a texture could not be loaded.
Please find attached a small fix which solves this issue."
2009-01-06 16:35:38 +00:00
Robert Osfield
4f3b1baee4 Added support for primitive instancing 2009-01-06 14:55:49 +00:00
Robert Osfield
85fffc2e76 From Roland Smeenk, "Attached you will find an improved Collada plugin to properly support camera's.
A Collada camera will be added to the scenegraph as osg::CameraView. This allows the user to create a set of predefined camera viewpoints. I also added a new MatrixManipulator to osgGA called CameraViewSwitchManipulator and added usage of this to the osgviewer example. This manipulator allows switching between the predefined camera viewpoints. The current design limition I ran into is that a MatrixManipulator only manipulates the ViewMatrix, but for this particular  manipulator I also want to update the projectionMatrix of the camera when switching to a new viewpoint. This is not implemented because I don't know what would be the best way to design it. Any ideas?
 
Furthermore Collada also supports orthographic camera's, where an osg::CameraView only supports a perspective camera. Would it be useful to create a CameraView with customizable optics for this?"
2009-01-05 16:53:29 +00:00
Robert Osfield
4f91d9769e Fixed warning 2008-12-24 11:05:22 +00:00
Robert Osfield
1697eb526d Fixed warnings 2008-12-24 10:30:21 +00:00
Robert Osfield
c0b696ba52 Fixed warnings 2008-12-22 21:16:40 +00:00
Robert Osfield
21b633e73b Build fix 2008-12-22 18:30:52 +00:00
Robert Osfield
f4c26f9cc8 Changed VolumeTile::setImage(Image*) to setImage(uint i, Image*) to allow multiple images to be attached to single tile 2008-12-21 20:42:29 +00:00
Robert Osfield
adb7a49c10 Renamed osgVolume::Brick to osgVolume::VolumeTile 2008-12-20 20:55:21 +00:00
Robert Osfield
f0270f934e Changed the scale from 0.03 to 0.0254 as the Q3 bsp files are in inches. 2008-12-20 20:30:08 +00:00
Robert Osfield
28ca8277f8 From Jason Daly, "'ve been busy working on the Source engine plugins. There are several contributions in this submission:
osgDB/FileUtils.cpp:
Needed this extra code to allow a true case-insensitive search.  This is because the HL2 map and model files are often sloppy with case.  For example, the file might look for materials/models/alyx/alyx_sheet.vtf, but the file is actually in materials/Models/Alyx/alyx_sheet.vtf.  In case-insensitive mode, the new code recursively disassembles the path and checks each path element without regard to case.  In case-sensitive mode, the code behaves exactly as it used to.  The new code is also mostly skipped on Windows because of the case-insensitive file system.  Previously, I did all of this with custom search code in the .bsp plugin, but this allows the user to tailor the search using OSGFILEPATH.  There are some instructions in the plugins' README files about this.

osgPlugins/mdl:
This is a new plug-in for Half-Life 2 models (as opposed to maps).  This allows you to load Source models individually, as well as allowing the .bsp plugin to load models (props) that are embedded into maps.  Mdl files can contain simple object (crates, barrels, bottles), as well as fully articulated characters with skeletal animations.  Currently, it can load the simple objects.  It can also load the characters, but it can't load the skeletons or animations.

osgPlugins/bsp:
This contains all of the changes needed to load props along with the basic map geometry.  There are also
several bugs fixed.

osgPlugins/vtf:
This is the loader for Valve's texture format.  Previously, we had agreed to put this in with the bsp plugin, but I didn't think of the .mdl plugin at that time.  It's conceivable that a user might want to load models individually (not as part of a map), so the vtf reader does have to be separate.  I also fixed a rather significant bug.

I tested all of this code on RHEL 5.2 (32-bit), and Fedora 9 (64-bit).  I'll be testing on Windows soon.

I also attached a simple .mdl file, along with it's associated files and textures.  Just extract the tarball into it's own directory, set your OSGFILEPATH to point at that directory, and load the model like this:

 osgviewer models/props_junk/gascan001a.mdl"
2008-12-20 13:35:49 +00:00
Robert Osfield
767096631a Fixed warning 2008-12-19 16:59:10 +00:00
Robert Osfield
df0f01c828 Fixed compile error during debug build 2008-12-19 16:35:45 +00:00
Robert Osfield
0ea6cdeb96 Added ClipNode::set/getReferenceFrame(); 2008-12-19 15:29:59 +00:00
Robert Osfield
1b942fed64 Fixed warnings 2008-12-18 16:10:12 +00:00
Robert Osfield
6055dee411 Fixed warnings 2008-12-18 15:49:44 +00:00
Robert Osfield
9d2b1b539c Fixed warnings 2008-12-18 13:23:48 +00:00
Robert Osfield
1d4a0e767c Fixed warning 2008-12-18 12:29:17 +00:00
Robert Osfield
bc6a7b03ab Quitened down debug messages 2008-12-18 12:27:34 +00:00
Robert Osfield
215cd5f29b Fixed warnings 2008-12-18 12:26:14 +00:00
Robert Osfield
666a55c0a0 Fixed warnings 2008-12-18 11:54:34 +00:00
Robert Osfield
4ad20a413a Fixed warnings 2008-12-18 11:06:57 +00:00
Robert Osfield
2225339208 Fixed warnings 2008-12-17 16:13:23 +00:00
Robert Osfield
4f561d84b3 Fixed warnings 2008-12-17 16:02:42 +00:00
Robert Osfield
34eab50197 Fixed warnings 2008-12-17 15:36:59 +00:00
Robert Osfield
c85437e967 Fixed warnings 2008-12-17 15:32:35 +00:00
Robert Osfield
33545ab332 Fixed warnings 2008-12-17 14:56:40 +00:00
Robert Osfield
e754fc5aab From Sekender, fixed warnins 2008-12-17 10:34:09 +00:00
Robert Osfield
ca3e855b9c Fixed warnings 2008-12-17 10:33:39 +00:00
Robert Osfield
ffe77a785a Build fixes for when the implict ref_ptr<> cast is not enabled 2008-12-16 20:49:12 +00:00
Robert Osfield
60fc821764 From Cedric Pinson and Jeremey Moles, Changes to OpenSceneGraph-osgWidget-dev branch.
Notes from Robert Osfield, Merged changes to OpenSceneGraph-osgWidget-dev r9367 (prior to my botched attempt at merged svn/trunk into the branch).
2008-12-16 20:29:00 +00:00
Robert Osfield
f63d33c003 Fixed warnings 2008-12-16 12:23:30 +00:00
Robert Osfield
de1031b264 Fixed warnings 2008-12-16 12:20:19 +00:00
Robert Osfield
315aeeb557 Where possible moved redundent C header includes from headers to source files 2008-12-12 18:47:30 +00:00
Robert Osfield
55fe4967ad From Mattias Helsing, "I have developed the earlier cpack example a bit. Perhaps you could
consider these initial cpack support scripts. It is hidden behind a
BUILD_PACKAGES option so won't affect the normal user. The submission
1) set the COMPONENT attribute on all cmake install commands.
COMPONENT names are according to
http://www.openscenegraph.org/projects/osg/wiki/Community/Packaging

2) provide cmake script and a template for creating CPack
configuration files. It will generate target for creating packages
with everything that gets "installed" (make package on unx, project
PACKAGE in MSVC) plus targets for generating one package per COMPONENT
(i.e. libopenscenegraph-core etc.).

I have temporariliy uploaded some examples to
http://www.openscenegraph.org/projects/osg/wiki/Community/People/MattiasHelsing

If this submission makes it into svn we can develop it to generate
rpms, installers for windows and mac (I know at least J-S don't like
these but there may be others who do ;) and even DEBs (not sure if we
can make them "ubuntu-ready" but they eventually may - at least we
could put a deb on the website)"
2008-12-12 11:01:09 +00:00
Robert Osfield
4896fe6e05 From Mattias Helsing, "When building osg static on Windows the _declspec's wasn't escaped for
applications, examples or wrappers. Attached are the CMakeLists I had
to change to make these compile.
"
2008-12-11 17:00:40 +00:00
Robert Osfield
3a623717a9 Cleaned up layout 2008-12-10 17:08:21 +00:00
Robert Osfield
c3611c5875 Added mechanism for registering proxy objects in the .osg plugin in a way that is compatible with static linking. 2008-12-10 16:26:02 +00:00
Robert Osfield
69f5e5c5e5 From Andreas Goebel, (submitted by Paul Martz) "A fix for the FLT exporter. This change adds support for normals with OVERALL binding (and improves support for normals with PER_PRIMITIVE binding -- still not correct, but at least it doesn't index off the end of the array anymore)." 2008-12-10 10:13:58 +00:00
Robert Osfield
9a554f7eec Fixed cull callback usage to ensure that the lazy updating of the browser image functions automatically. 2008-12-09 14:07:59 +00:00
Robert Osfield
c8190d9c54 Cleaned up osgWidget::VncClient and osgWidget::Browser so that their implementations are all more consitent with the osgWidget::PdfReader. 2008-12-09 11:05:04 +00:00
Robert Osfield
d8c17e4c4c Added support for setting background colour of Pdf document. 2008-12-09 09:26:51 +00:00
Robert Osfield
45160a2129 Added ability to customize keyboard events for controlling osgWidget::PdfImage/PdfReader 2008-12-07 17:37:26 +00:00
Robert Osfield
6f356aeb97 Intoduce new osgWidget::PdfReader and osgWidget::VncClient front ends to osgWidget,
with new pdf plugin and updated vnc plugin that now support these front ends.

Updated osgpdf and osgvnc examples to new these new interfaces.
2008-12-07 17:02:30 +00:00
Robert Osfield
0114ac4734 Fixed build problem 2008-12-06 11:03:32 +00:00
Robert Osfield
25eff6e27c From Jason Daly, added support for reading Valve's texture format files 2008-12-04 10:27:29 +00:00
Robert Osfield
9d92a26693 Revised the DYNAMIC vs STATIC library setup of COLLADA. 2008-12-02 10:42:58 +00:00
Robert Osfield
91f8dbb583 From Wang Rui, "Attachment is a plugin reading Biovision hierarchical files (.BVH) to generate character motion animations. BVH format is widely used by Character Studio of 3dsmax, MotionBuilder and other softwares, also supported by most motion capture devices. The plugin is based on the latest osgAnimation library of OSG 2.7.6 and will return a osgAnimation::AnimationManager pointer if using readNodeFile() to load it.
Source and CMake files are:
 
CMakeLists.txt
ReaderWriterBVH.cpp
 
Also there are 3 example BVH files. The first two are captured from motions of human beings - maybe a kung-fu master here. PLEASE use command below to see the results:
 
# osgviewer example1.bvh -O solids
 
This will demonstrate the animating of a skeleton and render bones as solid boxes. Note that the motion assumes XOZ is the ground and has an offset from the center, so we should adjust our view to get best effects.
 
You may also use "-O contours" to render bones as lines. The viewer shows nothing if without any options because osgAnimation::Bone does not render itself. User may add customized models to each named bones as osganimationskinning does to make uses of this plugin in their own applications.

I was wondering to support a BvhNode in my osgModeling peoject before, but soon found it better be a plugin for animation. A problem is, how to bind real geometry models to the skeleton. Maybe we could have a bindingToNode() visitor in future to find geodes matching names of bones and add them as bones' children."
2008-12-01 14:07:20 +00:00
Robert Osfield
78a808e444 Changed OPENEXR_LIBRARY to OPENEXR_LIBRARIES to pick up on Ulrich's changes to the FindOpenEXR.cmake 2008-11-30 16:33:55 +00:00
Robert Osfield
37682c6668 From Cedric Pinson, "updated the CMakelist.txt of curl plugin to compile with the static library of curl.
I added the external dependency wldap32"
2008-11-27 17:31:49 +00:00
Robert Osfield
cf440dfec3 Changed unsigned long to unsigned int to avoid 64bit portability issue. 2008-11-27 14:05:30 +00:00
Robert Osfield
25ec33d863 Enabled the build of exr plugin 2008-11-27 09:36:35 +00:00
Robert Osfield
db572a9142 Build fixes 2008-11-27 09:36:18 +00:00
Robert Osfield
c0e7e733ec Removed the use of = operator. 2008-11-27 09:33:06 +00:00
Robert Osfield
51fee6f75c From Ragnar Hammarqvist, "I wrote an EXR image plug-in to osg, I would like to contribute this plug-in to the osg project if you find it useful.
The plug-in is a wrapper around open-exr (http://www.openexr.com) that consists of two projects, ilmbase-1.0.1 and openexr-1.6.1.

I have only tested it on windows XP 32 machine. So there might be some work making it work on other platforms.

The plug-in supports writing and reading EXR files. When writing it can use the data type GL_HALF_FLOAT_ARB(se ilmbase-1.0.1) and GL_FLOAT. When reading the data type always becomes GL_HALF_FLOAT_ARB. It supports textures with three and four channels.

When reading an exr file it automatically removes Alfa channel if it didn't store any information."

--

From Robert Osfield, started work on ported it to other platforms, but could fix some problems relating to error: 

        ?Imf::OStream::OStream(const Imf::OStream&)? is private

I'm checking in now so that others can have a bash at completing the port.
2008-11-26 12:35:25 +00:00