Compare commits
1 Commits
OpenSceneG
...
OpenSceneG
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
35b99afc49 |
49
AUTHORS.txt
49
AUTHORS.txt
@@ -1,6 +1,6 @@
|
|||||||
OpenSceneGraph Library 2.8.1
|
OpenSceneGraph Library 2.8.0
|
||||||
|
|
||||||
372 Contributors:
|
365 Contributors:
|
||||||
|
|
||||||
Firstname Surname
|
Firstname Surname
|
||||||
-----------------
|
-----------------
|
||||||
@@ -31,40 +31,39 @@ Colin McDonald
|
|||||||
Andy Skinner
|
Andy Skinner
|
||||||
Roger James
|
Roger James
|
||||||
Pavel Moloshtan
|
Pavel Moloshtan
|
||||||
Mattias Helsing
|
|
||||||
Tom Jolley
|
Tom Jolley
|
||||||
Jeremy Moles
|
Jeremy Moles
|
||||||
Jason Beverage
|
Jason Beverage
|
||||||
Norman Vine
|
Norman Vine
|
||||||
|
Mattias Helsing
|
||||||
Cedric Pinson
|
Cedric Pinson
|
||||||
Art Tevs
|
Art Tevs
|
||||||
Alberto Farre
|
Alberto Farre
|
||||||
Roland Smeenk
|
|
||||||
Michael Platings
|
|
||||||
Andr<EFBFBD> Garneau
|
Andr<EFBFBD> Garneau
|
||||||
Ruben Lopez
|
Ruben Lopez
|
||||||
|
Roland Smeenk
|
||||||
Randall Hopper
|
Randall Hopper
|
||||||
Jason Daly
|
Michael Platings
|
||||||
J.P. Delport
|
|
||||||
Adrian Egli
|
Adrian Egli
|
||||||
Olaf Flebbe
|
Olaf Flebbe
|
||||||
Mathieu Marache
|
Jason Daly
|
||||||
|
J.P. Delport
|
||||||
Gideon May
|
Gideon May
|
||||||
Don Tidrow
|
Don Tidrow
|
||||||
Sherman Wilcox
|
Sherman Wilcox
|
||||||
Romano Jos<6F> Magacho da Silva
|
Romano Jos<6F> Magacho da Silva
|
||||||
Per Fahlberg
|
Per Fahlberg
|
||||||
Michael Gronager
|
Michael Gronager
|
||||||
|
Mathieu Marache
|
||||||
Joakim Simonsson
|
Joakim Simonsson
|
||||||
David Spilling
|
David Spilling
|
||||||
Daniel Sj<53>lie
|
Daniel Sj<53>lie
|
||||||
Chris Hanson
|
Chris Hanson
|
||||||
Alberto Luaces
|
Alberto Luaces
|
||||||
Philip Lowman
|
Philip Lowman
|
||||||
Chris Denham
|
|
||||||
Melchior Franz
|
Melchior Franz
|
||||||
|
Chris Denham
|
||||||
Serge Lages
|
Serge Lages
|
||||||
Lionel Lagarde
|
|
||||||
Joran Jessurun
|
Joran Jessurun
|
||||||
Frederic Marmond
|
Frederic Marmond
|
||||||
David Fries
|
David Fries
|
||||||
@@ -77,21 +76,21 @@ Stephane Lamoliatte
|
|||||||
Sondra Iverson
|
Sondra Iverson
|
||||||
Rune Schmidt Jensen
|
Rune Schmidt Jensen
|
||||||
Rainer Oder
|
Rainer Oder
|
||||||
Neil Groves
|
|
||||||
Mike Connell
|
Mike Connell
|
||||||
Martin Aumueller
|
|
||||||
Mario Valle
|
Mario Valle
|
||||||
Gordon Tomlinson
|
Gordon Tomlinson
|
||||||
Gino van den Bergen
|
Gino van den Bergen
|
||||||
Carlo Camporesi
|
Carlo Camporesi
|
||||||
Ben Discoe
|
Ben Discoe
|
||||||
Andreas Ekstrand
|
Andreas Ekstrand
|
||||||
Thibault Genessay
|
|
||||||
Sukender
|
Sukender
|
||||||
Sasa Bistrovic
|
Sasa Bistrovic
|
||||||
|
Neil Groves
|
||||||
Martin Naylor
|
Martin Naylor
|
||||||
|
Martin Aumueller
|
||||||
Markus Trenkwalder
|
Markus Trenkwalder
|
||||||
Loic Dachary
|
Loic Dachary
|
||||||
|
Lionel Lagarde
|
||||||
Joseph Steel
|
Joseph Steel
|
||||||
John Shue
|
John Shue
|
||||||
Jan Peciva
|
Jan Peciva
|
||||||
@@ -99,6 +98,7 @@ Jan Ciger
|
|||||||
Glenn Waldron
|
Glenn Waldron
|
||||||
Brad Colbert
|
Brad Colbert
|
||||||
Vivek Rajan
|
Vivek Rajan
|
||||||
|
Thibault Genessay
|
||||||
Sean Spicer
|
Sean Spicer
|
||||||
Ravi Mathur
|
Ravi Mathur
|
||||||
Peter Hrenka
|
Peter Hrenka
|
||||||
@@ -168,7 +168,6 @@ Wang Rui
|
|||||||
Tugkan Calapoglu
|
Tugkan Calapoglu
|
||||||
Tim Daoust
|
Tim Daoust
|
||||||
Terrex
|
Terrex
|
||||||
Tanguy Fautr<74>
|
|
||||||
Sylvain Marie
|
Sylvain Marie
|
||||||
Steve Lunsford
|
Steve Lunsford
|
||||||
Stephane Simon
|
Stephane Simon
|
||||||
@@ -179,8 +178,6 @@ Sebastian Messerschmidt
|
|||||||
Ralf Kern
|
Ralf Kern
|
||||||
Pierre Haritchabalet
|
Pierre Haritchabalet
|
||||||
Perry Miller
|
Perry Miller
|
||||||
Paul Obermeier
|
|
||||||
Neil Hughes
|
|
||||||
Nathan Monteleone
|
Nathan Monteleone
|
||||||
Morn<EFBFBD> Pistorius
|
Morn<EFBFBD> Pistorius
|
||||||
Michael Henheffer
|
Michael Henheffer
|
||||||
@@ -188,7 +185,6 @@ Michael Guerrero
|
|||||||
Maya Leonard
|
Maya Leonard
|
||||||
Max Bandazian
|
Max Bandazian
|
||||||
Mathew May
|
Mathew May
|
||||||
Martin Spott
|
|
||||||
Martijn Kragtwijk
|
Martijn Kragtwijk
|
||||||
Kevin Moiule
|
Kevin Moiule
|
||||||
Keith Steffen
|
Keith Steffen
|
||||||
@@ -204,7 +200,6 @@ Gustavo Wagner
|
|||||||
Guillaume Chouvenc
|
Guillaume Chouvenc
|
||||||
Gerrick Bivins
|
Gerrick Bivins
|
||||||
George Tarantilis
|
George Tarantilis
|
||||||
Frederic Bouvier
|
|
||||||
Ferdi Smit
|
Ferdi Smit
|
||||||
Ewe Woessner
|
Ewe Woessner
|
||||||
Erik den Dekker
|
Erik den Dekker
|
||||||
@@ -235,6 +230,7 @@ Tino Schwarze
|
|||||||
Thomas Weidner
|
Thomas Weidner
|
||||||
Thom Carlo
|
Thom Carlo
|
||||||
Tery Welsh
|
Tery Welsh
|
||||||
|
Tanguy Fautr<74>
|
||||||
Steven Thomas
|
Steven Thomas
|
||||||
Simon Hammett
|
Simon Hammett
|
||||||
Sid Byce
|
Sid Byce
|
||||||
@@ -242,8 +238,6 @@ Shuxing Xiao
|
|||||||
Shane Arnott
|
Shane Arnott
|
||||||
Sebastien Kuntz
|
Sebastien Kuntz
|
||||||
Ruth Lang
|
Ruth Lang
|
||||||
Ruben Smelik
|
|
||||||
Ross Anderson
|
|
||||||
Ronny Krueger
|
Ronny Krueger
|
||||||
Robert Swain
|
Robert Swain
|
||||||
Rob Bloemkool
|
Rob Bloemkool
|
||||||
@@ -259,8 +253,8 @@ Qing Shen
|
|||||||
Piotr Rak
|
Piotr Rak
|
||||||
Philipp Siemoleit
|
Philipp Siemoleit
|
||||||
Philipp M<>chler
|
Philipp M<>chler
|
||||||
Petr Salinger
|
|
||||||
Paul Palumbo
|
Paul Palumbo
|
||||||
|
Paul Obermeier
|
||||||
Paul Fredrikson
|
Paul Fredrikson
|
||||||
Patrick Hartling
|
Patrick Hartling
|
||||||
Parag Chaudhur
|
Parag Chaudhur
|
||||||
@@ -269,6 +263,7 @@ Panagiotis Koutsourakis
|
|||||||
Orhun Birsoy
|
Orhun Birsoy
|
||||||
Ole-Morten Duesund
|
Ole-Morten Duesund
|
||||||
Nicolas Brodu
|
Nicolas Brodu
|
||||||
|
Neil Hughes
|
||||||
Nathan Cournia
|
Nathan Cournia
|
||||||
Morten Haukness
|
Morten Haukness
|
||||||
Mirko Viviani
|
Mirko Viviani
|
||||||
@@ -286,11 +281,13 @@ Matt Burke
|
|||||||
Mathia Walker
|
Mathia Walker
|
||||||
Mason Menninger
|
Mason Menninger
|
||||||
Martins Innus
|
Martins Innus
|
||||||
|
Martin Spott
|
||||||
|
Martin Amueller
|
||||||
Mario Guimaraes
|
Mario Guimaraes
|
||||||
Marin Lavery
|
Marin Lavery
|
||||||
Marco Lehmann
|
Marco Lehmann
|
||||||
Marcin Prus
|
Marcin Prus
|
||||||
Maciej Krol
|
Maceij Krol
|
||||||
Lukas Diduch
|
Lukas Diduch
|
||||||
Louis Hamilton
|
Louis Hamilton
|
||||||
Lilin Xiong
|
Lilin Xiong
|
||||||
@@ -298,7 +295,6 @@ Lewis Harmon
|
|||||||
Lars Nilson
|
Lars Nilson
|
||||||
Kyle Centers
|
Kyle Centers
|
||||||
Kristopher Bixler
|
Kristopher Bixler
|
||||||
Konstantin Sinitsyn
|
|
||||||
Karsten Weiss
|
Karsten Weiss
|
||||||
Karl Heijdenberg
|
Karl Heijdenberg
|
||||||
Jutta Sauer
|
Jutta Sauer
|
||||||
@@ -310,27 +306,24 @@ John Donovan
|
|||||||
John Davis
|
John Davis
|
||||||
John Argentieri
|
John Argentieri
|
||||||
Joan Abadie
|
Joan Abadie
|
||||||
Jeroen den Dekker
|
Jeoen den Dekker
|
||||||
Jean-Christophe Lombardo
|
Jean-Christophe Lombardo
|
||||||
Jay Zuckerman
|
Jay Zuckerman
|
||||||
Jason Howlett
|
Jason Howlett
|
||||||
Jason Ballenger
|
Jason Ballenger
|
||||||
J.E. Hoffmann
|
J.E. Hoffmann
|
||||||
Humar Carmona
|
|
||||||
Henrique Bucher
|
Henrique Bucher
|
||||||
Hautio Jari
|
Hautio Jari
|
||||||
Guillaume Millet
|
Guillaume Millet
|
||||||
Graeme Harkness
|
Graeme Harkness
|
||||||
Glen Waldron
|
|
||||||
Gian Lorenzetto
|
Gian Lorenzetto
|
||||||
George Papagiannakis
|
George Papagiannakis
|
||||||
Galen Faidley
|
Galen Faidley
|
||||||
|
Frederic Bouvier
|
||||||
Frank Warmerdam
|
Frank Warmerdam
|
||||||
Frank Midgley
|
|
||||||
Frank Lindeman
|
Frank Lindeman
|
||||||
Frank Lichtenheld
|
Frank Lichtenheld
|
||||||
Ferdinand Cornelissen
|
Ferdinand Cornelissen
|
||||||
Fajran Iman
|
|
||||||
Fabien Dachicourt
|
Fabien Dachicourt
|
||||||
Emmanuel Roche
|
Emmanuel Roche
|
||||||
Edmond Gheury
|
Edmond Gheury
|
||||||
|
|||||||
@@ -28,7 +28,7 @@ PROJECT(OpenSceneGraph)
|
|||||||
|
|
||||||
SET(OPENSCENEGRAPH_MAJOR_VERSION 2)
|
SET(OPENSCENEGRAPH_MAJOR_VERSION 2)
|
||||||
SET(OPENSCENEGRAPH_MINOR_VERSION 8)
|
SET(OPENSCENEGRAPH_MINOR_VERSION 8)
|
||||||
SET(OPENSCENEGRAPH_PATCH_VERSION 1)
|
SET(OPENSCENEGRAPH_PATCH_VERSION 0)
|
||||||
SET(OPENSCENEGRAPH_SOVERSION 55)
|
SET(OPENSCENEGRAPH_SOVERSION 55)
|
||||||
|
|
||||||
# set to 0 when not a release candidate, non zero means that any generated
|
# set to 0 when not a release candidate, non zero means that any generated
|
||||||
@@ -131,7 +131,7 @@ IF (OSG_MAINTAINER)
|
|||||||
|
|
||||||
ADD_CUSTOM_TARGET(ChangeLog
|
ADD_CUSTOM_TARGET(ChangeLog
|
||||||
COMMAND ${SVNCOMMAND} update
|
COMMAND ${SVNCOMMAND} update
|
||||||
COMMAND ${GENERATELOGS} ${SVNSOURCEDIR}
|
COMMAND ${GENERATELOGS}
|
||||||
)
|
)
|
||||||
|
|
||||||
ENDIF(OSG_MAINTAINER)
|
ENDIF(OSG_MAINTAINER)
|
||||||
|
|||||||
@@ -55,13 +55,12 @@ ENDMACRO(FIND_DEPENDENCY DEPNAME INCLUDEFILE LIBRARY_NAMES SEARCHPATHLIST DEBUGS
|
|||||||
|
|
||||||
MACRO(SEARCH_3RDPARTY OSG_3RDPARTY_BIN)
|
MACRO(SEARCH_3RDPARTY OSG_3RDPARTY_BIN)
|
||||||
FIND_DEPENDENCY(TIFF tiff.h libtiff ${OSG_3RDPARTY_BIN} "D")
|
FIND_DEPENDENCY(TIFF tiff.h libtiff ${OSG_3RDPARTY_BIN} "D")
|
||||||
FIND_DEPENDENCY(FREETYPE ft2build.h "freetype;freetype234;freetype234MT;freetype235;freetype237" ${OSG_3RDPARTY_BIN} "_D")
|
FIND_DEPENDENCY(FREETYPE ft2build.h "freetype;freetype234;freetype234MT;freetype235" ${OSG_3RDPARTY_BIN} "_D")
|
||||||
IF(FREETYPE_FOUND)
|
IF(FREETYPE_FOUND)
|
||||||
#forcing subsequent FindFreeType stuff to not search for other variables.... kind of a hack
|
#forcing subsequent FindFreeType stuff to not search for other variables.... kind of a hack
|
||||||
SET(FREETYPE_INCLUDE_DIR_ft2build ${FREETYPE_INCLUDE_DIR} CACHE PATH "" FORCE)
|
SET(FREETYPE_INCLUDE_DIR_ft2build ${FREETYPE_INCLUDE_DIR} CACHE PATH "")
|
||||||
SET(FREETYPE_INCLUDE_DIR_freetype2 ${FREETYPE_INCLUDE_DIR} CACHE PATH "" FORCE)
|
SET(FREETYPE_INCLUDE_DIR_freetype2 ${FREETYPE_INCLUDE_DIR} CACHE PATH "")
|
||||||
MARK_AS_ADVANCED(FREETYPE_INCLUDE_DIR_ft2build FREETYPE_INCLUDE_DIR_freetype2)
|
MARK_AS_ADVANCED(FREETYPE_INCLUDE_DIR_ft2build FREETYPE_INCLUDE_DIR_freetype2)
|
||||||
SET(FREETYPE_INCLUDE_DIRS "${FREETYPE_INCLUDE_DIR_ft2build};${FREETYPE_INCLUDE_DIR_freetype2}")
|
|
||||||
ENDIF(FREETYPE_FOUND)
|
ENDIF(FREETYPE_FOUND)
|
||||||
FIND_DEPENDENCY(CURL curl/curl.h "libcurl;curllib" ${OSG_3RDPARTY_BIN} "D")
|
FIND_DEPENDENCY(CURL curl/curl.h "libcurl;curllib" ${OSG_3RDPARTY_BIN} "D")
|
||||||
FIND_DEPENDENCY(JPEG jpeglib.h libjpeg ${OSG_3RDPARTY_BIN} "D")
|
FIND_DEPENDENCY(JPEG jpeglib.h libjpeg ${OSG_3RDPARTY_BIN} "D")
|
||||||
|
|||||||
@@ -13,9 +13,9 @@
|
|||||||
# require i386 so this is for the future
|
# require i386 so this is for the future
|
||||||
IF("${CMAKE_SYSTEM_PROCESSOR}" STREQUAL "i686")
|
IF("${CMAKE_SYSTEM_PROCESSOR}" STREQUAL "i686")
|
||||||
SET(SYSTEM_ARCH "i386")
|
SET(SYSTEM_ARCH "i386")
|
||||||
ELSE()
|
ELSE("${CMAKE_SYSTEM_PROCESSOR}" STREQUAL "i686")
|
||||||
SET(SYSTEM_ARCH ${CMAKE_SYSTEM_PROCESSOR})
|
SET(SYSTEM_ARCH ${CMAKE_SYSTEM_PROCESSOR})
|
||||||
ENDIF()
|
ENDIF("${CMAKE_SYSTEM_PROCESSOR}" STREQUAL "i686")
|
||||||
|
|
||||||
# set a default system name - use CMake setting (Linux|Windows|...)
|
# set a default system name - use CMake setting (Linux|Windows|...)
|
||||||
SET(SYSTEM_NAME ${CMAKE_SYSTEM_NAME})
|
SET(SYSTEM_NAME ${CMAKE_SYSTEM_NAME})
|
||||||
@@ -26,34 +26,30 @@ SET(SYSTEM_NAME ${CMAKE_SYSTEM_NAME})
|
|||||||
IF(MSVC)
|
IF(MSVC)
|
||||||
IF(CMAKE_CL_64)
|
IF(CMAKE_CL_64)
|
||||||
SET(SYSTEM_NAME "win64")
|
SET(SYSTEM_NAME "win64")
|
||||||
ELSE()
|
ELSE(CMAKE_CL_64)
|
||||||
SET(SYSTEM_NAME "win32")
|
SET(SYSTEM_NAME "win32")
|
||||||
ENDIF()
|
ENDIF(CMAKE_CL_64)
|
||||||
ENDIF()
|
ENDIF(MSVC)
|
||||||
# Guess the compiler (is this desired for other platforms than windows?)
|
# Guess the compiler (is this desired for other platforms than windows?)
|
||||||
IF(NOT DEFINED OSG_CPACK_COMPILER)
|
IF(NOT DEFINED OSG_CPACK_COMPILER)
|
||||||
INCLUDE(OsgDetermineCompiler)
|
INCLUDE(OsgDetermineCompiler)
|
||||||
ENDIF()
|
ENDIF(NOT DEFINED OSG_CPACK_COMPILER)
|
||||||
|
|
||||||
# expose the compiler setting to the user
|
# expose the compiler setting to the user
|
||||||
SET(OSG_CPACK_COMPILER "${OSG_COMPILER}" CACHE STRING "This ia short string (vc90, vc80sp1, gcc-4.3, ...) describing your compiler. The string is used for creating package filenames")
|
SET(OSG_CPACK_COMPILER "${OSG_COMPILER}" CACHE STRING "This ia short string (vc90, vc80sp1, gcc-4.3, ...) describing your compiler. The string is used for creating package filenames")
|
||||||
|
|
||||||
IF(OSG_CPACK_COMPILER)
|
IF(OSG_CPACK_COMPILER)
|
||||||
SET(OSG_CPACK_SYSTEM_SPEC_STRING ${SYSTEM_NAME}-${SYSTEM_ARCH}-${OSG_CPACK_COMPILER})
|
SET(OSG_CPACK_SYSTEM_SPEC_STRING ${SYSTEM_NAME}-${SYSTEM_ARCH}-${OSG_CPACK_COMPILER})
|
||||||
ELSE()
|
ELSE(OSG_CPACK_COMPILER)
|
||||||
SET(OSG_CPACK_SYSTEM_SPEC_STRING ${SYSTEM_NAME}-${SYSTEM_ARCH})
|
SET(OSG_CPACK_SYSTEM_SPEC_STRING ${SYSTEM_NAME}-${SYSTEM_ARCH})
|
||||||
ENDIF()
|
ENDIF(OSG_CPACK_COMPILER)
|
||||||
|
|
||||||
|
|
||||||
## variables that apply to all packages
|
## variables that apply to all packages
|
||||||
SET(CPACK_PACKAGE_FILE_NAME "${CMAKE_PROJECT_NAME}-${OPENSCENEGRAPH_VERSION}")
|
SET(CPACK_PACKAGE_FILE_NAME "${CMAKE_PROJECT_NAME}-${OPENSCENEGRAPH_VERSION}")
|
||||||
|
|
||||||
# these goes for all platforms. Setting these stops the CPack.cmake script from generating options about other package compression formats (.z .tz, etc.)
|
# these goes for all platforms. Setting these stops the CPack.cmake script from generating options about other package compression formats (.z .tz, etc.)
|
||||||
IF(WIN32)
|
SET(CPACK_GENERATOR "TGZ")
|
||||||
SET(CPACK_GENERATOR "ZIP")
|
|
||||||
ELSE()
|
|
||||||
SET(CPACK_GENERATOR "TGZ")
|
|
||||||
ENDIF()
|
|
||||||
SET(CPACK_SOURCE_GENERATOR "TGZ")
|
SET(CPACK_SOURCE_GENERATOR "TGZ")
|
||||||
|
|
||||||
|
|
||||||
@@ -61,15 +57,15 @@ SET(CPACK_SOURCE_GENERATOR "TGZ")
|
|||||||
IF(MSVC_IDE)
|
IF(MSVC_IDE)
|
||||||
SET(OSG_CPACK_CONFIGURATION "$(OutDir)")
|
SET(OSG_CPACK_CONFIGURATION "$(OutDir)")
|
||||||
SET(PACKAGE_TARGET_PREFIX "Package ")
|
SET(PACKAGE_TARGET_PREFIX "Package ")
|
||||||
ELSE()
|
ELSE(MSVC_IDE)
|
||||||
# on un*x an empty CMAKE_BUILD_TYPE means release
|
# on un*x an empty CMAKE_BUILD_TYPE means release
|
||||||
IF(CMAKE_BUILD_TYPE)
|
IF(CMAKE_BUILD_TYPE)
|
||||||
SET(OSG_CPACK_CONFIGURATION ${CMAKE_BUILD_TYPE})
|
SET(OSG_CPACK_CONFIGURATION ${CMAKE_BUILD_TYPE})
|
||||||
ELSE()
|
ELSE(CMAKE_BUILD_TYPE)
|
||||||
SET(OSG_CPACK_CONFIGURATION "Release")
|
SET(OSG_CPACK_CONFIGURATION "Release")
|
||||||
ENDIF()
|
ENDIF(CMAKE_BUILD_TYPE)
|
||||||
SET(PACKAGE_TARGET_PREFIX "package_")
|
SET(PACKAGE_TARGET_PREFIX "package_")
|
||||||
ENDIF()
|
ENDIF(MSVC_IDE)
|
||||||
|
|
||||||
# Get all defined components
|
# Get all defined components
|
||||||
GET_CMAKE_PROPERTY(CPACK_COMPONENTS_ALL COMPONENTS)
|
GET_CMAKE_PROPERTY(CPACK_COMPONENTS_ALL COMPONENTS)
|
||||||
@@ -78,7 +74,7 @@ IF(NOT CPACK_COMPONENTS_ALL)
|
|||||||
# I set it manually to be the packages that can always be packaged
|
# I set it manually to be the packages that can always be packaged
|
||||||
MESSAGE("When building packages please consider using cmake version 2.6.1 or above")
|
MESSAGE("When building packages please consider using cmake version 2.6.1 or above")
|
||||||
SET(CPACK_COMPONENTS_ALL libopenscenegraph libopenthreads openscenegraph libopenscenegraph-dev libopenthreads-dev)
|
SET(CPACK_COMPONENTS_ALL libopenscenegraph libopenthreads openscenegraph libopenscenegraph-dev libopenthreads-dev)
|
||||||
ENDIF()
|
ENDIF(NOT CPACK_COMPONENTS_ALL)
|
||||||
|
|
||||||
# Create a target that will be used to generate all packages defined below
|
# Create a target that will be used to generate all packages defined below
|
||||||
SET(PACKAGE_ALL_TARGETNAME "${PACKAGE_TARGET_PREFIX}ALL")
|
SET(PACKAGE_ALL_TARGETNAME "${PACKAGE_TARGET_PREFIX}ALL")
|
||||||
@@ -90,12 +86,12 @@ MACRO(GENERATE_PACKAGING_TARGET package_name)
|
|||||||
# the doc packages don't need a system-arch specification
|
# the doc packages don't need a system-arch specification
|
||||||
IF(${package} MATCHES -doc)
|
IF(${package} MATCHES -doc)
|
||||||
SET(OSG_PACKAGE_FILE_NAME ${package_name}-${OPENSCENEGRAPH_VERSION})
|
SET(OSG_PACKAGE_FILE_NAME ${package_name}-${OPENSCENEGRAPH_VERSION})
|
||||||
ELSE()
|
ELSE(${package} MATCHES -doc)
|
||||||
SET(OSG_PACKAGE_FILE_NAME ${package_name}-${OPENSCENEGRAPH_VERSION}-${OSG_CPACK_SYSTEM_SPEC_STRING}-${OSG_CPACK_CONFIGURATION})
|
SET(OSG_PACKAGE_FILE_NAME ${package_name}-${OPENSCENEGRAPH_VERSION}-${OSG_CPACK_SYSTEM_SPEC_STRING}-${OSG_CPACK_CONFIGURATION})
|
||||||
IF(NOT DYNAMIC_OPENSCENEGRAPH)
|
IF(NOT DYNAMIC_OPENSCENEGRAPH)
|
||||||
SET(OSG_PACKAGE_FILE_NAME ${OSG_PACKAGE_FILE_NAME}-static)
|
SET(OSG_PACKAGE_FILE_NAME ${OSG_PACKAGE_FILE_NAME}-static)
|
||||||
ENDIF()
|
ENDIF(NOT DYNAMIC_OPENSCENEGRAPH)
|
||||||
ENDIF()
|
ENDIF(${package} MATCHES -doc)
|
||||||
|
|
||||||
CONFIGURE_FILE("${OpenSceneGraph_SOURCE_DIR}/CMakeModules/OsgCPackConfig.cmake.in" "${OpenSceneGraph_BINARY_DIR}/CPackConfig-${package_name}.cmake" IMMEDIATE)
|
CONFIGURE_FILE("${OpenSceneGraph_SOURCE_DIR}/CMakeModules/OsgCPackConfig.cmake.in" "${OpenSceneGraph_BINARY_DIR}/CPackConfig-${package_name}.cmake" IMMEDIATE)
|
||||||
|
|
||||||
@@ -104,32 +100,25 @@ MACRO(GENERATE_PACKAGING_TARGET package_name)
|
|||||||
# This is naive and will probably need fixing eventually
|
# This is naive and will probably need fixing eventually
|
||||||
IF(MSVC)
|
IF(MSVC)
|
||||||
SET(MOVE_COMMAND "move")
|
SET(MOVE_COMMAND "move")
|
||||||
ELSE()
|
ELSE(MSVC)
|
||||||
SET(MOVE_COMMAND "mv")
|
SET(MOVE_COMMAND "mv")
|
||||||
ENDIF()
|
ENDIF(MSVC)
|
||||||
|
|
||||||
# Set in and out archive filenames. Windows = zip, others = tar.gz
|
|
||||||
IF(WIN32)
|
|
||||||
SET(ARCHIVE_EXT "zip")
|
|
||||||
ELSE()
|
|
||||||
SET(ARCHIVE_EXT "tar.gz")
|
|
||||||
ENDIF()
|
|
||||||
|
|
||||||
# Create a target that creates the current package
|
# Create a target that creates the current package
|
||||||
# and rename the package to give it proper filename
|
# and rename the package to give it proper filename
|
||||||
ADD_CUSTOM_TARGET(${PACKAGE_TARGETNAME})
|
ADD_CUSTOM_TARGET(${PACKAGE_TARGETNAME})
|
||||||
ADD_CUSTOM_COMMAND(TARGET ${PACKAGE_TARGETNAME}
|
ADD_CUSTOM_COMMAND(TARGET ${PACKAGE_TARGETNAME}
|
||||||
COMMAND ${CMAKE_CPACK_COMMAND} -C ${OSG_CPACK_CONFIGURATION} --config ${OpenSceneGraph_BINARY_DIR}/CPackConfig-${package_name}.cmake
|
COMMAND ${CMAKE_CPACK_COMMAND} -C ${OSG_CPACK_CONFIGURATION} --config ${OpenSceneGraph_BINARY_DIR}/CPackConfig-${package_name}.cmake
|
||||||
COMMAND "${MOVE_COMMAND}" "${CPACK_PACKAGE_FILE_NAME}.${ARCHIVE_EXT}" "${OSG_PACKAGE_FILE_NAME}.${ARCHIVE_EXT}"
|
COMMAND "${MOVE_COMMAND}" "${CPACK_PACKAGE_FILE_NAME}.tar.gz" "${OSG_PACKAGE_FILE_NAME}.tar.gz"
|
||||||
COMMAND ${CMAKE_COMMAND} -E echo "renamed ${CPACK_PACKAGE_FILE_NAME}.${ARCHIVE_EXT} -> ${OSG_PACKAGE_FILE_NAME}.${ARCHIVE_EXT}"
|
COMMAND ${CMAKE_COMMAND} -E echo "renamed ${CPACK_PACKAGE_FILE_NAME}.tar.gz -> ${OSG_PACKAGE_FILE_NAME}.tar.gz"
|
||||||
COMMENT "Run CPack packaging for ${package_name}..."
|
COMMENT "Run CPack packaging for ${package_name}..."
|
||||||
)
|
)
|
||||||
# Add the exact same custom command to the all package generating target.
|
# Add the exact same custom command to the all package generating target.
|
||||||
# I can't use add_dependencies to do this because it would allow parallell building of packages so am going brute here
|
# I can't use add_dependencies to do this because it would allow parallell building of packages so am going brute here
|
||||||
ADD_CUSTOM_COMMAND(TARGET ${PACKAGE_ALL_TARGETNAME}
|
ADD_CUSTOM_COMMAND(TARGET ${PACKAGE_ALL_TARGETNAME}
|
||||||
COMMAND ${CMAKE_CPACK_COMMAND} -C ${OSG_CPACK_CONFIGURATION} --config ${OpenSceneGraph_BINARY_DIR}/CPackConfig-${package_name}.cmake
|
COMMAND ${CMAKE_CPACK_COMMAND} -C ${OSG_CPACK_CONFIGURATION} --config ${OpenSceneGraph_BINARY_DIR}/CPackConfig-${package_name}.cmake
|
||||||
COMMAND "${MOVE_COMMAND}" "${CPACK_PACKAGE_FILE_NAME}.${ARCHIVE_EXT}" "${OSG_PACKAGE_FILE_NAME}.${ARCHIVE_EXT}"
|
COMMAND "${MOVE_COMMAND}" "${CPACK_PACKAGE_FILE_NAME}.tar.gz" "${OSG_PACKAGE_FILE_NAME}.tar.gz"
|
||||||
COMMAND ${CMAKE_COMMAND} -E echo "renamed ${CPACK_PACKAGE_FILE_NAME}.${ARCHIVE_EXT} -> ${OSG_PACKAGE_FILE_NAME}.${ARCHIVE_EXT}"
|
COMMAND ${CMAKE_COMMAND} -E echo "renamed ${CPACK_PACKAGE_FILE_NAME}.tar.gz -> ${OSG_PACKAGE_FILE_NAME}.tar.gz"
|
||||||
)
|
)
|
||||||
ENDMACRO(GENERATE_PACKAGING_TARGET)
|
ENDMACRO(GENERATE_PACKAGING_TARGET)
|
||||||
|
|
||||||
@@ -141,4 +130,4 @@ GENERATE_PACKAGING_TARGET(openscenegraph-all)
|
|||||||
FOREACH(package ${CPACK_COMPONENTS_ALL})
|
FOREACH(package ${CPACK_COMPONENTS_ALL})
|
||||||
SET(OSG_CPACK_COMPONENT ${package})
|
SET(OSG_CPACK_COMPONENT ${package})
|
||||||
GENERATE_PACKAGING_TARGET(${package})
|
GENERATE_PACKAGING_TARGET(${package})
|
||||||
ENDFOREACH()
|
ENDFOREACH(package ${CPACK_COMPONENTS_ALL})
|
||||||
|
|||||||
718
ChangeLog
718
ChangeLog
@@ -1,721 +1,3 @@
|
|||||||
2009-05-19 16:05 robert
|
|
||||||
|
|
||||||
* CMakeLists.txt, NEWS.txt, README.txt: Updated dates and reset
|
|
||||||
release candidate back to 0 for final 2.8.1 release
|
|
||||||
|
|
||||||
2009-05-18 16:02 robert
|
|
||||||
|
|
||||||
* AUTHORS.txt, CMakeLists.txt, ChangeLog, NEWS.txt, README.txt:
|
|
||||||
Updated ChangeLog, NEWS, README and AUTHORS files for rc5.
|
|
||||||
|
|
||||||
2009-05-18 15:49 robert
|
|
||||||
|
|
||||||
* src/osgUtil/RenderStage.cpp: Merged changed from svn/trunk,
|
|
||||||
improving the reliability of the clear of the stencil and depth
|
|
||||||
buffer.
|
|
||||||
|
|
||||||
2009-05-18 14:53 robert
|
|
||||||
|
|
||||||
* include/osg, include/osg/BoundingSphere, include/osg/ImageUtils,
|
|
||||||
include/osg/Vec2b, include/osg/Vec3b, include/osg/Vec4b,
|
|
||||||
include/osg/Vec4ub, src/osgWrappers/osg/Vec2b.cpp,
|
|
||||||
src/osgWrappers/osg/Vec3b.cpp, src/osgWrappers/osg/Vec4b.cpp,
|
|
||||||
src/osgWrappers/osg/Vec4ub.cpp: From Paul Obermeier, "Please find
|
|
||||||
enclosed some changed OSG header files.
|
|
||||||
The changes are more or less just beautifications
|
|
||||||
(when looked at them from the C++ view), but make
|
|
||||||
wrapping OSG with SWIG easier.
|
|
||||||
I have tested the changes with both 2.8.1-rc4 and the
|
|
||||||
current head and would appreciate to incorporate the
|
|
||||||
changes in both branches.
|
|
||||||
|
|
||||||
Here is a description of the changes:
|
|
||||||
|
|
||||||
osg/BoundingSphere:
|
|
||||||
Use the following typedef (like used in BoundingBox)
|
|
||||||
typedef typename VT::value_type value_type;
|
|
||||||
instead of
|
|
||||||
typedef typename vec_type::value_type value_type;
|
|
||||||
|
|
||||||
SWIG reports errors on the latter construct.
|
|
||||||
Also makes it consistent with BoundingBox.
|
|
||||||
|
|
||||||
|
|
||||||
osg/Vec4ub:
|
|
||||||
Consistent use of "value_type" throughout the file.
|
|
||||||
|
|
||||||
|
|
||||||
osg/Vec?b:
|
|
||||||
Consistent use of "value_type" throughout the files.
|
|
||||||
|
|
||||||
Also changed
|
|
||||||
typedef char value_type;
|
|
||||||
to
|
|
||||||
typedef signed char value_type;
|
|
||||||
|
|
||||||
In the case of a simple "char", SWIG assumes a string.
|
|
||||||
Using "signed char" instead of "char" does not change
|
|
||||||
the behaviour of the class."
|
|
||||||
|
|
||||||
2009-05-18 12:56 robert
|
|
||||||
|
|
||||||
* src/osgTerrain, src/osgTerrain/Layer.cpp: From Ross Anderson,
|
|
||||||
"Symptom: The computation of TerrainTiles containing only image
|
|
||||||
layers (no elevation layer) is incorrect. The resulting bounding
|
|
||||||
sphere will always have a radius of zero.
|
|
||||||
|
|
||||||
The fix is to remove the call to bs.expandBy(v) and compute the
|
|
||||||
radius directly. I believe this call was intended to be
|
|
||||||
bs.expandRadiusBy(v), but it is superfluous when the radius is
|
|
||||||
computed directly.
|
|
||||||
"
|
|
||||||
|
|
||||||
Merged from svn/trunk using:
|
|
||||||
|
|
||||||
svn merge -r 10229:10230
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osgTerrain
|
|
||||||
|
|
||||||
2009-05-15 15:13 robert
|
|
||||||
|
|
||||||
* src/osgPlugins/curl, src/osgPlugins/curl/ReaderWriterCURL.cpp:
|
|
||||||
Merged from svn/trunk libcurl version checks to enable build
|
|
||||||
against older versions of libcurl.
|
|
||||||
|
|
||||||
svn merge -r 10221:10222
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osgPlugins/curl/
|
|
||||||
|
|
||||||
2009-05-15 12:37 robert
|
|
||||||
|
|
||||||
* src/OpenThreads/pthreads, src/OpenThreads/pthreads/PThread.c++:
|
|
||||||
Removed redundent errno and version string declaration
|
|
||||||
|
|
||||||
2009-05-15 09:25 robert
|
|
||||||
|
|
||||||
* ChangeLog, NEWS.txt, README.txt: Updated ChangeLog and dates for
|
|
||||||
2.8.0-rc4
|
|
||||||
|
|
||||||
2009-05-14 17:26 robert
|
|
||||||
|
|
||||||
* NEWS.txt, README.txt: Updated dates
|
|
||||||
|
|
||||||
2009-05-14 17:25 robert
|
|
||||||
|
|
||||||
* AUTHORS.txt, ChangeLog: Updated ChangeLog and AUTHOR file
|
|
||||||
|
|
||||||
2009-05-14 17:18 robert
|
|
||||||
|
|
||||||
* applications/osgversion/CMakeLists.txt,
|
|
||||||
applications/osgversion/Contributors.cpp,
|
|
||||||
applications/osgversion/osgversion.cpp: Moved the Contributors
|
|
||||||
generation code out into a separate source file that is only
|
|
||||||
compiled when OSG_MAINTAINER is enable via ccamke. This has been
|
|
||||||
done to prevent build issues on some machines with compilers that
|
|
||||||
chose a different local to the one that the contributors names
|
|
||||||
are encoded.
|
|
||||||
|
|
||||||
2009-05-13 08:35 robert
|
|
||||||
|
|
||||||
* src/OpenThreads/win32, src/OpenThreads/win32/Win32Thread.cpp:
|
|
||||||
From Thibault Genessay, "On Windows, when a process tries to
|
|
||||||
spawn one too many thread,
|
|
||||||
_beginthreadex() fails but OpenThreads still waits on the startup
|
|
||||||
Block before returning to the caller of
|
|
||||||
OpenThreads::Thread::start().
|
|
||||||
This causes a deadlock. The return value of _beginthreadex() is
|
|
||||||
actually checked, but after the call to
|
|
||||||
OpenThreads::Block::block() so
|
|
||||||
it is basically useless.
|
|
||||||
|
|
||||||
Attached is a fix to move the check for the return value of
|
|
||||||
_beginthreadex() before the call to block(), so that start() can
|
|
||||||
return to the caller with a non-zero error code. This solves the
|
|
||||||
problem for me."
|
|
||||||
|
|
||||||
Merged from svn trunk using:
|
|
||||||
|
|
||||||
svn merge -r 10190:10191
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/OpenThreads/win32
|
|
||||||
|
|
||||||
2009-05-12 11:15 robert
|
|
||||||
|
|
||||||
* ChangeLog, NEWS.txt, README.txt: Updated ChangeLog and
|
|
||||||
NEWS/READER for release candidate
|
|
||||||
|
|
||||||
2009-05-12 11:12 robert
|
|
||||||
|
|
||||||
* src/osgWrappers/osgUtil/IntersectVisitor.cpp: Updated wrappers
|
|
||||||
|
|
||||||
2009-05-12 10:49 robert
|
|
||||||
|
|
||||||
* src/osgWidget, src/osgWidget/WindowManager.cpp: From Fajran Iman
|
|
||||||
Rusadi, fixed to handling of widget indices in insert and remove
|
|
||||||
methods. Merged from svn/trunk using:
|
|
||||||
|
|
||||||
svn merge -r 10181:10182
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osgWidget
|
|
||||||
|
|
||||||
2009-05-08 12:38 robert
|
|
||||||
|
|
||||||
* src/osgViewer/GraphicsWindowWin32.cpp: Added initializer for
|
|
||||||
_mouseCursor
|
|
||||||
|
|
||||||
2009-05-08 07:49 robert
|
|
||||||
|
|
||||||
* src/osgViewer/GraphicsWindowWin32.cpp: From Neil Groves, fixed
|
|
||||||
unitialized variable
|
|
||||||
|
|
||||||
2009-05-07 15:59 robert
|
|
||||||
|
|
||||||
* CMakeLists.txt: Updated release candidate to 4.
|
|
||||||
|
|
||||||
2009-05-07 15:14 robert
|
|
||||||
|
|
||||||
* src/osgViewer/GraphicsWindowWin32.cpp: From Frederic Bouvier,
|
|
||||||
workaround of setCursor problems under Windows.
|
|
||||||
|
|
||||||
2009-05-07 14:58 robert
|
|
||||||
|
|
||||||
* src/osg/GraphicsContext.cpp: Fixed ABSOLUTE_RF slave camera
|
|
||||||
resize policy, merged from svn trunk using:
|
|
||||||
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/
|
|
||||||
|
|
||||||
2009-05-07 13:24 robert
|
|
||||||
|
|
||||||
* src/osgDB, src/osgDB/CMakeLists.txt, src/osgDB/DatabasePager.cpp,
|
|
||||||
src/osgDB/Registry.cpp: From Stephan Huber, "while debugging a
|
|
||||||
problem in finding plugins on OS X I discovered, that
|
|
||||||
the conditional directives for setting the prepend-string in
|
|
||||||
createLibraryNameForExtension were not in effect, because of the
|
|
||||||
mixture
|
|
||||||
of different #ifdef styles.
|
|
||||||
|
|
||||||
I removed the conditional part for __APPLE__ completely to be
|
|
||||||
more
|
|
||||||
standard-conform with other platforms (plugins should be located
|
|
||||||
in
|
|
||||||
osgPlugins-X.X.X/). Because of the wrong syntax of the
|
|
||||||
conditional
|
|
||||||
compile the old code was not used anyway -- so no functional
|
|
||||||
change.
|
|
||||||
"
|
|
||||||
|
|
||||||
Merged from svn/trunk using:
|
|
||||||
|
|
||||||
svn merge -r 10149:10150
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osgDB
|
|
||||||
|
|
||||||
2009-05-07 13:18 robert
|
|
||||||
|
|
||||||
* src/osgViewer, src/osgViewer/GraphicsWindowWin32.cpp: From Chris
|
|
||||||
Denham, fix for swapBuffers warning when window is minimized
|
|
||||||
under Windows.
|
|
||||||
|
|
||||||
|
|
||||||
svn merge -r 10146:10147
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osgViewer/
|
|
||||||
|
|
||||||
2009-05-07 09:47 robert
|
|
||||||
|
|
||||||
* src/osgPlugins/pdf, src/osgPlugins/pdf/CMakeLists.txt: Fixed name
|
|
||||||
of POPPLER_LIBRARY_DIRS, merged from svn trunk using svn merge -r
|
|
||||||
10143:10144
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osgPlugins/pdf
|
|
||||||
|
|
||||||
2009-05-05 12:56 robert
|
|
||||||
|
|
||||||
* src/osgPlugins/osgVolume,
|
|
||||||
src/osgPlugins/osgVolume/ImageLayer.cpp,
|
|
||||||
src/osgPlugins/osgVolume/RayTracedTechnique.cpp: Merged from
|
|
||||||
svn/trunk support for searching for imagery in path relative to
|
|
||||||
the .osg file being loaded. Merged using:
|
|
||||||
|
|
||||||
svn merge -r 10100:10137
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osgPlugins/osgVolume
|
|
||||||
|
|
||||||
2009-05-05 12:54 robert
|
|
||||||
|
|
||||||
* src/osgVolume, src/osgVolume/FixedFunctionTechnique.cpp,
|
|
||||||
src/osgVolume/RayTracedTechnique.cpp,
|
|
||||||
src/osgVolume/Shaders/volume_iso_frag.cpp,
|
|
||||||
src/osgVolume/VolumeTile.cpp: Merged improvements to osgVolume
|
|
||||||
from svn/trunk using :
|
|
||||||
|
|
||||||
svn merge -r 10100:10137
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osgVolume
|
|
||||||
|
|
||||||
2009-04-24 17:52 robert
|
|
||||||
|
|
||||||
* include/osgUtil/IntersectVisitor: Changed doxygen docs to
|
|
||||||
indicate deprecated status with suggestion of IntersectionVisitor
|
|
||||||
instead.
|
|
||||||
|
|
||||||
2009-04-24 10:56 robert
|
|
||||||
|
|
||||||
* src/osgPlugins/mdl, src/osgPlugins/mdl/VTXReader.cpp: 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)."
|
|
||||||
|
|
||||||
merged from svn/trunk using:
|
|
||||||
|
|
||||||
svn merge -r 10092:10093
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osgPlugins/mdl/
|
|
||||||
|
|
||||||
2009-04-23 15:11 robert
|
|
||||||
|
|
||||||
* NEWS.txt: Fixed typo
|
|
||||||
|
|
||||||
2009-04-23 13:46 robert
|
|
||||||
|
|
||||||
* AUTHORS.txt, ChangeLog, NEWS.txt, README.txt: Update ChnageLog,
|
|
||||||
dates and authors for 2.8.1-rc3
|
|
||||||
|
|
||||||
2009-04-23 13:27 robert
|
|
||||||
|
|
||||||
* CMakeLists.txt: Updated release candidate number
|
|
||||||
|
|
||||||
2009-04-23 11:08 robert
|
|
||||||
|
|
||||||
* src/osgPlugins/OpenFlight,
|
|
||||||
src/osgPlugins/OpenFlight/Document.cpp,
|
|
||||||
src/osgPlugins/OpenFlight/Document.h,
|
|
||||||
src/osgPlugins/OpenFlight/GeometryRecords.cpp: Fix to handling of
|
|
||||||
subsurface layers so that more appropriate PolygonOffset values
|
|
||||||
are chosen. Merged from svn/trunk using:
|
|
||||||
|
|
||||||
svn merge -r 10083:10084
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osgPlugins/OpenFlight/
|
|
||||||
|
|
||||||
2009-04-23 11:07 robert
|
|
||||||
|
|
||||||
* src/osg/PolygonOffset.cpp: Merged from svn trunk using:
|
|
||||||
|
|
||||||
svn merge -r 10082:10083
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osg/PolygonOffset.cpp
|
|
||||||
|
|
||||||
2009-04-22 13:54 robert
|
|
||||||
|
|
||||||
* applications/osgversion/osgversion.cpp: Fixed typo.
|
|
||||||
|
|
||||||
2009-04-22 13:09 robert
|
|
||||||
|
|
||||||
* src/osgPlugins/dae/daeWriter.h: 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 10:56 robert
|
|
||||||
|
|
||||||
* examples, examples/osgcluster/broadcaster.cpp,
|
|
||||||
examples/osgmanipulator/osgmanipulator.cpp,
|
|
||||||
examples/osgscreencapture/osgscreencapture.cpp: From Paul Martz,
|
|
||||||
"Looks like the people who created these two examples were a bit
|
|
||||||
careless with cut and paste."
|
|
||||||
|
|
||||||
Merged from svn/trunk using:
|
|
||||||
|
|
||||||
svn merge -r 10063:10064
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/examples/
|
|
||||||
|
|
||||||
2009-04-22 10:49 robert
|
|
||||||
|
|
||||||
* src/osg/Image.cpp: From Eric Sokolowsky, "src/osg/Image.cpp is
|
|
||||||
missing the GL_RGBA8 image type when calculating the number of
|
|
||||||
components in an image. It is added here."
|
|
||||||
|
|
||||||
Merged from svn trunk using:
|
|
||||||
|
|
||||||
svn merge -r 10061:10062
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osg/Image.cpp
|
|
||||||
|
|
||||||
2009-04-21 10:20 robert
|
|
||||||
|
|
||||||
* src/osgDB/DatabasePager.cpp: Fix for handling case of no graphics
|
|
||||||
contexts being registered.
|
|
||||||
|
|
||||||
Merged from svn/trunk using:
|
|
||||||
svn merge -r 10053:10054
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osgDB/DatabasePager.cpp
|
|
||||||
|
|
||||||
2009-04-12 18:58 robert
|
|
||||||
|
|
||||||
* CMakeLists.txt, NEWS.txt, README.txt: Updated dates for 2.8.1-rc2
|
|
||||||
|
|
||||||
2009-04-12 18:53 robert
|
|
||||||
|
|
||||||
* CMakeLists.txt, ChangeLog,
|
|
||||||
applications/osgversion/osgversion.cpp: Updated CMakeLists.txt
|
|
||||||
ChangeLog generator so that it tracks the current branch or
|
|
||||||
svn/trunk to prevent branches generating logs for svn/trunk.
|
|
||||||
|
|
||||||
Updated osgversion's authors mapping.
|
|
||||||
|
|
||||||
Updated ChangeLog.
|
|
||||||
|
|
||||||
2009-04-12 10:29 robert
|
|
||||||
|
|
||||||
* src/osg/GraphicsThread.cpp: Added release from svn/trunk to
|
|
||||||
enable osgCompute.
|
|
||||||
|
|
||||||
2009-04-10 21:25 robert
|
|
||||||
|
|
||||||
* NEWS.txt: Updated NEWS for 2.8.1-rc1
|
|
||||||
|
|
||||||
2009-04-10 14:35 robert
|
|
||||||
|
|
||||||
* README.txt: UPdated date
|
|
||||||
|
|
||||||
2009-04-10 12:56 robert
|
|
||||||
|
|
||||||
* AUTHORS.txt, ChangeLog: Update ChangeLog and AUTHORS.txt file for
|
|
||||||
2.8.1-rc1
|
|
||||||
|
|
||||||
2009-04-10 12:54 robert
|
|
||||||
|
|
||||||
* applications/osgversion/osgversion.cpp: Merged changes from
|
|
||||||
svn/trunk
|
|
||||||
|
|
||||||
2009-04-10 10:58 robert
|
|
||||||
|
|
||||||
* CMakeLists.txt, include/osg/Version: Updater version numbers to
|
|
||||||
2.8.1-rc1
|
|
||||||
|
|
||||||
2009-04-10 09:43 robert
|
|
||||||
|
|
||||||
* LICENSE.txt: From J.P. Delport, spelling and grammer fixes
|
|
||||||
|
|
||||||
2009-04-09 15:56 robert
|
|
||||||
|
|
||||||
* CMakeModules/OsgCPack.cmake: From Mattias Helsing, "
|
|
||||||
* Use the CPack ZIP generator on windows (WIN32)
|
|
||||||
* Reformatted according to Philip Lowman's recent submissions"
|
|
||||||
|
|
||||||
2009-04-08 10:50 robert
|
|
||||||
|
|
||||||
* src/osgUtil/Optimizer.cpp: From Glen Waldron, "Attached is a
|
|
||||||
patch for osgUtil::Optimizer. If you run the
|
|
||||||
SpatializeGroupsVisitor on a scene graph containing Geodes,
|
|
||||||
StateSets attached to Geodes can be lost.
|
|
||||||
|
|
||||||
The problem is in SpatializeGroupsVisitor::divide(osg::Geode*,
|
|
||||||
unsigned int) where the code creates a new Group and divides up
|
|
||||||
the input Geode into one Geode per Drawable.
|
|
||||||
|
|
||||||
I fixed the problem by assigning the Geode's stateset to the new
|
|
||||||
parent group.
|
|
||||||
|
|
||||||
To replicate the bug, see attached osg/dds files:
|
|
||||||
|
|
||||||
osgviewer b.osg -- model renders correctly
|
|
||||||
set OSG_OPTIMIZER="SPATIALIZE_GROUPS"
|
|
||||||
osgviewer b.osg -- textures are missing."
|
|
||||||
|
|
||||||
Merged from svn/trunk using:
|
|
||||||
|
|
||||||
svn merge -r 9986:9987
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osgUtil/Optimizer.cpp
|
|
||||||
|
|
||||||
2009-04-06 12:29 robert
|
|
||||||
|
|
||||||
* src/osgTerrain/GeometryTechnique.cpp: Added disabling of
|
|
||||||
mipmapping for non power of two textures
|
|
||||||
|
|
||||||
2009-04-06 11:27 robert
|
|
||||||
|
|
||||||
* src/osgTerrain/GeometryTechnique.cpp: Merged from svn/trunk
|
|
||||||
disabling of use of display lists and a extra check against NULL
|
|
||||||
to prevent a crash when NULL colour layers are assigned
|
|
||||||
|
|
||||||
2009-04-03 11:29 robert
|
|
||||||
|
|
||||||
* src/osg/Drawable.cpp: Merged fix in svn/trunk that avoids the
|
|
||||||
building of display lists when VBO's are compiled.
|
|
||||||
|
|
||||||
2009-03-26 10:25 robert
|
|
||||||
|
|
||||||
* src/osg/Texture.cpp: Merged fixes to the texture compression
|
|
||||||
settings from svn/trunk that don't change the
|
|
||||||
requested compression type when the pixel type is not a direct
|
|
||||||
match.
|
|
||||||
|
|
||||||
2009-03-23 16:26 robert
|
|
||||||
|
|
||||||
* src/osgPlugins/dae/daeRGeometry.cpp,
|
|
||||||
src/osgPlugins/dae/daeRMaterials.cpp,
|
|
||||||
src/osgPlugins/dae/daeReader.h: From Michael Platings, fixed
|
|
||||||
memory leak
|
|
||||||
|
|
||||||
2009-03-12 17:57 robert
|
|
||||||
|
|
||||||
* src/osgDB/CMakeLists.txt: From Frank Midgley, "I tried running
|
|
||||||
osgconv --formats yesterday on OS X and got no results. Turns out
|
|
||||||
the changes discussed in the "osgDB::listAllAvailablePlugins
|
|
||||||
win32 fix" thread back in Sep '08 broke this. The
|
|
||||||
OSG_PLUGIN_EXTENSION macro is being defined in
|
|
||||||
src/osgDB/CMakeLists.txt from CMAKE_SHARED_LIBRARY_SUFFIX which
|
|
||||||
is "dylib" on OS X. The problem is that all of the plug-ins are
|
|
||||||
setup in OsgMacroUtils.cmake with:
|
|
||||||
|
|
||||||
ADD_LIBRARY(${TARGET_TARGETNAME} MODULE ${TARGET_SRC}
|
|
||||||
${TARGET_H})
|
|
||||||
|
|
||||||
which gives them .so extensions. Since ".so" != ".dylib"
|
|
||||||
osgDB::listAllAvailablePlugins finds no plug-ins. I believe the
|
|
||||||
correct solution is to use CMAKE_SHARED_MODULE_SUFFIX instead.
|
|
||||||
This builds and runs correctly on OS X but I have not tested on
|
|
||||||
other platforms.
|
|
||||||
|
|
||||||
Attached is an updated src/osgDB/CMakeLists.txt based on rev
|
|
||||||
9915. The change is at line 108. To validate: build and then run
|
|
||||||
bin/osgconv --formats. You should get many screenfuls of plug-in
|
|
||||||
features, extensions and options."
|
|
||||||
|
|
||||||
Merged from svn/trunk using:
|
|
||||||
|
|
||||||
svn merge -r 9921:9922
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osgDB/CMakeLists.txt
|
|
||||||
|
|
||||||
2009-03-12 17:51 robert
|
|
||||||
|
|
||||||
* src/osgUtil/Optimizer.cpp: From Konstantin Sinitsyn, "At this
|
|
||||||
moment, I just introducing to OSG. When I reviewing optimizer
|
|
||||||
code, I find a mistake in
|
|
||||||
Optimizer::RemoveLoadedProxyNodesVisitor, as it seems. This
|
|
||||||
optimizer removes proxy nodes that fully loaded and in some cases
|
|
||||||
attach their childs to parrents directly (without creating of
|
|
||||||
group). I dont understand how this works, because if proxy node
|
|
||||||
doesn't have any attributes such as name, description, node mask
|
|
||||||
and any callbacks, then new group does not created to hold proxy
|
|
||||||
node childs. And code below trying to attach their children to
|
|
||||||
all parents but seems like only first child beeing attached to
|
|
||||||
all parents correctly."
|
|
||||||
|
|
||||||
Merged from svn/trunk using:
|
|
||||||
svn merge -r 9919:9920
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osgUtil/Optimizer.cpp
|
|
||||||
|
|
||||||
2009-03-11 13:31 robert
|
|
||||||
|
|
||||||
* src/osgPlugins/3ds/ReaderWriter3DS.cpp: From Neil Hughes, changed
|
|
||||||
the handling of opacity maps so that when they are used blending
|
|
||||||
in enabled. Merged from svn/trunk using:
|
|
||||||
|
|
||||||
svn merge -r 9905:9906
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osgPlugins/3ds/ReaderWriter3DS.cpp
|
|
||||||
|
|
||||||
2009-03-11 12:42 robert
|
|
||||||
|
|
||||||
* src/osgUtil/Optimizer.cpp: From Lionel Lagarde, "the attachment
|
|
||||||
contains a correction of the Optimizer::MergeGeometryVisitor.
|
|
||||||
When 2 geometries are merged, the primitive sets of the second
|
|
||||||
geometry
|
|
||||||
are copied to the first geometry.
|
|
||||||
|
|
||||||
The primitive sets were copied with a std::insert into the first
|
|
||||||
geometry
|
|
||||||
primitive set vector. It doesn't work when the geometry is using
|
|
||||||
VBOs (because
|
|
||||||
the element buffer object of the primitive set is not updated).
|
|
||||||
|
|
||||||
The correction replaces
|
|
||||||
|
|
||||||
lhs.getPrimitiveSetList().insert(
|
|
||||||
lhs.getPrimitiveSetList().end(),
|
|
||||||
rhs.getPrimitiveSetList().begin(),
|
|
||||||
rhs.getPrimitiveSetList().end() );
|
|
||||||
|
|
||||||
by
|
|
||||||
for( primItr=rhs.getPrimitiveSetList().begin();
|
|
||||||
primItr!=rhs.getPrimitiveSetList().end();
|
|
||||||
++primItr )
|
|
||||||
{
|
|
||||||
lhs.addPrimitiveSet(primItr->get());
|
|
||||||
}
|
|
||||||
"
|
|
||||||
|
|
||||||
2009-03-11 12:02 robert
|
|
||||||
|
|
||||||
* src/osg/Geometry.cpp: Fix to crash due to indices being present
|
|
||||||
witout any associated arrays. Merged from svn/trunk using:
|
|
||||||
|
|
||||||
svn merge -r 9899:9900
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osg/Geometry.cpp
|
|
||||||
|
|
||||||
2009-03-11 11:03 robert
|
|
||||||
|
|
||||||
* src/osg/Drawable.cpp, src/osg/ImageUtils.cpp, src/osg/Node.cpp:
|
|
||||||
From Lionel Lagarde, "The copy constructor of the nodes and the
|
|
||||||
drawables do :
|
|
||||||
|
|
||||||
Node::Node(Node &node, copyop) :
|
|
||||||
_stateSet(copyop(node.getStateSet()),
|
|
||||||
|
|
||||||
It doesn't call the setStateSet method of osg::Node (or
|
|
||||||
osg::Drawable). So the parent
|
|
||||||
list of the state set is not updated with the new node
|
|
||||||
(drawable)."
|
|
||||||
|
|
||||||
Merged from svn/trunk using:
|
|
||||||
|
|
||||||
svn merge -r 9896:9897
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osg/Drawable.cpp
|
|
||||||
svn merge -r 9896:9897
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osg/Node.cpp
|
|
||||||
|
|
||||||
2009-03-10 11:56 robert
|
|
||||||
|
|
||||||
* include/osg/GLU, include/osg/Math: From Martin Spott, fixes for
|
|
||||||
IBM AIX build. Merged from svn/trunk using:
|
|
||||||
|
|
||||||
svn merge -r 9881:9882
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/include/osg/
|
|
||||||
|
|
||||||
2009-03-02 10:51 robert
|
|
||||||
|
|
||||||
* src/OpenThreads/win32, src/OpenThreads/win32/Win32Thread.cpp,
|
|
||||||
src/OpenThreads/win32/Win32ThreadPrivateData.h: From Mathias
|
|
||||||
Froehlich, "An other one:
|
|
||||||
The TLS Varialbe is accessed before it is initialized.
|
|
||||||
Attached is a change to rev 9791."
|
|
||||||
|
|
||||||
Merged from svn/trunk using:
|
|
||||||
|
|
||||||
svn merge -r 9831:9832
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/OpenThreads/win32
|
|
||||||
|
|
||||||
2009-03-02 09:59 robert
|
|
||||||
|
|
||||||
* examples/osgcluster/broadcaster.cpp: From Petr Salinger, build
|
|
||||||
fix for GNU/kFreeBSD.
|
|
||||||
|
|
||||||
Merged from svn/trunk using:
|
|
||||||
|
|
||||||
svn merge -r 9827:9828
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/examples/osgcluster/broadcaster.cpp
|
|
||||||
|
|
||||||
2009-02-27 11:14 robert
|
|
||||||
|
|
||||||
* src/osgViewer/GraphicsWindowWin32.cpp: From Roland Smeenk,
|
|
||||||
"Attached is a small bug fix for the redundant messages that are
|
|
||||||
created in OSG applications on windows.
|
|
||||||
GraphicsWindowWin32::setCursor is called every frame from the
|
|
||||||
WM_NCHITTEST message. This will result in a call to
|
|
||||||
::SetCursor(_currentCursor) every frame, which again causes a
|
|
||||||
WM_MOUSEMOVE to occur. The fix exits
|
|
||||||
GraphicsWindowWin32::setCursor if the requested cursor already is
|
|
||||||
the current cursor.
|
|
||||||
|
|
||||||
"
|
|
||||||
|
|
||||||
Merged from svn/trunk using:
|
|
||||||
|
|
||||||
svn merge -r 9823:9824
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osgViewer/GraphicsWindowWin32.cpp
|
|
||||||
|
|
||||||
2009-02-27 10:50 robert
|
|
||||||
|
|
||||||
* src/osgUtil/RenderStage.cpp: From Atr Tevs, fixes to FBO
|
|
||||||
blitting. Merged from svn/trunk using:
|
|
||||||
|
|
||||||
svn merge -r 9821:9822
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osgUtil/RenderStage.cpp
|
|
||||||
|
|
||||||
2009-02-26 22:10 robert
|
|
||||||
|
|
||||||
* CMakeModules/Find3rdPartyDependencies.cmake: From Mattias
|
|
||||||
Helsing, "
|
|
||||||
In file
|
|
||||||
"/home/robert/OpenSceneGraph/CMakeModules//Find3rdPartyDependencies.cmake":
|
|
||||||
------------------------------
|
|
||||||
64: SET(FREETYPE_INCLUDE_DIRS
|
|
||||||
"${FREETYPE_INCLUDE_DIR_ft2build};${FREETYPE_INCLUDE_DIR_freetype2}")
|
|
||||||
"
|
|
||||||
|
|
||||||
2009-02-20 17:28 robert
|
|
||||||
|
|
||||||
* applications/osgarchive/osgarchive.cpp: From Mathieu Marache, "I
|
|
||||||
was trying to use the archive output of osgdem without success
|
|
||||||
when
|
|
||||||
I eventually found out that it was now disabled (the mailing list
|
|
||||||
archive tells me it is because of multithreaded write issues with
|
|
||||||
vpn). I then decided to use osgarchive to make it myself from the
|
|
||||||
generated output. However if one of the insert parameters is a
|
|
||||||
directory, it won't be able to find them. The attached versions
|
|
||||||
corrects this"
|
|
||||||
|
|
||||||
2009-02-20 11:41 robert
|
|
||||||
|
|
||||||
* src/osgPlugins/dxf, src/osgPlugins/dxf/dxfEntity.cpp: From Humar
|
|
||||||
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. "
|
|
||||||
|
|
||||||
Merged from svn trunk using:
|
|
||||||
svn merge -r 9803:9804
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osgPlugins/dxf/dxfEntity.cpp
|
|
||||||
|
|
||||||
2009-02-19 17:40 robert
|
|
||||||
|
|
||||||
* src/osgPlugins/hdr/hdrloader.cpp: Fixed bug in checking of return
|
|
||||||
values. Fix merged in from svn/trunk using:
|
|
||||||
|
|
||||||
svn merge -r 9800:9801
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osgPlugins/hdr/hdrloader.cpp
|
|
||||||
|
|
||||||
2009-02-19 16:36 robert
|
|
||||||
|
|
||||||
* src/osg/State.cpp: From Tanguy Fautre, This fixes the OSG crashes
|
|
||||||
reported by
|
|
||||||
http://lists.openscenegraph.org/pipermail/osg-users-openscenegraph.org/2009-February/023499.html
|
|
||||||
|
|
||||||
It's a one line change against OSG 2.8.0 (see line 196). I've
|
|
||||||
already tested the change, and confirmed it\u2019s fixing the
|
|
||||||
crashes described above."
|
|
||||||
|
|
||||||
merged from svn trunk using:
|
|
||||||
|
|
||||||
svn merge -r 9797:9798
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osg/State.cpp
|
|
||||||
|
|
||||||
2009-02-19 16:00 robert
|
|
||||||
|
|
||||||
* src/osg/PrimitiveSet.cpp: From Ruben Smelik, "I've found a
|
|
||||||
(copy-paste?) error in PrimitiveSet.cpp regarding instanced
|
|
||||||
drawing. For DrawElementsUInt and DrawElementsUShort the type
|
|
||||||
argument of glDrawElementsInstanced was set as GL_BYTE instead of
|
|
||||||
GL_UNSIGNED_INT and GL_UNSIGNED_SHORT. I've attached the fixed
|
|
||||||
source file (based on the current SVN head version)."
|
|
||||||
|
|
||||||
Merged from svn/trunk using:
|
|
||||||
|
|
||||||
svn merge -r 9795:9796
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk/src/osg/
|
|
||||||
|
|
||||||
2009-02-19 15:38 robert
|
|
||||||
|
|
||||||
* src/OpenThreads/CMakeLists.txt: merged from svn/trunk using:
|
|
||||||
|
|
||||||
svn merge -r 9793:9794
|
|
||||||
http://www.openscenegraph.org/svn/osg/OpenSceneGraph/trunk
|
|
||||||
|
|
||||||
2009-02-19 13:44 robert
|
|
||||||
|
|
||||||
* NEWS.txt: Fixed number of contributors
|
|
||||||
|
|
||||||
2009-02-12 14:46 robert
|
|
||||||
|
|
||||||
* ChangeLog: Updated ChangeLog for 2.8.0
|
|
||||||
|
|
||||||
2009-02-12 14:35 robert
|
2009-02-12 14:35 robert
|
||||||
|
|
||||||
* examples/osgviewerQT/QOSGWidget.cpp: Compiled fix
|
* examples/osgviewerQT/QOSGWidget.cpp: Compiled fix
|
||||||
|
|||||||
@@ -13,9 +13,8 @@
|
|||||||
under the terms of the OpenSceneGraph Public License (OSGPL) version 0.0
|
under the terms of the OpenSceneGraph Public License (OSGPL) version 0.0
|
||||||
or later.
|
or later.
|
||||||
|
|
||||||
Notes: the OSGPL is based on the LGPL, with the 4 exceptions laid
|
Notes: the OSGPL is based on the LGPL, with the 4 exceptions laid in the wxWindows
|
||||||
out in the wxWindows section below. The LGPL is contained in the
|
section below. The LGPL in the final section of this license.
|
||||||
final section of this license.
|
|
||||||
|
|
||||||
|
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
@@ -188,7 +187,7 @@ modification follow. Pay close attention to the difference between a
|
|||||||
former contains code derived from the library, whereas the latter must
|
former contains code derived from the library, whereas the latter must
|
||||||
be combined with the library in order to run.
|
be combined with the library in order to run.
|
||||||
|
|
||||||
GNU LESSER GENERAL PUBLIC LICENSE
|
GNU LESSER GENERAL PUBLIC LICENSE
|
||||||
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
|
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
|
||||||
|
|
||||||
0. This License Agreement applies to any software library or other
|
0. This License Agreement applies to any software library or other
|
||||||
|
|||||||
30
NEWS.txt
30
NEWS.txt
@@ -1,34 +1,14 @@
|
|||||||
OSG News
|
OSG News
|
||||||
========
|
========
|
||||||
|
|
||||||
= !OpenSceneGraph 2.8.1 release - bug fix release =
|
= !OpenSceneGraph 2.8 release adds osgAnimation and osgVolume libraries, DICOM support, LispSM shadowing and much more. =
|
||||||
|
|
||||||
PERTHSHIRE, Scotland - 19th May 2009 - !OpenSceneGraph Professional Services announces the release of !OpenSceneGraph 2.8.1, the industry's leading open-source scene graph technology, designed to accelerate application development and improve 3D graphics performance. !OpenSceneGraph 2.8 written entirely in Standard C++ and built upon OpenGL, offers developers working in the visual simulation, game development, virtual reality, scientific visualization and modeling markets - a real-time visualization tool which eclipses commercial scene graph toolkits in functionality, stability and performance. !OpenSceneGraph 2.8 runs on all Microsoft Windows platforms, Apple OS/X, GNU/Linux, IRIX, Solaris, HP-UX, AIX and FreeBSD operating systems.
|
PERTHSHIRE, Scotland - 12th February 2009 - !OpenSceneGraph Professional Services announces the release of !OpenSceneGraph 2.8, the industry's leading open-source scene graph technology, designed to accelerate application development and improve 3D graphics performance. !OpenSceneGraph 2.8 written entirely in Standard C++ and built upon OpenGL, offers developers working in the visual simulation, game development, virtual reality, scientific visualization and modeling markets - a real-time visualization tool which eclipses commercial scene graph toolkits in functionality, stability and performance. !OpenSceneGraph 2.8 runs on all Microsoft Windows platforms, Apple OS/X, GNU/Linux, IRIX, Solaris, HP-UX, AIX and FreeBSD operating systems.
|
||||||
|
|
||||||
=== Open-source development delivers industry-leading features and performance ===
|
=== Open-source development delivers industry-leading features and performance ===
|
||||||
The !OpenSceneGraph 2.8.1 release is the culmination of 10 years of work by the lead developers and the open-source community that has grown up around the project. The real-time graphics industry and academia embraced it from the very beginning, deploying it in real-world applications, and actively participating in its development, testing and refinement. The end result is a high-quality library with a feature set relevant to application developers' needs.
|
The !OpenSceneGraph 2.8 release is the culmination of 10 years of work by the lead developers and the open-source community that has grown up around the project. The real-time graphics industry and academia embraced it from the very beginning, deploying it in real-world applications, and actively participating in its development, testing and refinement. The end result is a high-quality library with a feature set relevant to application developers' needs.
|
||||||
|
|
||||||
=== Updates between 2.8.1 and 2.8.0 releases include: ===
|
=== Updates include: ===
|
||||||
|
|
||||||
* Build fixes under FreeBSD and IBM AIX, and RedHat Enterprise Linux.
|
|
||||||
* Improved compatibility with SWIG wrapper building
|
|
||||||
* Crash fixes in osg::State, osg::Geometry and osgWidget.
|
|
||||||
* Bug fixes to :
|
|
||||||
* draw instanced support
|
|
||||||
* Optimizer - MergeGeometryVisitor, RemoveLoadedProxyNodesVisitor and SpatializeGroupsVistor
|
|
||||||
* hdr image loader
|
|
||||||
* handling of opacity maps in 3ds loader
|
|
||||||
* dxf loader
|
|
||||||
* frame buffer object
|
|
||||||
* cursor/event handling in windows
|
|
||||||
* windows threading
|
|
||||||
* memory leak in Collada loader
|
|
||||||
* fixes to display lists/vbo creation that prevent crash under ATI drivers
|
|
||||||
* subface PolygonOffset setting in OpenFlight
|
|
||||||
* osgconv --formats under OSX
|
|
||||||
* osgTerrain::Layer bounding volume calculation.
|
|
||||||
|
|
||||||
=== Updates between 2.8 and 2.6 include: ===
|
|
||||||
|
|
||||||
* New osgVolume library for volume rendering, with support for:
|
* New osgVolume library for volume rendering, with support for:
|
||||||
* High quality GPU based Ray tracing
|
* High quality GPU based Ray tracing
|
||||||
@@ -77,7 +57,7 @@ The !OpenSceneGraph Quick Start Guide is now available in Chinese as well as Eng
|
|||||||
=== Community support and contributions ===
|
=== Community support and contributions ===
|
||||||
The diverse and growing community of over 2000 developers is centred around the public osg-users mailing list, where members discuss how best to use !OpenSceneGraph, provide mutual support, and coordinate development of new features and bug fixes. Members of this community come from many different countries with backgrounds ranging from some of the world's largest aerospace companies, game companies, and visual simulation specialists to university researchers, students and hobbyists.
|
The diverse and growing community of over 2000 developers is centred around the public osg-users mailing list, where members discuss how best to use !OpenSceneGraph, provide mutual support, and coordinate development of new features and bug fixes. Members of this community come from many different countries with backgrounds ranging from some of the world's largest aerospace companies, game companies, and visual simulation specialists to university researchers, students and hobbyists.
|
||||||
|
|
||||||
The !OpenSceneGraph project owes a great deal to the community for its development and support, in particular we wish to thank the [http://www.openscenegraph.org/projects/osg/wiki/Support/Contributors/TwoPointEight 365 individuals] from around the world that have directly contributed to the development and refinement of the !OpenSceneGraph code base.
|
The !OpenSceneGraph project owes a great deal to the community for its development and support, in particular we wish to thank the [http://www.openscenegraph.org/projects/osg/wiki/Support/Contributors/TwoPointEight 364 individuals] from around the world that have directly contributed to the development and refinement of the !OpenSceneGraph code base.
|
||||||
|
|
||||||
----
|
----
|
||||||
|
|
||||||
|
|||||||
@@ -12,9 +12,10 @@ subscribe to our public mailing list:
|
|||||||
http://www.openscenegraph.org/projects/osg/wiki/MailingLists
|
http://www.openscenegraph.org/projects/osg/wiki/MailingLists
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Robert Osfield.
|
Robert Osfield.
|
||||||
Project Lead.
|
Project Lead.
|
||||||
19th May 2009.
|
12th February 2009.
|
||||||
|
|
||||||
--
|
--
|
||||||
|
|
||||||
|
|||||||
@@ -79,12 +79,7 @@ int main( int argc, char **argv )
|
|||||||
else if (fileType==osgDB::DIRECTORY)
|
else if (fileType==osgDB::DIRECTORY)
|
||||||
{
|
{
|
||||||
osgDB::DirectoryContents directory = osgDB::getDirectoryContents(arguments[pos]);
|
osgDB::DirectoryContents directory = osgDB::getDirectoryContents(arguments[pos]);
|
||||||
osgDB::DirectoryContents::iterator it = directory.begin();
|
files.insert(files.end(),directory.begin(),directory.end());
|
||||||
while( it != directory.end())
|
|
||||||
{
|
|
||||||
files.push_back(filePath + "/" + (*it));
|
|
||||||
++it;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|||||||
@@ -1,10 +1,5 @@
|
|||||||
SET(TARGET_SRC osgversion.cpp )
|
SET(TARGET_SRC osgversion.cpp )
|
||||||
|
|
||||||
IF (OSG_MAINTAINER)
|
|
||||||
SET(TARGET_SRC ${TARGET_SRC} Contributors.cpp )
|
|
||||||
ADD_DEFINITIONS("-DBUILD_CONTRIBUTORS")
|
|
||||||
ENDIF()
|
|
||||||
|
|
||||||
SET(TARGET_COMMON_LIBRARIES
|
SET(TARGET_COMMON_LIBRARIES
|
||||||
OpenThreads
|
OpenThreads
|
||||||
osg
|
osg
|
||||||
|
|||||||
@@ -1,836 +0,0 @@
|
|||||||
// The majority of the application is dedicated to building the
|
|
||||||
// current contribitors list by parsing the ChangeLog, it just takes
|
|
||||||
// one line in the main itself to report the version number.
|
|
||||||
|
|
||||||
#include <set>
|
|
||||||
#include <vector>
|
|
||||||
#include <iostream>
|
|
||||||
|
|
||||||
#include <OpenThreads/Version>
|
|
||||||
|
|
||||||
#include <osg/Notify>
|
|
||||||
#include <osg/Version>
|
|
||||||
#include <osg/ArgumentParser>
|
|
||||||
#include <osg/ApplicationUsage>
|
|
||||||
|
|
||||||
#include <osg/Matrix>
|
|
||||||
#include <osg/Plane>
|
|
||||||
#include <osg/BoundingBox>
|
|
||||||
#include <osg/BoundingSphere>
|
|
||||||
|
|
||||||
#include <osgDB/fstream>
|
|
||||||
|
|
||||||
using namespace std;
|
|
||||||
|
|
||||||
|
|
||||||
#if defined(_MSC_VER)
|
|
||||||
#pragma setlocale("C")
|
|
||||||
#endif
|
|
||||||
|
|
||||||
typedef pair<string, string> NamePair;
|
|
||||||
typedef map<NamePair, unsigned int> NameMap;
|
|
||||||
typedef vector<string> Words;
|
|
||||||
|
|
||||||
NamePair EmptyNamePair;
|
|
||||||
NamePair NameRobertOsfield("Robert", "Osfield");
|
|
||||||
NamePair NameDonBurns ("Don", "Burns");
|
|
||||||
|
|
||||||
|
|
||||||
const char* validNames[] =
|
|
||||||
{
|
|
||||||
"de",
|
|
||||||
"den",
|
|
||||||
"van"
|
|
||||||
};
|
|
||||||
|
|
||||||
const char* invalidNames[] =
|
|
||||||
{
|
|
||||||
"Added",
|
|
||||||
"AnimationPath",
|
|
||||||
"AnimationPathCallback",
|
|
||||||
"AnimationPathManipulator",
|
|
||||||
"ArgumentParser",
|
|
||||||
"AttrData",
|
|
||||||
"AutoTransform",
|
|
||||||
"AutoTransform.",
|
|
||||||
"Azimuth",
|
|
||||||
"BlenColour(Vec4",
|
|
||||||
"Camera",
|
|
||||||
"CameraBarrierCallback",
|
|
||||||
"CameraNode",
|
|
||||||
"Canvas",
|
|
||||||
"CluserCullingCallback",
|
|
||||||
"ClusterCullingCallback",
|
|
||||||
"CoordinateSystem",
|
|
||||||
"CoordinateSystemNode",
|
|
||||||
"CoordinateSystemNode&",
|
|
||||||
"CopyOp",
|
|
||||||
"Copyright",
|
|
||||||
"Core",
|
|
||||||
"Creator",
|
|
||||||
"CullCallbacks",
|
|
||||||
"CullingSettngs",
|
|
||||||
"CullVisitor",
|
|
||||||
"CullVistor",
|
|
||||||
"Cygwin",
|
|
||||||
"DatabasePager",
|
|
||||||
"DataSet",
|
|
||||||
"DataVariance",
|
|
||||||
"DeleteHandler",
|
|
||||||
"DisplaySettings",
|
|
||||||
"Drawable",
|
|
||||||
"DrawElementsUByte",
|
|
||||||
"Endian",
|
|
||||||
"Escape",
|
|
||||||
"EventQueue",
|
|
||||||
"Face",
|
|
||||||
"Files",
|
|
||||||
"Fixed",
|
|
||||||
"Fixes",
|
|
||||||
"FluidProgram",
|
|
||||||
"FontImplementation",
|
|
||||||
"FrameStats",
|
|
||||||
"Framstamp",
|
|
||||||
"FreeBSD",
|
|
||||||
"Geode",
|
|
||||||
"GeoemtryTechnique",
|
|
||||||
"GeometryTechnique",
|
|
||||||
"GeoSet",
|
|
||||||
"GraphicsContext",
|
|
||||||
"GraphicsContextImplementation",
|
|
||||||
"GraphicsThread",
|
|
||||||
"GraphicsWindowX11",
|
|
||||||
"Group",
|
|
||||||
"Image",
|
|
||||||
"ImageOptions",
|
|
||||||
"Images",
|
|
||||||
"Images/SolarSystem",
|
|
||||||
"ImageStream",
|
|
||||||
"Improved",
|
|
||||||
"IndexBlock",
|
|
||||||
"IndexFaceSets",
|
|
||||||
"IntersectVisitor",
|
|
||||||
"Inventor",
|
|
||||||
"KdTree",
|
|
||||||
"KeyboardMouse",
|
|
||||||
"KeyboardMouseCallback",
|
|
||||||
"LightModel",
|
|
||||||
"LightPointNode",
|
|
||||||
"LineSegment",
|
|
||||||
"LineStipple",
|
|
||||||
"Logos",
|
|
||||||
"LongIDRecord",
|
|
||||||
"Make",
|
|
||||||
"Makefile",
|
|
||||||
"Material",
|
|
||||||
"Matrix",
|
|
||||||
"Matrix*",
|
|
||||||
"MatrixManipulator",
|
|
||||||
"MatrixTransform",
|
|
||||||
"MemoryManager",
|
|
||||||
"MergeGeometryVisitor",
|
|
||||||
"MeshRecord",
|
|
||||||
"Mode",
|
|
||||||
"Mr",
|
|
||||||
"Multigen",
|
|
||||||
"New",
|
|
||||||
"NewCullVisitor",
|
|
||||||
"NodeVisitor",
|
|
||||||
"Object",
|
|
||||||
"OpenDX",
|
|
||||||
"OpenSceneGraph",
|
|
||||||
"OpenSceneGraph-2",
|
|
||||||
"OpenSceneGraph-osgWidget-dev",
|
|
||||||
"OpenThreads",
|
|
||||||
"OperationThread",
|
|
||||||
"Optimizer",
|
|
||||||
"OrientationConverter",
|
|
||||||
"Osfields",
|
|
||||||
"Ouput",
|
|
||||||
"Output",
|
|
||||||
"OveralyNode",
|
|
||||||
"PagedLOD",
|
|
||||||
"PageLOD",
|
|
||||||
"Paging",
|
|
||||||
"ParentList",
|
|
||||||
"Performer",
|
|
||||||
"PickHandler",
|
|
||||||
"PixelDataBufferObject",
|
|
||||||
"PolygonStipple",
|
|
||||||
"PolytopeVisitor",
|
|
||||||
"PrimitiveIndexFunctor",
|
|
||||||
"Prodcuer",
|
|
||||||
"Producer",
|
|
||||||
"ProducerEventCallback",
|
|
||||||
"Program",
|
|
||||||
"Proxy",
|
|
||||||
"ProxyNode",
|
|
||||||
"Quake3",
|
|
||||||
"Quicktime",
|
|
||||||
"ReaderWriters",
|
|
||||||
"ReentrantMutex",
|
|
||||||
"Referenced",
|
|
||||||
"ReferenceFrame",
|
|
||||||
"Removed",
|
|
||||||
"RemoveLoadedProxyNodes",
|
|
||||||
"RenderStage",
|
|
||||||
"RenderTargetFallback",
|
|
||||||
"RenderToTextureStage",
|
|
||||||
"SceneGraphBuilder",
|
|
||||||
"SceneView",
|
|
||||||
"Sequence",
|
|
||||||
"Shape",
|
|
||||||
"SimpleViewer",
|
|
||||||
"SimpleViewer",
|
|
||||||
"SmokeTrailEffect",
|
|
||||||
"Source",
|
|
||||||
"SpotExponent",
|
|
||||||
"State",
|
|
||||||
"StateAttribute",
|
|
||||||
"Stats",
|
|
||||||
"StatsVisitor",
|
|
||||||
"Studio",
|
|
||||||
"Support",
|
|
||||||
"Switch",
|
|
||||||
"TechniqueEventHandler",
|
|
||||||
"TerraPage",
|
|
||||||
"TessellationHints",
|
|
||||||
"TestManipulator",
|
|
||||||
"TestSupportCallback",
|
|
||||||
"TexEnv",
|
|
||||||
"TexMat(Matrix",
|
|
||||||
"Texture",
|
|
||||||
"Texture2DArray",
|
|
||||||
"Texture3D",
|
|
||||||
"TextureCubeMap",
|
|
||||||
"TextureObjectManager",
|
|
||||||
"TextureRectangle",
|
|
||||||
"TextureRectangle(Image*",
|
|
||||||
"TextureType",
|
|
||||||
"Texuture",
|
|
||||||
"TriStripVisitor",
|
|
||||||
"TrPageViewer",
|
|
||||||
"Uniform",
|
|
||||||
"UseFarLineSegments",
|
|
||||||
"UserData",
|
|
||||||
"Valve",
|
|
||||||
"Vec*",
|
|
||||||
"Vec2d",
|
|
||||||
"Vec3d",
|
|
||||||
"Vec4ub",
|
|
||||||
"Version",
|
|
||||||
"VertexData",
|
|
||||||
"View",
|
|
||||||
"Viewer",
|
|
||||||
"ViewPoint",
|
|
||||||
"Viewport",
|
|
||||||
"Viewport",
|
|
||||||
"Visual",
|
|
||||||
"VisualStudio",
|
|
||||||
"WindowData",
|
|
||||||
"Windows",
|
|
||||||
"X",
|
|
||||||
"Xcode",
|
|
||||||
"Y"
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
struct TypoCorrection
|
|
||||||
{
|
|
||||||
const char* original;
|
|
||||||
const char* corrected;
|
|
||||||
};
|
|
||||||
|
|
||||||
TypoCorrection typoCorrections[] =
|
|
||||||
{
|
|
||||||
{"Aderian", "Adrian"},
|
|
||||||
{"Adndre", "Andre"},
|
|
||||||
{"Adrain", "Adrian"},
|
|
||||||
{"Amueller", "Aumueller"},
|
|
||||||
{"Andew", "Andrew"},
|
|
||||||
{"André", "Andr<EFBFBD>"},
|
|
||||||
{"Antione", "Antoine"},
|
|
||||||
{"Antonoine", "Antoine"},
|
|
||||||
{"Atr", "Art"},
|
|
||||||
{"Baverage", "Beverage"},
|
|
||||||
{"Bistroviae", "Bistrovic"},
|
|
||||||
{"Callue", "Callu"},
|
|
||||||
{"Christaiansen", "Christiansen"},
|
|
||||||
{"Cobin", "Corbin"},
|
|
||||||
{"Comporesi", "Camporesi"},
|
|
||||||
{"Connel", "Connell"},
|
|
||||||
{"Cullu", "Callu"},
|
|
||||||
{"Daneil", "Daniel"},
|
|
||||||
{"Daust", "Daoust"},
|
|
||||||
{"Daved", "David"},
|
|
||||||
{"Drederic", "Frederic"},
|
|
||||||
{"Eileman", "Eilemann"},
|
|
||||||
{"Elgi", "Egli"},
|
|
||||||
{"Fabian", "Fabien"},
|
|
||||||
{"Fautre", "Fautr<EFBFBD>"},
|
|
||||||
{"Frashid", "Farshid"},
|
|
||||||
{"Fred", "Frederic"},
|
|
||||||
{"Fredrick", "Frederic"},
|
|
||||||
{"Fredric", "Frederic"},
|
|
||||||
{"Froechlich", "Fr<EFBFBD>hlich"},
|
|
||||||
{"Froehilch", "Fr<EFBFBD>hlich"},
|
|
||||||
{"Froehlich", "Fr<EFBFBD>hlich"},
|
|
||||||
{"Froelich", "Fr<EFBFBD>hlich"},
|
|
||||||
{"Froenlich", "Fr<EFBFBD>hlich"},
|
|
||||||
{"Fröhlich", "Fr<EFBFBD>hlich"},
|
|
||||||
{"Fruciel", "Frauciel"},
|
|
||||||
{"García", "Garcea"},
|
|
||||||
{"Garrat", "Garrett"},
|
|
||||||
{"Garret", "Garrett"},
|
|
||||||
{"Geof", "Geoff"},
|
|
||||||
{"Giatan", "Gaitan"},
|
|
||||||
{"Gronenger", "Gronager"},
|
|
||||||
{"Gronger", "Gronager"},
|
|
||||||
{"Haritchablaet", "Haritchabalet"},
|
|
||||||
{"Hebelin", "Herbelin"},
|
|
||||||
{"Heirtlein", "Hertlein"},
|
|
||||||
{"Heirtlein", "Hertlein"},
|
|
||||||
{"Hertleinm", "Hertlein"},
|
|
||||||
{"Hertlien", "Hertlein"},
|
|
||||||
{"Hi", "He"},
|
|
||||||
{"Hooper", "Hopper"},
|
|
||||||
{"Inverson", "Iverson"},
|
|
||||||
{"Iversion", "Iverson"},
|
|
||||||
{"Jean-Sebastein", "Jean-Sebastien"},
|
|
||||||
{"Jean-Sebastian", "Jean-Sebastien"},
|
|
||||||
{"Jean-Sebastirn", "Jean-Sebastien"},
|
|
||||||
{"Jea-Sebastien", "Jean-Sebastien"},
|
|
||||||
{"Johhansen", "Johansen"},
|
|
||||||
{"Johnansen", "Johansen"},
|
|
||||||
{"Johnasen", "Johansen"},
|
|
||||||
{"Jolly", "Jolley"},
|
|
||||||
{"Jose", "Jos<EFBFBD>"},
|
|
||||||
{"José", "Jos<EFBFBD>"},
|
|
||||||
{"Joson", "Jason"},
|
|
||||||
{"J", "Jos<EFBFBD>"},
|
|
||||||
{"Keuhne", "Kuehne"},
|
|
||||||
{"Kheune", "Kuehne"},
|
|
||||||
{"Lagrade", "Lagarde"},
|
|
||||||
{"Larshkari", "Lashkari"},
|
|
||||||
{"Lashakari", "Lashkari"},
|
|
||||||
{"Lashari", "Lashkari"},
|
|
||||||
{"Lasharki", "Lashkari"},
|
|
||||||
{"Laskari", "Lashkari"},
|
|
||||||
{"Leandowski", "Lewandowski"},
|
|
||||||
{"Lawandowski", "Lewandowski"},
|
|
||||||
{"Lucas", "Luaces"},
|
|
||||||
{"Lugi", "Luigi"},
|
|
||||||
{"Lweandowski", "Lewandowski"},
|
|
||||||
{"Maceij", "Maciej"},
|
|
||||||
{"Machler", "M<EFBFBD>chler"},
|
|
||||||
{"Macro", "Marco"},
|
|
||||||
{"Maechler", "M<EFBFBD>chler"},
|
|
||||||
{"Mahai", "Mihai"},
|
|
||||||
{"Mammond", "Marmond"},
|
|
||||||
{"March", "Marco"},
|
|
||||||
{"Martsz", "Martz"},
|
|
||||||
{"Marz", "Martz"},
|
|
||||||
{"Matz", "Martz"},
|
|
||||||
{"Melchoir", "Melchior"},
|
|
||||||
{"Mellis", "Melis"},
|
|
||||||
{"Messerschimdt", "Messerschmidt"},
|
|
||||||
{"Micheal", "Michael"},
|
|
||||||
{"Mihair", "Mihai"},
|
|
||||||
{"Molishtan", "Moloshtan"},
|
|
||||||
{"Molishtan", "Moloshtan"},
|
|
||||||
{"Moloshton", "Moloshtan"},
|
|
||||||
{"Morné", "Morn<EFBFBD>"},
|
|
||||||
{"Morne", "Morn<EFBFBD>"},
|
|
||||||
{"Moule", "Moiule"},
|
|
||||||
{"Narache", "Marache"},
|
|
||||||
{"Nicklov", "Nikolov"},
|
|
||||||
{"Nickolov", "Nikolov"},
|
|
||||||
{"Olad", "Olaf"},
|
|
||||||
{"Olar", "Olaf"},
|
|
||||||
{"Oritz", "Ortiz"},
|
|
||||||
{"Osfeld", "Osfield"},
|
|
||||||
{"Osfied", "Osfield"},
|
|
||||||
{"Pail", "Paul"},
|
|
||||||
{"Rajce", "Trajce"},
|
|
||||||
{"Randal", "Randall"},
|
|
||||||
{"Robet", "Robert"},
|
|
||||||
{"Rodger", "Roger"},
|
|
||||||
{"Rolad", "Roland"},
|
|
||||||
{"Rucard", "Richard"},
|
|
||||||
{"Sekender", "Sukender"},
|
|
||||||
{"Sewel", "Sewell"},
|
|
||||||
{"Simmonson", "Simonsson"},
|
|
||||||
{"Simmonsson", "Simonsson"},
|
|
||||||
{"Sjolie", "Sj<EFBFBD>lie"},
|
|
||||||
{"Sjölie", "Sj<EFBFBD>lie"},
|
|
||||||
{"Skinnder", "Skinner"},
|
|
||||||
{"Sokolosky", "Sokolowsky"},
|
|
||||||
{"Sokolowky", "Sokolowsky"},
|
|
||||||
{"Sokolowki", "Sokolowsky"},
|
|
||||||
{"Sokolowski", "Sokolowsky"},
|
|
||||||
{"Sokolsky", "Sokolowsky"},
|
|
||||||
{"Sokolwsky", "Sokolowsky"},
|
|
||||||
{"Sonda", "Sondra"},
|
|
||||||
{"Stansilav", "Stanislav"},
|
|
||||||
{"Stefan", "Stephan"},
|
|
||||||
{"Stell", "Steel"},
|
|
||||||
{"Sylvan", "Sylvain"},
|
|
||||||
{"Takeahei", "Takahei"},
|
|
||||||
{"Takehei", "Takahei"},
|
|
||||||
{"Tarantilils", "Tarantilis"},
|
|
||||||
{"Trastenjak", "Trstenjak"},
|
|
||||||
{"Urlich", "Ulrich"},
|
|
||||||
{"Vines", "Vine"},
|
|
||||||
{"Waldrom", "Waldron"},
|
|
||||||
{"Wedner", "Weidner"},
|
|
||||||
{"Weidemann", "Wiedemann"},
|
|
||||||
{"Wieblen", "Weiblen"},
|
|
||||||
{"Woesnner", "Woessner"},
|
|
||||||
{"Wojchiech", "Wojciech"},
|
|
||||||
{"Wojiech", "Wojciech"},
|
|
||||||
{"Xennon", "Hanson"},
|
|
||||||
{"Yefrei", "Yefei"},
|
|
||||||
{"Yfei", "Yefei"}
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
struct NameCorrection
|
|
||||||
{
|
|
||||||
const char* originalFirst;
|
|
||||||
const char* originalSecond;
|
|
||||||
const char* correctedFirst;
|
|
||||||
const char* correctedSecond;
|
|
||||||
};
|
|
||||||
|
|
||||||
NameCorrection nameCorrections[] =
|
|
||||||
{
|
|
||||||
{"Marc", "Sciabica",
|
|
||||||
"Mark", "Sciabica"},
|
|
||||||
{"Jean", "Sebastien",
|
|
||||||
"Jean-Sebastien", "Guay"},
|
|
||||||
{"Michale", "Platings",
|
|
||||||
"Michael", "Platings"},
|
|
||||||
{"Mick", "",
|
|
||||||
"Maik", "Keller"},
|
|
||||||
{"Gary", "Quin",
|
|
||||||
"Gary", "Quinn"},
|
|
||||||
{"BjornHein", "",
|
|
||||||
"Bj<EFBFBD>rn", "Hein"},
|
|
||||||
{"Bjorn", "Hein",
|
|
||||||
"Bj<EFBFBD>rn", "Hein"},
|
|
||||||
{"Erik", "van",
|
|
||||||
"Erik", "den Dekker"},
|
|
||||||
{"Erik", "den",
|
|
||||||
"Erik", "den Dekker"},
|
|
||||||
{"Jeoen", "den",
|
|
||||||
"Jeroen", "den Dekker"},
|
|
||||||
{"John", "Vidar",
|
|
||||||
"John", "Vidar Larring"},
|
|
||||||
{"John", "Vida",
|
|
||||||
"John", "Vidar Larring"},
|
|
||||||
{"Sebastien", "Messerschmidt",
|
|
||||||
"Sebastian", "Messerschmidt"},
|
|
||||||
{"Mattias", "Fr<EFBFBD>hlich",
|
|
||||||
"Mathias", "Fr<EFBFBD>hlich"},
|
|
||||||
{"Mathias", "Helsing",
|
|
||||||
"Mattias", "Helsing"},
|
|
||||||
{"Jose", "Delport",
|
|
||||||
"J.P.", "Delport"},
|
|
||||||
{"Jos<EFBFBD>", "Delport",
|
|
||||||
"J.P.", "Delport"},
|
|
||||||
{"Franz", "Melchior",
|
|
||||||
"Melchior", "Franz"},
|
|
||||||
{"Glen", "Waldon",
|
|
||||||
"Glenn", "Waldron"},
|
|
||||||
{"Ralf", "Karn",
|
|
||||||
"Ralf", "Kern"},
|
|
||||||
{"Donny", "Cipperly",
|
|
||||||
"Donald", "Cipperly"},
|
|
||||||
{"Gino", "van",
|
|
||||||
"Gino", "van den Bergen"},
|
|
||||||
{"Radu", "Mihai",
|
|
||||||
"Mihai", "Radu"},
|
|
||||||
{"Art", "Trevs",
|
|
||||||
"Art", "Tevs"},
|
|
||||||
{"Tim", "More",
|
|
||||||
"Tim", "Moore"},
|
|
||||||
{"Andre", "Garneau",
|
|
||||||
"Andr<EFBFBD>", "Garneau"},
|
|
||||||
{"Eric", "Hammil",
|
|
||||||
"Chris", "Hanson"},
|
|
||||||
{"Paul", "de",
|
|
||||||
"Paul", "de Repentigny"},
|
|
||||||
{"Raymond", "de",
|
|
||||||
"Raymond", "de Vries"},
|
|
||||||
{"Nick", "",
|
|
||||||
"Trajce", "Nikolov"},
|
|
||||||
{"Daniel", "",
|
|
||||||
"Daniel", "Sj<EFBFBD>lie"},
|
|
||||||
{"Julia", "Ortiz",
|
|
||||||
"Julian", "Ortiz"},
|
|
||||||
{"Rune", "Schmidt",
|
|
||||||
"Rune", "Schmidt Jensen"},
|
|
||||||
{"Romano", "Jos<EFBFBD>",
|
|
||||||
"Romano", "Jos<EFBFBD> Magacho da Silva"},
|
|
||||||
{"Rommano", "Silva",
|
|
||||||
"Romano", "Jos<EFBFBD> Magacho da Silva"},
|
|
||||||
{"Leandro", "Motta",
|
|
||||||
"Leandro", "Motta Barros"},
|
|
||||||
{"A", "Botorabi",
|
|
||||||
"Ali", "Botorabi"},
|
|
||||||
{"Waltice", "",
|
|
||||||
"Walter", "J. Altice"},
|
|
||||||
{"Drew", "",
|
|
||||||
"Drew", "Whitehouse"},
|
|
||||||
{"Douglas", "A",
|
|
||||||
"Douglas", "A. Pouk"},
|
|
||||||
{"Colin", "MacDonald",
|
|
||||||
"Colin", "McDonald"},
|
|
||||||
{"Nikolov", "Trajce",
|
|
||||||
"Trajce", "Nikolov"},
|
|
||||||
{"Frauciel", "Luc",
|
|
||||||
"Luc", "Frauciel"},
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
bool validName(const string& first)
|
|
||||||
{
|
|
||||||
// Check for valid names
|
|
||||||
for (unsigned int i = 0; i < sizeof(validNames) / sizeof(char*); ++i)
|
|
||||||
{
|
|
||||||
if (first == validNames[i])
|
|
||||||
{
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (first.empty()) return false;
|
|
||||||
|
|
||||||
if (first[0] < 'A' || first[0] > 'Z') return false;
|
|
||||||
|
|
||||||
if (first.size() >= 2 && (first[1] < 'a' || first[1] > 'z') && (first[1] != '.') && (first[1] != ',')) return false;
|
|
||||||
|
|
||||||
// Check for invalid names
|
|
||||||
for (unsigned int i = 0; i < sizeof(invalidNames) / sizeof(char*); ++i)
|
|
||||||
{
|
|
||||||
if (first == invalidNames[i])
|
|
||||||
{
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// Default to a valid name
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
string typoCorrection(const string& name)
|
|
||||||
{
|
|
||||||
// Loop over all known typo corrections
|
|
||||||
for (unsigned int i = 0; i < sizeof(typoCorrections) / sizeof(TypoCorrection); ++i)
|
|
||||||
{
|
|
||||||
// If a typo is found
|
|
||||||
if (name == typoCorrections[i].original)
|
|
||||||
{
|
|
||||||
// Return the correction
|
|
||||||
return typoCorrections[i].corrected;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return name;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
void nameCorrection(NamePair& name)
|
|
||||||
{
|
|
||||||
// Loop over all known name corrections
|
|
||||||
for (unsigned int i = 0; i < sizeof(nameCorrections) / sizeof(NameCorrection); ++i)
|
|
||||||
{
|
|
||||||
// If a matching name is found
|
|
||||||
if (name.first == nameCorrections[i].originalFirst &&
|
|
||||||
name.second == nameCorrections[i].originalSecond)
|
|
||||||
{
|
|
||||||
// Return the correction
|
|
||||||
name.first = nameCorrections[i].correctedFirst;
|
|
||||||
name.second = nameCorrections[i].correctedSecond;
|
|
||||||
|
|
||||||
// Early out, since we don't want corrections of corrections
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
void lastValidCharacter(const string& name, unsigned int& pos, char c)
|
|
||||||
{
|
|
||||||
for (unsigned int i = 0; i < pos; ++i)
|
|
||||||
{
|
|
||||||
if (name[i] == c)
|
|
||||||
{
|
|
||||||
pos = i;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
void lastValidCharacter(const string& name, unsigned int& last)
|
|
||||||
{
|
|
||||||
lastValidCharacter(name, last, '.');
|
|
||||||
lastValidCharacter(name, last, ',');
|
|
||||||
lastValidCharacter(name, last, '\'');
|
|
||||||
lastValidCharacter(name, last, '/');
|
|
||||||
lastValidCharacter(name, last, '\\');
|
|
||||||
lastValidCharacter(name, last, ':');
|
|
||||||
lastValidCharacter(name, last, ';');
|
|
||||||
lastValidCharacter(name, last, ')');
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
NamePair createName(const string& first, const string& second)
|
|
||||||
{
|
|
||||||
if (first.empty()) return EmptyNamePair;
|
|
||||||
|
|
||||||
// cout << "first = " << first << " second = " << second << endl;
|
|
||||||
|
|
||||||
unsigned int last = first.size();
|
|
||||||
lastValidCharacter(first, last);
|
|
||||||
|
|
||||||
if (last == 0) return EmptyNamePair;
|
|
||||||
|
|
||||||
string name;
|
|
||||||
|
|
||||||
name.append(first.begin(), first.begin() + last);
|
|
||||||
|
|
||||||
if (!validName(name)) return EmptyNamePair;
|
|
||||||
|
|
||||||
name = typoCorrection(name);
|
|
||||||
|
|
||||||
if (second.empty() ||
|
|
||||||
!validName(second))
|
|
||||||
{
|
|
||||||
// filter any single or two letter words as unlike to be names.
|
|
||||||
if (name.size() <= 2) return EmptyNamePair;
|
|
||||||
|
|
||||||
return NamePair(name, "");
|
|
||||||
}
|
|
||||||
|
|
||||||
last = second.size();
|
|
||||||
|
|
||||||
lastValidCharacter(second, last);
|
|
||||||
|
|
||||||
if (last > 0)
|
|
||||||
{
|
|
||||||
string surname(second.begin(), second.begin() + last);
|
|
||||||
|
|
||||||
if (validName(surname))
|
|
||||||
{
|
|
||||||
surname = typoCorrection(surname);
|
|
||||||
return NamePair(name, surname);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// filter any single or two letter words as unlike to be names.
|
|
||||||
if (name.size() <= 2) return EmptyNamePair;
|
|
||||||
|
|
||||||
return NamePair(name, "");
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
bool submissionsSequence(const Words& words, unsigned int& i)
|
|
||||||
{
|
|
||||||
if (i + 1 >= words.size()) return false;
|
|
||||||
|
|
||||||
if (words[i] == "From" ||
|
|
||||||
words[i] == "from" ||
|
|
||||||
words[i] == "From:" ||
|
|
||||||
words[i] == "from:" ||
|
|
||||||
words[i] == "Merged" ||
|
|
||||||
words[i] == "Integrated") return true;
|
|
||||||
|
|
||||||
if (i + 2 >= words.size()) return false;
|
|
||||||
|
|
||||||
if (words[i] == "submitted" && words[i + 1] == "by")
|
|
||||||
{
|
|
||||||
i += 1;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (words[i] == "Folded" && words[i + 1] == "in")
|
|
||||||
{
|
|
||||||
i += 1;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (words[i] == "Rolled" && words[i + 1] == "in")
|
|
||||||
{
|
|
||||||
i += 1;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (words[i] == "Checked" && words[i + 1] == "in")
|
|
||||||
{
|
|
||||||
i += 1;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (i + 3 >= words.size()) return false;
|
|
||||||
|
|
||||||
if (words[i] == "sent" && words[i + 1] == "in" && words[i + 2] == "by")
|
|
||||||
{
|
|
||||||
i += 2;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
void readContributors(NameMap& names, const string& file)
|
|
||||||
{
|
|
||||||
osgDB::ifstream fin(file.c_str());
|
|
||||||
|
|
||||||
Words words;
|
|
||||||
while(fin)
|
|
||||||
{
|
|
||||||
string keyword;
|
|
||||||
fin >> keyword;
|
|
||||||
words.push_back(keyword);
|
|
||||||
}
|
|
||||||
|
|
||||||
string blank_string;
|
|
||||||
|
|
||||||
for(unsigned int i = 0; i < words.size(); ++i)
|
|
||||||
{
|
|
||||||
if (submissionsSequence(words, i))
|
|
||||||
{
|
|
||||||
if (i + 2 < words.size() && validName(words[i + 1]))
|
|
||||||
{
|
|
||||||
NamePair name = createName(words[i + 1], words[i + 2]);
|
|
||||||
nameCorrection(name);
|
|
||||||
if (!name.first.empty()) ++names[name];
|
|
||||||
i += 2;
|
|
||||||
}
|
|
||||||
else if (i + 1 < words.size() && validName(words[i + 1]))
|
|
||||||
{
|
|
||||||
NamePair name = createName(words[i + 1], blank_string);
|
|
||||||
nameCorrection(name);
|
|
||||||
if (!name.first.empty()) ++names[name];
|
|
||||||
i += 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
if (words[i] == "robert")
|
|
||||||
{
|
|
||||||
++names[NameRobertOsfield];
|
|
||||||
}
|
|
||||||
else if (words[i] == "don")
|
|
||||||
{
|
|
||||||
++names[NameDonBurns];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// reassign fisrt name entries to their full names entries
|
|
||||||
if (names.size() > 1)
|
|
||||||
{
|
|
||||||
for (NameMap::iterator itr = names.begin(); itr != names.end(); )
|
|
||||||
{
|
|
||||||
if (itr->first.second.empty())
|
|
||||||
{
|
|
||||||
NameMap::iterator next_itr = itr;
|
|
||||||
++next_itr;
|
|
||||||
|
|
||||||
if (next_itr != names.end() && itr->first.first == next_itr->first.first)
|
|
||||||
{
|
|
||||||
next_itr->second += itr->second;
|
|
||||||
names.erase(itr);
|
|
||||||
itr = next_itr;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
++itr;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
++itr;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// remove the double entries from Robert's contributions
|
|
||||||
if (names.size() > 1)
|
|
||||||
{
|
|
||||||
for (NameMap::iterator itr = names.begin(); itr != names.end(); ++itr)
|
|
||||||
{
|
|
||||||
if (itr->first != NameRobertOsfield && itr->first != NameDonBurns)
|
|
||||||
{
|
|
||||||
names[NameRobertOsfield] -= itr->second;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
void buildContributors(NameMap& names)
|
|
||||||
{
|
|
||||||
// top five contributors
|
|
||||||
++names[NamePair("Robert", "Osfield")];
|
|
||||||
++names[NamePair("Don", "Burns")];
|
|
||||||
++names[NamePair("Marco", "Jez")];
|
|
||||||
++names[NamePair("Mike", "Weiblen")];
|
|
||||||
++names[NamePair("Geoff", "Michel")];
|
|
||||||
++names[NamePair("Ben", "van Basten")];
|
|
||||||
|
|
||||||
// contributors that don't appear in the ChangeLog due to their contributions
|
|
||||||
// being before CVS started for the OSG, or before the name logging began.
|
|
||||||
++names[NamePair("Karsten", "Weiss")];
|
|
||||||
++names[NamePair("Graeme", "Harkness")];
|
|
||||||
++names[NamePair("Axel", "Volley")];
|
|
||||||
++names[NamePair("Nikolaus", "Hanekamp")];
|
|
||||||
++names[NamePair("Kristopher", "Bixler")];
|
|
||||||
++names[NamePair("Tanguy", "Fautr<EFBFBD>")];
|
|
||||||
++names[NamePair("J.E.", "Hoffmann")];
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
void printContributors(const std::string& changeLog, bool printNumEntries)
|
|
||||||
{
|
|
||||||
NameMap names;
|
|
||||||
buildContributors(names);
|
|
||||||
if (!changeLog.empty())
|
|
||||||
{
|
|
||||||
readContributors(names, changeLog);
|
|
||||||
}
|
|
||||||
|
|
||||||
typedef multimap<unsigned int, NamePair> SortedNameMap;
|
|
||||||
|
|
||||||
SortedNameMap sortedNames;
|
|
||||||
for (NameMap::iterator itr = names.begin(); itr != names.end(); ++itr)
|
|
||||||
{
|
|
||||||
sortedNames.insert(SortedNameMap::value_type(itr->second, itr->first));
|
|
||||||
}
|
|
||||||
|
|
||||||
cout << names.size() << " Contributors:" << endl << endl;
|
|
||||||
|
|
||||||
if (printNumEntries)
|
|
||||||
{
|
|
||||||
cout << "Entries Firstname Surname" << endl;
|
|
||||||
cout << "-------------------------" << endl;
|
|
||||||
for (SortedNameMap::reverse_iterator sitr = sortedNames.rbegin(); sitr != sortedNames.rend(); ++sitr)
|
|
||||||
{
|
|
||||||
cout << sitr->first << "\t" << sitr->second.first << " " << sitr->second.second << endl;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
cout << "Firstname Surname" << endl;
|
|
||||||
cout << "-----------------" << endl;
|
|
||||||
for (SortedNameMap::reverse_iterator sitr = sortedNames.rbegin(); sitr != sortedNames.rend(); ++sitr)
|
|
||||||
{
|
|
||||||
cout << sitr->second.first << " " << sitr->second.second << endl;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
File diff suppressed because it is too large
Load Diff
@@ -37,7 +37,7 @@
|
|||||||
#if defined(__linux)
|
#if defined(__linux)
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <linux/sockios.h>
|
#include <linux/sockios.h>
|
||||||
#elif defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
|
#elif defined(__FreeBSD__)
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <sys/sockio.h>
|
#include <sys/sockio.h>
|
||||||
#elif defined(__sgi)
|
#elif defined(__sgi)
|
||||||
|
|||||||
@@ -351,6 +351,7 @@ int main( int argc, char **argv )
|
|||||||
|
|
||||||
// set up the usage document, in case we need to print out how to use this program.
|
// set up the usage document, in case we need to print out how to use this program.
|
||||||
arguments.getApplicationUsage()->setApplicationName(arguments.getApplicationName());
|
arguments.getApplicationUsage()->setApplicationName(arguments.getApplicationName());
|
||||||
|
arguments.getApplicationUsage()->setDescription(arguments.getApplicationName()+" is the standard OpenSceneGraph example which loads and visualises 3d models.");
|
||||||
arguments.getApplicationUsage()->setCommandLineUsage(arguments.getApplicationName()+" [options] filename ...");
|
arguments.getApplicationUsage()->setCommandLineUsage(arguments.getApplicationName()+" [options] filename ...");
|
||||||
arguments.getApplicationUsage()->addCommandLineOption("--image <filename>","Load an image and render it on a quad");
|
arguments.getApplicationUsage()->addCommandLineOption("--image <filename>","Load an image and render it on a quad");
|
||||||
arguments.getApplicationUsage()->addCommandLineOption("--dem <filename>","Load an image/DEM and render it on a HeightField");
|
arguments.getApplicationUsage()->addCommandLineOption("--dem <filename>","Load an image/DEM and render it on a HeightField");
|
||||||
|
|||||||
@@ -604,6 +604,7 @@ int main(int argc, char** argv)
|
|||||||
osg::ArgumentParser arguments(&argc,argv);
|
osg::ArgumentParser arguments(&argc,argv);
|
||||||
|
|
||||||
arguments.getApplicationUsage()->setApplicationName(arguments.getApplicationName());
|
arguments.getApplicationUsage()->setApplicationName(arguments.getApplicationName());
|
||||||
|
arguments.getApplicationUsage()->setDescription(arguments.getApplicationName()+" is the standard OpenSceneGraph example which loads and visualises 3d models.");
|
||||||
arguments.getApplicationUsage()->setCommandLineUsage(arguments.getApplicationName()+" [options] filename ...");
|
arguments.getApplicationUsage()->setCommandLineUsage(arguments.getApplicationName()+" [options] filename ...");
|
||||||
|
|
||||||
osgViewer::Viewer viewer(arguments);
|
osgViewer::Viewer viewer(arguments);
|
||||||
|
|||||||
@@ -35,7 +35,7 @@ class BoundingSphereImpl
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
typedef VT vec_type;
|
typedef VT vec_type;
|
||||||
typedef typename VT::value_type value_type;
|
typedef typename vec_type::value_type value_type;
|
||||||
|
|
||||||
vec_type _center;
|
vec_type _center;
|
||||||
value_type _radius;
|
value_type _radius;
|
||||||
|
|||||||
@@ -16,8 +16,7 @@
|
|||||||
|
|
||||||
#include <osg/GL>
|
#include <osg/GL>
|
||||||
|
|
||||||
#if defined(__APPLE__) || \
|
#if defined(__APPLE__) || defined (_AIX)
|
||||||
(defined (_AIX) && !defined (_AIX51))
|
|
||||||
#include <OpenGL/glu.h>
|
#include <OpenGL/glu.h>
|
||||||
#else
|
#else
|
||||||
#include <GL/glu.h>
|
#include <GL/glu.h>
|
||||||
|
|||||||
@@ -44,9 +44,7 @@
|
|||||||
#include <float.h>
|
#include <float.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined (sun) || \
|
#if defined (sun) || defined (__APPLE__)
|
||||||
defined (__APPLE__) || \
|
|
||||||
(defined (_AIX) && defined (__GNUC__))
|
|
||||||
|
|
||||||
#include <float.h>
|
#include <float.h>
|
||||||
|
|
||||||
@@ -95,8 +93,7 @@
|
|||||||
|
|
||||||
#if defined (sun) || \
|
#if defined (sun) || \
|
||||||
defined (__hpux) || \
|
defined (__hpux) || \
|
||||||
defined (APPLE_PRE_10_2) || \
|
defined (APPLE_PRE_10_2)
|
||||||
(defined (_AIX) && defined (__GNUC__))
|
|
||||||
|
|
||||||
#ifndef floorf
|
#ifndef floorf
|
||||||
inline float floorf(float value) { return static_cast<float>(floor(value)); }
|
inline float floorf(float value) { return static_cast<float>(floor(value)); }
|
||||||
|
|||||||
@@ -29,7 +29,7 @@ class Vec2b
|
|||||||
// Methods are defined here so that they are implicitly inlined
|
// Methods are defined here so that they are implicitly inlined
|
||||||
|
|
||||||
/** Type of Vec class.*/
|
/** Type of Vec class.*/
|
||||||
typedef signed char value_type;
|
typedef char value_type;
|
||||||
|
|
||||||
/** Number of vector components. */
|
/** Number of vector components. */
|
||||||
enum { num_components = 2 };
|
enum { num_components = 2 };
|
||||||
@@ -39,7 +39,7 @@ class Vec2b
|
|||||||
|
|
||||||
Vec2b() { _v[0]=0; _v[1]=0; }
|
Vec2b() { _v[0]=0; _v[1]=0; }
|
||||||
|
|
||||||
Vec2b(value_type r, value_type g)
|
Vec2b(char r, char g)
|
||||||
{
|
{
|
||||||
_v[0]=r; _v[1]=g;
|
_v[0]=r; _v[1]=g;
|
||||||
}
|
}
|
||||||
@@ -94,8 +94,8 @@ class Vec2b
|
|||||||
/** Unary multiply by scalar. */
|
/** Unary multiply by scalar. */
|
||||||
inline Vec2b& operator *= (float rhs)
|
inline Vec2b& operator *= (float rhs)
|
||||||
{
|
{
|
||||||
_v[0]=(value_type)((float)_v[0]*rhs);
|
_v[0]=(char)((float)_v[0]*rhs);
|
||||||
_v[1]=(value_type)((float)_v[1]*rhs);
|
_v[1]=(char)((float)_v[1]*rhs);
|
||||||
return *this;
|
return *this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -27,7 +27,7 @@ class Vec3b
|
|||||||
public:
|
public:
|
||||||
|
|
||||||
/** Type of Vec class.*/
|
/** Type of Vec class.*/
|
||||||
typedef signed char value_type;
|
typedef char value_type;
|
||||||
|
|
||||||
/** Number of vector components. */
|
/** Number of vector components. */
|
||||||
enum { num_components = 3 };
|
enum { num_components = 3 };
|
||||||
@@ -94,9 +94,9 @@ class Vec3b
|
|||||||
/** Unary multiply by scalar. */
|
/** Unary multiply by scalar. */
|
||||||
inline Vec3b& operator *= (float rhs)
|
inline Vec3b& operator *= (float rhs)
|
||||||
{
|
{
|
||||||
_v[0]=(value_type)((float)_v[0]*rhs);
|
_v[0]=(char)((float)_v[0]*rhs);
|
||||||
_v[1]=(value_type)((float)_v[1]*rhs);
|
_v[1]=(char)((float)_v[1]*rhs);
|
||||||
_v[2]=(value_type)((float)_v[2]*rhs);
|
_v[2]=(char)((float)_v[2]*rhs);
|
||||||
return *this;
|
return *this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -27,7 +27,7 @@ class Vec4b
|
|||||||
public:
|
public:
|
||||||
|
|
||||||
/** Type of Vec class.*/
|
/** Type of Vec class.*/
|
||||||
typedef signed char value_type;
|
typedef char value_type;
|
||||||
|
|
||||||
/** Number of vector components. */
|
/** Number of vector components. */
|
||||||
enum { num_components = 4 };
|
enum { num_components = 4 };
|
||||||
@@ -101,10 +101,10 @@ class Vec4b
|
|||||||
/** Unary multiply by scalar. */
|
/** Unary multiply by scalar. */
|
||||||
inline Vec4b& operator *= (float rhs)
|
inline Vec4b& operator *= (float rhs)
|
||||||
{
|
{
|
||||||
_v[0]=(value_type)((float)_v[0]*rhs);
|
_v[0]=(char)((float)_v[0]*rhs);
|
||||||
_v[1]=(value_type)((float)_v[1]*rhs);
|
_v[1]=(char)((float)_v[1]*rhs);
|
||||||
_v[2]=(value_type)((float)_v[2]*rhs);
|
_v[2]=(char)((float)_v[2]*rhs);
|
||||||
_v[3]=(value_type)((float)_v[3]*rhs);
|
_v[3]=(char)((float)_v[3]*rhs);
|
||||||
return *this;
|
return *this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -62,26 +62,26 @@ class Vec4ub
|
|||||||
else return (_v[3]<v._v[3]);
|
else return (_v[3]<v._v[3]);
|
||||||
}
|
}
|
||||||
|
|
||||||
inline value_type* ptr() { return _v; }
|
inline unsigned char* ptr() { return _v; }
|
||||||
inline const value_type* ptr() const { return _v; }
|
inline const unsigned char* ptr() const { return _v; }
|
||||||
|
|
||||||
inline void set(value_type r, value_type g, value_type b, value_type a)
|
inline void set(unsigned char r, unsigned char g, unsigned char b, unsigned char a)
|
||||||
{
|
{
|
||||||
_v[0]=r; _v[1]=g; _v[2]=b; _v[3]=a;
|
_v[0]=r; _v[1]=g; _v[2]=b; _v[3]=a;
|
||||||
}
|
}
|
||||||
|
|
||||||
inline value_type& operator [] (unsigned int i) { return _v[i]; }
|
inline unsigned char& operator [] (unsigned int i) { return _v[i]; }
|
||||||
inline value_type operator [] (unsigned int i) const { return _v[i]; }
|
inline unsigned char operator [] (unsigned int i) const { return _v[i]; }
|
||||||
|
|
||||||
inline value_type& r() { return _v[0]; }
|
inline unsigned char& r() { return _v[0]; }
|
||||||
inline value_type& g() { return _v[1]; }
|
inline unsigned char& g() { return _v[1]; }
|
||||||
inline value_type& b() { return _v[2]; }
|
inline unsigned char& b() { return _v[2]; }
|
||||||
inline value_type& a() { return _v[3]; }
|
inline unsigned char& a() { return _v[3]; }
|
||||||
|
|
||||||
inline value_type r() const { return _v[0]; }
|
inline unsigned char r() const { return _v[0]; }
|
||||||
inline value_type g() const { return _v[1]; }
|
inline unsigned char g() const { return _v[1]; }
|
||||||
inline value_type b() const { return _v[2]; }
|
inline unsigned char b() const { return _v[2]; }
|
||||||
inline value_type a() const { return _v[3]; }
|
inline unsigned char a() const { return _v[3]; }
|
||||||
|
|
||||||
/** Multiply by scalar. */
|
/** Multiply by scalar. */
|
||||||
inline Vec4ub operator * (float rhs) const
|
inline Vec4ub operator * (float rhs) const
|
||||||
@@ -94,10 +94,10 @@ class Vec4ub
|
|||||||
/** Unary multiply by scalar. */
|
/** Unary multiply by scalar. */
|
||||||
inline Vec4ub& operator *= (float rhs)
|
inline Vec4ub& operator *= (float rhs)
|
||||||
{
|
{
|
||||||
_v[0]=(value_type)((float)_v[0]*rhs);
|
_v[0]=(unsigned char)((float)_v[0]*rhs);
|
||||||
_v[1]=(value_type)((float)_v[1]*rhs);
|
_v[1]=(unsigned char)((float)_v[1]*rhs);
|
||||||
_v[2]=(value_type)((float)_v[2]*rhs);
|
_v[2]=(unsigned char)((float)_v[2]*rhs);
|
||||||
_v[3]=(value_type)((float)_v[3]*rhs);
|
_v[3]=(unsigned char)((float)_v[3]*rhs);
|
||||||
return *this;
|
return *this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -21,7 +21,7 @@ extern "C" {
|
|||||||
|
|
||||||
#define OPENSCENEGRAPH_MAJOR_VERSION 2
|
#define OPENSCENEGRAPH_MAJOR_VERSION 2
|
||||||
#define OPENSCENEGRAPH_MINOR_VERSION 8
|
#define OPENSCENEGRAPH_MINOR_VERSION 8
|
||||||
#define OPENSCENEGRAPH_PATCH_VERSION 1
|
#define OPENSCENEGRAPH_PATCH_VERSION 0
|
||||||
#define OPENSCENEGRAPH_SOVERSION 55
|
#define OPENSCENEGRAPH_SOVERSION 55
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -31,7 +31,12 @@ namespace osgUtil {
|
|||||||
|
|
||||||
class OSGUTIL_EXPORT Hit
|
class OSGUTIL_EXPORT Hit
|
||||||
{
|
{
|
||||||
/** Deprecated */
|
/** Describes a point in space produced by an intersection of a line with a scene.
|
||||||
|
* A Hit is always on a surface as rendered by the Open Scene Graph scene (usually
|
||||||
|
* a triangle or other primitive, but a special hit handler could return a
|
||||||
|
* different value perhaps: a sphere shape might return a Hit on the true sphere
|
||||||
|
* rather than the approximate tessellated sphere rendered.
|
||||||
|
*/
|
||||||
public:
|
public:
|
||||||
|
|
||||||
Hit();
|
Hit();
|
||||||
@@ -89,7 +94,7 @@ class OSGUTIL_EXPORT Hit
|
|||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
/** Deprecated - use IntersectionVisitor instead.*/
|
/** Basic visitor for ray based collisions of a scene.*/
|
||||||
class OSGUTIL_EXPORT IntersectVisitor : public osg::NodeVisitor
|
class OSGUTIL_EXPORT IntersectVisitor : public osg::NodeVisitor
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
|||||||
@@ -94,4 +94,4 @@ CONFIGURE_FILE(${PROJECT_SOURCE_DIR}/packaging/pkgconfig/openthreads.pc.in
|
|||||||
@ONLY
|
@ONLY
|
||||||
)
|
)
|
||||||
|
|
||||||
INSTALL(FILES ${PROJECT_BINARY_DIR}/packaging/pkgconfig/openthreads.pc DESTINATION lib${LIB_POSTFIX}/pkgconfig COMPONENT libopenthreads-dev)
|
INSTALL(FILES ${PROJECT_BINARY_DIR}/packaging/pkgconfig/openthreads.pc DESTINATION lib${LIB_POSTFIX}/pkgconfig)
|
||||||
|
|||||||
@@ -50,6 +50,9 @@
|
|||||||
|
|
||||||
using namespace OpenThreads;
|
using namespace OpenThreads;
|
||||||
|
|
||||||
|
extern int errno;
|
||||||
|
const char *OPENTHREAD_VERSION_STRING = "OpenThreads v1.2preAlpha, Posix Threads (Public Implementation)";
|
||||||
|
|
||||||
#ifdef DEBUG
|
#ifdef DEBUG
|
||||||
# define DPRINTF(arg) printf arg
|
# define DPRINTF(arg) printf arg
|
||||||
#else
|
#else
|
||||||
|
|||||||
@@ -98,7 +98,7 @@ namespace OpenThreads {
|
|||||||
|
|
||||||
if (thread->_prvData==0) return 0;
|
if (thread->_prvData==0) return 0;
|
||||||
|
|
||||||
TlsSetValue(Win32ThreadPrivateData::TLS.getId(), data);
|
TlsSetValue(Win32ThreadPrivateData::TLS.ID ,data);
|
||||||
//---------------------------------------------------------------------
|
//---------------------------------------------------------------------
|
||||||
// Set the proper scheduling priorities
|
// Set the proper scheduling priorities
|
||||||
//
|
//
|
||||||
@@ -127,7 +127,6 @@ namespace OpenThreads {
|
|||||||
// abnormal termination but must be caught in win32 anyway
|
// abnormal termination but must be caught in win32 anyway
|
||||||
}
|
}
|
||||||
|
|
||||||
TlsSetValue(Win32ThreadPrivateData::TLS.getId(), 0);
|
|
||||||
pd->isRunning = false;
|
pd->isRunning = false;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
@@ -208,7 +207,7 @@ namespace OpenThreads {
|
|||||||
|
|
||||||
Thread* Thread::CurrentThread()
|
Thread* Thread::CurrentThread()
|
||||||
{
|
{
|
||||||
return (Thread* )TlsGetValue(Win32ThreadPrivateData::TLS.getId());
|
return (Thread* )TlsGetValue(Win32ThreadPrivateData::TLS.ID);
|
||||||
};
|
};
|
||||||
|
|
||||||
//----------------------------------------------------------------------------
|
//----------------------------------------------------------------------------
|
||||||
@@ -345,13 +344,13 @@ int Thread::start() {
|
|||||||
|
|
||||||
pd->uniqueId = (int)ID;
|
pd->uniqueId = (int)ID;
|
||||||
|
|
||||||
|
// wait till the thread has actually started.
|
||||||
|
pd->threadStartedBlock.block();
|
||||||
|
|
||||||
if(!pd->tid) {
|
if(!pd->tid) {
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
// wait till the thread has actually started.
|
|
||||||
pd->threadStartedBlock.block();
|
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -69,20 +69,12 @@ public:
|
|||||||
HandleHolder cancelEvent;
|
HandleHolder cancelEvent;
|
||||||
|
|
||||||
struct TlsHolder{ // thread local storage slot
|
struct TlsHolder{ // thread local storage slot
|
||||||
DWORD getId()
|
DWORD ID;
|
||||||
{
|
TlsHolder(): ID(TlsAlloc()){
|
||||||
static bool initialized = false;
|
|
||||||
if (!initialized) {
|
|
||||||
ID = TlsAlloc();
|
|
||||||
initialized = true;
|
|
||||||
}
|
|
||||||
return ID;
|
|
||||||
}
|
}
|
||||||
~TlsHolder(){
|
~TlsHolder(){
|
||||||
TlsFree(ID);
|
TlsFree(ID);
|
||||||
}
|
}
|
||||||
private:
|
|
||||||
DWORD ID;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
static TlsHolder TLS;
|
static TlsHolder TLS;
|
||||||
|
|||||||
@@ -223,6 +223,7 @@ Drawable::Drawable()
|
|||||||
Drawable::Drawable(const Drawable& drawable,const CopyOp& copyop):
|
Drawable::Drawable(const Drawable& drawable,const CopyOp& copyop):
|
||||||
Object(drawable,copyop),
|
Object(drawable,copyop),
|
||||||
_parents(), // leave empty as parentList is managed by Geode
|
_parents(), // leave empty as parentList is managed by Geode
|
||||||
|
_stateset(copyop(drawable._stateset.get())),
|
||||||
_initialBound(drawable._initialBound),
|
_initialBound(drawable._initialBound),
|
||||||
_computeBoundCallback(drawable._computeBoundCallback),
|
_computeBoundCallback(drawable._computeBoundCallback),
|
||||||
_boundingBox(drawable._boundingBox),
|
_boundingBox(drawable._boundingBox),
|
||||||
@@ -239,7 +240,6 @@ Drawable::Drawable(const Drawable& drawable,const CopyOp& copyop):
|
|||||||
_cullCallback(drawable._cullCallback),
|
_cullCallback(drawable._cullCallback),
|
||||||
_drawCallback(drawable._drawCallback)
|
_drawCallback(drawable._drawCallback)
|
||||||
{
|
{
|
||||||
setStateSet(copyop(drawable._stateset.get()));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Drawable::~Drawable()
|
Drawable::~Drawable()
|
||||||
@@ -443,17 +443,6 @@ void Drawable::dirtyBound()
|
|||||||
|
|
||||||
void Drawable::compileGLObjects(RenderInfo& renderInfo) const
|
void Drawable::compileGLObjects(RenderInfo& renderInfo) const
|
||||||
{
|
{
|
||||||
bool useVertexArrays = _supportsVertexBufferObjects && _useVertexBufferObjects && renderInfo.getState()->isVertexBufferObjectSupported();
|
|
||||||
if (useVertexArrays)
|
|
||||||
{
|
|
||||||
if (_drawCallback.valid())
|
|
||||||
_drawCallback->drawImplementation(renderInfo,this);
|
|
||||||
else
|
|
||||||
drawImplementation(renderInfo);
|
|
||||||
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!_useDisplayList) return;
|
if (!_useDisplayList) return;
|
||||||
|
|
||||||
// get the contextID (user defined ID of 0 upwards) for the
|
// get the contextID (user defined ID of 0 upwards) for the
|
||||||
|
|||||||
@@ -3084,7 +3084,7 @@ void Geometry::copyToAndOptimize(Geometry& target)
|
|||||||
if (!copyToSelf) target.getPrimitiveSetList() = getPrimitiveSetList();
|
if (!copyToSelf) target.getPrimitiveSetList() = getPrimitiveSetList();
|
||||||
|
|
||||||
// copy over attribute arrays.
|
// copy over attribute arrays.
|
||||||
if (getVertexIndices() && getVertexArray())
|
if (getVertexIndices())
|
||||||
{
|
{
|
||||||
ExpandIndexedArray eia(*(getVertexIndices()),target.getVertexArray());
|
ExpandIndexedArray eia(*(getVertexIndices()),target.getVertexArray());
|
||||||
getVertexArray()->accept(eia);
|
getVertexArray()->accept(eia);
|
||||||
@@ -3098,7 +3098,7 @@ void Geometry::copyToAndOptimize(Geometry& target)
|
|||||||
}
|
}
|
||||||
|
|
||||||
target.setNormalBinding(getNormalBinding());
|
target.setNormalBinding(getNormalBinding());
|
||||||
if (getNormalIndices() && getNormalArray())
|
if (getNormalIndices())
|
||||||
{
|
{
|
||||||
ExpandIndexedArray eia(*(getNormalIndices()),target.getNormalArray());
|
ExpandIndexedArray eia(*(getNormalIndices()),target.getNormalArray());
|
||||||
getNormalArray()->accept(eia);
|
getNormalArray()->accept(eia);
|
||||||
@@ -3112,7 +3112,7 @@ void Geometry::copyToAndOptimize(Geometry& target)
|
|||||||
}
|
}
|
||||||
|
|
||||||
target.setColorBinding(getColorBinding());
|
target.setColorBinding(getColorBinding());
|
||||||
if (getColorIndices() && getColorArray())
|
if (getColorIndices())
|
||||||
{
|
{
|
||||||
ExpandIndexedArray eia(*(getColorIndices()),target.getColorArray());
|
ExpandIndexedArray eia(*(getColorIndices()),target.getColorArray());
|
||||||
getColorArray()->accept(eia);
|
getColorArray()->accept(eia);
|
||||||
@@ -3126,7 +3126,7 @@ void Geometry::copyToAndOptimize(Geometry& target)
|
|||||||
}
|
}
|
||||||
|
|
||||||
target.setSecondaryColorBinding(getSecondaryColorBinding());
|
target.setSecondaryColorBinding(getSecondaryColorBinding());
|
||||||
if (getSecondaryColorIndices() && getSecondaryColorArray())
|
if (getSecondaryColorIndices())
|
||||||
{
|
{
|
||||||
ExpandIndexedArray eia(*(getSecondaryColorIndices()),target.getSecondaryColorArray());
|
ExpandIndexedArray eia(*(getSecondaryColorIndices()),target.getSecondaryColorArray());
|
||||||
getSecondaryColorArray()->accept(eia);
|
getSecondaryColorArray()->accept(eia);
|
||||||
@@ -3140,7 +3140,7 @@ void Geometry::copyToAndOptimize(Geometry& target)
|
|||||||
}
|
}
|
||||||
|
|
||||||
target.setFogCoordBinding(getFogCoordBinding());
|
target.setFogCoordBinding(getFogCoordBinding());
|
||||||
if (getFogCoordIndices() && getFogCoordArray())
|
if (getFogCoordIndices())
|
||||||
{
|
{
|
||||||
ExpandIndexedArray eia(*(getFogCoordIndices()),target.getFogCoordArray());
|
ExpandIndexedArray eia(*(getFogCoordIndices()),target.getFogCoordArray());
|
||||||
getFogCoordArray()->accept(eia);
|
getFogCoordArray()->accept(eia);
|
||||||
@@ -3155,10 +3155,9 @@ void Geometry::copyToAndOptimize(Geometry& target)
|
|||||||
|
|
||||||
for(unsigned int ti=0;ti<getNumTexCoordArrays();++ti)
|
for(unsigned int ti=0;ti<getNumTexCoordArrays();++ti)
|
||||||
{
|
{
|
||||||
if (getTexCoordIndices(ti) && getTexCoordArray(ti))
|
if (getTexCoordIndices(ti))
|
||||||
{
|
{
|
||||||
ExpandIndexedArray eia(*(getTexCoordIndices(ti)),target.getTexCoordArray(ti));
|
ExpandIndexedArray eia(*(getTexCoordIndices(ti)),target.getTexCoordArray(ti));
|
||||||
|
|
||||||
getTexCoordArray(ti)->accept(eia);
|
getTexCoordArray(ti)->accept(eia);
|
||||||
|
|
||||||
target.setTexCoordArray(ti,eia._targetArray);
|
target.setTexCoordArray(ti,eia._targetArray);
|
||||||
|
|||||||
@@ -818,26 +818,14 @@ void GraphicsContext::resizedImplementation(int x, int y, int width, int height)
|
|||||||
{
|
{
|
||||||
osg::View* view = camera->getView();
|
osg::View* view = camera->getView();
|
||||||
osg::View::Slave* slave = view ? view->findSlaveForCamera(camera) : 0;
|
osg::View::Slave* slave = view ? view->findSlaveForCamera(camera) : 0;
|
||||||
|
|
||||||
if (slave)
|
if (slave && camera->getReferenceFrame()==osg::Transform::RELATIVE_RF)
|
||||||
{
|
{
|
||||||
if (camera->getReferenceFrame()==osg::Transform::RELATIVE_RF)
|
switch(view->getCamera()->getProjectionResizePolicy())
|
||||||
{
|
{
|
||||||
switch(view->getCamera()->getProjectionResizePolicy())
|
case(osg::Camera::HORIZONTAL): slave->_projectionOffset *= osg::Matrix::scale(1.0/aspectRatioChange,1.0,1.0); break;
|
||||||
{
|
case(osg::Camera::VERTICAL): slave->_projectionOffset *= osg::Matrix::scale(1.0, aspectRatioChange,1.0); break;
|
||||||
case(osg::Camera::HORIZONTAL): slave->_projectionOffset *= osg::Matrix::scale(1.0/aspectRatioChange,1.0,1.0); break;
|
default: break;
|
||||||
case(osg::Camera::VERTICAL): slave->_projectionOffset *= osg::Matrix::scale(1.0, aspectRatioChange,1.0); break;
|
|
||||||
default: break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
switch(camera->getProjectionResizePolicy())
|
|
||||||
{
|
|
||||||
case(osg::Camera::HORIZONTAL): camera->getProjectionMatrix() *= osg::Matrix::scale(1.0/aspectRatioChange,1.0,1.0); break;
|
|
||||||
case(osg::Camera::VERTICAL): camera->getProjectionMatrix() *= osg::Matrix::scale(1.0, aspectRatioChange,1.0); break;
|
|
||||||
default: break;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@@ -851,10 +839,10 @@ void GraphicsContext::resizedImplementation(int x, int y, int width, int height)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
_traits->x = x;
|
_traits->x = x;
|
||||||
_traits->y = y;
|
_traits->y = y;
|
||||||
_traits->width = width;
|
_traits->width = width;
|
||||||
|
|||||||
@@ -37,9 +37,6 @@ void GraphicsThread::run()
|
|||||||
|
|
||||||
OperationThread::run();
|
OperationThread::run();
|
||||||
|
|
||||||
// release operations before the thread stops working.
|
|
||||||
_operationQueue->releaseAllOperations();
|
|
||||||
|
|
||||||
if (graphicsContext)
|
if (graphicsContext)
|
||||||
{
|
{
|
||||||
graphicsContext->releaseContext();
|
graphicsContext->releaseContext();
|
||||||
|
|||||||
@@ -319,7 +319,6 @@ unsigned int Image::computeNumComponents(GLenum pixelFormat)
|
|||||||
case(GL_RGBA32F_ARB): return 4;
|
case(GL_RGBA32F_ARB): return 4;
|
||||||
case(GL_RGBA): return 4;
|
case(GL_RGBA): return 4;
|
||||||
case(GL_BGRA): return 4;
|
case(GL_BGRA): return 4;
|
||||||
case(GL_RGBA8): return 4;
|
|
||||||
case(GL_LUMINANCE): return 1;
|
case(GL_LUMINANCE): return 1;
|
||||||
case(GL_LUMINANCE4): return 1;
|
case(GL_LUMINANCE4): return 1;
|
||||||
case(GL_LUMINANCE8): return 1;
|
case(GL_LUMINANCE8): return 1;
|
||||||
|
|||||||
@@ -82,9 +82,9 @@ Node::Node(const Node& node,const CopyOp& copyop):
|
|||||||
_numChildrenWithCullingDisabled(0), // assume no children yet.
|
_numChildrenWithCullingDisabled(0), // assume no children yet.
|
||||||
_numChildrenWithOccluderNodes(0),
|
_numChildrenWithOccluderNodes(0),
|
||||||
_nodeMask(node._nodeMask),
|
_nodeMask(node._nodeMask),
|
||||||
_descriptions(node._descriptions)
|
_descriptions(node._descriptions),
|
||||||
|
_stateset(copyop(node._stateset.get()))
|
||||||
{
|
{
|
||||||
setStateSet(copyop(node._stateset.get()));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Node::~Node()
|
Node::~Node()
|
||||||
|
|||||||
@@ -55,7 +55,6 @@ void PolygonOffset::setFactorAndUnitsMultipliersUsingBestGuessForDriver()
|
|||||||
s_MultiplerSet = true;
|
s_MultiplerSet = true;
|
||||||
// osg::notify(osg::NOTICE)<<"PolygonOffset::setFactorAndUnitMultipliersUsingBestGuessForDriver()"<<std::endl;
|
// osg::notify(osg::NOTICE)<<"PolygonOffset::setFactorAndUnitMultipliersUsingBestGuessForDriver()"<<std::endl;
|
||||||
|
|
||||||
#if 0
|
|
||||||
const GLubyte* renderer = glGetString(GL_RENDERER);
|
const GLubyte* renderer = glGetString(GL_RENDERER);
|
||||||
if (renderer)
|
if (renderer)
|
||||||
{
|
{
|
||||||
@@ -68,7 +67,6 @@ void PolygonOffset::setFactorAndUnitsMultipliersUsingBestGuessForDriver()
|
|||||||
osg::notify(osg::INFO)<<"PolygonOffset::setFactorAndUnitsMultipliersUsingBestGuessForDriver() apply ATI workaround."<<std::endl;
|
osg::notify(osg::INFO)<<"PolygonOffset::setFactorAndUnitsMultipliersUsingBestGuessForDriver() apply ATI workaround."<<std::endl;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -180,18 +180,18 @@ void DrawElementsUShort::draw(State& state, bool useVertexBufferObjects) const
|
|||||||
state.bindElementBufferObject(ebo);
|
state.bindElementBufferObject(ebo);
|
||||||
if (ebo)
|
if (ebo)
|
||||||
{
|
{
|
||||||
if (_numInstances>=1) state.glDrawElementsInstanced(_mode, size(), GL_UNSIGNED_SHORT, getElementBufferObjectOffset(), _numInstances);
|
if (_numInstances>=1) state.glDrawElementsInstanced(_mode, size(), GL_UNSIGNED_BYTE, getElementBufferObjectOffset(), _numInstances);
|
||||||
else glDrawElements(_mode, size(), GL_UNSIGNED_SHORT, getElementBufferObjectOffset());
|
else glDrawElements(_mode, size(), GL_UNSIGNED_SHORT, getElementBufferObjectOffset());
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (_numInstances>=1) state.glDrawElementsInstanced(_mode, size(), GL_UNSIGNED_SHORT, &front(), _numInstances);
|
if (_numInstances>=1) state.glDrawElementsInstanced(_mode, size(), GL_UNSIGNED_BYTE, &front(), _numInstances);
|
||||||
else glDrawElements(_mode, size(), GL_UNSIGNED_SHORT, &front());
|
else glDrawElements(_mode, size(), GL_UNSIGNED_SHORT, &front());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (_numInstances>=1) state.glDrawElementsInstanced(_mode, size(), GL_UNSIGNED_SHORT, &front(), _numInstances);
|
if (_numInstances>=1) state.glDrawElementsInstanced(_mode, size(), GL_UNSIGNED_BYTE, &front(), _numInstances);
|
||||||
else glDrawElements(_mode, size(), GL_UNSIGNED_SHORT, &front());
|
else glDrawElements(_mode, size(), GL_UNSIGNED_SHORT, &front());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -230,18 +230,18 @@ void DrawElementsUInt::draw(State& state, bool useVertexBufferObjects) const
|
|||||||
state.bindElementBufferObject(ebo);
|
state.bindElementBufferObject(ebo);
|
||||||
if (ebo)
|
if (ebo)
|
||||||
{
|
{
|
||||||
if (_numInstances>=1) state.glDrawElementsInstanced(_mode, size(), GL_UNSIGNED_INT, getElementBufferObjectOffset(), _numInstances);
|
if (_numInstances>=1) state.glDrawElementsInstanced(_mode, size(), GL_UNSIGNED_BYTE, getElementBufferObjectOffset(), _numInstances);
|
||||||
else glDrawElements(_mode, size(), GL_UNSIGNED_INT, getElementBufferObjectOffset());
|
else glDrawElements(_mode, size(), GL_UNSIGNED_INT, getElementBufferObjectOffset());
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (_numInstances>=1) state.glDrawElementsInstanced(_mode, size(), GL_UNSIGNED_INT, &front(), _numInstances);
|
if (_numInstances>=1) state.glDrawElementsInstanced(_mode, size(), GL_UNSIGNED_BYTE, &front(), _numInstances);
|
||||||
else glDrawElements(_mode, size(), GL_UNSIGNED_INT, &front());
|
else glDrawElements(_mode, size(), GL_UNSIGNED_INT, &front());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (_numInstances>=1) state.glDrawElementsInstanced(_mode, size(), GL_UNSIGNED_INT, &front(), _numInstances);
|
if (_numInstances>=1) state.glDrawElementsInstanced(_mode, size(), GL_UNSIGNED_BYTE, &front(), _numInstances);
|
||||||
else glDrawElements(_mode, size(), GL_UNSIGNED_INT, &front());
|
else glDrawElements(_mode, size(), GL_UNSIGNED_INT, &front());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -193,7 +193,6 @@ void State::reset()
|
|||||||
++apitr)
|
++apitr)
|
||||||
{
|
{
|
||||||
(*apitr)->resetAppliedUniforms();
|
(*apitr)->resetAppliedUniforms();
|
||||||
(*apitr)->removeObserver(this);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
_appliedProgramObjectSet.clear();
|
_appliedProgramObjectSet.clear();
|
||||||
|
|||||||
@@ -603,7 +603,7 @@ void Texture::computeInternalFormatWithImage(const osg::Image& image) const
|
|||||||
switch(image.getPixelFormat())
|
switch(image.getPixelFormat())
|
||||||
{
|
{
|
||||||
case(3):
|
case(3):
|
||||||
case(GL_RGB): internalFormat = GL_COMPRESSED_RGBA_S3TC_DXT3_EXT; break;
|
case(GL_RGB): internalFormat = GL_COMPRESSED_RGB_S3TC_DXT1_EXT; break;
|
||||||
case(4):
|
case(4):
|
||||||
case(GL_RGBA): internalFormat = GL_COMPRESSED_RGBA_S3TC_DXT3_EXT; break;
|
case(GL_RGBA): internalFormat = GL_COMPRESSED_RGBA_S3TC_DXT3_EXT; break;
|
||||||
default: internalFormat = image.getInternalTextureFormat(); break;
|
default: internalFormat = image.getInternalTextureFormat(); break;
|
||||||
@@ -618,7 +618,7 @@ void Texture::computeInternalFormatWithImage(const osg::Image& image) const
|
|||||||
switch(image.getPixelFormat())
|
switch(image.getPixelFormat())
|
||||||
{
|
{
|
||||||
case(3):
|
case(3):
|
||||||
case(GL_RGB): internalFormat = GL_COMPRESSED_RGBA_S3TC_DXT5_EXT; break;
|
case(GL_RGB): internalFormat = GL_COMPRESSED_RGB_S3TC_DXT1_EXT; break;
|
||||||
case(4):
|
case(4):
|
||||||
case(GL_RGBA): internalFormat = GL_COMPRESSED_RGBA_S3TC_DXT5_EXT; break;
|
case(GL_RGBA): internalFormat = GL_COMPRESSED_RGBA_S3TC_DXT5_EXT; break;
|
||||||
default: internalFormat = image.getInternalTextureFormat(); break;
|
default: internalFormat = image.getInternalTextureFormat(); break;
|
||||||
|
|||||||
@@ -95,7 +95,7 @@ IF(OPENVRML_FOUND)
|
|||||||
ENDIF(OPENVRML_FOUND)
|
ENDIF(OPENVRML_FOUND)
|
||||||
|
|
||||||
|
|
||||||
ADD_DEFINITIONS(-DOSG_PLUGIN_EXTENSION=${CMAKE_SHARED_MODULE_SUFFIX})
|
ADD_DEFINITIONS(-DOSG_PLUGIN_EXTENSION=${CMAKE_SHARED_LIBRARY_SUFFIX})
|
||||||
|
|
||||||
LINK_INTERNAL(${LIB_NAME}
|
LINK_INTERNAL(${LIB_NAME}
|
||||||
osg
|
osg
|
||||||
|
|||||||
@@ -111,7 +111,7 @@ RefPtrAdapter<FuncObj> refPtrAdapt(const FuncObj& func)
|
|||||||
class DatabasePager::FindCompileableGLObjectsVisitor : public osg::NodeVisitor
|
class DatabasePager::FindCompileableGLObjectsVisitor : public osg::NodeVisitor
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
FindCompileableGLObjectsVisitor(DatabasePager::DataToCompile* dataToCompile,
|
FindCompileableGLObjectsVisitor(DatabasePager::DataToCompile& dataToCompile,
|
||||||
bool changeAutoUnRef, bool valueAutoUnRef,
|
bool changeAutoUnRef, bool valueAutoUnRef,
|
||||||
bool changeAnisotropy, float valueAnisotropy,
|
bool changeAnisotropy, float valueAnisotropy,
|
||||||
DatabasePager::DrawablePolicy drawablePolicy,
|
DatabasePager::DrawablePolicy drawablePolicy,
|
||||||
@@ -127,34 +127,36 @@ public:
|
|||||||
{
|
{
|
||||||
_kdTreeBuilder = osgDB::Registry::instance()->getKdTreeBuilder()->clone();
|
_kdTreeBuilder = osgDB::Registry::instance()->getKdTreeBuilder()->clone();
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
META_NodeVisitor("osgDB","FindCompileableGLObjectsVisitor")
|
META_NodeVisitor("osgDB","FindCompileableGLObjectsVisitor")
|
||||||
|
|
||||||
virtual void apply(osg::Node& node)
|
virtual void apply(osg::Node& node)
|
||||||
{
|
{
|
||||||
apply(node.getStateSet());
|
apply(node.getStateSet());
|
||||||
|
|
||||||
traverse(node);
|
traverse(node);
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void apply(osg::Geode& geode)
|
virtual void apply(osg::Geode& geode)
|
||||||
{
|
{
|
||||||
apply(geode.getStateSet());
|
apply(geode.getStateSet());
|
||||||
|
|
||||||
for(unsigned int i=0;i<geode.getNumDrawables();++i)
|
for(unsigned int i=0;i<geode.getNumDrawables();++i)
|
||||||
{
|
{
|
||||||
apply(geode.getDrawable(i));
|
apply(geode.getDrawable(i));
|
||||||
}
|
}
|
||||||
|
|
||||||
traverse(geode);
|
traverse(geode);
|
||||||
|
|
||||||
if (_kdTreeBuilder.valid())
|
if (_kdTreeBuilder.valid())
|
||||||
{
|
{
|
||||||
geode.accept(*_kdTreeBuilder);
|
geode.accept(*_kdTreeBuilder);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
inline void apply(osg::StateSet* stateset)
|
inline void apply(osg::StateSet* stateset)
|
||||||
{
|
{
|
||||||
if (stateset)
|
if (stateset)
|
||||||
@@ -179,7 +181,7 @@ public:
|
|||||||
if (_changeAnisotropy)
|
if (_changeAnisotropy)
|
||||||
texture->setMaxAnisotropy(_valueAnisotropy);
|
texture->setMaxAnisotropy(_valueAnisotropy);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!_pager->isCompiled(texture))
|
if (!_pager->isCompiled(texture))
|
||||||
{
|
{
|
||||||
compileStateSet = true;
|
compileStateSet = true;
|
||||||
@@ -195,23 +197,23 @@ public:
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (compileStateSet && _dataToCompile)
|
if (compileStateSet)
|
||||||
{
|
{
|
||||||
_dataToCompile->first.insert(stateset);
|
_dataToCompile.first.insert(stateset);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
inline void apply(osg::Drawable* drawable)
|
inline void apply(osg::Drawable* drawable)
|
||||||
{
|
{
|
||||||
if (_drawableSet.count(drawable))
|
if (_drawableSet.count(drawable))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
_drawableSet.insert(drawable);
|
_drawableSet.insert(drawable);
|
||||||
|
|
||||||
apply(drawable->getStateSet());
|
apply(drawable->getStateSet());
|
||||||
|
|
||||||
switch(_drawablePolicy)
|
switch(_drawablePolicy)
|
||||||
{
|
{
|
||||||
case DatabasePager::DO_NOT_MODIFY_DRAWABLE_SETTINGS:
|
case DatabasePager::DO_NOT_MODIFY_DRAWABLE_SETTINGS:
|
||||||
@@ -238,14 +240,14 @@ public:
|
|||||||
//
|
//
|
||||||
// XXX This "compiles" VBOs too, but compilation doesn't do
|
// XXX This "compiles" VBOs too, but compilation doesn't do
|
||||||
// anything for VBOs, does it?
|
// anything for VBOs, does it?
|
||||||
if (_dataToCompile && drawable->getUseDisplayList() && !_pager->isCompiled(drawable))
|
if (drawable->getUseDisplayList() && !_pager->isCompiled(drawable))
|
||||||
{
|
{
|
||||||
// osg::notify(osg::NOTICE)<<" Found compilable drawable"<<std::endl;
|
// osg::notify(osg::NOTICE)<<" Found compilable drawable"<<std::endl;
|
||||||
_dataToCompile->second.push_back(drawable);
|
_dataToCompile.second.push_back(drawable);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
DatabasePager::DataToCompile* _dataToCompile;
|
DatabasePager::DataToCompile& _dataToCompile;
|
||||||
bool _changeAutoUnRef;
|
bool _changeAutoUnRef;
|
||||||
bool _valueAutoUnRef;
|
bool _valueAutoUnRef;
|
||||||
bool _changeAnisotropy;
|
bool _changeAnisotropy;
|
||||||
@@ -593,12 +595,8 @@ void DatabasePager::DatabaseThread::run()
|
|||||||
// merged with the main scene graph and large computeBound() isn't incurred.
|
// merged with the main scene graph and large computeBound() isn't incurred.
|
||||||
ActiveGraphicsContexts::iterator itr = _pager->_activeGraphicsContexts.begin();
|
ActiveGraphicsContexts::iterator itr = _pager->_activeGraphicsContexts.begin();
|
||||||
|
|
||||||
DataToCompile* dtc = 0;
|
DataToCompile& dtc = databaseRequest->_dataToCompileMap[*itr];
|
||||||
if (itr != _pager->_activeGraphicsContexts.end())
|
++itr;
|
||||||
{
|
|
||||||
dtc = &(databaseRequest->_dataToCompileMap[*itr]);
|
|
||||||
++itr;
|
|
||||||
}
|
|
||||||
|
|
||||||
// find all the compileable rendering objects
|
// find all the compileable rendering objects
|
||||||
DatabasePager::FindCompileableGLObjectsVisitor frov(dtc,
|
DatabasePager::FindCompileableGLObjectsVisitor frov(dtc,
|
||||||
@@ -621,7 +619,7 @@ void DatabasePager::DatabaseThread::run()
|
|||||||
if (_pager->_doPreCompile &&
|
if (_pager->_doPreCompile &&
|
||||||
!_pager->_activeGraphicsContexts.empty())
|
!_pager->_activeGraphicsContexts.empty())
|
||||||
{
|
{
|
||||||
if (!dtc->first.empty() || !dtc->second.empty())
|
if (!dtc.first.empty() || !dtc.second.empty())
|
||||||
{
|
{
|
||||||
loadedObjectsNeedToBeCompiled = true;
|
loadedObjectsNeedToBeCompiled = true;
|
||||||
|
|
||||||
@@ -630,7 +628,7 @@ void DatabasePager::DatabaseThread::run()
|
|||||||
itr != _pager->_activeGraphicsContexts.end();
|
itr != _pager->_activeGraphicsContexts.end();
|
||||||
++itr)
|
++itr)
|
||||||
{
|
{
|
||||||
databaseRequest->_dataToCompileMap[*itr] = *dtc;
|
databaseRequest->_dataToCompileMap[*itr] = dtc;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -646,7 +644,7 @@ void DatabasePager::DatabaseThread::run()
|
|||||||
++itr;
|
++itr;
|
||||||
|
|
||||||
// find all the compileable rendering objects
|
// find all the compileable rendering objects
|
||||||
DatabasePager::FindCompileableGLObjectsVisitor frov(&dtc,
|
DatabasePager::FindCompileableGLObjectsVisitor frov(dtc,
|
||||||
_pager->_changeAutoUnRef, _pager->_valueAutoUnRef,
|
_pager->_changeAutoUnRef, _pager->_valueAutoUnRef,
|
||||||
_pager->_changeAnisotropy, _pager->_valueAnisotropy,
|
_pager->_changeAnisotropy, _pager->_valueAnisotropy,
|
||||||
_pager->_drawablePolicy,
|
_pager->_drawablePolicy,
|
||||||
@@ -1495,7 +1493,7 @@ public:
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
META_NodeVisitor("osgDB","MarkPagedLODsVisitor")
|
META_NodeVisitor("osgDB","FindCompileableGLObjectsVisitor")
|
||||||
|
|
||||||
virtual void apply(osg::PagedLOD& plod)
|
virtual void apply(osg::PagedLOD& plod)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -640,8 +640,13 @@ std::string Registry::createLibraryNameForExtension(const std::string& ext)
|
|||||||
ExtensionAliasMap::iterator itr=_extAliasMap.find(lowercase_ext);
|
ExtensionAliasMap::iterator itr=_extAliasMap.find(lowercase_ext);
|
||||||
if (itr!=_extAliasMap.end() && ext != itr->second) return createLibraryNameForExtension(itr->second);
|
if (itr!=_extAliasMap.end() && ext != itr->second) return createLibraryNameForExtension(itr->second);
|
||||||
|
|
||||||
#if defined(OSG_JAVA_BUILD)
|
#ifdef OSG_JAVA_BUILD
|
||||||
static std::string prepend = std::string("osgPlugins-")+std::string(osgGetVersion())+std::string("/java");
|
static std::string prepend = std::string("osgPlugins-")+std::string(osgGetVersion())+std::string("/java");
|
||||||
|
#elseif defined(__APPLE__)
|
||||||
|
// OSX is rather a mess in FileUtils.cpp w.r.t its appendPlatformSpecificLibraryFilePaths implementation
|
||||||
|
// as it hardwires the plugin name to PlugIns. This *needs* fixing to use the naming convention as all
|
||||||
|
// other platforms.
|
||||||
|
static std::string prepend = "";
|
||||||
#else
|
#else
|
||||||
static std::string prepend = std::string("osgPlugins-")+std::string(osgGetVersion())+std::string("/");
|
static std::string prepend = std::string("osgPlugins-")+std::string(osgGetVersion())+std::string("/");
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -821,7 +821,7 @@ osg::StateSet* ReaderWriter3DS::ReaderObject::createStateSet(Lib3dsMaterial *mat
|
|||||||
// stateset->setTextureAttribute(0,texenv);
|
// stateset->setTextureAttribute(0,texenv);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (transparency>0.0f || textureTransparancy || mat->opacity_map.flags!=0)
|
if (transparency>0.0f || textureTransparancy)
|
||||||
{
|
{
|
||||||
stateset->setMode(GL_BLEND,osg::StateAttribute::ON);
|
stateset->setMode(GL_BLEND,osg::StateAttribute::ON);
|
||||||
stateset->setRenderingHint(osg::StateSet::TRANSPARENT_BIN);
|
stateset->setRenderingHint(osg::StateSet::TRANSPARENT_BIN);
|
||||||
|
|||||||
@@ -45,7 +45,6 @@ Document::Document() :
|
|||||||
_lightPointAnimationPoolParent(false),
|
_lightPointAnimationPoolParent(false),
|
||||||
_shaderPoolParent(false)
|
_shaderPoolParent(false)
|
||||||
{
|
{
|
||||||
_subsurfaceDepth = new osg::Depth(osg::Depth::LESS, 0.0, 1.0,false);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Document::~Document()
|
Document::~Document()
|
||||||
@@ -111,22 +110,6 @@ osg::Node* Document::getInstanceDefinition(int no)
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
void Document::setSubSurfacePolygonOffset(int level, osg::PolygonOffset* po)
|
|
||||||
{
|
|
||||||
_subsurfacePolygonOffsets[level] = po;
|
|
||||||
}
|
|
||||||
|
|
||||||
osg::PolygonOffset* Document::getSubSurfacePolygonOffset(int level)
|
|
||||||
{
|
|
||||||
osg::notify(osg::DEBUG_INFO)<<"Document::getSubSurfacePolygonOffset("<<level<<")"<<std::endl;
|
|
||||||
osg::ref_ptr<osg::PolygonOffset>& po = _subsurfacePolygonOffsets[level];
|
|
||||||
if (!po)
|
|
||||||
{
|
|
||||||
po = new osg::PolygonOffset(-1.0f*float(level), -1.0f);
|
|
||||||
}
|
|
||||||
return po.get();
|
|
||||||
}
|
|
||||||
|
|
||||||
double flt::unitsToMeters(CoordUnits unit)
|
double flt::unitsToMeters(CoordUnits unit)
|
||||||
{
|
{
|
||||||
switch (unit)
|
switch (unit)
|
||||||
|
|||||||
@@ -24,8 +24,6 @@
|
|||||||
#include <osg/Notify>
|
#include <osg/Notify>
|
||||||
#include <osg/Transform>
|
#include <osg/Transform>
|
||||||
#include <osg/Geometry>
|
#include <osg/Geometry>
|
||||||
#include <osg/PolygonOffset>
|
|
||||||
#include <osg/Depth>
|
|
||||||
#include <osgDB/ReaderWriter>
|
#include <osgDB/ReaderWriter>
|
||||||
|
|
||||||
#include "Types.h"
|
#include "Types.h"
|
||||||
@@ -168,12 +166,6 @@ class Document
|
|||||||
ShaderPool* getOrCreateShaderPool();
|
ShaderPool* getOrCreateShaderPool();
|
||||||
bool getShaderPoolParent() const { return _shaderPoolParent; }
|
bool getShaderPoolParent() const { return _shaderPoolParent; }
|
||||||
|
|
||||||
void setSubSurfacePolygonOffset(int level, osg::PolygonOffset* po);
|
|
||||||
osg::PolygonOffset* getSubSurfacePolygonOffset(int level);
|
|
||||||
|
|
||||||
void setSubSurfaceDepth(osg::Depth* depth) { _subsurfaceDepth = depth; }
|
|
||||||
osg::Depth* getSubSurfaceDepth() { return _subsurfaceDepth.get(); }
|
|
||||||
|
|
||||||
|
|
||||||
// Options
|
// Options
|
||||||
void setReplaceClampWithClampToEdge(bool flag) { _replaceClampWithClampToEdge = flag; }
|
void setReplaceClampWithClampToEdge(bool flag) { _replaceClampWithClampToEdge = flag; }
|
||||||
@@ -192,7 +184,7 @@ class Document
|
|||||||
bool getDoUnitsConversion() const { return _doUnitsConversion; }
|
bool getDoUnitsConversion() const { return _doUnitsConversion; }
|
||||||
void setDesiredUnits(CoordUnits units ) { _desiredUnits=units; }
|
void setDesiredUnits(CoordUnits units ) { _desiredUnits=units; }
|
||||||
CoordUnits getDesiredUnits() const { return _desiredUnits; }
|
CoordUnits getDesiredUnits() const { return _desiredUnits; }
|
||||||
|
|
||||||
void setKeepExternalReferences( bool flag) { _keepExternalReferences=flag; }
|
void setKeepExternalReferences( bool flag) { _keepExternalReferences=flag; }
|
||||||
bool getKeepExternalReferences() const { return _keepExternalReferences; }
|
bool getKeepExternalReferences() const { return _keepExternalReferences; }
|
||||||
|
|
||||||
@@ -233,11 +225,6 @@ class Document
|
|||||||
osg::ref_ptr<LightPointAppearancePool> _lightPointAppearancePool;
|
osg::ref_ptr<LightPointAppearancePool> _lightPointAppearancePool;
|
||||||
osg::ref_ptr<LightPointAnimationPool> _lightPointAnimationPool;
|
osg::ref_ptr<LightPointAnimationPool> _lightPointAnimationPool;
|
||||||
osg::ref_ptr<ShaderPool> _shaderPool;
|
osg::ref_ptr<ShaderPool> _shaderPool;
|
||||||
|
|
||||||
typedef std::map<int, osg::ref_ptr<osg::PolygonOffset> > SubSurfacePolygonOffsets;
|
|
||||||
SubSurfacePolygonOffsets _subsurfacePolygonOffsets;
|
|
||||||
osg::ref_ptr<osg::Depth> _subsurfaceDepth;
|
|
||||||
|
|
||||||
bool _colorPoolParent;
|
bool _colorPoolParent;
|
||||||
bool _texturePoolParent;
|
bool _texturePoolParent;
|
||||||
bool _materialPoolParent;
|
bool _materialPoolParent;
|
||||||
|
|||||||
@@ -23,6 +23,8 @@
|
|||||||
#include <osg/Geometry>
|
#include <osg/Geometry>
|
||||||
#include <osg/Texture2D>
|
#include <osg/Texture2D>
|
||||||
#include <osg/CullFace>
|
#include <osg/CullFace>
|
||||||
|
#include <osg/PolygonOffset>
|
||||||
|
#include <osg/Depth>
|
||||||
#include <osg/BlendFunc>
|
#include <osg/BlendFunc>
|
||||||
#include <osgUtil/TransformAttributeFunctor>
|
#include <osgUtil/TransformAttributeFunctor>
|
||||||
#include "Registry.h"
|
#include "Registry.h"
|
||||||
@@ -381,12 +383,28 @@ protected:
|
|||||||
// Subface
|
// Subface
|
||||||
if (document.subfaceLevel() > 0)
|
if (document.subfaceLevel() > 0)
|
||||||
{
|
{
|
||||||
stateset->setAttributeAndModes(document.getSubSurfacePolygonOffset(document.subfaceLevel()), osg::StateAttribute::ON);
|
static osg::ref_ptr<osg::PolygonOffset> polygonOffset = new osg::PolygonOffset(-10.0f, -40.0f);
|
||||||
stateset->setAttribute(document.getSubSurfaceDepth());
|
stateset->setAttributeAndModes(polygonOffset.get(), osg::StateAttribute::ON);
|
||||||
|
|
||||||
|
static osg::ref_ptr<osg::Depth> depth = new osg::Depth(osg::Depth::LESS, 0.0, 1.0,false);
|
||||||
|
stateset->setAttribute(depth.get());
|
||||||
|
|
||||||
stateset->setRenderBinDetails(document.subfaceLevel(),"RenderBin");
|
stateset->setRenderBinDetails(document.subfaceLevel(),"RenderBin");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if 0
|
||||||
|
// note from Robert Osfield, this "optimization" breaks multi-textured datasets that mix single texture
|
||||||
|
// and mulit-texture geometries as the Multitexture parsing can come after the below code, and accidentally
|
||||||
|
// polute the non multi-texture geometries StateSet.
|
||||||
|
|
||||||
|
// A simple share stateset optimization.
|
||||||
|
static osg::ref_ptr<osg::StateSet> lastStateset;
|
||||||
|
if (lastStateset.valid() && (stateset->compare(*lastStateset,false)==0))
|
||||||
|
stateset = lastStateset;
|
||||||
|
else
|
||||||
|
lastStateset = stateset;
|
||||||
|
#endif
|
||||||
|
|
||||||
_geode->setStateSet(stateset.get());
|
_geode->setStateSet(stateset.get());
|
||||||
|
|
||||||
// Add to parent.
|
// Add to parent.
|
||||||
@@ -934,12 +952,28 @@ protected:
|
|||||||
// Subface
|
// Subface
|
||||||
if (document.subfaceLevel() > 0)
|
if (document.subfaceLevel() > 0)
|
||||||
{
|
{
|
||||||
stateset->setAttributeAndModes(document.getSubSurfacePolygonOffset(document.subfaceLevel()), osg::StateAttribute::ON);
|
static osg::ref_ptr<osg::PolygonOffset> polygonOffset = new osg::PolygonOffset(-10.0f, -40.0f);
|
||||||
stateset->setAttribute(document.getSubSurfaceDepth());
|
stateset->setAttributeAndModes(polygonOffset.get(), osg::StateAttribute::ON);
|
||||||
|
|
||||||
|
static osg::ref_ptr<osg::Depth> depth = new osg::Depth(osg::Depth::LESS, 0.0, 1.0,false);
|
||||||
|
stateset->setAttribute(depth.get());
|
||||||
|
|
||||||
stateset->setRenderBinDetails(document.subfaceLevel(),"RenderBin");
|
stateset->setRenderBinDetails(document.subfaceLevel(),"RenderBin");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if 0
|
||||||
|
// note from Robert Osfield, this "optimization" breaks multi-textured datasets that mix single texture
|
||||||
|
// and mulit-texture geometries as the Multitexture parsing can come after the below code, and accidentally
|
||||||
|
// polute the non multi-texture geometries StateSet.
|
||||||
|
|
||||||
|
// A simple share stateset optimization.
|
||||||
|
static osg::ref_ptr<osg::StateSet> lastStateset;
|
||||||
|
if (lastStateset.valid() && (stateset->compare(*lastStateset,false)==0))
|
||||||
|
stateset = lastStateset;
|
||||||
|
else
|
||||||
|
lastStateset = stateset;
|
||||||
|
#endif
|
||||||
|
|
||||||
_geode->setStateSet(stateset.get());
|
_geode->setStateSet(stateset.get());
|
||||||
|
|
||||||
// Add to parent.
|
// Add to parent.
|
||||||
|
|||||||
@@ -123,14 +123,11 @@ osgDB::ReaderWriter::ReadResult EasyCurl::read(const std::string& proxyAddress,
|
|||||||
// use for https.
|
// use for https.
|
||||||
// curl_easy_setopt(_curl, CURLOPT_KEYPASSWD, password.c_str());
|
// curl_easy_setopt(_curl, CURLOPT_KEYPASSWD, password.c_str());
|
||||||
|
|
||||||
#if LIBCURL_VERSION_NUM >= 0x070a07
|
|
||||||
if (details->httpAuthentication != _previousHttpAuthentication)
|
if (details->httpAuthentication != _previousHttpAuthentication)
|
||||||
{
|
{
|
||||||
curl_easy_setopt(_curl, CURLOPT_HTTPAUTH, details->httpAuthentication);
|
curl_easy_setopt(_curl, CURLOPT_HTTPAUTH, details->httpAuthentication);
|
||||||
_previousHttpAuthentication = details->httpAuthentication;
|
_previousHttpAuthentication = details->httpAuthentication;
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -139,15 +136,13 @@ osgDB::ReaderWriter::ReadResult EasyCurl::read(const std::string& proxyAddress,
|
|||||||
curl_easy_setopt(_curl, CURLOPT_USERPWD, 0);
|
curl_easy_setopt(_curl, CURLOPT_USERPWD, 0);
|
||||||
_previousPassword.clear();
|
_previousPassword.clear();
|
||||||
}
|
}
|
||||||
|
|
||||||
#if LIBCURL_VERSION_NUM >= 0x070a07
|
|
||||||
// need to reset if previously set.
|
// need to reset if previously set.
|
||||||
if (_previousHttpAuthentication!=0)
|
if (_previousHttpAuthentication!=0)
|
||||||
{
|
{
|
||||||
curl_easy_setopt(_curl, CURLOPT_HTTPAUTH, 0);
|
curl_easy_setopt(_curl, CURLOPT_HTTPAUTH, 0);
|
||||||
_previousHttpAuthentication = 0;
|
_previousHttpAuthentication = 0;
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
curl_easy_setopt(_curl, CURLOPT_URL, fileName.c_str());
|
curl_easy_setopt(_curl, CURLOPT_URL, fileName.c_str());
|
||||||
@@ -159,8 +154,6 @@ osgDB::ReaderWriter::ReadResult EasyCurl::read(const std::string& proxyAddress,
|
|||||||
|
|
||||||
if (res==0)
|
if (res==0)
|
||||||
{
|
{
|
||||||
|
|
||||||
#if LIBCURL_VERSION_NUM >= 0x070a07
|
|
||||||
long code;
|
long code;
|
||||||
if(!proxyAddress.empty())
|
if(!proxyAddress.empty())
|
||||||
{
|
{
|
||||||
@@ -198,19 +191,13 @@ osgDB::ReaderWriter::ReadResult EasyCurl::read(const std::string& proxyAddress,
|
|||||||
|
|
||||||
return rr;
|
return rr;
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
return osgDB::ReaderWriter::ReadResult::FILE_LOADED;
|
return osgDB::ReaderWriter::ReadResult::FILE_LOADED;
|
||||||
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
osg::notify(osg::NOTICE)<<"Error: libcurl read error, file="<<fileName<<" error = "<<curl_easy_strerror(res)<<std::endl;
|
||||||
#if LIBCURL_VERSION_NUM >= 0x070c00
|
|
||||||
osg::notify(osg::NOTICE)<<"Error: libcurl read error, file="<<fileName<<" error = "<<curl_easy_strerror(res)<<std::endl;
|
|
||||||
#else
|
|
||||||
osg::notify(osg::NOTICE)<<"Error: libcurl read error, file="<<fileName<<" error no = "<<res<<std::endl;
|
|
||||||
#endif
|
|
||||||
return osgDB::ReaderWriter::ReadResult::FILE_NOT_HANDLED;
|
return osgDB::ReaderWriter::ReadResult::FILE_NOT_HANDLED;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -40,7 +40,7 @@ osg::Geode* daeReader::processInstanceGeometry( domInstance_geometry *ig )
|
|||||||
domGeometryGeodeMap::iterator iter = geometryMap.find( geom );
|
domGeometryGeodeMap::iterator iter = geometryMap.find( geom );
|
||||||
if ( iter != geometryMap.end() )
|
if ( iter != geometryMap.end() )
|
||||||
{
|
{
|
||||||
cachedGeode = iter->second.get();
|
cachedGeode = iter->second;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -119,7 +119,7 @@ osg::Geode* daeReader::processInstanceController( domInstance_controller *ictrl
|
|||||||
domGeometryGeodeMap::iterator iter = geometryMap.find( geom );
|
domGeometryGeodeMap::iterator iter = geometryMap.find( geom );
|
||||||
if ( iter != geometryMap.end() )
|
if ( iter != geometryMap.end() )
|
||||||
{
|
{
|
||||||
cachedGeode = iter->second.get();
|
cachedGeode = iter->second;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -83,7 +83,7 @@ void daeReader::processBindMaterial( domBind_material *bm, domGeometry *geom, os
|
|||||||
if ( iter != materialMap.end() )
|
if ( iter != materialMap.end() )
|
||||||
{
|
{
|
||||||
// Reuse material
|
// Reuse material
|
||||||
ss = iter->second.get();
|
ss = iter->second;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -232,9 +232,9 @@ protected:
|
|||||||
domInstance_effect *currentInstance_effect;
|
domInstance_effect *currentInstance_effect;
|
||||||
domEffect *currentEffect;
|
domEffect *currentEffect;
|
||||||
|
|
||||||
typedef std::map< domGeometry*, osg::ref_ptr<osg::Geode> > domGeometryGeodeMap;
|
typedef std::map< domGeometry*, osg::Geode*> domGeometryGeodeMap;
|
||||||
typedef std::map< domMaterial*, osg::ref_ptr<osg::StateSet> > domMaterialStateSetMap;
|
typedef std::map< domMaterial*, osg::StateSet*> domMaterialStateSetMap;
|
||||||
typedef std::map< std::string, osg::ref_ptr<osg::StateSet> > MaterialStateSetMap;
|
typedef std::map< std::string, osg::StateSet*> MaterialStateSetMap;
|
||||||
|
|
||||||
/// Maps geometry to a Geode
|
/// Maps geometry to a Geode
|
||||||
domGeometryGeodeMap geometryMap;
|
domGeometryGeodeMap geometryMap;
|
||||||
|
|||||||
@@ -17,7 +17,6 @@
|
|||||||
#include <map>
|
#include <map>
|
||||||
#include <stack>
|
#include <stack>
|
||||||
|
|
||||||
#include <osg/io_utils>
|
|
||||||
#include <osg/Node>
|
#include <osg/Node>
|
||||||
#include <osg/Geode>
|
#include <osg/Geode>
|
||||||
#include <osg/Geometry>
|
#include <osg/Geometry>
|
||||||
|
|||||||
@@ -597,7 +597,7 @@ dxfPolyline::drawScene(scene* sc)
|
|||||||
// is there a flag 1 or 32 for 64?
|
// is there a flag 1 or 32 for 64?
|
||||||
} else {
|
} else {
|
||||||
// simple polyline?
|
// simple polyline?
|
||||||
for (int i = _vertices.size()-1; i >= 0; i--)
|
for (short i = _vertices.size()-1; i >= 0; i--)
|
||||||
vlist.push_back(_vertices[i]->getVertex());
|
vlist.push_back(_vertices[i]->getVertex());
|
||||||
if (_flag & 1) {
|
if (_flag & 1) {
|
||||||
// std::cout << "line loop " << _vertices.size() << std::endl;
|
// std::cout << "line loop " << _vertices.size() << std::endl;
|
||||||
|
|||||||
@@ -60,7 +60,7 @@ bool HDRLoader::isHDRFile(const char *_fileName)
|
|||||||
|
|
||||||
fclose(file);
|
fclose(file);
|
||||||
|
|
||||||
if (numRead<1) return false;
|
if (numRead<10) return false;
|
||||||
|
|
||||||
if (memcmp(str, "#?RADIANCE", 10) && memcmp(str, "#?RGBE", 6))
|
if (memcmp(str, "#?RADIANCE", 10) && memcmp(str, "#?RGBE", 6))
|
||||||
return false;
|
return false;
|
||||||
@@ -80,7 +80,7 @@ bool HDRLoader::load(const char *_fileName, const bool _rawRGBE, HDRLoaderResult
|
|||||||
|
|
||||||
size_t numRead = fread(str, 10, 1, file);
|
size_t numRead = fread(str, 10, 1, file);
|
||||||
|
|
||||||
if (numRead<1)
|
if (numRead<10)
|
||||||
{
|
{
|
||||||
fclose(file);
|
fclose(file);
|
||||||
return false;
|
return false;
|
||||||
@@ -90,7 +90,7 @@ bool HDRLoader::load(const char *_fileName, const bool _rawRGBE, HDRLoaderResult
|
|||||||
{
|
{
|
||||||
fseek(file, 0, SEEK_SET);
|
fseek(file, 0, SEEK_SET);
|
||||||
numRead = fread(str, 6, 1, file);
|
numRead = fread(str, 6, 1, file);
|
||||||
if (numRead<1 || memcmp(str, "#?RGBE", 6))
|
if (numRead<6 || memcmp(str, "#?RGBE", 6))
|
||||||
{
|
{
|
||||||
fclose(file);
|
fclose(file);
|
||||||
return false;
|
return false;
|
||||||
|
|||||||
@@ -328,7 +328,6 @@ ref_ptr<PrimitiveSet> VTXReader::processStrip(unsigned short * indexArray,
|
|||||||
int offset)
|
int offset)
|
||||||
{
|
{
|
||||||
VTXStrip strip;
|
VTXStrip strip;
|
||||||
DrawElementsUShort * drawElements;
|
|
||||||
ref_ptr<PrimitiveSet> primSet;
|
ref_ptr<PrimitiveSet> primSet;
|
||||||
unsigned short * start;
|
unsigned short * start;
|
||||||
unsigned short * end;
|
unsigned short * end;
|
||||||
@@ -349,17 +348,13 @@ ref_ptr<PrimitiveSet> VTXReader::processStrip(unsigned short * indexArray,
|
|||||||
|
|
||||||
// Create the primitive set (based on the flag)
|
// Create the primitive set (based on the flag)
|
||||||
if (strip.strip_flags & STRIP_IS_TRI_LIST)
|
if (strip.strip_flags & STRIP_IS_TRI_LIST)
|
||||||
drawElements =
|
primSet =
|
||||||
new DrawElementsUShort(PrimitiveSet::TRIANGLES, start, end);
|
new DrawElementsUShort(PrimitiveSet::TRIANGLES, start, end);
|
||||||
else
|
else
|
||||||
drawElements =
|
primSet =
|
||||||
new DrawElementsUShort(PrimitiveSet::TRIANGLE_STRIP, start, end);
|
new DrawElementsUShort(PrimitiveSet::TRIANGLE_STRIP, start, end);
|
||||||
|
|
||||||
// Flip the indices to get the front faces correct
|
|
||||||
std::reverse(drawElements->begin(), drawElements->end());
|
|
||||||
|
|
||||||
// Return the primitive set
|
// Return the primitive set
|
||||||
primSet = drawElements;
|
|
||||||
return primSet;
|
return primSet;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -56,7 +56,7 @@ bool ImageLayer_readLocalData(osg::Object& obj, osgDB::Input &fr)
|
|||||||
osgDB::FileType fileType = osgDB::fileType(filename);
|
osgDB::FileType fileType = osgDB::fileType(filename);
|
||||||
if (fileType == osgDB::FILE_NOT_FOUND)
|
if (fileType == osgDB::FILE_NOT_FOUND)
|
||||||
{
|
{
|
||||||
filename = osgDB::findDataFile(filename, fr.getOptions());
|
filename = osgDB::findDataFile(filename);
|
||||||
fileType = osgDB::fileType(filename);
|
fileType = osgDB::fileType(filename);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -71,10 +71,10 @@ bool ImageLayer_readLocalData(osg::Object& obj, osgDB::Input &fr)
|
|||||||
image = osgDB::readRefImageFile( filename );
|
image = osgDB::readRefImageFile( filename );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
osg::notify(osg::INFO)<<"osgVolume::ImageLayer image read: "<<filename<<" pixelFormat "<<std::hex<<image->getPixelFormat()<<" textureFormat "<<image->getInternalTextureFormat()<<" dataType "<<image->getDataType()<<std::dec<<std::endl;
|
||||||
|
|
||||||
if (image.valid())
|
if (image.valid())
|
||||||
{
|
{
|
||||||
osg::notify(osg::INFO)<<"osgVolume::ImageLayer image read: "<<filename<<" pixelFormat "<<std::hex<<image->getPixelFormat()<<" textureFormat "<<image->getInternalTextureFormat()<<" dataType "<<image->getDataType()<<std::dec<<std::endl;
|
|
||||||
layer.setImage(image.get());
|
layer.setImage(image.get());
|
||||||
layer.rescaleToZeroToOneRange();
|
layer.rescaleToZeroToOneRange();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
SET(TARGET_SRC ReaderWriterPDF.cpp )
|
SET(TARGET_SRC ReaderWriterPDF.cpp )
|
||||||
|
|
||||||
INCLUDE_DIRECTORIES( ${CAIRO_INCLUDE_DIRS} ${POPPLER_INCLUDE_DIRS} )
|
INCLUDE_DIRECTORIES( ${CAIRO_INCLUDE_DIRS} ${POPPLER_INCLUDE_DIRS} )
|
||||||
LINK_DIRECTORIES(${CAIRO_LIBRARY_DIRS} ${POPPLER_LIBRARY_DIRS})
|
LINK_DIRECTORIES(${CAIRO_LIBRARY_DIRS} ${POPPLER_LIB_DIRS})
|
||||||
SET(TARGET_EXTERNAL_LIBRARIES ${CAIRO_LIBRARIES} ${POPPLER_LIBRARIES} )
|
SET(TARGET_EXTERNAL_LIBRARIES ${CAIRO_LIBRARIES} ${POPPLER_LIBRARIES} )
|
||||||
|
|
||||||
SET(TARGET_ADDED_LIBRARIES osgWidget)
|
SET(TARGET_ADDED_LIBRARIES osgWidget)
|
||||||
|
|||||||
@@ -664,7 +664,7 @@ void GeometryTechnique::generateGeometry(Locator* masterLocator, const osg::Vec3
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
geometry->setUseDisplayList(false);
|
//geometry->setUseDisplayList(false);
|
||||||
geometry->setUseVertexBufferObjects(true);
|
geometry->setUseVertexBufferObjects(true);
|
||||||
|
|
||||||
|
|
||||||
@@ -702,7 +702,7 @@ void GeometryTechnique::applyColorLayers()
|
|||||||
{
|
{
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
colorLayer = switchLayer->getLayer(switchLayer->getActiveLayer());
|
colorLayer = switchLayer->getLayer(switchLayer->getActiveLayer());
|
||||||
if (!colorLayer) continue;
|
if (!colorLayer) continue;
|
||||||
}
|
}
|
||||||
@@ -726,21 +726,10 @@ void GeometryTechnique::applyColorLayers()
|
|||||||
|
|
||||||
texture2D->setFilter(osg::Texture::MIN_FILTER, colorLayer->getMinFilter());
|
texture2D->setFilter(osg::Texture::MIN_FILTER, colorLayer->getMinFilter());
|
||||||
texture2D->setFilter(osg::Texture::MAG_FILTER, colorLayer->getMagFilter());
|
texture2D->setFilter(osg::Texture::MAG_FILTER, colorLayer->getMagFilter());
|
||||||
|
|
||||||
texture2D->setWrap(osg::Texture::WRAP_S,osg::Texture::CLAMP_TO_EDGE);
|
texture2D->setWrap(osg::Texture::WRAP_S,osg::Texture::CLAMP_TO_EDGE);
|
||||||
texture2D->setWrap(osg::Texture::WRAP_T,osg::Texture::CLAMP_TO_EDGE);
|
texture2D->setWrap(osg::Texture::WRAP_T,osg::Texture::CLAMP_TO_EDGE);
|
||||||
|
|
||||||
bool mipMapping = !(texture2D->getFilter(osg::Texture::MIN_FILTER)==osg::Texture::LINEAR || texture2D->getFilter(osg::Texture::MIN_FILTER)==osg::Texture::NEAREST);
|
|
||||||
bool s_NotPowerOfTwo = image->s()==0 || (image->s() & (image->s() - 1));
|
|
||||||
bool t_NotPowerOfTwo = image->t()==0 || (image->t() & (image->t() - 1));
|
|
||||||
|
|
||||||
if (mipMapping && (s_NotPowerOfTwo || t_NotPowerOfTwo))
|
|
||||||
{
|
|
||||||
osg::notify(osg::INFO)<<"Disabling mipmapping for non power of two tile size("<<image->s()<<", "<<image->t()<<")"<<std::endl;
|
|
||||||
texture2D->setFilter(osg::Texture::MIN_FILTER, osg::Texture::LINEAR);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
layerToTextureMap[colorLayer] = texture2D;
|
layerToTextureMap[colorLayer] = texture2D;
|
||||||
|
|
||||||
// osg::notify(osg::NOTICE)<<"Creating new ImageLayer texture "<<layerNum<<" image->s()="<<image->s()<<" image->t()="<<image->t()<<std::endl;
|
// osg::notify(osg::NOTICE)<<"Creating new ImageLayer texture "<<layerNum<<" image->s()="<<image->s()<<" image->t()="<<image->t()<<std::endl;
|
||||||
@@ -783,7 +772,7 @@ void GeometryTechnique::applyTransparency()
|
|||||||
bool containsTransparency = false;
|
bool containsTransparency = false;
|
||||||
for(unsigned int i=0; i<_terrainTile->getNumColorLayers(); ++i)
|
for(unsigned int i=0; i<_terrainTile->getNumColorLayers(); ++i)
|
||||||
{
|
{
|
||||||
osg::Image* image = (_terrainTile->getColorLayer(i)!=0) ? _terrainTile->getColorLayer(i)->getImage() : 0;
|
osg::Image* image = _terrainTile->getColorLayer(i)->getImage();
|
||||||
if (image)
|
if (image)
|
||||||
{
|
{
|
||||||
containsTransparency = image->isImageTranslucent();
|
containsTransparency = image->isImageTranslucent();
|
||||||
|
|||||||
@@ -117,6 +117,8 @@ osg::BoundingSphere Layer::computeBound(bool treatAsElevationLayer) const
|
|||||||
|
|
||||||
if (getLocator()->convertLocalToModel(osg::Vec3d(0.0,0.0,0.0), v))
|
if (getLocator()->convertLocalToModel(osg::Vec3d(0.0,0.0,0.0), v))
|
||||||
{
|
{
|
||||||
|
bs.expandBy(v);
|
||||||
|
|
||||||
bs.radius() = (bs.center() - v).length();
|
bs.radius() = (bs.center() - v).length();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1494,15 +1494,14 @@ void Optimizer::RemoveLoadedProxyNodesVisitor::removeRedundantNodes()
|
|||||||
// take a copy of parents list since subsequent removes will modify the original one.
|
// take a copy of parents list since subsequent removes will modify the original one.
|
||||||
osg::Node::ParentList parents = group->getParents();
|
osg::Node::ParentList parents = group->getParents();
|
||||||
|
|
||||||
for(osg::Node::ParentList::iterator pitr=parents.begin();
|
for(unsigned int i=0;i<group->getNumChildren();++i)
|
||||||
pitr!=parents.end();
|
|
||||||
++pitr)
|
|
||||||
{
|
{
|
||||||
(*pitr)->removeChild(group.get());
|
osg::Node* child = group->getChild(i);
|
||||||
for(unsigned int i=0;i<group->getNumChildren();++i)
|
for(osg::Node::ParentList::iterator pitr=parents.begin();
|
||||||
|
pitr!=parents.end();
|
||||||
|
++pitr)
|
||||||
{
|
{
|
||||||
osg::Node* child = group->getChild(i);
|
(*pitr)->replaceChild(group.get(),child);
|
||||||
(*pitr)->addChild(child);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -2416,11 +2415,11 @@ bool Optimizer::MergeGeometryVisitor::mergeGeometry(osg::Geometry& lhs,osg::Geom
|
|||||||
|
|
||||||
|
|
||||||
// shift the indices of the incoming primitives to account for the pre existing geometry.
|
// shift the indices of the incoming primitives to account for the pre existing geometry.
|
||||||
osg::Geometry::PrimitiveSetList::iterator primItr;
|
for(osg::Geometry::PrimitiveSetList::iterator primItr=rhs.getPrimitiveSetList().begin();
|
||||||
for(primItr=rhs.getPrimitiveSetList().begin(); primItr!=rhs.getPrimitiveSetList().end(); ++primItr)
|
primItr!=rhs.getPrimitiveSetList().end();
|
||||||
|
++primItr)
|
||||||
{
|
{
|
||||||
osg::PrimitiveSet* primitive = primItr->get();
|
osg::PrimitiveSet* primitive = primItr->get();
|
||||||
|
|
||||||
switch(primitive->getType())
|
switch(primitive->getType())
|
||||||
{
|
{
|
||||||
case(osg::PrimitiveSet::DrawElementsUBytePrimitiveType):
|
case(osg::PrimitiveSet::DrawElementsUBytePrimitiveType):
|
||||||
@@ -2487,12 +2486,12 @@ bool Optimizer::MergeGeometryVisitor::mergeGeometry(osg::Geometry& lhs,osg::Geom
|
|||||||
primitive->offsetIndices(base);
|
primitive->offsetIndices(base);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
for(primItr=rhs.getPrimitiveSetList().begin(); primItr!=rhs.getPrimitiveSetList().end(); ++primItr)
|
lhs.getPrimitiveSetList().insert(lhs.getPrimitiveSetList().end(),
|
||||||
{
|
rhs.getPrimitiveSetList().begin(),rhs.getPrimitiveSetList().end());
|
||||||
lhs.addPrimitiveSet(primItr->get());
|
|
||||||
}
|
|
||||||
|
|
||||||
lhs.dirtyBound();
|
lhs.dirtyBound();
|
||||||
lhs.dirtyDisplayList();
|
lhs.dirtyDisplayList();
|
||||||
@@ -2792,8 +2791,6 @@ bool Optimizer::SpatializeGroupsVisitor::divide(osg::Geode* geode, unsigned int
|
|||||||
}
|
}
|
||||||
|
|
||||||
osg::ref_ptr<osg::Group> group = new osg::Group;
|
osg::ref_ptr<osg::Group> group = new osg::Group;
|
||||||
group->setName(geode->getName());
|
|
||||||
group->setStateSet(geode->getStateSet());
|
|
||||||
for(i=0; i<geode->getNumDrawables(); ++i)
|
for(i=0; i<geode->getNumDrawables(); ++i)
|
||||||
{
|
{
|
||||||
osg::Geode* newGeode = new osg::Geode;
|
osg::Geode* newGeode = new osg::Geode;
|
||||||
|
|||||||
@@ -391,14 +391,8 @@ void RenderStage::runCameraSetUp(osg::RenderInfo& renderInfo)
|
|||||||
case Camera::PACKED_DEPTH_STENCIL_BUFFER:
|
case Camera::PACKED_DEPTH_STENCIL_BUFFER:
|
||||||
internalFormat = GL_DEPTH_STENCIL_EXT;
|
internalFormat = GL_DEPTH_STENCIL_EXT;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
// all other buffers are color buffers
|
|
||||||
default:
|
default:
|
||||||
// setup the internal format based on attached texture if such exists, otherwise just default format
|
internalFormat = GL_RGBA;
|
||||||
if (attachment._texture)
|
|
||||||
internalFormat = attachment._texture->getInternalFormat();
|
|
||||||
else
|
|
||||||
internalFormat = GL_RGBA;
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -893,7 +887,6 @@ void RenderStage::drawInner(osg::RenderInfo& renderInfo,RenderLeaf*& previous, b
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Bind the resolve framebuffer to blit into.
|
// Bind the resolve framebuffer to blit into.
|
||||||
_fbo->apply(state, FrameBufferObject::READ_FRAMEBUFFER);
|
|
||||||
_resolveFbo->apply(state, FrameBufferObject::DRAW_FRAMEBUFFER);
|
_resolveFbo->apply(state, FrameBufferObject::DRAW_FRAMEBUFFER);
|
||||||
|
|
||||||
// Blit to the resolve framebuffer.
|
// Blit to the resolve framebuffer.
|
||||||
@@ -1202,12 +1195,17 @@ void RenderStage::drawImplementation(osg::RenderInfo& renderInfo,RenderLeaf*& pr
|
|||||||
// set up the back buffer.
|
// set up the back buffer.
|
||||||
state.applyAttribute(_viewport.get());
|
state.applyAttribute(_viewport.get());
|
||||||
|
|
||||||
|
#define USE_SISSOR_TEST
|
||||||
|
#ifdef USE_SISSOR_TEST
|
||||||
glScissor( static_cast<int>(_viewport->x()),
|
glScissor( static_cast<int>(_viewport->x()),
|
||||||
static_cast<int>(_viewport->y()),
|
static_cast<int>(_viewport->y()),
|
||||||
static_cast<int>(_viewport->width()),
|
static_cast<int>(_viewport->width()),
|
||||||
static_cast<int>(_viewport->height()) );
|
static_cast<int>(_viewport->height()) );
|
||||||
//cout << " clearing "<<this<< " "<<_viewport->x()<<","<< _viewport->y()<<","<< _viewport->width()<<","<< _viewport->height()<<std::endl;
|
//cout << " clearing "<<this<< " "<<_viewport->x()<<","<< _viewport->y()<<","<< _viewport->width()<<","<< _viewport->height()<<std::endl;
|
||||||
state.applyMode( GL_SCISSOR_TEST, true );
|
|
||||||
|
glEnable( GL_SCISSOR_TEST );
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
// glEnable( GL_DEPTH_TEST );
|
// glEnable( GL_DEPTH_TEST );
|
||||||
|
|
||||||
@@ -1216,33 +1214,21 @@ void RenderStage::drawImplementation(osg::RenderInfo& renderInfo,RenderLeaf*& pr
|
|||||||
else glColorMask(GL_TRUE,GL_TRUE,GL_TRUE,GL_TRUE);
|
else glColorMask(GL_TRUE,GL_TRUE,GL_TRUE,GL_TRUE);
|
||||||
|
|
||||||
if (_clearMask & GL_COLOR_BUFFER_BIT)
|
if (_clearMask & GL_COLOR_BUFFER_BIT)
|
||||||
{
|
|
||||||
glClearColor( _clearColor[0], _clearColor[1], _clearColor[2], _clearColor[3]);
|
glClearColor( _clearColor[0], _clearColor[1], _clearColor[2], _clearColor[3]);
|
||||||
}
|
|
||||||
|
|
||||||
if (_clearMask & GL_DEPTH_BUFFER_BIT)
|
if (_clearMask & GL_DEPTH_BUFFER_BIT)
|
||||||
{
|
|
||||||
glClearDepth( _clearDepth);
|
glClearDepth( _clearDepth);
|
||||||
glDepthMask ( GL_TRUE );
|
|
||||||
state.haveAppliedAttribute( osg::StateAttribute::DEPTH );
|
|
||||||
}
|
|
||||||
|
|
||||||
if (_clearMask & GL_STENCIL_BUFFER_BIT)
|
if (_clearMask & GL_STENCIL_BUFFER_BIT)
|
||||||
{
|
|
||||||
glClearStencil( _clearStencil);
|
glClearStencil( _clearStencil);
|
||||||
glStencilMask ( GL_TRUE );
|
|
||||||
state.haveAppliedAttribute( osg::StateAttribute::STENCIL );
|
|
||||||
}
|
|
||||||
|
|
||||||
if (_clearMask & GL_ACCUM_BUFFER_BIT)
|
if (_clearMask & GL_ACCUM_BUFFER_BIT)
|
||||||
{
|
|
||||||
glClearAccum( _clearAccum[0], _clearAccum[1], _clearAccum[2], _clearAccum[3]);
|
glClearAccum( _clearAccum[0], _clearAccum[1], _clearAccum[2], _clearAccum[3]);
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
glClear( _clearMask );
|
glClear( _clearMask );
|
||||||
|
|
||||||
#ifdef USE_SCISSOR_TEST
|
#ifdef USE_SISSOR_TEST
|
||||||
glDisable( GL_SCISSOR_TEST );
|
glDisable( GL_SCISSOR_TEST );
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|||||||
@@ -1029,7 +1029,6 @@ GraphicsWindowWin32::GraphicsWindowWin32( osg::GraphicsContext::Traits* traits )
|
|||||||
_closeWindow(false),
|
_closeWindow(false),
|
||||||
_destroyWindow(false),
|
_destroyWindow(false),
|
||||||
_destroying(false),
|
_destroying(false),
|
||||||
_mouseCursor(InheritCursor),
|
|
||||||
_appMouseCursor(LeftArrowCursor),
|
_appMouseCursor(LeftArrowCursor),
|
||||||
_applyWorkaroundForMultimonitorMultithreadNVidiaWin32Issues( false )
|
_applyWorkaroundForMultimonitorMultithreadNVidiaWin32Issues( false )
|
||||||
{
|
{
|
||||||
@@ -1783,7 +1782,7 @@ void GraphicsWindowWin32::closeImplementation()
|
|||||||
void GraphicsWindowWin32::swapBuffersImplementation()
|
void GraphicsWindowWin32::swapBuffersImplementation()
|
||||||
{
|
{
|
||||||
if (!_realized) return;
|
if (!_realized) return;
|
||||||
if (!::SwapBuffers(_hdc) && ::GetLastError() != 0)
|
if (!::SwapBuffers(_hdc))
|
||||||
{
|
{
|
||||||
reportErrorForScreen("GraphicsWindowWin32::swapBuffersImplementation() - Unable to swap display buffers", _traits->screenNum, ::GetLastError());
|
reportErrorForScreen("GraphicsWindowWin32::swapBuffersImplementation() - Unable to swap display buffers", _traits->screenNum, ::GetLastError());
|
||||||
}
|
}
|
||||||
@@ -1936,28 +1935,25 @@ void GraphicsWindowWin32::useCursor( bool cursorOn )
|
|||||||
|
|
||||||
void GraphicsWindowWin32::setCursor( MouseCursor mouseCursor )
|
void GraphicsWindowWin32::setCursor( MouseCursor mouseCursor )
|
||||||
{
|
{
|
||||||
if (_mouseCursor != mouseCursor)
|
if (mouseCursor != LeftRightCursor &&
|
||||||
|
mouseCursor != UpDownCursor &&
|
||||||
|
mouseCursor != TopLeftCorner &&
|
||||||
|
mouseCursor != TopRightCorner &&
|
||||||
|
mouseCursor != BottomLeftCorner &&
|
||||||
|
mouseCursor != BottomRightCorner)
|
||||||
{
|
{
|
||||||
if (mouseCursor != LeftRightCursor &&
|
_appMouseCursor = mouseCursor;
|
||||||
mouseCursor != UpDownCursor &&
|
|
||||||
mouseCursor != TopLeftCorner &&
|
|
||||||
mouseCursor != TopRightCorner &&
|
|
||||||
mouseCursor != BottomLeftCorner &&
|
|
||||||
mouseCursor != BottomRightCorner)
|
|
||||||
{
|
|
||||||
_appMouseCursor = mouseCursor;
|
|
||||||
}
|
|
||||||
|
|
||||||
_mouseCursor = mouseCursor;
|
|
||||||
HCURSOR newCursor = getOrCreateCursor( mouseCursor);
|
|
||||||
if (newCursor == _currentCursor) return;
|
|
||||||
|
|
||||||
_currentCursor = newCursor;
|
|
||||||
_traits->useCursor = (_currentCursor != NULL);
|
|
||||||
|
|
||||||
if (_mouseCursor != InheritCursor)
|
|
||||||
::SetCursor(_currentCursor);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
_mouseCursor = mouseCursor;
|
||||||
|
HCURSOR newCursor = getOrCreateCursor( mouseCursor);
|
||||||
|
if (newCursor == _currentCursor) return;
|
||||||
|
|
||||||
|
_currentCursor = newCursor;
|
||||||
|
_traits->useCursor = (_currentCursor != NULL);
|
||||||
|
|
||||||
|
if (_mouseCursor != InheritCursor)
|
||||||
|
::SetCursor(_currentCursor);
|
||||||
}
|
}
|
||||||
|
|
||||||
HCURSOR GraphicsWindowWin32::getOrCreateCursor(MouseCursor mouseCursor)
|
HCURSOR GraphicsWindowWin32::getOrCreateCursor(MouseCursor mouseCursor)
|
||||||
@@ -2368,7 +2364,7 @@ LRESULT GraphicsWindowWin32::handleNativeWindowingEvent( HWND hwnd, UINT uMsg, W
|
|||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
if (_traits->useCursor && _appMouseCursor != InheritCursor)
|
if (_traits->useCursor && _appMouseCursor != InheritCursor)
|
||||||
setCursor(_appMouseCursor);
|
setCursor(LeftArrowCursor);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
return result;
|
return result;
|
||||||
|
|||||||
@@ -98,25 +98,9 @@ osg::Node* createCube(const osg::Vec3& center, float size, unsigned int numSlice
|
|||||||
|
|
||||||
void FixedFunctionTechnique::init()
|
void FixedFunctionTechnique::init()
|
||||||
{
|
{
|
||||||
osg::notify(osg::INFO)<<"FixedFunctionTechnique::init()"<<std::endl;
|
osg::notify(osg::NOTICE)<<"FixedFunctionTechnique::init()"<<std::endl;
|
||||||
|
|
||||||
if (!_volumeTile)
|
if (!_volumeTile) return;
|
||||||
{
|
|
||||||
osg::notify(osg::NOTICE)<<"FixedFunctionTechnique::init(), error no volume tile assigned."<<std::endl;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (_volumeTile->getLayer()==0)
|
|
||||||
{
|
|
||||||
osg::notify(osg::NOTICE)<<"FixedFunctionTechnique::init(), error no layer assigend to volume tile."<<std::endl;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (_volumeTile->getLayer()->getImage()==0)
|
|
||||||
{
|
|
||||||
osg::notify(osg::NOTICE)<<"FixedFunctionTechnique::init(), error no image assigned to layer."<<std::endl;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
float alphaFuncValue = 0.1;
|
float alphaFuncValue = 0.1;
|
||||||
|
|
||||||
|
|||||||
@@ -51,38 +51,21 @@ enum ShadingModel
|
|||||||
|
|
||||||
void RayTracedTechnique::init()
|
void RayTracedTechnique::init()
|
||||||
{
|
{
|
||||||
osg::notify(osg::INFO)<<"RayTracedTechnique::init()"<<std::endl;
|
osg::notify(osg::NOTICE)<<"RayTracedTechnique::init()"<<std::endl;
|
||||||
|
|
||||||
if (!_volumeTile)
|
if (!_volumeTile) return;
|
||||||
{
|
|
||||||
osg::notify(osg::NOTICE)<<"RayTracedTechnique::init(), error no volume tile assigned."<<std::endl;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (_volumeTile->getLayer()==0)
|
|
||||||
{
|
|
||||||
osg::notify(osg::NOTICE)<<"RayTracedTechnique::init(), error no layer assigend to volume tile."<<std::endl;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (_volumeTile->getLayer()->getImage()==0)
|
|
||||||
{
|
|
||||||
osg::notify(osg::NOTICE)<<"RayTracedTechnique::init(), error no image assigned to layer."<<std::endl;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
ShadingModel shadingModel = Isosurface;
|
ShadingModel shadingModel = Isosurface;
|
||||||
float alphaFuncValue = 0.1;
|
float alphaFuncValue = 0.1;
|
||||||
|
|
||||||
_geode = new osg::Geode;
|
_geode = new osg::Geode;
|
||||||
|
|
||||||
osg::Image* image_3d = 0;
|
osg::Image* image_3d = 0;
|
||||||
osg::TransferFunction1D* tf = 0;
|
osg::TransferFunction1D* tf = 0;
|
||||||
osgVolume::Locator* masterLocator = _volumeTile->getLocator();
|
osgVolume::Locator* masterLocator = _volumeTile->getLocator();
|
||||||
|
|
||||||
image_3d = _volumeTile->getLayer()->getImage();
|
image_3d = _volumeTile->getLayer()->getImage();
|
||||||
|
|
||||||
|
|
||||||
CollectPropertiesVisitor cpv;
|
CollectPropertiesVisitor cpv;
|
||||||
if (_volumeTile->getLayer()->getProperty())
|
if (_volumeTile->getLayer()->getProperty())
|
||||||
{
|
{
|
||||||
@@ -130,7 +113,7 @@ void RayTracedTechnique::init()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
osg::notify(osg::INFO)<<"RayTracedTechnique::init() : matrix = "<<matrix<<std::endl;
|
osg::notify(osg::NOTICE)<<"Matrix = "<<matrix<<std::endl;
|
||||||
|
|
||||||
osg::Texture::InternalFormatMode internalFormatMode = osg::Texture::USE_IMAGE_DATA_FORMAT;
|
osg::Texture::InternalFormatMode internalFormatMode = osg::Texture::USE_IMAGE_DATA_FORMAT;
|
||||||
|
|
||||||
@@ -190,12 +173,8 @@ void RayTracedTechnique::init()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
bool enableBlending = false;
|
|
||||||
|
|
||||||
if (shadingModel==MaximumIntensityProjection)
|
if (shadingModel==MaximumIntensityProjection)
|
||||||
{
|
{
|
||||||
enableBlending = true;
|
|
||||||
|
|
||||||
if (tf)
|
if (tf)
|
||||||
{
|
{
|
||||||
osg::Texture1D* texture1D = new osg::Texture1D;
|
osg::Texture1D* texture1D = new osg::Texture1D;
|
||||||
@@ -280,8 +259,6 @@ void RayTracedTechnique::init()
|
|||||||
}
|
}
|
||||||
else if (shadingModel==Light)
|
else if (shadingModel==Light)
|
||||||
{
|
{
|
||||||
enableBlending = true;
|
|
||||||
|
|
||||||
if (tf)
|
if (tf)
|
||||||
{
|
{
|
||||||
osg::Texture1D* texture1D = new osg::Texture1D;
|
osg::Texture1D* texture1D = new osg::Texture1D;
|
||||||
@@ -324,12 +301,10 @@ void RayTracedTechnique::init()
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
enableBlending = true;
|
|
||||||
|
|
||||||
if (tf)
|
if (tf)
|
||||||
{
|
{
|
||||||
osg::notify(osg::INFO)<<"Setting up TF path"<<std::endl;
|
osg::notify(osg::NOTICE)<<"Setting up TF path"<<std::endl;
|
||||||
|
|
||||||
osg::Texture1D* texture1D = new osg::Texture1D;
|
osg::Texture1D* texture1D = new osg::Texture1D;
|
||||||
texture1D->setImage(tf->getImage());
|
texture1D->setImage(tf->getImage());
|
||||||
texture1D->setResizeNonPowerOfTwoHint(false);
|
texture1D->setResizeNonPowerOfTwoHint(false);
|
||||||
@@ -354,7 +329,7 @@ void RayTracedTechnique::init()
|
|||||||
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
||||||
osg::Shader* fragmentShader = osgDB::readShaderFile(osg::Shader::FRAGMENT, "shaders/volume.frag");
|
osg::Shader* fragmentShader = osgDB::readShaderFile(osg::Shader::FRAGMENT, "shaders/volume.frag");
|
||||||
if (fragmentShader)
|
if (fragmentShader)
|
||||||
@@ -387,13 +362,6 @@ void RayTracedTechnique::init()
|
|||||||
stateset->addUniform(new osg::Uniform("AlphaFuncValue",alphaFuncValue));
|
stateset->addUniform(new osg::Uniform("AlphaFuncValue",alphaFuncValue));
|
||||||
|
|
||||||
|
|
||||||
if (enableBlending)
|
|
||||||
{
|
|
||||||
stateset->setMode(GL_BLEND, osg::StateAttribute::ON);
|
|
||||||
stateset->setRenderingHint(osg::StateSet::TRANSPARENT_BIN);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
stateset->setMode(GL_CULL_FACE, osg::StateAttribute::ON);
|
stateset->setMode(GL_CULL_FACE, osg::StateAttribute::ON);
|
||||||
|
|
||||||
osg::TexGen* texgen = new osg::TexGen;
|
osg::TexGen* texgen = new osg::TexGen;
|
||||||
|
|||||||
@@ -108,9 +108,8 @@ char volume_iso_frag[] = "uniform sampler3D baseTexture;\n"
|
|||||||
" color.y = lightScale;\n"
|
" color.y = lightScale;\n"
|
||||||
" color.z = lightScale;\n"
|
" color.z = lightScale;\n"
|
||||||
" }\n"
|
" }\n"
|
||||||
"\n"
|
" \n"
|
||||||
" color.a = 1.0;\n"
|
" if (color.w>1.0) color.w = 1.0; \n"
|
||||||
"\n"
|
|
||||||
" gl_FragColor = color;\n"
|
" gl_FragColor = color;\n"
|
||||||
" \n"
|
" \n"
|
||||||
" return;\n"
|
" return;\n"
|
||||||
@@ -125,5 +124,4 @@ char volume_iso_frag[] = "uniform sampler3D baseTexture;\n"
|
|||||||
"\n"
|
"\n"
|
||||||
" // we didn't find an intersection so just discard fragment\n"
|
" // we didn't find an intersection so just discard fragment\n"
|
||||||
" discard;\n"
|
" discard;\n"
|
||||||
"}\n"
|
"}\n";
|
||||||
"\n";
|
|
||||||
|
|||||||
@@ -232,11 +232,6 @@ void WindowManager::childInserted(unsigned int i) {
|
|||||||
|
|
||||||
if(!window) return;
|
if(!window) return;
|
||||||
|
|
||||||
// Update Window's index
|
|
||||||
for(Iterator w = begin(); w != end(); w++) {
|
|
||||||
if(w->get()->_index >= i) w->get()->_index++;
|
|
||||||
}
|
|
||||||
|
|
||||||
_objects.push_back(window);
|
_objects.push_back(window);
|
||||||
|
|
||||||
window->_index = i;
|
window->_index = i;
|
||||||
@@ -266,12 +261,6 @@ void WindowManager::childRemoved(unsigned int start, unsigned int numChildren) {
|
|||||||
window->unmanaged(this);
|
window->unmanaged(this);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Update Window's index
|
|
||||||
for(Iterator w = begin(); w != end(); w++) {
|
|
||||||
if(w->get()->_index >= start) w->get()->_index -= numChildren;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// This method performs intersection testing at the given XY coords, and returns true if
|
// This method performs intersection testing at the given XY coords, and returns true if
|
||||||
|
|||||||
@@ -22,7 +22,7 @@
|
|||||||
|
|
||||||
#include <osg/io_utils>
|
#include <osg/io_utils>
|
||||||
|
|
||||||
TYPE_NAME_ALIAS(signed char, osg::Vec2b::value_type)
|
TYPE_NAME_ALIAS(char, osg::Vec2b::value_type)
|
||||||
|
|
||||||
BEGIN_VALUE_REFLECTOR(osg::Vec2b)
|
BEGIN_VALUE_REFLECTOR(osg::Vec2b)
|
||||||
I_ReaderWriter(osgIntrospection::StdReaderWriter<reflected_type>); // user-defined
|
I_ReaderWriter(osgIntrospection::StdReaderWriter<reflected_type>); // user-defined
|
||||||
@@ -31,8 +31,8 @@ BEGIN_VALUE_REFLECTOR(osg::Vec2b)
|
|||||||
I_Constructor0(____Vec2b,
|
I_Constructor0(____Vec2b,
|
||||||
"",
|
"",
|
||||||
"");
|
"");
|
||||||
I_Constructor2(IN, osg::Vec2b::value_type, r, IN, osg::Vec2b::value_type, g,
|
I_Constructor2(IN, char, r, IN, char, g,
|
||||||
____Vec2b__value_type__value_type,
|
____Vec2b__char__char,
|
||||||
"",
|
"",
|
||||||
"");
|
"");
|
||||||
I_Method0(osg::Vec2b::value_type *, ptr,
|
I_Method0(osg::Vec2b::value_type *, ptr,
|
||||||
|
|||||||
@@ -22,7 +22,7 @@
|
|||||||
|
|
||||||
#include <osg/io_utils>
|
#include <osg/io_utils>
|
||||||
|
|
||||||
TYPE_NAME_ALIAS(signed char, osg::Vec3b::value_type)
|
TYPE_NAME_ALIAS(char, osg::Vec3b::value_type)
|
||||||
|
|
||||||
BEGIN_VALUE_REFLECTOR(osg::Vec3b)
|
BEGIN_VALUE_REFLECTOR(osg::Vec3b)
|
||||||
I_ReaderWriter(osgIntrospection::StdReaderWriter<reflected_type>); // user-defined
|
I_ReaderWriter(osgIntrospection::StdReaderWriter<reflected_type>); // user-defined
|
||||||
|
|||||||
@@ -22,7 +22,7 @@
|
|||||||
|
|
||||||
#include <osg/io_utils>
|
#include <osg/io_utils>
|
||||||
|
|
||||||
TYPE_NAME_ALIAS(signed char, osg::Vec4b::value_type)
|
TYPE_NAME_ALIAS(char, osg::Vec4b::value_type)
|
||||||
|
|
||||||
BEGIN_VALUE_REFLECTOR(osg::Vec4b)
|
BEGIN_VALUE_REFLECTOR(osg::Vec4b)
|
||||||
I_ReaderWriter(osgIntrospection::StdReaderWriter<reflected_type>); // user-defined
|
I_ReaderWriter(osgIntrospection::StdReaderWriter<reflected_type>); // user-defined
|
||||||
|
|||||||
@@ -35,59 +35,59 @@ BEGIN_VALUE_REFLECTOR(osg::Vec4ub)
|
|||||||
____Vec4ub__value_type__value_type__value_type__value_type,
|
____Vec4ub__value_type__value_type__value_type__value_type,
|
||||||
"",
|
"",
|
||||||
"");
|
"");
|
||||||
I_Method0(osg::Vec4ub::value_type *, ptr,
|
I_Method0(unsigned char *, ptr,
|
||||||
Properties::NON_VIRTUAL,
|
Properties::NON_VIRTUAL,
|
||||||
__value_type_P1__ptr,
|
__unsigned_char_P1__ptr,
|
||||||
"",
|
"",
|
||||||
"");
|
"");
|
||||||
I_Method0(const osg::Vec4ub::value_type *, ptr,
|
I_Method0(const unsigned char *, ptr,
|
||||||
Properties::NON_VIRTUAL,
|
Properties::NON_VIRTUAL,
|
||||||
__C5_value_type_P1__ptr,
|
__C5_unsigned_char_P1__ptr,
|
||||||
"",
|
"",
|
||||||
"");
|
"");
|
||||||
I_Method4(void, set, IN, osg::Vec4ub::value_type, r, IN, osg::Vec4ub::value_type, g, IN, osg::Vec4ub::value_type, b, IN, osg::Vec4ub::value_type, a,
|
I_Method4(void, set, IN, unsigned char, r, IN, unsigned char, g, IN, unsigned char, b, IN, unsigned char, a,
|
||||||
Properties::NON_VIRTUAL,
|
Properties::NON_VIRTUAL,
|
||||||
__void__set__value_type__value_type__value_type__value_type,
|
__void__set__unsigned_char__unsigned_char__unsigned_char__unsigned_char,
|
||||||
"",
|
"",
|
||||||
"");
|
"");
|
||||||
I_Method0(osg::Vec4ub::value_type &, r,
|
I_Method0(unsigned char &, r,
|
||||||
Properties::NON_VIRTUAL,
|
Properties::NON_VIRTUAL,
|
||||||
__value_type_R1__r,
|
__unsigned_char_R1__r,
|
||||||
"",
|
"",
|
||||||
"");
|
"");
|
||||||
I_Method0(osg::Vec4ub::value_type &, g,
|
I_Method0(unsigned char &, g,
|
||||||
Properties::NON_VIRTUAL,
|
Properties::NON_VIRTUAL,
|
||||||
__value_type_R1__g,
|
__unsigned_char_R1__g,
|
||||||
"",
|
"",
|
||||||
"");
|
"");
|
||||||
I_Method0(osg::Vec4ub::value_type &, b,
|
I_Method0(unsigned char &, b,
|
||||||
Properties::NON_VIRTUAL,
|
Properties::NON_VIRTUAL,
|
||||||
__value_type_R1__b,
|
__unsigned_char_R1__b,
|
||||||
"",
|
"",
|
||||||
"");
|
"");
|
||||||
I_Method0(osg::Vec4ub::value_type &, a,
|
I_Method0(unsigned char &, a,
|
||||||
Properties::NON_VIRTUAL,
|
Properties::NON_VIRTUAL,
|
||||||
__value_type_R1__a,
|
__unsigned_char_R1__a,
|
||||||
"",
|
"",
|
||||||
"");
|
"");
|
||||||
I_Method0(osg::Vec4ub::value_type, r,
|
I_Method0(unsigned char, r,
|
||||||
Properties::NON_VIRTUAL,
|
Properties::NON_VIRTUAL,
|
||||||
__value_type__r,
|
__unsigned_char__r,
|
||||||
"",
|
"",
|
||||||
"");
|
"");
|
||||||
I_Method0(osg::Vec4ub::value_type, g,
|
I_Method0(unsigned char, g,
|
||||||
Properties::NON_VIRTUAL,
|
Properties::NON_VIRTUAL,
|
||||||
__value_type__g,
|
__unsigned_char__g,
|
||||||
"",
|
"",
|
||||||
"");
|
"");
|
||||||
I_Method0(osg::Vec4ub::value_type, b,
|
I_Method0(unsigned char, b,
|
||||||
Properties::NON_VIRTUAL,
|
Properties::NON_VIRTUAL,
|
||||||
__value_type__b,
|
__unsigned_char__b,
|
||||||
"",
|
"",
|
||||||
"");
|
"");
|
||||||
I_Method0(osg::Vec4ub::value_type, a,
|
I_Method0(unsigned char, a,
|
||||||
Properties::NON_VIRTUAL,
|
Properties::NON_VIRTUAL,
|
||||||
__value_type__a,
|
__unsigned_char__a,
|
||||||
"",
|
"",
|
||||||
"");
|
"");
|
||||||
END_REFLECTOR
|
END_REFLECTOR
|
||||||
|
|||||||
@@ -40,8 +40,8 @@ TYPE_NAME_ALIAS(std::vector< int >, osgUtil::Hit::VecIndexList)
|
|||||||
BEGIN_VALUE_REFLECTOR(osgUtil::Hit)
|
BEGIN_VALUE_REFLECTOR(osgUtil::Hit)
|
||||||
I_DeclaringFile("osgUtil/IntersectVisitor");
|
I_DeclaringFile("osgUtil/IntersectVisitor");
|
||||||
I_Constructor0(____Hit,
|
I_Constructor0(____Hit,
|
||||||
"Deprecated. ",
|
"Describes a point in space produced by an intersection of a line with a scene. ",
|
||||||
"");
|
"A Hit is always on a surface as rendered by the Open Scene Graph scene (usually a triangle or other primitive, but a special hit handler could return a different value perhaps: a sphere shape might return a Hit on the true sphere rather than the approximate tessellated sphere rendered. ");
|
||||||
I_Constructor1(IN, const osgUtil::Hit &, hit,
|
I_Constructor1(IN, const osgUtil::Hit &, hit,
|
||||||
Properties::NON_EXPLICIT,
|
Properties::NON_EXPLICIT,
|
||||||
____Hit__C5_Hit_R1,
|
____Hit__C5_Hit_R1,
|
||||||
|
|||||||
Reference in New Issue
Block a user