Commit Graph

1242 Commits

Author SHA1 Message Date
Robert Osfield
fdda54e77e Changed instances of setCoord(const Vec3) to setCoord(const Vec3&) style. 2006-05-15 11:22:08 +00:00
Robert Osfield
132b355d4f From Brede Johansen,
"- Replaced some member attributes with local variables in Face record.
 - Multitexture support in Vertex class.
 - Renamed VertexList to VertexListRecord (VertexList is now a Vertex array)
 - new Mesh (with reserved field at offset 12, thanks to Paul Martz)
 - new LocalVertexPool
 - new MeshPrimitive
 - Use ProxyNode for externals.
 - Local cache for externals"
2006-05-15 11:18:50 +00:00
Robert Osfield
f104656d9f From Carlos García and Paul Baker, Port of Paul Baker's Quake3 BSP loader to OSG by Carlos García.
Added Quake3 BSP plugin.
2006-05-15 09:46:54 +00:00
Robert Osfield
43f0efd6d2 Reorganised the Group::removeChild and Geode::removeDrawable methods so
that removeChild(Node*), removeChild(uint) and equivilant Geode methods are
now inline methods, not designed to be overriden, and seperated out the
multiple remove method to be called removeChildren(uint, uint) which is
now the only virtual method.  There removeChildren is now the method to
override in subclasses.

This reorganisation requires some call code to be rename removeChild usage
to removeChildren.
2006-05-02 09:45:31 +00:00
Robert Osfield
ffb4c79132 Ran dos2unix. 2006-05-01 16:13:37 +00:00
Don BURNS
f76a324c95 Don Tidrow's ifdef for MingW 2006-03-31 01:37:38 +00:00
Robert Osfield
7f101c37ad From Glenn Waldrom, addition of .ive support for PriorityOffset and PriorityScale. 2006-03-28 14:45:48 +00:00
Robert Osfield
7f731f330a From Farshid Lasharki, added IO suppoty fo osgParticle::ConstantRateContour 2006-03-18 07:07:19 +00:00
Robert Osfield
14dab7f818 From Farshid Lashkari, Added ability to read/write the texture tile
settings of osgParticle::Particle to .osg files.
2006-03-17 14:05:40 +00:00
Robert Osfield
3425ba9706 From Martin Naylor, build fix for Win32. 2006-03-15 11:21:44 +00:00
Robert Osfield
d43dbaeadd Build fixes 2006-03-14 13:18:21 +00:00
Robert Osfield
f3715665c0 Added 21 as the version number of xine video plugin to allow it work with latest versions of xine. 2006-03-14 09:33:14 +00:00
Robert Osfield
d50f2e3add From Andrew Sampson, "The terravista terrain generation tool can insert references to external model files into a terrapage tile. It unfortunately does not update the bounding sphere of that tile to include the extents of the external model. This means that if a large model (such as an airfield model) is attached to a tile, the model will disappear when the tile is off-screen (outside the view volume), even though the model is on-screen." 2006-03-13 21:20:07 +00:00
Robert Osfield
3246dde716 From Brede Johansen, new OpenFlight plugin!!!!!
By default the original flt plugin is still used, to select at runtime
the new plugin set the env OSG_OPEN_FLIGHT_PLUGIN=new
2006-03-08 21:38:37 +00:00
Robert Osfield
02f5681180 From Roger James, "1. Fixed a problem with the caching of textures when the associated image file was not in the current working directory. In this case the texture object was being placed in the cache with the short filename, but was looked up with the full path.
2. Fixed a problem with the caching of textures when CACHE_IMAGES was enabled. This caused a conflict is the names used to cache the image and texture objects.

3. Fixed a problem where AC3D generates surfaces with duplicate vertex indices.

4. Removed what I believe are redundant calls to the tesselator.

5. Added a couple of asserts which should fire in debug mode if my assumptions about 4. are incorrect.

6. Removed obviously unused code. (Stuff that was commented or ifdeffed out.)"

