OpenSceneGraph\CMakeModules\FindFBX.cmake
This version can find fbx sdk 2015.1 and will prefer it over older versions.
Tested with Visual Studio Express 2013 on 64bit windows 7"
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14782 16af8721-9629-0410-8352-f15c8da7e697
broken:
-- Could NOT find GStreamer (missing: GSTREAMER_BASE_INCLUDE_DIRS GSTREAMER_BASE_LIBRARIES GSTREAMER_GSTREAMER-APP_INCLUDE_DIRS GSTREAMER_GSTREAMER-APP_LIBRARIES GSTREAMER_GSTREAMER-PBUTILS_INCLUDE_DIRS GSTREAMER_GSTREAMER-PBUTILS_LIBRARIES) (found version "1.4.5")
though all required modules are installed.
There are two problems: first, module names are spelled incorrectly in root
CMakeLists.txt (e.g. gstreamer-app instead of app), so variables expected
for them are e.g. GSTREAMER_GSTREAMER-APP_INCLUDE_DIRS instead of
GSTREAMER_APP_INCLUDE_DIRS.
Second, gstreamer base component is detected as GSTREAMER while checked
later as GSTREAMER_BASE. I've uncommented the detection as
GSTREAMER_BASE, but obviously that should be revisited and only one
detection left. With this patch, gstreamer is detected properly and
the plugins is successfully built and installed."
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14719 16af8721-9629-0410-8352-f15c8da7e697
$ osgmovie --audio movie.avi.ffmpeg
FFmpegImageStream::open audio failed, audio stream will be disabled: unknown audio format
With the attached FFmpegDecoderAudio.cpp, audio sounds correctly.
I am also attaching a modified version of FindFFmpeg.cmake that allows to set as FFMPEG_DIR the ffmpeg compiled in the source directory structure. It should not break anything as it only adds some additional search paths.
"
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14654 16af8721-9629-0410-8352-f15c8da7e697
cmake vars weren't passed correctly to find_package_handler_args, so
while the find script didn't find a single required GStreamer lib or
include path it still reported GSTREAMER_FOUND=TRUE (and then tried to
compile the new plugin). This fixes it and correctly reports missing
components."
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14611 16af8721-9629-0410-8352-f15c8da7e697
$ osgmovie --audio movie.avi.ffmpeg
FFmpegImageStream::open audio failed, audio stream will be disabled: unknown audio format
With the attached FFmpegDecoderAudio.cpp, audio sounds correctly.
I am also attaching a modified version of FindFFmpeg.cmake that allows to set as FFMPEG_DIR the ffmpeg compiled in the source directory structure. It should not break anything as it only adds some additional search paths.
"
Note from Robert Osfield, I have found in testing that audio quality is not good for planar floating point formats, even with adding support for SDL2 to the osgmovie example. I haven't yet tracked down the cause of these audio problems or a solution.
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14609 16af8721-9629-0410-8352-f15c8da7e697
From Robert Osfield, fixed handled of row widths so that they are padded to a 4 byte boundary as certain row widths were being rendered incorrectly.
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14604 16af8721-9629-0410-8352-f15c8da7e697
The mac os sdk version is recognized by the current CMAKE script as 10.1 instead of 10.10 since it cuts the version string from the 4th place. I introduced a more reliable version checking based on splitting the returned version code into MAJOR MINOR and PATCH parts and reassemble the OSG sdk version afterwards.
I replaced the existing CMake code against the following (returning now version 10.10 as expected):
# Determine the canonical name of the selected Platform SDK
EXECUTE_PROCESS(COMMAND "/usr/bin/sw_vers" "-productVersion"
OUTPUT_VARIABLE OSG_OSX_SDK_NAME
OUTPUT_STRIP_TRAILING_WHITESPACE)
STRING(REPLACE "." ";" MACOS_VERSION_LIST ${OSG_OSX_SDK_NAME})
LIST(GET MACOS_VERSION_LIST 0 MACOS_VERSION_MAJOR)
LIST(GET MACOS_VERSION_LIST 1 MACOS_VERSION_MINOR)
LIST(GET MACOS_VERSION_LIST 2 MACOS_VERSION_PATCH)
SET(OSG_OSX_SDK_NAME "macosx${MACOS_VERSION_MAJOR}.${MACOS_VERSION_MINOR}")
Also i added the check for the new Version to some more find scripts.
Additionally the nil object in Objective C now seems to be equivalent with a null_ptr that cannot be passed as GLInt anymore. So i switched this in the PixelBufferCocoa.mm to pass a zero instead of nil.
"
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14527 16af8721-9629-0410-8352-f15c8da7e697
My changes:
-------------------
- I changed the cmake files and added a toolchain for building OSG in Android. The toolchain is based on the one used at OpenCV. For building OSG for android you just need to do:
mkdir build_android_static_gles2 && cd build_android_static_gles2
cmake .. -DANDROID_NDK=<path-to-the-android-ndk>
-DCMAKE_TOOLCHAIN_FILE=../PlatformSpecifics/Android/android.toolchain.cmake
-DOPENGL_PROFILE="GLES2"
-DDYNAMIC_OPENTHREADS=OFF
-DDYNAMIC_OPENSCENEGRAPH=OFF
-DANDROID_NATIVE_API_LEVEL=15 # optional
-DANDROID_ABI=armeabim #optional
-DCMAKE_INSTALL_PREFIX=<path-to-the-install-path> #optional
make -j 8
make install
The OPENGL_PROFILE works as expected, changing it to "GLES1" it builds and links OSG using GLES1.
The DYNAMIC_OPENTHREADS/DYNAMIC_OPENSCENEGRAPH parameters also allows to build the dynamic libraries
- I also added some build fixes for android related to the texture formats and added some missing USE_OSG_SERIALIZER_WRAPPER in the osg serializer library to support loading osgb files in static."
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14514 16af8721-9629-0410-8352-f15c8da7e697
Currently this submission is Windows-only. I don't think OSX or Linux require any help in locating gl/glcorearb.h. But if they do, this submission can be easily modified.
Files:
- "CMakeLists.txt" is the top-level file.
- FindGLCORE.cmake" and "OsgMacroUtils.cmake" go in CMakeModules.
"
says that modules that are found and ran from cmake modules dir should
prefer cmake-provided modules. find_package() and include() still look
in CMAKE_MODULE_PATH first.
After some investigating I've come up with a proposal examplified in
the attached FindGDAL.cmake script. It simply calls the cmake provided
FindGDAL.cmake if it exists and returns if it succeeds in finding GDAL
using that, otherwise continue with our local cmake code.
Pro: Wont clutter our root CMakeLists.txt
Con: If we begin to write more advanced Findxxx modules (using
COMPONENTS, REQUIRED etc.) we may have to revise this scheme.
"
- ReaderWriterFBX.cpp: add "z up scene axis" support: FBX provides facility to convert model scene axis during conversion. Currently fbx plugin convert axis to fbx:opengl axis system (which is arbitrarily at Y up, as opengl is in reality axis agnostic) and sometimes what is needed is Z up so added an option for Z up conversion
- FindFBX.cmake: add support for latest fbx sdk ( 2014.2 )"
* force _OPENTHREADS_ATOMIC_USE_BSD_ATOMIC for IOS device + simulator as the test does not pick the right implementation
* fixed a small compile-bug for iphone-example
* added a check to prevent multiple realization of a GraphicsWindowIOS-object
"
include(${CMAKE_MODULE_PATH}/FindPackageHandleStandardArgs.cmake)
in CMakeModules/FindLua52.cmake
changing to a more common
include(FindPackageHandleStandardArgs)
solves my problem."
* fixed a bug with multi-touch and touch-id-generation on iOS and OS X. (will fix a bug reported by Colin Cochran, without ditching the existing logic)
* removed unnecessary warning-flagss when generating xcode-projects via cmake, will enable the usage of OSG_AGGRESSIVE_WARNING_FLAGS
* added support for 10.9 (OS X)
* new cmake-variable: IPHONE_VERSION_MIN, this will set the deployment-target (previously hard-coded) If you set the IPHONE_VERSION_MIN to something like 7.0 osg gets compiled also for 64bit (amd64)
* cmake defaults now to the clang compiler if IPHONE_VERSION_MIN > 4.2
* cmake now sets some xcode-settings so the compiler uses the c++98-standard (clang defaults to c++11, w/o this I got a lot of linking errors)
* removed include-dir for avfoundation-plugin as not needed on OSX/IOS.
* enhanced the ios-example, will now show multitouch-information on a hud (similar to the osgmultitouch-example), and more importantly, will compile + link out of the box
* small enhancements for the osc-device-plugin (send only one msg for MOVE/DRAG, even if multiple msgs/event is enabled)
* better memory-handling for the zeroconf-plugin
* fixed a possible bug in the rest-http-plugin when receiving mouse-events.
* incorporated a fix from Colin Cochran "forwarded touch events are not transformed into the GL UIView“
"
functional again for some libraries:
Find3rdPa..: Fix to find libxml2
FindCollada: Rearranged to handle different MSVC versions more effective.
This file is already prepared for the upcoming VS 2013.
FindNVTT: introduced management of debug libraries (also auto detected).
"
new 3rdparty package (V8).
This package is compiled with Visual Studio 2012 Update 3. Some community
members complained that these package is very large (indeed), so I
introduced 2 versions:
- The small version contains the dependencies for several image file formats
( tiff, png, gif, jpeg), as well as zlib, minizip, curl, freetype, glut,
gdal and openSSL
- The full version will include all libraries which were include in the
previous releases of my 3rd party package.
Some of the included libraries are released in newer versions, so I adapted
the attached CMake module to find these renamed files.
I hope you can merge this minor changes soon, since I plan to publish the
small 3rdparty package today.
"
The API has changed quite a bit, so lots of changes had to be made in the osg readerwriter. The preious version of the FBX SDK (2013.3) already deprecated a lot of the names and functions. The code I submit now still compiles against 2013.3 (possibly needs a #define FBX_NEW_API). Not sure if that's useful, but it might ease the transition."
Header update
FindFFmpeg.cmake has been changed in order to support the new header include format for FFmpeg. In the 1.0 release, a new file had been added with the name “time.h” in the avutil library. The previous method of adding includes caused conflicts with the ANSI C “time.h” file. Now the include directive will only use the main include folder. All files using the old include format have been updated to reflect the change.
Added __STDC_CONSTANT_MACROS define to CMakeLists.txt
Since there is no guarantee that FFmpegHeaders.hpp will be included before stdint.h is included, the define has been moved from FFmpegHeaders.hpp to be part of the CMakeLists.txt for the FFmpeg plugin. This will allow the define to work on all compilers regardless of include order.
Replaced AVFormatParameters with AVDictionary
AVFormatParameters is no longer supported in FFmpeg and has been replaced with a key/value map of strings for each setting. FFmpegParameters and FFmpegDecoder has been updated to reflect this.
Replaced av_open_input_file with avformat_open_input
FFmpeg now opens files using avformat_open_input. Since the av_open_input_file method is deprecated, the FFmpegDecoder class has been updated to reflect this change.
Added custom AVIOContext field to options
Since some formats and inputs may not be supported by FFmpeg, I have added a new parameter that allows a user to allocate their own AVIOContext. This class will allow for creating a read, seek, and write callback if they desire.
Checking for start_time validity
It is possible for some file formats to not provide a start_time to FFmpeg. This would cause stuttering in the video since the clocks class would be incorrect.
Removed findVideoStream and findAudioStream
The new FFmpeg release already has a function that will find the best audio and video stream. The code has been replaced with this function.
Updated error reporting
Some functions would not log an error when opening a file or modifying a file failed. New logs have been added as well as a function to convert error numbers to their string descriptions.
decode_video has been replaced
The old decode_video function would remove extra data that some decoders use in order to properly decode a packet. Now av_codec_decode_video2 has replaced that function.
Picture format changed from RGBA32 to RGB24
Since most video will not contain an alpha channel, using a 24 bit texture will use less memory."
* avfoundation: added support for IOS (CoreVideo-support is still in development, works only for SDK >= 6.0, set IPHONE_SDKVER in cMake accordingly)
* zeroconf: added ZeroConf-device-plugin (Mac/Win only, linux implementation missing) to advertise and discover services via ZeroConf/Bonjour, on windows you'll need the Bonjour SDK from Apple
* osgosc: modified the example to demonstrate the usage of the ZeroConf-plugin (start the example with the command-line-argument --zeroconf)
* SlideShowConstructor: enable/disable CoreVideo via a environment variable (P3D_ENABLE_CORE_VIDEO)
* RestHttp: mouse-motion-events get interpolated
* RestHttp: unhandled http-requests get sent as an user-event to the event-queue, all arguments get attached as user-values to the event
* modified some CMakeModules to work correctly when compiling for IOS
* fixed a compile-error for IOS in GraphicsWindowIOS
* some minor bugfixes"
(http://gta.nongnu.org). This allows to read and write floating point
image data. Unlike other formats, GTA also allows very good compression
ratios for floating point data. The compression method can be selected
with the COMPRESSION option of the plugin.
"