Note, from Robert Osfield, changed the asserts to if () report error using notify so we can catch errors in both optimized and debug builds, but without crashing.
2006-03-08 15:16:59 +00:00
Don BURNS
582967286a Improved the GET protocol for the http socket. By adding Connection: close
the server sends a EOF immediately after the data, improving performance
because readers are not left waiting for EOF.
2006-03-07 18:26:32 +00:00
Robert Osfield
cdc8b13f14 From Farshid Lashkari, support for writing to istream for the the TIFF plugin and support for
controlling PNG compression level via the the ReaderWriter::Option string "PNG_COMPRESSION <level>"
2006-03-02 20:39:20 +00:00
Robert Osfield
8796f37acb Added automatic toggling between png and jpeg when compressImageData option is used. Jpeg
is used to compress RGB data only, the just of the formats are passed on to the png plugin.
2006-03-02 20:31:40 +00:00
Robert Osfield
507fb0074f From Farshid Lashakari, support for png write. 2006-03-02 14:58:13 +00:00
Robert Osfield
74f073c2a8 From Farshid Lashkari, "I've attached another modified version of the IVE loader which
supports compressing the image data. The option to compress the data
is "compressImageData". Currently it uses the jpeg plugin to write the
image. Maybe we could add an option that allows the user to specify
which image format to use. The jpeg writer supports specifying the
quality of the jpeg, so you could use the following command line to
convert the skydome.osg model to IVE using 50% jpeg quality:

osgconv -O "compressImageData JPEG_QUALITY 50" skydome.osg skydome.ive"
2006-03-01 10:17:53 +00:00
Robert Osfield
58bdc6f92f Added TextureRectangle.cpp 2006-02-28 21:18:45 +00:00
Robert Osfield
10d139fc1f From Farshid Lashkari, "I've made some changes to the IVE loader which will add the capability
of saving image files inside the IVE file. Currently, only the raw
image data is saved into the file. If your model uses jpg images as
textures then this will cause your file size to increase.

I've added an option that will embed the original image file into the
IVE file. The IVE file will then attempt to read the image from
memory. Since most image loaders support reading from memory, this
shouldn't be a problem. To use this new feature the user must specify
the option "includeImageFileInIVEFile" when converting to IVE.

I tested this out on the "skydome.osg" model that comes with OSG.
Using the old method, the IVE file size would be 785 KB, with the new
method it is only 42 KB.

Also, I've added the support for TextureRectangle's to the IVE reader/writer."
2006-02-26 17:45:52 +00:00
Robert Osfield
964110f315 Completed .osg support for ClusterCullingCallback. 2006-02-23 20:37:19 +00:00
Robert Osfield
ae9e0e6838 Added initial cut of ClusterCullingCallback .osg support. 2006-02-21 21:28:57 +00:00
Robert Osfield
4a0a0a30ea From Trajce Nikolov, "small fix for the flt loader - the back color of the bidirectional light points" 2006-02-21 12:39:47 +00:00
Robert Osfield
7d5c81bf5e From Ulrich Hertlein, spelling corrections and a few Doxgen comments. 2006-02-20 21:05:23 +00:00
Robert Osfield
b0358c698a From Eric Sokolowsky, "There was a problem with the PNG plugin when it encounters an image that is
less than 8 bits per pixel (this can happen with greyscale or paletted images).
It was a pretty simple problem to fix."
2006-02-20 20:06:26 +00:00
Robert Osfield
af6af82e56 From Nathan Monteleone, addition of AutoTransform support. 2006-02-20 19:13:11 +00:00
Robert Osfield
9935b0fa27 Added missing swap byte operations to readVec*sArray() methods. 2006-02-20 15:46:29 +00:00
Robert Osfield
4b8fb5e5f9 From Daniel Larimer, fixed error is swap byte code handling vector<short> 2006-02-20 15:32:03 +00:00
Don BURNS
da9de96fae Added 'normals' pseudoloader 2006-02-06 19:40:45 +00:00
Don BURNS
d4bacf93cd Changes to zip and tgz plug-ins to allow for use of TEMP variable on Windows.
Submitted by Zach Deedler
2006-01-24 17:43:53 +00:00
Robert Osfield
cc1ee1fa26 From Marco Jez, adding osgDB::findDataFile() usage. 2006-01-18 12:16:45 +00:00
Robert Osfield
fe3b68dbb1 From Marco Jez:
here is a patch that enables a new option named "BIND_TEXTURE_MAP" in the LWO plugin. Its purpose is to allow explicit binding between texture UV maps defined in the LWO file and OpenGL texture units, overriding the default mechanism that allocates texture units automatically. This is useful when you have an UV map built in Lightwave (for example an atlas map) but no textures actually using it, so you can keep the UV map (that would be discarded otherwise) and add a texture later int your program.

Syntax is:
BIND_TEXTURE_MAP <map_name> <texunit>
2006-01-18 12:13:48 +00:00
Robert Osfield
2067543aea From Maya Leonard, ERSIShape VS project file, and compile fixes for Win32. 2006-01-18 12:03:55 +00:00
Robert Osfield
eaf6c5ac35 Added new BoxPlacer files. 2006-01-17 15:18:44 +00:00
Robert Osfield
c9b25a5b50 From Zach Deedler, addition of osgParticle/BoxSpacer. 2006-01-17 15:17:15 +00:00
Robert Osfield
b5f86d9984 Added support for an externally referenced shader file, via the keyword combinations
file "shader.vert"

OR

   file shader.vert.
2005-12-21 10:32:48 +00:00
Robert Osfield
523f608ba6 From Ali Botorabi, adding of osg::Depth support in .ive format. 2005-12-19 14:48:04 +00:00
Robert Osfield
cc78197fb3 From Paul de Repentigny, ciyple fo fixes for the DXF reader. 2005-12-15 15:36:55 +00:00
Robert Osfield
fcdf5826db Added a static_cast<std::streampos> to get round IRIX64 build problem. 2005-12-02 09:57:19 +00:00
Robert Osfield
b324156ec8 From Thom DeCarlo, build fix for Cygwin. 2005-12-01 13:38:27 +00:00
Robert Osfield
f3f86973a0 Added default opening of the file as a binary file, and once the type is
confirmed then close and reopen as an ascii as required.  This is done to get
round problems under Windows.

Also made the running of the SmoothingVisitor optional, now use -O smooth to
make the loader run the osgUtil::SmoothingVisitor over the model.
2005-11-29 18:38:40 +00:00
Robert Osfield
2ce7718a66 From Eric Wing, fixes for "warning: converting of negative value '-0x00000000000000001' to 'unsigned int'" 2005-11-29 11:39:07 +00:00
Robert Osfield
a44f0cf25a From Eric Wing, warning fixes for gcc4.0/OSX. 2005-11-22 09:51:02 +00:00
Robert Osfield
8289eecb7e From Roger James, reworked the export of std::vector<> on standard types to prevent
problems with .lib being built for all targets under VS7.x
2005-11-21 13:51:24 +00:00
Robert Osfield
8dd631f4ec Replaced asserts with notification of error. 2005-11-20 22:07:43 +00:00
Robert Osfield
cb40a7361f From Donn Mielcarek, added support Materials being declared globally. 2005-11-20 22:06:16 +00:00
Robert Osfield
d0c9ef1e14 Added the ability for osgParticle::ParticleEffect to switch off the automatic setup.
Normally the automatic setup is useful, but in the case of the .osg support this automatic
update was forcing premature loading of imagery that wasn't necessarily, and can lead to
reports of looking for files that arn't present.
2005-11-18 17:04:55 +00:00
Robert Osfield
65244321b4 The OpenFlight plugin was crashing with pre 15.6 .flt files that contained
light points.  This was due to the mismatch is size and fiels in the LightPointRecord
before 15.6 and after it, the OSG's flt plugin was assuming just 15.6 record
structure.  As a temporary solution I have disabled the processing of light point
records on .flt file version before 15.6, this allows these files to be loaded
safely, but without light points.
2005-11-18 14:46:38 +00:00
Robert Osfield
7b117ada29 From Andrew Reyonolds : changed the endian conversion code to work on a temporary
rather then on a flt structure to prevent repeated conversion of the same value,
something that led to eroneously large light point string sizes.
2005-11-18 10:03:11 +00:00
Robert Osfield
d3541b96ed Replaced tabs with spaces. 2005-11-17 15:03:51 +00:00
Robert Osfield
7f19c7833e Removed redundent copyop. 2005-11-16 21:08:16 +00:00
Robert Osfield
9415f669e8 Converted remaining osg::Matrix usage to osg::Matrixd. 2005-11-16 16:30:51 +00:00
Robert Osfield
5cd39a3119 Did a unix2dos and trimmed end of file of rendundent newlines. 2005-11-15 22:14:50 +00:00
Robert Osfield
4e580f46cf From Gideon May, "I've added an alias for the new mpeg 4 format used by quicktime and
podcasts."
2005-11-15 21:24:35 +00:00
Robert Osfield
71e202cb38 Warning fixes. 2005-11-15 11:39:48 +00:00
Robert Osfield
8306efddf8 Warning fix. 2005-11-15 11:23:44 +00:00
Robert Osfield
44b38986d3 Fixed warnings in geo plugin 2005-11-14 12:49:05 +00:00
Robert Osfield
e8aeca1418 From Geoff Michel, geo plugin updated to for latest updates in .geo format. 2005-11-12 21:29:59 +00:00
Robert Osfield
35e50365da Added support for ConnectedParticleSystem. 2005-11-12 13:38:32 +00:00
Robert Osfield
ae75981e36 Added .osg support for osgParticle::SmokeTrailEffect 2005-11-12 13:27:49 +00:00
Robert Osfield
91f5b9b04e Fixes for VS6.0 build. 2005-11-11 12:45:59 +00:00
Robert Osfield
435e4b828c Fixes for dumb VS6.0 compiler 2005-11-10 19:32:37 +00:00
Robert Osfield
20d9c3c3c4 Compile fixes for VS7.1 2005-11-10 09:42:34 +00:00
Robert Osfield
6c70812928 Fixed warnings. 2005-11-09 10:41:52 +00:00
Robert Osfield
af83527622 Updated the bin number to be 100 for the logo overlay to force it to draw later. 2005-11-09 09:30:16 +00:00
Robert Osfield
a70768b6e9 Added .ive support for osg::Texture SourceFormat and SourceType 2005-11-08 16:41:34 +00:00
Robert Osfield
da7f5e7e60 Added support for SourceType and SourceFormat to .osg. 2005-11-08 16:22:33 +00:00
Robert Osfield
6ed9cb40cc From Colin McDonald, fixed image size calculation in getTotalSizeInBytesIncludingMipmaps(),
added checks on success of opening files for writing in the .ive plugin.
2005-11-08 13:51:28 +00:00
Robert Osfield
31ec432e06 From David Spilling, added "noRotation" ReaderWriter::Option into the .obj plugin
to enable disabling of the automatic rotation from Y up coordinate frame to Z up coordinate frame.
2005-11-07 14:42:36 +00:00
Robert Osfield
a3f42b480c From David Spilling, fix for typo of OVERRIDE. 2005-11-07 12:41:32 +00:00
Robert Osfield
efd96108fb From Gideon May, compile fixes for OSX. 2005-11-07 11:14:23 +00:00
Robert Osfield
2773d45f2a From Wang Lam,"The changes allow users of OpenSceneGraph to call a new function
readFontStream() to load fonts from a std::istream, rather than from the
local filesystem by name.  Such a call may be used, for example, if the
user has a font fetched over a network, or a font available in memory
without a correspondng filename.

The changes implement the new function by following the corresponding code
for readFontFile().  readFontStream() reads a stream into memory, and
holds that memory for FreeType.

As a basic test, I mangled the osgtext example to use
readFontStream(std::ifstream("font")) in lieu of a readFontFile call, and
the modified example ran completely."
2005-11-07 11:05:16 +00:00
Robert Osfield
4915259878 Improved support for texture subload/render to texture in various Texture classes
and RenderStage.
2005-11-04 12:08:16 +00:00
Robert Osfield
89b0ef09a8 Improvements to CameraNode IO support, now handles render to texture. 2005-11-03 21:35:45 +00:00
Robert Osfield
06e8ee3646 Changed the CameraNode read/write code to use Transform as its parent. 2005-11-03 19:20:04 +00:00
Robert Osfield
e7ac09153a Removed debugging message 2005-11-03 17:12:49 +00:00
Robert Osfield
40ef0bbdff Further work on osg::CameraNode support. 2005-11-03 17:08:40 +00:00
Robert Osfield
fb2d3ae108 Further work on added IO support from CameraNode. 2005-11-03 15:59:17 +00:00
Robert Osfield
9d9d6c5a12 Completed osg::CameraView support in .osg and .ive formats. 2005-11-03 12:25:25 +00:00
Robert Osfield
6562aa4f5f Added initial CameraNode and CameraView stups for the .ive loader 2005-11-03 10:16:38 +00:00
Robert Osfield
4c13328d98 Added CameraNode.cpp and CameraView.cpp 2005-11-03 09:03:46 +00:00
Robert Osfield
5dee96c14f Inital work on adding .osg support for CameraNode and CameraView. 2005-11-02 19:52:58 +00:00
Robert Osfield
df2299cb50 From Alan Ott, added support for palletted imagery. 2005-11-02 16:20:55 +00:00
Robert Osfield
781f6d3cec From Colin McDonald, "Fixes for some duplicate global symbol definitions in the plugins,
which cause errors when creating a statically linked executable."
2005-11-02 10:29:38 +00:00
Robert Osfield
030fe7d9ea From Steve Lunsford, "Attached is a copy of TXPNode.cpp with the repaired computeBounds call. I
discovered that TXPNodes were being culled out prematurely because the
loaded sub-tiles resulted in a computed bounds that was smaller than the
extents indicated in the archive.  I think this fix should be fine.  I can't
think of any reason why we would want to use anything other than the archive
extents."
2005-10-31 16:40:23 +00:00
Robert Osfield
280f50b3d9 From Don Tidrow, removed unncessary includes. 2005-10-25 09:43:37 +00:00
Robert Osfield
fe1536ebd6 Fixed compile warnings. 2005-10-24 13:46:31 +00:00
Robert Osfield
a76ae5e830 From Tony Horrobin:
"This is a small fix for flt2osg.[cpp|h] that handles
    old style road segments ( from Multigen II w/road
    tools on IRIX ) in the same way as the newer road
    constructions. ie create a group and do a nested
    traversal.

    This makes roads appear in older format files where
    there was previously a gap.  This actually works
    properly with the paths which are marked as hidden in
    the openflight database."
2005-10-24 11:37:03 +00:00
Robert Osfield
f7bd1fc456 From Don Tidrow, "I discovered that externally-referenced models in the TXP format didn't
get positioned correctly when the TXP database was built using the
'tile-offset' mode.  I've included a tarball with what I believe are the
needed changes - they work for the sample databases I have available,
but not all conditions have been tested.  I've set things up such that
these changes shouldn't affect 'normal' txp databases."
2005-10-24 11:34:12 +00:00
Robert Osfield
b5085b7799 Warning fixes for Win32 build. 2005-10-24 11:25:20 +00:00
Robert Osfield
34dd065d66 Added into CVS missing PolgonMode files. 2005-10-07 07:46:48 +00:00
Robert Osfield
808511468b From Brede Johansen, added support for PolygonMode into .ive format. 2005-10-06 15:43:29 +00:00
Robert Osfield
2092016c7b From Don Tidrow, Added support for locally referenced origins. 2005-09-27 14:48:09 +00:00
Don BURNS
e17ac7a8d9 Brede's changes for limited morphed vertex support. These changes allow
a model with morphed vertecies to load correctly with LOD switches, but
does not implement the vertex morphing.
2005-09-24 16:11:55 +00:00
Robert Osfield
d1108ea862 Added support for "-O OutputTextureFiles" options string in .osg plugin to
allow texture files to be written out when writing out a .osg file.
2005-09-19 14:07:44 +00:00
Robert Osfield
8dc8dcb95f Added querry of video size during open() call and associated allocImage to
ensure that the imagestream passed back is of a valid size.
2005-09-12 19:42:36 +00:00
Robert Osfield
d2ae4d692d From Henrique Bucher, add check against null light entry in LightPool. 2005-09-11 19:12:54 +00:00
Robert Osfield
9eaaa55d05 converted hardware tabs to spaces. 2005-09-11 19:02:20 +00:00