diff --git a/code/CMakeModules/FindWindowsSDK.cmake b/code/CMakeModules/FindWindowsSDK.cmake index 25903be14..9d9b91777 100644 --- a/code/CMakeModules/FindWindowsSDK.cmake +++ b/code/CMakeModules/FindWindowsSDK.cmake @@ -2,47 +2,86 @@ # Find the Windows includes # # WINSDK_INCLUDE_DIR - where to find Windows.h +# WINSDK_INCLUDE_DIRS - where to find all Windows headers +# WINSDK_LIBRARY_DIR - where to find libraries # WINSDK_FOUND - True if Windows SDK found. IF(WINSDK_INCLUDE_DIR) # Already in cache, be silent - SET(WINSDK_FIND_QUIETLY TRUE) + SET(WindowsSDK_FIND_QUIETLY TRUE) ENDIF(WINSDK_INCLUDE_DIR) +# TODO: add the possibility to use a specific Windows SDK + +IF(MSVC11) + GET_FILENAME_COMPONENT(WINSDK8_DIR "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Microsoft SDKs\\Windows\\v8.0;InstallationFolder]" ABSOLUTE CACHE) + GET_FILENAME_COMPONENT(WINSDK8_VERSION "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Microsoft SDKs\\Windows\\v8.0;ProductVersion]" NAME) + + IF(WINSDK8_DIR) + IF(NOT WindowsSDK_FIND_QUIETLY) + MESSAGE(STATUS "Found Windows SDK ${WINSDK8_VERSION} in ${WINSDK8_DIR}") + ENDIF(NOT WindowsSDK_FIND_QUIETLY) + IF(TARGET_ARM) + SET(WINSDK8_SUFFIX "arm") + ELSEIF(TARGET_X64) + SET(WINSDK8_SUFFIX "x64") + ELSEIF(TARGET_X86) + SET(WINSDK8_SUFFIX "x86") + ENDIF(TARGET_ARM) + ENDIF(WINSDK8_DIR) +ENDIF(MSVC11) + GET_FILENAME_COMPONENT(WINSDK71_DIR "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Microsoft SDKs\\Windows\\v7.1;InstallationFolder]" ABSOLUTE CACHE) GET_FILENAME_COMPONENT(WINSDK71_VERSION "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Microsoft SDKs\\Windows\\v7.1;ProductVersion]" NAME) IF(WINSDK71_DIR) - IF(NOT WINSDK_FIND_QUIETLY) + IF(NOT WindowsSDK_FIND_QUIETLY) MESSAGE(STATUS "Found Windows SDK ${WINSDK71_VERSION} in ${WINSDK71_DIR}") - ENDIF(NOT WINSDK_FIND_QUIETLY) + ENDIF(NOT WindowsSDK_FIND_QUIETLY) ENDIF(WINSDK71_DIR) GET_FILENAME_COMPONENT(WINSDKCURRENT_DIR "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Microsoft SDKs\\Windows;CurrentInstallFolder]" ABSOLUTE CACHE) GET_FILENAME_COMPONENT(WINSDKCURRENT_VERSION "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Microsoft SDKs\\Windows;CurrentVersion]" NAME) IF(WINSDKCURRENT_DIR) - IF(NOT WINSDK_FIND_QUIETLY) + IF(NOT WindowsSDK_FIND_QUIETLY) MESSAGE(STATUS "Found Windows SDK ${WINSDKCURRENT_VERSION} in ${WINSDKCURRENT_DIR}") - ENDIF(NOT WINSDK_FIND_QUIETLY) + ENDIF(NOT WindowsSDK_FIND_QUIETLY) ENDIF(WINSDKCURRENT_DIR) FIND_PATH(WINSDK_INCLUDE_DIR Windows.h - PATHS + HINTS + ${WINSDK8_DIR}/Include/um ${WINSDK71_DIR}/Include ${WINSDKCURRENT_DIR}/Include ) +FIND_PATH(WINSDK_SHARED_INCLUDE_DIR d3d9.h + HINTS + ${WINSDK8_DIR}/Include/shared + ${WINSDK71_DIR}/Include + ${WINSDKCURRENT_DIR}/Include +) + +FIND_PATH(WINSDK_LIBRARY_DIR ComCtl32.lib + HINTS + ${WINSDK8_DIR}/Lib/win8/um/${WINSDK8_SUFFIX} + ${WINSDK71_DIR}/Lib + ${WINSDKCURRENT_DIR}/Lib +) + FIND_PROGRAM(WINSDK_SIGNTOOL signtool - PATHS + HINTS + ${WINSDK8_DIR}/Bin/x86 ${WINSDK71_DIR}/Bin ${WINSDKCURRENT_DIR}/Bin ) IF(WINSDK_INCLUDE_DIR) SET(WINSDK_FOUND TRUE) + SET(WINSDK_INCLUDE_DIRS ${WINSDK_INCLUDE_DIR} ${WINSDK_SHARED_INCLUDE_DIR}) ELSE(WINSDK_INCLUDE_DIR) - IF(NOT WINSDK_FIND_QUIETLY) + IF(NOT WindowsSDK_FIND_QUIETLY) MESSAGE(STATUS "Warning: Unable to find Windows SDK!") - ENDIF(NOT WINSDK_FIND_QUIETLY) + ENDIF(NOT WindowsSDK_FIND_QUIETLY) ENDIF(WINSDK_INCLUDE_DIR) diff --git a/code/CMakeModules/PCHSupport.cmake b/code/CMakeModules/PCHSupport.cmake index 0ef2243d6..d444bfa3d 100644 --- a/code/CMakeModules/PCHSupport.cmake +++ b/code/CMakeModules/PCHSupport.cmake @@ -9,250 +9,384 @@ # ADD_NATIVE_PRECOMPILED_HEADER _targetName _inputh _inputcpp IF(MSVC) - SET(PCHSupport_FOUND TRUE) - SET(_PCH_include_prefix "/I") + SET(PCHSupport_FOUND TRUE) + SET(_PCH_include_prefix "/I") ELSE(MSVC) - IF(CMAKE_COMPILER_IS_GNUCXX) - EXEC_PROGRAM(${CMAKE_CXX_COMPILER} - ARGS ${CMAKE_CXX_COMPILER_ARG1} -dumpversion - OUTPUT_VARIABLE gcc_compiler_version) - - IF(gcc_compiler_version MATCHES "4\\.[0-9]\\.[0-9]") - SET(PCHSupport_FOUND TRUE) - ELSE(gcc_compiler_version MATCHES "4\\.[0-9]\\.[0-9]") - IF(gcc_compiler_version MATCHES "3\\.4\\.[0-9]") - SET(PCHSupport_FOUND TRUE) - ENDIF(gcc_compiler_version MATCHES "3\\.4\\.[0-9]") - ENDIF(gcc_compiler_version MATCHES "4\\.[0-9]\\.[0-9]") - ELSE(CMAKE_COMPILER_IS_GNUCXX) - # TODO: make tests for other compilers than GCC - SET(PCHSupport_FOUND TRUE) - ENDIF(CMAKE_COMPILER_IS_GNUCXX) - - SET(_PCH_include_prefix "-I") + IF(CMAKE_COMPILER_IS_GNUCXX) + EXEC_PROGRAM(${CMAKE_CXX_COMPILER} + ARGS ${CMAKE_CXX_COMPILER_ARG1} -dumpversion + OUTPUT_VARIABLE gcc_compiler_version) + + IF(gcc_compiler_version MATCHES "^4\\.1(\\.[0-9]+)?") + SET(PCHSupport_FOUND FALSE) + ELSEIF(gcc_compiler_version MATCHES "^4\\.[0-9]+(\\.[0-9]+)?") + SET(PCHSupport_FOUND TRUE) + ENDIF(gcc_compiler_version MATCHES "^4\\.1(\\.[0-9]+)?") + ELSE(CMAKE_COMPILER_IS_GNUCXX) + # TODO: make tests for other compilers than GCC + SET(PCHSupport_FOUND TRUE) + ENDIF(CMAKE_COMPILER_IS_GNUCXX) + + SET(_PCH_include_prefix "-I") ENDIF(MSVC) -MACRO(_PCH_GET_COMPILE_FLAGS _out_compile_flags) - STRING(TOUPPER "CMAKE_CXX_FLAGS_${CMAKE_BUILD_TYPE}" _flags_var_name) - SET(_FLAGS ${${_flags_var_name}} ) - - IF(NOT MSVC) - GET_TARGET_PROPERTY(_targetType ${_PCH_current_target} TYPE) - IF(${_targetType} STREQUAL SHARED_LIBRARY OR ${_targetType} STREQUAL MODULE_LIBRARY) - LIST(APPEND _FLAGS "-fPIC") - ENDIF(${_targetType} STREQUAL SHARED_LIBRARY OR ${_targetType} STREQUAL MODULE_LIBRARY) - ENDIF(NOT MSVC) - - GET_DIRECTORY_PROPERTY(DIRINC INCLUDE_DIRECTORIES ) - FOREACH(item ${DIRINC}) - LIST(APPEND _FLAGS " ${_PCH_include_prefix}\"${item}\"") - ENDFOREACH(item) - - # Required for CMake 2.6 - SET(GLOBAL_DEFINITIONS "") - GET_DIRECTORY_PROPERTY(DEFINITIONS COMPILE_DEFINITIONS) - FOREACH(item ${DEFINITIONS}) - LIST(APPEND GLOBAL_DEFINITIONS -D${item}) - ENDFOREACH(item) - - GET_DIRECTORY_PROPERTY(_directory_flags DEFINITIONS) - GET_DIRECTORY_PROPERTY(_directory_definitions DIRECTORY ${CMAKE_SOURCE_DIR} DEFINITIONS) - LIST(APPEND _FLAGS ${GLOBAL_DEFINITIONS}) - LIST(APPEND _FLAGS ${_directory_flags}) - LIST(APPEND _FLAGS ${_directory_definitions}) - LIST(APPEND _FLAGS ${CMAKE_CXX_FLAGS}) - - # Format definitions - SEPARATE_ARGUMENTS(_FLAGS) - - IF(CLANG) - SET(_IGNORE_NEXT OFF) - FOREACH(item ${_FLAGS}) - IF(_IGNORE_NEXT) - SET(_IGNORE_NEXT OFF) - ELSE(_IGNORE_NEXT) - IF(item MATCHES "^-Xarch") - SET(_IGNORE_NEXT ON) - ELSEIF(item MATCHES "^-arch") - SET(_IGNORE_NEXT ON) - ELSE(item MATCHES "^-Xarch") - LIST(APPEND ${_out_compile_flags} ${item}) - ENDIF(item MATCHES "^-Xarch") - ENDIF(_IGNORE_NEXT) - ENDFOREACH(item) - ELSE(CLANG) - SET(${_out_compile_flags} ${_FLAGS}) - ENDIF(CLANG) -ENDMACRO(_PCH_GET_COMPILE_FLAGS) - -MACRO(_PCH_GET_PDB_FILENAME out_filename _target) - # determine output directory based on target type - GET_TARGET_PROPERTY(_targetType ${_target} TYPE) - IF(${_targetType} STREQUAL EXECUTABLE) - SET(_targetOutput ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}) - ELSEIF(${_targetType} STREQUAL STATIC_LIBRARY) - SET(_targetOutput ${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}) - ELSE(${_targetType} STREQUAL EXECUTABLE) - SET(_targetOutput ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}) - ENDIF(${_targetType} STREQUAL EXECUTABLE) - - # determine target postfix - STRING(TOUPPER "${CMAKE_BUILD_TYPE}_POSTFIX" _postfix_var_name) - GET_TARGET_PROPERTY(_targetPostfix ${_target} ${_postfix_var_name}) - IF(${_targetPostfix} MATCHES NOTFOUND) - SET(_targetPostfix "") - ENDIF(${_targetPostfix} MATCHES NOTFOUND) - - SET(${out_filename} "${_targetOutput}/${_target}${_targetPostfix}.pdb") -ENDMACRO(_PCH_GET_PDB_FILENAME) - -MACRO(_PCH_GET_COMPILE_COMMAND out_command _input _inputcpp _output) - IF(CMAKE_CXX_COMPILER_ARG1) - # remove leading space in compiler argument - STRING(REGEX REPLACE "^ +" "" pchsupport_compiler_cxx_arg1 ${CMAKE_CXX_COMPILER_ARG1}) - ELSE(CMAKE_CXX_COMPILER_ARG1) - SET(pchsupport_compiler_cxx_arg1 "") - ENDIF(CMAKE_CXX_COMPILER_ARG1) - - IF(MSVC) - _PCH_GET_PDB_FILENAME(PDB_FILE ${_PCH_current_target}) - SET(${out_command} ${CMAKE_CXX_COMPILER} ${pchsupport_compiler_cxx_arg1} ${_compile_FLAGS} /Yc /Fp\"${_output}\" ${_inputcpp} /c /Fd\"${PDB_FILE}\") - ELSE(MSVC) - SET(HEADER_FORMAT "c++-header") - IF(APPLE) - SET(HEADER_FORMAT "objective-${HEADER_FORMAT}") - ENDIF(APPLE) - SET(${out_command} ${CMAKE_CXX_COMPILER} ${pchsupport_compiler_cxx_arg1} ${_compile_FLAGS} -x ${HEADER_FORMAT} -o ${_output} -c ${_input}) - ENDIF(MSVC) -ENDMACRO(_PCH_GET_COMPILE_COMMAND) - -MACRO(GET_PRECOMPILED_HEADER_OUTPUT _targetName _input _output) - IF(MSVC) - GET_FILENAME_COMPONENT(_name ${_input} NAME_WE) - SET(_output "${CMAKE_CURRENT_BINARY_DIR}/${_name}.pch") - ELSE(MSVC) - GET_FILENAME_COMPONENT(_name ${_input} NAME) - SET(_output "${CMAKE_CURRENT_BINARY_DIR}/${_name}.gch") - ENDIF(MSVC) -ENDMACRO(GET_PRECOMPILED_HEADER_OUTPUT _targetName _input) - -MACRO(ADD_PRECOMPILED_HEADER_TO_TARGET _targetName _input _pch_output_to_use ) - GET_TARGET_PROPERTY(oldProps ${_targetName} COMPILE_FLAGS) - IF(${oldProps} MATCHES NOTFOUND) - SET(oldProps "") - ENDIF(${oldProps} MATCHES NOTFOUND) - - IF(MSVC) - SET(_target_cflags "${oldProps} /Yu\"${_input}\" /FI\"${_input}\" /Fp\"${_pch_output_to_use}\"") - ELSE(MSVC) - # to do: test whether compiler flags match between target _targetName - # and _pch_output_to_use - FILE(TO_NATIVE_PATH ${_pch_output_to_use} _native_pch_path) - - # for use with distcc and gcc >4.0.1 if preprocessed files are accessible - # on all remote machines set - # PCH_ADDITIONAL_COMPILER_FLAGS to -fpch-preprocess - SET(_target_cflags "${oldProps} ${PCH_ADDITIONAL_COMPILER_FLAGS}-include ${_input} -Winvalid-pch") - ENDIF(MSVC) - - SET_TARGET_PROPERTIES(${_targetName} PROPERTIES COMPILE_FLAGS ${_target_cflags}) - IF(oldProps) - SET_TARGET_PROPERTIES(${_targetName}_pch_dephelp PROPERTIES COMPILE_FLAGS ${oldProps}) - ENDIF(oldProps) - ADD_CUSTOM_TARGET(pch_Generate_${_targetName} DEPENDS ${_pch_output_to_use}) - ADD_DEPENDENCIES(${_targetName} pch_Generate_${_targetName}) +# Set PCH_FLAGS for common flags, PCH_ARCH_XXX_FLAGS for specific archs flags and PCH_ARCHS for archs +MACRO(PCH_SET_COMPILE_FLAGS _target) + SET(PCH_FLAGS) + SET(PCH_ARCHS) + + SET(FLAGS) + LIST(APPEND _FLAGS ${CMAKE_CXX_FLAGS}) + + STRING(TOUPPER "${CMAKE_BUILD_TYPE}" _UPPER_BUILD) + LIST(APPEND _FLAGS " ${CMAKE_CXX_FLAGS_${_UPPER_BUILD}}") + + IF(NOT MSVC) + GET_TARGET_PROPERTY(_targetType ${_target} TYPE) + IF(${_targetType} STREQUAL SHARED_LIBRARY OR ${_targetType} STREQUAL MODULE_LIBRARY) + LIST(APPEND _FLAGS " -fPIC") + ENDIF(${_targetType} STREQUAL SHARED_LIBRARY OR ${_targetType} STREQUAL MODULE_LIBRARY) + ENDIF(NOT MSVC) + + GET_DIRECTORY_PROPERTY(DIRINC INCLUDE_DIRECTORIES) + FOREACH(item ${DIRINC}) + LIST(APPEND _FLAGS " ${_PCH_include_prefix}\"${item}\"") + ENDFOREACH(item) + + # Required for CMake 2.6 + SET(GLOBAL_DEFINITIONS) + GET_DIRECTORY_PROPERTY(DEFINITIONS COMPILE_DEFINITIONS) + FOREACH(item ${DEFINITIONS}) + LIST(APPEND GLOBAL_DEFINITIONS " -D${item}") + ENDFOREACH(item) + + GET_DIRECTORY_PROPERTY(DEFINITIONS COMPILE_DEFINITIONS_${_UPPER_BUILD}) + FOREACH(item ${DEFINITIONS}) + LIST(APPEND GLOBAL_DEFINITIONS " -D${item}") + ENDFOREACH(item) + + GET_TARGET_PROPERTY(oldProps ${_target} COMPILE_FLAGS) + IF(oldProps) + LIST(APPEND _FLAGS " ${oldProps}") + ENDIF(oldProps) + + GET_TARGET_PROPERTY(oldPropsBuild ${_target} COMPILE_FLAGS_${_UPPER_BUILD}) + IF(oldPropsBuild) + LIST(APPEND _FLAGS " ${oldPropsBuild}") + ENDIF(oldPropsBuild) + + GET_DIRECTORY_PROPERTY(_directory_flags DEFINITIONS) + GET_DIRECTORY_PROPERTY(_directory_definitions DIRECTORY ${CMAKE_SOURCE_DIR} DEFINITIONS) + LIST(APPEND _FLAGS " ${GLOBAL_DEFINITIONS}") + LIST(APPEND _FLAGS " ${_directory_flags}") + LIST(APPEND _FLAGS " ${_directory_definitions}") + + STRING(REGEX REPLACE " +" " " _FLAGS ${_FLAGS}) + + # Format definitions + SEPARATE_ARGUMENTS(_FLAGS) + + IF(CLANG) + # Determining all architectures and get common flags + SET(_ARCH_NEXT) + SET(_XARCH_NEXT) + FOREACH(item ${_FLAGS}) + IF(_ARCH_NEXT) + LIST(FIND PCH_ARCHS ${item} ITEM_FOUND) + IF(ITEM_FOUND EQUAL -1) + LIST(APPEND PCH_ARCHS ${item}) + STRING(TOUPPER "${item}" _UPPER_ARCH) + SET(PCH_ARCH_${_UPPER_ARCH}_FLAGS "-arch" ${item}) + ENDIF(ITEM_FOUND EQUAL -1) + SET(_ARCH_NEXT OFF) + ELSEIF(_XARCH_NEXT) + SET(_XARCH_NEXT OFF) + ELSE(_ARCH_NEXT) + IF(item MATCHES "^-arch") + SET(_ARCH_NEXT ON) + ELSEIF(item MATCHES "^-Xarch_") + STRING(REGEX REPLACE "-Xarch_([a-z0-9_]+)" "\\1" item ${item}) + LIST(FIND PCH_ARCHS ${item} ITEM_FOUND) + IF(ITEM_FOUND EQUAL -1) + LIST(APPEND PCH_ARCHS ${item}) + STRING(TOUPPER "${item}" _UPPER_ARCH) + SET(PCH_ARCH_${_UPPER_ARCH}_FLAGS "-arch" ${item}) + ENDIF(ITEM_FOUND EQUAL -1) + SET(_XARCH_NEXT ON) + ELSE(item MATCHES "^-arch") + LIST(APPEND PCH_FLAGS ${item}) + ENDIF(item MATCHES "^-arch") + ENDIF(_ARCH_NEXT) + ENDFOREACH(item) + + # Get architcture specific flags + SET(_XARCH_NEXT) + FOREACH(item ${_FLAGS}) + IF(_XARCH_NEXT) + STRING(TOUPPER "${_XARCH_NEXT}" _UPPER_XARCH) + LIST(APPEND PCH_ARCH_${_UPPER_XARCH}_FLAGS ${item}) + SET(_XARCH_NEXT OFF) + ELSE(_XARCH_NEXT) + IF(item MATCHES "^-Xarch_") + STRING(SUBSTRING "${item}" 7 -1 _XARCH_NEXT) + ENDIF(item MATCHES "^-Xarch_") + ENDIF(_XARCH_NEXT) + ENDFOREACH(item) + + # Remove duplicated architectures + IF(_ARCHS AND PCH_ARCHS) + LIST(REMOVE_DUPLICATES PCH_ARCHS) + ENDIF(_ARCHS AND PCH_ARCHS) + ELSE(CLANG) + SET(PCH_FLAGS ${_FLAGS}) + ENDIF(CLANG) + + IF(PCH_FLAGS) + LIST(REMOVE_DUPLICATES PCH_FLAGS) + ENDIF(PCH_FLAGS) +ENDMACRO(PCH_SET_COMPILE_FLAGS) + +MACRO(GET_PDB_FILENAME _out_filename _target) + # determine output directory based on target type + GET_TARGET_PROPERTY(_targetType ${_target} TYPE) + IF(${_targetType} STREQUAL EXECUTABLE) + SET(_targetOutput ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}) + ELSEIF(${_targetType} STREQUAL STATIC_LIBRARY) + SET(_targetOutput ${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}) + ELSE(${_targetType} STREQUAL EXECUTABLE) + SET(_targetOutput ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}) + ENDIF(${_targetType} STREQUAL EXECUTABLE) + + # determine target postfix + STRING(TOUPPER "${CMAKE_BUILD_TYPE}_POSTFIX" _postfix_var_name) + GET_TARGET_PROPERTY(_targetPostfix ${_target} ${_postfix_var_name}) + IF(${_targetPostfix} MATCHES NOTFOUND) + SET(_targetPostfix "") + ENDIF(${_targetPostfix} MATCHES NOTFOUND) + + SET(${_out_filename} "${_targetOutput}/${_target}${_targetPostfix}.pdb") +ENDMACRO(GET_PDB_FILENAME) + +MACRO(PCH_SET_COMPILE_COMMAND _inputcpp _compile_FLAGS) + IF(CMAKE_CXX_COMPILER_ARG1) + # remove leading space in compiler argument + STRING(REGEX REPLACE "^ +" "" pchsupport_compiler_cxx_arg1 ${CMAKE_CXX_COMPILER_ARG1}) + ELSE(CMAKE_CXX_COMPILER_ARG1) + SET(pchsupport_compiler_cxx_arg1 "") + ENDIF(CMAKE_CXX_COMPILER_ARG1) + + IF(MSVC) + GET_PDB_FILENAME(PDB_FILE ${_PCH_current_target}) + SET(PCH_COMMAND ${CMAKE_CXX_COMPILER} ${pchsupport_compiler_cxx_arg1} ${_compile_FLAGS} /Yc /Fp"${PCH_OUTPUT}" ${_inputcpp} /Fd"${PDB_FILE}" /c /Fo"${PCH_OUTPUT}.obj") + ELSE(MSVC) + SET(HEADER_FORMAT "c++-header") + SET(_FLAGS "") + IF(APPLE) + SET(HEADER_FORMAT "objective-${HEADER_FORMAT}") + SET(_FLAGS -fobjc-abi-version=2 -fobjc-legacy-dispatch) + ENDIF(APPLE) + SET(PCH_COMMAND ${CMAKE_CXX_COMPILER} ${pchsupport_compiler_cxx_arg1} ${_compile_FLAGS} ${_FLAGS} -x ${HEADER_FORMAT} -o ${PCH_OUTPUT} -c ${PCH_INPUT}) + ENDIF(MSVC) +ENDMACRO(PCH_SET_COMPILE_COMMAND) + +MACRO(PCH_SET_PRECOMPILED_HEADER_OUTPUT _targetName _input _arch _language) + SET(_OUTPUT_DIR "${CMAKE_CURRENT_BINARY_DIR}/${_targetName}_pch") + + IF(MSVC) + FILE(MAKE_DIRECTORY ${_OUTPUT_DIR}) + GET_FILENAME_COMPONENT(_name ${_input} NAME_WE) + SET(PCH_INPUT ${_input}) + SET(PCH_OUTPUT "${_OUTPUT_DIR}/${_name}.pch") + ELSE(MSVC) + IF(NOT "${_arch}" STREQUAL "") + SET(_OUTPUT_DIR "${_OUTPUT_DIR}_${_arch}") + ENDIF(NOT "${_arch}" STREQUAL "") + + IF(NOT "${_language}" STREQUAL "") + SET(_OUTPUT_DIR "${_OUTPUT_DIR}_${_language}") + ENDIF(NOT "${_language}" STREQUAL "") + + GET_FILENAME_COMPONENT(_name ${_input} NAME) + + # Copy .h to output dir + SET(PCH_INPUT "${_OUTPUT_DIR}/${_name}") + ADD_CUSTOM_COMMAND(OUTPUT ${PCH_INPUT} + COMMAND ${CMAKE_COMMAND} -E copy_if_different ${_input} ${PCH_INPUT} + DEPENDS ${_input} + COMMENT "[${_targetName}] Update precompiled header - done" + ) + + IF(CLANG) + SET(PCH_EXT "pth") + ELSE(CLANG) + SET(PCH_EXT "gch") + ENDIF(CLANG) + + # For GCC and Clang, PCH needs to be in the same directory as .h + SET(PCH_OUTPUT "${_OUTPUT_DIR}/${_name}.${PCH_EXT}") + ENDIF(MSVC) +ENDMACRO(PCH_SET_PRECOMPILED_HEADER_OUTPUT) + +# Add common flags +MACRO(ADD_PRECOMPILED_HEADER_TO_TARGET _targetName) + GET_TARGET_PROPERTY(oldProps ${_targetName} COMPILE_FLAGS) + + IF(${oldProps} MATCHES NOTFOUND) + SET(oldProps "") + ENDIF(${oldProps} MATCHES NOTFOUND) + + IF(MSVC) + SET(_target_cflags "${oldProps} /Yu\"${PCH_INPUT}\" /FI\"${PCH_INPUT}\" /Fp\"${PCH_OUTPUT}\"") + ELSE(MSVC) + # for use with distcc and gcc >4.0.1 if preprocessed files are accessible + # on all remote machines set + # PCH_ADDITIONAL_COMPILER_FLAGS to -fpch-preprocess + SET(PCH_ADDITIONAL_COMPILER_FLAGS) + LIST(LENGTH PCH_ARCHS PCH_ARCHS_COUNT) + + # If no arch is specified, create common flags + IF(PCH_ARCHS_COUNT LESS 2) + SET(PCH_ADDITIONAL_COMPILER_FLAGS "-include ${PCH_INPUT} ${PCH_ADDITIONAL_COMPILER_FLAGS}") + ENDIF(PCH_ARCHS_COUNT LESS 2) + + IF(APPLE) + SET(PCH_ADDITIONAL_COMPILER_FLAGS "-fobjc-abi-version=2 -fobjc-legacy-dispatch -x objective-c++ ${PCH_ADDITIONAL_COMPILER_FLAGS}") + ENDIF(APPLE) + + IF(WITH_PCH_DEBUG) + SET(PCH_ADDITIONAL_COMPILER_FLAGS "-H ${PCH_ADDITIONAL_COMPILER_FLAGS}") + ENDIF(WITH_PCH_DEBUG) + + SET(_target_cflags "${oldProps} ${PCH_ADDITIONAL_COMPILER_FLAGS} -Winvalid-pch") + ENDIF(MSVC) + + SET_TARGET_PROPERTIES(${_targetName} PROPERTIES COMPILE_FLAGS ${_target_cflags}) ENDMACRO(ADD_PRECOMPILED_HEADER_TO_TARGET) -MACRO(ADD_PRECOMPILED_HEADER _targetName _inputh _inputcpp) +# Add specific flags for an arch +MACRO(ADD_PRECOMPILED_HEADER_TO_TARGET_ARCH _targetName _arch) + LIST(LENGTH PCH_ARCHS PCH_ARCHS_COUNT) + + IF(PCH_ARCHS_COUNT GREATER 1) + GET_TARGET_PROPERTY(_FLAGS ${_targetName} COMPILE_FLAGS) + + IF(${_FLAGS} MATCHES NOTFOUND) + SET(_FLAGS "") + ENDIF(${_FLAGS} MATCHES NOTFOUND) + + SET(_FLAGS "${_FLAGS} -Xarch_${_arch} -include${PCH_INPUT}") - SET(_PCH_current_target ${_targetName}) + SET_TARGET_PROPERTIES(${_targetName} PROPERTIES COMPILE_FLAGS ${_FLAGS}) + ENDIF(PCH_ARCHS_COUNT GREATER 1) +ENDMACRO(ADD_PRECOMPILED_HEADER_TO_TARGET_ARCH) - IF(NOT CMAKE_BUILD_TYPE) - MESSAGE(FATAL_ERROR - "This is the ADD_PRECOMPILED_HEADER macro. " - "You must set CMAKE_BUILD_TYPE!" - ) - ENDIF(NOT CMAKE_BUILD_TYPE) +MACRO(PCH_CREATE_TARGET _targetName _targetNamePCH) + ADD_CUSTOM_COMMAND(OUTPUT ${PCH_OUTPUT} COMMAND ${PCH_COMMAND} COMMENT "Generating ${_targetNamePCH}" DEPENDS ${PCH_INPUT}) + ADD_CUSTOM_TARGET(${_targetNamePCH} DEPENDS ${PCH_INPUT} ${PCH_OUTPUT}) + ADD_DEPENDENCIES(${_targetName} ${_targetNamePCH}) +ENDMACRO(PCH_CREATE_TARGET _targetName _inputh _inputcpp) - GET_PRECOMPILED_HEADER_OUTPUT( ${_targetName} ${_inputh} _output) +MACRO(ADD_PRECOMPILED_HEADER _targetName _inputh _inputcpp) + SET(_PCH_current_target ${_targetName}) + + IF(NOT CMAKE_BUILD_TYPE) + MESSAGE(FATAL_ERROR + "This is the ADD_PRECOMPILED_HEADER macro. " + "You must set CMAKE_BUILD_TYPE!" + ) + ENDIF(NOT CMAKE_BUILD_TYPE) - GET_TARGET_PROPERTY(_targetType ${_PCH_current_target} TYPE) + PCH_SET_COMPILE_FLAGS(${_targetName}) - # always build static library because it doesn't need linking - ADD_LIBRARY(${_targetName}_pch_dephelp STATIC ${_inputcpp}) + IF(PCH_ARCHS) + SET(PCH_OUTPUTS) + FOREACH(_ARCH ${PCH_ARCHS}) + STRING(TOUPPER "${_ARCH}" _UPPER_ARCH) - _PCH_GET_COMPILE_FLAGS(_compile_FLAGS) + PCH_SET_PRECOMPILED_HEADER_OUTPUT(${_targetName} ${_inputh} ${_ARCH} "") + LIST(APPEND PCH_OUTPUTS ${PCH_OUTPUT}) - SET_SOURCE_FILES_PROPERTIES(${_inputh} PROPERTIES GENERATED 1) + PCH_SET_COMPILE_COMMAND(${_inputcpp} "${PCH_ARCH_${_UPPER_ARCH}_FLAGS};${PCH_FLAGS}") + PCH_CREATE_TARGET(${_targetName} ${_targetName}_pch_${_ARCH}) - _PCH_GET_COMPILE_COMMAND(_command ${_inputh} ${_inputcpp} ${_output}) + ADD_PRECOMPILED_HEADER_TO_TARGET_ARCH(${_targetName} ${_ARCH}) + ENDFOREACH(_ARCH) + ELSE(PCH_ARCHS) + PCH_SET_PRECOMPILED_HEADER_OUTPUT(${_targetName} ${_inputh} "" "") + LIST(APPEND PCH_OUTPUTS ${PCH_OUTPUT}) - ADD_CUSTOM_COMMAND( - OUTPUT ${_output} - COMMAND ${_command} - DEPENDS ${_inputh} ${_targetName}_pch_dephelp - ) + PCH_SET_COMPILE_COMMAND(${_inputcpp} "${PCH_FLAGS}") + PCH_CREATE_TARGET(${_targetName} ${_targetName}_pch) + ENDIF(PCH_ARCHS) - ADD_PRECOMPILED_HEADER_TO_TARGET(${_targetName} ${_inputh} ${_output}) + ADD_PRECOMPILED_HEADER_TO_TARGET(${_targetName}) + + SET_DIRECTORY_PROPERTIES(PROPERTIES ADDITIONAL_MAKE_CLEAN_FILES "${PCH_OUTPUTS}") ENDMACRO(ADD_PRECOMPILED_HEADER) # Macro to move PCH creation file to the front of files list +# or remove .cpp from library/executable to avoid warning MACRO(FIX_PRECOMPILED_HEADER _files _pch) - # Remove .cpp creating PCH from the list - LIST(REMOVE_ITEM ${_files} ${_pch}) - # Prepend .cpp creating PCH to the list - LIST(INSERT ${_files} 0 ${_pch}) + # Remove .cpp creating PCH from the list + LIST(REMOVE_ITEM ${_files} ${_pch}) + IF(MSVC) + # Prepend .cpp creating PCH to the list + LIST(INSERT ${_files} 0 ${_pch}) + ENDIF(MSVC) ENDMACRO(FIX_PRECOMPILED_HEADER) MACRO(ADD_NATIVE_PRECOMPILED_HEADER _targetName _inputh _inputcpp) - SET(PCH_METHOD 0) - - # 0 => creating a new target for PCH, works for all makefiles - # 1 => setting PCH for VC++ project, works for VC++ projects - # 2 => setting PCH for XCode project, works for XCode projects - IF(CMAKE_GENERATOR MATCHES "Visual Studio") - SET(PCH_METHOD 1) - ELSEIF(CMAKE_GENERATOR MATCHES "NMake Makefiles" AND MFC_FOUND AND CMAKE_MFC_FLAG) - # To fix a bug with MFC - # Don't forget to use FIX_PRECOMPILED_HEADER before creating the target -# SET(PCH_METHOD 1) - ELSEIF(CMAKE_GENERATOR MATCHES "Xcode") - SET(PCH_METHOD 2) - ENDIF(CMAKE_GENERATOR MATCHES "Visual Studio") - - IF(PCH_METHOD EQUAL 1) - # Auto include the precompile (useful for moc processing, since the use of - # precompiled is specified at the target level - # and I don't want to specifiy /F- for each moc/res/ui generated files (using Qt) - - GET_TARGET_PROPERTY(oldProps ${_targetName} COMPILE_FLAGS) - IF(${oldProps} MATCHES NOTFOUND) - SET(oldProps "") - ENDIF(${oldProps} MATCHES NOTFOUND) - - SET(newProperties "${oldProps} /Yu\"${_inputh}\" /FI\"${_inputh}\"") - SET_TARGET_PROPERTIES(${_targetName} PROPERTIES COMPILE_FLAGS "${newProperties}") - - #also inlude ${oldProps} to have the same compile options - SET_SOURCE_FILES_PROPERTIES(${_inputcpp} PROPERTIES COMPILE_FLAGS "${oldProps} /Yc\"${_inputh}\"") - ELSEIF(PCH_METHOD EQUAL 2) - # For Xcode, cmake needs my patch to process - # GCC_PREFIX_HEADER and GCC_PRECOMPILE_PREFIX_HEADER as target properties - - GET_TARGET_PROPERTY(oldProps ${_targetName} COMPILE_FLAGS) - IF(${oldProps} MATCHES NOTFOUND) - SET(oldProps "") - ENDIF(${oldProps} MATCHES NOTFOUND) - - # When buiding out of the tree, precompiled may not be located - # Use full path instead. - GET_FILENAME_COMPONENT(fullPath ${_inputh} ABSOLUTE) - - SET_TARGET_PROPERTIES(${_targetName} PROPERTIES XCODE_ATTRIBUTE_GCC_PREFIX_HEADER "${fullPath}") - SET_TARGET_PROPERTIES(${_targetName} PROPERTIES XCODE_ATTRIBUTE_GCC_PRECOMPILE_PREFIX_HEADER "YES") - ELSE(PCH_METHOD EQUAL 1) - #Fallback to the "old" precompiled suppport - ADD_PRECOMPILED_HEADER(${_targetName} ${_inputh} ${_inputcpp}) - ENDIF(PCH_METHOD EQUAL 1) - + IF(NOT PCHSupport_FOUND) + MESSAGE(STATUS "PCH disabled because compiler doesn't support them") + RETURN() + ENDIF(NOT PCHSupport_FOUND) + + # 0 => creating a new target for PCH, works for all makefiles + # 1 => setting PCH for VC++ project, works for VC++ projects + # 2 => setting PCH for XCode project, works for XCode projects + IF(CMAKE_GENERATOR MATCHES "Visual Studio") + SET(PCH_METHOD 1) + ELSEIF(CMAKE_GENERATOR MATCHES "NMake Makefiles" AND MFC_FOUND AND CMAKE_MFC_FLAG) + # To fix a bug with MFC + # Don't forget to use FIX_PRECOMPILED_HEADER before creating the target +# SET(PCH_METHOD 1) + ELSEIF(CMAKE_GENERATOR MATCHES "Xcode") + SET(PCH_METHOD 2) + ELSE(CMAKE_GENERATOR MATCHES "Visual Studio") + SET(PCH_METHOD 0) + ENDIF(CMAKE_GENERATOR MATCHES "Visual Studio") + + IF(PCH_METHOD EQUAL 1) + # Auto include the precompile (useful for moc processing, since the use of + # precompiled is specified at the target level + # and I don't want to specifiy /F- for each moc/res/ui generated files (using Qt) + + GET_TARGET_PROPERTY(oldProps ${_targetName} COMPILE_FLAGS) + IF(${oldProps} MATCHES NOTFOUND) + SET(oldProps "") + ENDIF(${oldProps} MATCHES NOTFOUND) + + SET(newProperties "${oldProps} /Yu\"${_inputh}\" /FI\"${_inputh}\"") + SET_TARGET_PROPERTIES(${_targetName} PROPERTIES COMPILE_FLAGS "${newProperties}") + + #also inlude ${oldProps} to have the same compile options + SET_SOURCE_FILES_PROPERTIES(${_inputcpp} PROPERTIES COMPILE_FLAGS "${oldProps} /Yc\"${_inputh}\"") + ELSEIF(PCH_METHOD EQUAL 2) + # For Xcode, cmake needs my patch to process + # GCC_PREFIX_HEADER and GCC_PRECOMPILE_PREFIX_HEADER as target properties + + # When buiding out of the tree, precompiled may not be located + # Use full path instead. + GET_FILENAME_COMPONENT(fullPath ${_inputh} ABSOLUTE) + + SET_TARGET_PROPERTIES(${_targetName} PROPERTIES XCODE_ATTRIBUTE_GCC_PREFIX_HEADER "${fullPath}") + SET_TARGET_PROPERTIES(${_targetName} PROPERTIES XCODE_ATTRIBUTE_GCC_PRECOMPILE_PREFIX_HEADER "YES") + ELSE(PCH_METHOD EQUAL 1) + #Fallback to the "old" precompiled suppport + ADD_PRECOMPILED_HEADER(${_targetName} ${_inputh} ${_inputcpp}) + ENDIF(PCH_METHOD EQUAL 1) + + IF(TARGET ${_targetName}_static) + ADD_NATIVE_PRECOMPILED_HEADER(${_targetName}_static ${_inputh} ${_inputcpp}) + ENDIF(TARGET ${_targetName}_static) ENDMACRO(ADD_NATIVE_PRECOMPILED_HEADER) diff --git a/code/CMakeModules/nel.cmake b/code/CMakeModules/nel.cmake index e990e75c7..e867609f7 100644 --- a/code/CMakeModules/nel.cmake +++ b/code/CMakeModules/nel.cmake @@ -50,14 +50,11 @@ MACRO(NL_GEN_REVISION_H) IF(TOOL_FOUND) # a custom target that is always built - ADD_CUSTOM_TARGET(revision ALL) - - # creates revision.h using cmake script - ADD_CUSTOM_COMMAND(TARGET revision - PRE_BUILD + ADD_CUSTOM_TARGET(revision ALL COMMAND ${CMAKE_COMMAND} -DSOURCE_DIR=${CMAKE_SOURCE_DIR} -DROOT_DIR=${CMAKE_SOURCE_DIR}/.. + -DCMAKE_MODULE_PATH=${CMAKE_SOURCE_DIR}/CMakeModules -P ${CMAKE_SOURCE_DIR}/CMakeModules/GetRevision.cmake) # revision.h is a generated file @@ -102,6 +99,11 @@ ENDMACRO(NL_TARGET_DRIVER) # Argument: ### MACRO(NL_DEFAULT_PROPS name label) + IF(HAVE_REVISION_H) + # explicitly say that the target depends on revision.h + ADD_DEPENDENCIES(${name} revision) + ENDIF(HAVE_REVISION_H) + # Note: This is just a workaround for a CMake bug generating VS10 files with a colon in the project name. # CMake Bug ID: http://www.cmake.org/Bug/view.php?id=11819 STRING(REGEX REPLACE "\\:" " -" proj_label ${label}) @@ -410,7 +412,7 @@ MACRO(NL_SETUP_BUILD) ENDIF(CMAKE_GENERATOR MATCHES "Xcode") # If target and host CPU are the same - IF("${HOST_CPU}" STREQUAL "${TARGET_CPU}") + IF("${HOST_CPU}" STREQUAL "${TARGET_CPU}" AND NOT CMAKE_CROSSCOMPILING) # x86-compatible CPU IF(HOST_CPU MATCHES "x86") IF(NOT CMAKE_SIZEOF_VOID_P) @@ -431,9 +433,9 @@ MACRO(NL_SETUP_BUILD) MESSAGE(STATUS "Unknown architecture: ${HOST_CPU}") ENDIF(HOST_CPU MATCHES "x86") # TODO: add checks for PPC - ELSE("${HOST_CPU}" STREQUAL "${TARGET_CPU}") + ELSE("${HOST_CPU}" STREQUAL "${TARGET_CPU}" AND NOT CMAKE_CROSSCOMPILING) MESSAGE(STATUS "Compiling on ${HOST_CPU} for ${TARGET_CPU}") - ENDIF("${HOST_CPU}" STREQUAL "${TARGET_CPU}") + ENDIF("${HOST_CPU}" STREQUAL "${TARGET_CPU}" AND NOT CMAKE_CROSSCOMPILING) # Use values from environment variables SET(PLATFORM_CFLAGS "$ENV{CFLAGS} $ENV{CPPFLAGS} ${PLATFORM_CFLAGS}") @@ -454,6 +456,7 @@ MACRO(NL_SETUP_BUILD) IF(NOT CMAKE_OSX_ARCHITECTURES) IF(TARGET_CPU STREQUAL "x86_64") SET(TARGET_X64 1) + SET(TARGET_X86 1) ELSEIF(TARGET_CPU STREQUAL "x86") SET(TARGET_X86 1) ELSEIF(TARGET_CPU STREQUAL "armv7s") @@ -470,7 +473,37 @@ MACRO(NL_SETUP_BUILD) SET(TARGET_ARMV5 1) ELSEIF(TARGET_CPU STREQUAL "arm") SET(TARGET_ARM 1) + ELSEIF(TARGET_CPU STREQUAL "mips") + SET(TARGET_MIPS 1) ENDIF(TARGET_CPU STREQUAL "x86_64") + + IF(TARGET_ARM) + IF(TARGET_ARMV7S) + ADD_PLATFORM_FLAGS("-DHAVE_ARMV7S") + ENDIF(TARGET_ARMV7S) + + IF(TARGET_ARMV7) + ADD_PLATFORM_FLAGS("-DHAVE_ARMV7") + ENDIF(TARGET_ARMV7) + + IF(TARGET_ARMV6) + ADD_PLATFORM_FLAGS("-HAVE_ARMV6") + ENDIF(TARGET_ARMV6) + + ADD_PLATFORM_FLAGS("-DHAVE_ARM") + ENDIF(TARGET_ARM) + + IF(TARGET_X86) + ADD_PLATFORM_FLAGS("-DHAVE_X86") + ENDIF(TARGET_X86) + + IF(TARGET_X64) + ADD_PLATFORM_FLAGS("-DHAVE_X64 -DHAVE_X86_64") + ENDIF(TARGET_X64) + + IF(TARGET_MIPS) + ADD_PLATFORM_FLAGS("-DHAVE_MIPS") + ENDIF(TARGET_MIPS) ENDIF(NOT CMAKE_OSX_ARCHITECTURES) # Fix library paths suffixes for Debian MultiArch @@ -478,10 +511,9 @@ MACRO(NL_SETUP_BUILD) SET(CMAKE_LIBRARY_PATH /lib/${LIBRARY_ARCHITECTURE} /usr/lib/${LIBRARY_ARCHITECTURE} ${CMAKE_LIBRARY_PATH}) IF(TARGET_X64) SET(CMAKE_LIBRARY_PATH ${CMAKE_LIBRARY_PATH} /lib64 /usr/lib64) - ENDIF(TARGET_X64) - IF(TARGET_X86) + ELSEIF(TARGET_X86) SET(CMAKE_LIBRARY_PATH ${CMAKE_LIBRARY_PATH} /lib32 /usr/lib32) - ENDIF(TARGET_X86) + ENDIF(TARGET_X64) ENDIF(LIBRARY_ARCHITECTURE) IF(APPLE AND NOT IOS) @@ -489,32 +521,22 @@ MACRO(NL_SETUP_BUILD) SET(CMAKE_LIBRARY_PATH /opt/local/lib ${CMAKE_LIBRARY_PATH}) ENDIF(APPLE AND NOT IOS) - IF(TARGET_ARM) - IF(TARGET_ARMV7) - ADD_PLATFORM_FLAGS("-DHAVE_ARMV7") - ENDIF(TARGET_ARMV7) - - IF(TARGET_ARMV6) - ADD_PLATFORM_FLAGS("-HAVE_ARMV6") - ENDIF(TARGET_ARMV6) - - ADD_PLATFORM_FLAGS("-DHAVE_ARM") - ENDIF(TARGET_ARM) - - IF(TARGET_X86) - ADD_PLATFORM_FLAGS("-DHAVE_X86") - ENDIF(TARGET_X86) - - IF(TARGET_X64) - ADD_PLATFORM_FLAGS("-DHAVE_X64 -DHAVE_X86_64") - ENDIF(TARGET_X64) - IF(WITH_LOGGING) ADD_PLATFORM_FLAGS("-DENABLE_LOGS") ENDIF(WITH_LOGGING) IF(MSVC) - IF(MSVC10) + IF(MSVC_VERSION EQUAL "1700" AND NOT MSVC11) + SET(MSVC11 ON) + ENDIF(MSVC_VERSION EQUAL "1700" AND NOT MSVC11) + + IF(MSVC11) + ADD_PLATFORM_FLAGS("/Gy- /MP") + # /Ox is working with VC++ 2010, but custom optimizations don't exist + SET(RELEASE_CFLAGS "/Ox /GF /GS- ${RELEASE_CFLAGS}") + # without inlining it's unusable, use custom optimizations again + SET(DEBUG_CFLAGS "/Od /Ob1 /GF- ${DEBUG_CFLAGS}") + ELSEIF(MSVC10) ADD_PLATFORM_FLAGS("/Gy- /MP") # /Ox is working with VC++ 2010, but custom optimizations don't exist SET(RELEASE_CFLAGS "/Ox /GF /GS- ${RELEASE_CFLAGS}") @@ -532,9 +554,9 @@ MACRO(NL_SETUP_BUILD) SET(RELEASE_CFLAGS "/Ox /GF /GS- ${RELEASE_CFLAGS}") # without inlining it's unusable, use custom optimizations again SET(DEBUG_CFLAGS "/Od /Ob1 ${DEBUG_CFLAGS}") - ELSE(MSVC10) + ELSE(MSVC11) MESSAGE(FATAL_ERROR "Can't determine compiler version ${MSVC_VERSION}") - ENDIF(MSVC10) + ENDIF(MSVC11) ADD_PLATFORM_FLAGS("/D_CRT_SECURE_NO_DEPRECATE /D_CRT_SECURE_NO_WARNINGS /D_CRT_NONSTDC_NO_WARNINGS /DWIN32 /D_WINDOWS /Zm1000 /wd4250") @@ -577,13 +599,10 @@ MACRO(NL_SETUP_BUILD) ENDIF(CLANG) ENDIF(WIN32) - IF(TARGET_ARM) - ADD_PLATFORM_FLAGS("-mthumb") - ENDIF(TARGET_ARM) - IF(APPLE) IF(IOS) - SET(CMAKE_OSX_DEPLOYMENT_TARGET "10.7" CACHE PATH "" FORCE) + # Disable CMAKE_OSX_DEPLOYMENT_TARGET for iOS + SET(CMAKE_OSX_DEPLOYMENT_TARGET "" CACHE PATH "" FORCE) ELSE(IOS) IF(NOT CMAKE_OSX_DEPLOYMENT_TARGET) SET(CMAKE_OSX_DEPLOYMENT_TARGET "10.6" CACHE PATH "" FORCE) @@ -609,6 +628,11 @@ MACRO(NL_SETUP_BUILD) SET(_ARCHS "${_ARCHS} x86_64") SET(TARGET_X64 1) MATH(EXPR TARGETS_COUNT "${TARGETS_COUNT}+1") + ELSEIF(_ARCH STREQUAL "armv7s") + SET(_ARCHS "${_ARCHS} armv7s") + SET(TARGET_ARMV7S 1) + SET(TARGET_ARM 1) + MATH(EXPR TARGETS_COUNT "${TARGETS_COUNT}+1") ELSEIF(_ARCH STREQUAL "armv7") SET(_ARCHS "${_ARCHS} armv7") SET(TARGET_ARMV7 1) @@ -619,16 +643,51 @@ MACRO(NL_SETUP_BUILD) SET(TARGET_ARMV6 1) SET(TARGET_ARM 1) MATH(EXPR TARGETS_COUNT "${TARGETS_COUNT}+1") + ELSEIF(_ARCH STREQUAL "mips") + SET(_ARCHS "${_ARCHS} mips") + SET(TARGET_MIPS 1) + MATH(EXPR TARGETS_COUNT "${TARGETS_COUNT}+1") ELSE(_ARCH STREQUAL "i386") SET(_ARCHS "${_ARCHS} unknwon(${_ARCH})") ENDIF(_ARCH STREQUAL "i386") ENDFOREACH(_ARCH) MESSAGE(STATUS "Compiling under Mac OS X for ${TARGETS_COUNT} architectures: ${_ARCHS}") ELSE(CMAKE_OSX_ARCHITECTURES) - SET(TARGETS_COUNT 1) + SET(TARGETS_COUNT 0) ENDIF(CMAKE_OSX_ARCHITECTURES) IF(TARGETS_COUNT EQUAL 1) + IF(TARGET_ARM) + IF(TARGET_ARMV7S) + ADD_PLATFORM_FLAGS("-arch armv7s -DHAVE_ARMV7S") + ENDIF(TARGET_ARMV7S) + + IF(TARGET_ARMV7) + ADD_PLATFORM_FLAGS("-arch armv7 -DHAVE_ARMV7") + ENDIF(TARGET_ARMV7) + + IF(TARGET_ARMV6) + ADD_PLATFORM_FLAGS("-arch armv6 -DHAVE_ARMV6") + ENDIF(TARGET_ARMV6) + + IF(TARGET_ARMV5) + ADD_PLATFORM_FLAGS("-arch armv5 -DHAVE_ARMV5") + ENDIF(TARGET_ARMV5) + + ADD_PLATFORM_FLAGS("-mthumb -DHAVE_ARM") + ENDIF(TARGET_ARM) + + IF(TARGET_X64) + ADD_PLATFORM_FLAGS("-arch x86_64 -DHAVE_X64 -DHAVE_X86_64 -DHAVE_X86") + ELSEIF(TARGET_X86) + ADD_PLATFORM_FLAGS("-arch i386 -DHAVE_X86") + ENDIF(TARGET_X64) + + IF(TARGET_MIPS) + ADD_PLATFORM_FLAGS("-arch mips -DHAVE_MIPS") + ENDIF(TARGET_MIPS) + ELSEIF(TARGETS_COUNT EQUAL 0) + # Not using CMAKE_OSX_ARCHITECTURES, HAVE_XXX already defined before IF(TARGET_ARM) IF(TARGET_ARMV7S) ADD_PLATFORM_FLAGS("-arch armv7s") @@ -645,15 +704,19 @@ MACRO(NL_SETUP_BUILD) IF(TARGET_ARMV5) ADD_PLATFORM_FLAGS("-arch armv5") ENDIF(TARGET_ARMV5) - ENDIF(TARGET_ARM) - IF(TARGET_X86) - ADD_PLATFORM_FLAGS("-arch i386") - ENDIF(TARGET_X86) + ADD_PLATFORM_FLAGS("-mthumb") + ENDIF(TARGET_ARM) IF(TARGET_X64) ADD_PLATFORM_FLAGS("-arch x86_64") + ELSEIF(TARGET_X86) + ADD_PLATFORM_FLAGS("-arch i386") ENDIF(TARGET_X64) + + IF(TARGET_MIPS) + ADD_PLATFORM_FLAGS("-arch mips") + ENDIF(TARGET_MIPS) ELSE(TARGETS_COUNT EQUAL 1) IF(TARGET_ARMV6) ADD_PLATFORM_FLAGS("-Xarch_armv6 -mthumb -Xarch_armv6 -DHAVE_ARM -Xarch_armv6 -DHAVE_ARMV6") @@ -664,15 +727,21 @@ MACRO(NL_SETUP_BUILD) ENDIF(TARGET_ARMV7) IF(TARGET_X86) - ADD_PLATFORM_FLAGS("-arch i386 -Xarch_i386 -DHAVE_X86") + ADD_PLATFORM_FLAGS("-Xarch_i386 -DHAVE_X86") ENDIF(TARGET_X86) IF(TARGET_X64) - ADD_PLATFORM_FLAGS("-arch x86_64 -Xarch_x86_64 -DHAVE_X64 -Xarch_x86_64 -DHAVE_X86_64") + ADD_PLATFORM_FLAGS("-Xarch_x86_64 -DHAVE_X64 -Xarch_x86_64 -DHAVE_X86_64") ENDIF(TARGET_X64) + + IF(TARGET_MIPS) + ADD_PLATFORM_FLAGS("-Xarch_mips -DHAVE_MIPS") + ENDIF(TARGET_MIPS) ENDIF(TARGETS_COUNT EQUAL 1) IF(IOS) + SET(CMAKE_OSX_SYSROOT "" CACHE PATH "" FORCE) + IF(IOS_VERSION) PARSE_VERSION_STRING(${IOS_VERSION} IOS_VERSION_MAJOR IOS_VERSION_MINOR IOS_VERSION_PATCH) CONVERT_VERSION_NUMBER(${IOS_VERSION_MAJOR} ${IOS_VERSION_MINOR} ${IOS_VERSION_PATCH} IOS_VERSION_NUMBER) @@ -681,20 +750,44 @@ MACRO(NL_SETUP_BUILD) ENDIF(IOS_VERSION) IF(CMAKE_IOS_SYSROOT) - ADD_PLATFORM_FLAGS("-isysroot${CMAKE_IOS_SYSROOT}") - ADD_PLATFORM_FLAGS("-miphoneos-version-min=${IOS_VERSION}") - SET(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} -Wl,-iphoneos_version_min,${IOS_VERSION}") + IF(TARGET_ARMV7S) + IF(TARGETS_COUNT GREATER 1) + SET(XARCH "-Xarch_armv7s ") + ENDIF(TARGETS_COUNT GREATER 1) + + ADD_PLATFORM_FLAGS("${XARCH}-isysroot${CMAKE_IOS_SYSROOT}") + ADD_PLATFORM_FLAGS("${XARCH}-miphoneos-version-min=${IOS_VERSION}") + SET(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} ${XARCH}-Wl,-iphoneos_version_min,${IOS_VERSION}") + ENDIF(TARGET_ARMV7S) + + IF(TARGET_ARMV7) + IF(TARGETS_COUNT GREATER 1) + SET(XARCH "-Xarch_armv7 ") + ENDIF(TARGETS_COUNT GREATER 1) + + ADD_PLATFORM_FLAGS("${XARCH}-isysroot${CMAKE_IOS_SYSROOT}") + ADD_PLATFORM_FLAGS("${XARCH}-miphoneos-version-min=${IOS_VERSION}") + SET(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} ${XARCH}-Wl,-iphoneos_version_min,${IOS_VERSION}") + ENDIF(TARGET_ARMV7) + + IF(TARGET_ARMV6) + IF(TARGETS_COUNT GREATER 1) + SET(XARCH "-Xarch_armv6 ") + ENDIF(TARGETS_COUNT GREATER 1) + + ADD_PLATFORM_FLAGS("${XARCH}-isysroot${CMAKE_IOS_SYSROOT}") + ADD_PLATFORM_FLAGS("${XARCH}-miphoneos-version-min=${IOS_VERSION}") + SET(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} ${XARCH}-Wl,-iphoneos_version_min,${IOS_VERSION}") + ENDIF(TARGET_ARMV6) ENDIF(CMAKE_IOS_SYSROOT) IF(CMAKE_IOS_SIMULATOR_SYSROOT AND TARGET_X86) - IF(TARGETS_COUNT EQUAL 1) - ADD_PLATFORM_FLAGS("-arch i386") - ELSE(TARGETS_COUNT EQUAL 1) + IF(TARGETS_COUNT GREATER 1) SET(XARCH "-Xarch_i386 ") - ENDIF(TARGETS_COUNT EQUAL 1) + ENDIF(TARGETS_COUNT GREATER 1) - # Always force -mmacosx-version-min to override environement variable - ADD_PLATFORM_FLAGS("${XARCH}-mmacosx-version-min=${CMAKE_OSX_DEPLOYMENT_TARGET}") + ADD_PLATFORM_FLAGS("${XARCH}-isysroot${CMAKE_IOS_SIMULATOR_SYSROOT}") + ADD_PLATFORM_FLAGS("${XARCH}-mios-simulator-version-min=${IOS_VERSION}") SET(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} ${XARCH}-Wl,-macosx_version_min,${CMAKE_OSX_DEPLOYMENT_TARGET}") ENDIF(CMAKE_IOS_SIMULATOR_SYSROOT AND TARGET_X86) ELSE(IOS) @@ -746,6 +839,46 @@ MACRO(NL_SETUP_BUILD) ENDIF(CLANG) ENDIF(WITH_WARNINGS) + IF(ANDROID) + ADD_PLATFORM_FLAGS("--sysroot=${PLATFORM_ROOT}") + ADD_PLATFORM_FLAGS("-ffunction-sections -funwind-tables") + ADD_PLATFORM_FLAGS("-DANDROID") + ADD_PLATFORM_FLAGS("-Wa,--noexecstack") + + IF(TARGET_ARM) + ADD_PLATFORM_FLAGS("-fpic -fstack-protector") + ADD_PLATFORM_FLAGS("-D__ARM_ARCH_5__ -D__ARM_ARCH_5T__ -D__ARM_ARCH_5E__ -D__ARM_ARCH_5TE__") + + IF(TARGET_ARMV7) + ADD_PLATFORM_FLAGS("-march=armv7-a -mfloat-abi=softfp -mfpu=vfpv3-d16") + SET(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} -march=armv7-a -Wl,--fix-cortex-a8") + ELSEIF(TARGET_ARMV5) + ADD_PLATFORM_FLAGS("-march=armv5te -mtune=xscale -msoft-float") + ENDIF(TARGET_ARMV7) + + SET(TARGET_THUMB ON) + IF(TARGET_THUMB) + ADD_PLATFORM_FLAGS("-mthumb -fno-strict-aliasing -finline-limit=64") + SET(DEBUG_CFLAGS "${DEBUG_CFLAGS} -marm") + ELSE(TARGET_THUMB) + ADD_PLATFORM_FLAGS("-funswitch-loops -finline-limit=300") + SET(DEBUG_CFLAGS "${DEBUG_CFLAGS} -fno-strict-aliasing") + SET(RELEASE_CFLAGS "${RELEASE_CFLAGS} -fstrict-aliasing") + ENDIF(TARGET_THUMB) + ELSEIF(TARGET_X86) + # Optimizations for Intel Atom + ADD_PLATFORM_FLAGS("-march=i686 -mtune=atom -mstackrealign -msse3 -mfpmath=sse -m32 -flto -ffast-math -funroll-loops") + ADD_PLATFORM_FLAGS("-fstack-protector -funswitch-loops -finline-limit=300") + SET(RELEASE_CFLAGS "${RELEASE_CFLAGS} -fstrict-aliasing") + SET(DEBUG_CFLAGS "${DEBUG_CFLAGS} -fno-strict-aliasing") + ELSEIF(TARGET_MIPS) + ADD_PLATFORM_FLAGS("-fpic -finline-functions -fmessage-length=0 -fno-inline-functions-called-once -fgcse-after-reload -frerun-cse-after-loop -frename-registers -fno-strict-aliasing") + SET(RELEASE_CFLAGS "${RELEASE_CFLAGS} -funswitch-loops -finline-limit=300") + ENDIF(TARGET_ARM) + SET(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} -Wl,-z,noexecstack -Wl,-z,relro -Wl,-z,now") + SET(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} -L${PLATFORM_ROOT}/usr/lib") + ENDIF(ANDROID) + IF(APPLE) ADD_PLATFORM_FLAGS("-gdwarf-2") ENDIF(APPLE) @@ -799,7 +932,7 @@ ENDMACRO(NL_SETUP_BUILD_FLAGS) MACRO(NL_MAKE_ABSOLUTE_PREFIX NAME_RELATIVE NAME_ABSOLUTE) IF(IS_ABSOLUTE "${${NAME_RELATIVE}}") SET(${NAME_ABSOLUTE} ${${NAME_RELATIVE}}) - ELSE(IS_ABSOLUTE "${${{NAME_RELATIVE}}") + ELSE(IS_ABSOLUTE "${${NAME_RELATIVE}}") IF(WIN32) SET(${NAME_ABSOLUTE} ${${NAME_RELATIVE}}) ELSE(WIN32) @@ -950,11 +1083,37 @@ MACRO(SETUP_EXTERNAL) SET(VC_DIR $ENV{VC_DIR}) ENDIF(NOT VC_DIR) - IF(MSVC10) - IF(NOT MSVC10_REDIST_DIR) + IF(MSVC11) + IF(NOT MSVC_REDIST_DIR) + # If you have VC++ 2012 Express, put x64/Microsoft.VC110.CRT/*.dll in ${EXTERNAL_PATH}/redist + SET(MSVC_REDIST_DIR "${EXTERNAL_PATH}/redist") + ENDIF(NOT MSVC_REDIST_DIR) + + IF(NOT VC_DIR) + IF(NOT VC_ROOT_DIR) + GET_FILENAME_COMPONENT(VC_ROOT_DIR "[HKEY_CURRENT_USER\\Software\\Microsoft\\VisualStudio\\11.0_Config;InstallDir]" ABSOLUTE) + # VC_ROOT_DIR is set to "registry" when a key is not found + IF(VC_ROOT_DIR MATCHES "registry") + GET_FILENAME_COMPONENT(VC_ROOT_DIR "[HKEY_CURRENT_USER\\Software\\Microsoft\\WDExpress\\11.0_Config\\Setup\\VC;InstallDir]" ABSOLUTE) + IF(VC_ROOT_DIR MATCHES "registry") + SET(VS110COMNTOOLS $ENV{VS110COMNTOOLS}) + IF(VS110COMNTOOLS) + FILE(TO_CMAKE_PATH ${VS110COMNTOOLS} VC_ROOT_DIR) + ENDIF(VS110COMNTOOLS) + IF(NOT VC_ROOT_DIR) + MESSAGE(FATAL_ERROR "Unable to find VC++ 2012 directory!") + ENDIF(NOT VC_ROOT_DIR) + ENDIF(VC_ROOT_DIR MATCHES "registry") + ENDIF(VC_ROOT_DIR MATCHES "registry") + ENDIF(NOT VC_ROOT_DIR) + # convert IDE fullpath to VC++ path + STRING(REGEX REPLACE "Common7/.*" "VC" VC_DIR ${VC_ROOT_DIR}) + ENDIF(NOT VC_DIR) + ELSEIF(MSVC10) + IF(NOT MSVC_REDIST_DIR) # If you have VC++ 2010 Express, put x64/Microsoft.VC100.CRT/*.dll in ${EXTERNAL_PATH}/redist - SET(MSVC10_REDIST_DIR "${EXTERNAL_PATH}/redist") - ENDIF(NOT MSVC10_REDIST_DIR) + SET(MSVC_REDIST_DIR "${EXTERNAL_PATH}/redist") + ENDIF(NOT MSVC_REDIST_DIR) IF(NOT VC_DIR) IF(NOT VC_ROOT_DIR) @@ -976,7 +1135,7 @@ MACRO(SETUP_EXTERNAL) # convert IDE fullpath to VC++ path STRING(REGEX REPLACE "Common7/.*" "VC" VC_DIR ${VC_ROOT_DIR}) ENDIF(NOT VC_DIR) - ELSE(MSVC10) + ELSE(MSVC11) IF(NOT VC_DIR) IF(${CMAKE_MAKE_PROGRAM} MATCHES "Common7") # convert IDE fullpath to VC++ path @@ -986,7 +1145,7 @@ MACRO(SETUP_EXTERNAL) STRING(REGEX REPLACE "VC/bin/.+" "VC" VC_DIR ${CMAKE_CXX_COMPILER}) ENDIF(${CMAKE_MAKE_PROGRAM} MATCHES "Common7") ENDIF(NOT VC_DIR) - ENDIF(MSVC10) + ENDIF(MSVC11) ELSE(WIN32) IF(APPLE) IF(WITH_STATIC_EXTERNAL) @@ -1011,7 +1170,7 @@ MACRO(SETUP_EXTERNAL) FIND_PACKAGE(WindowsSDK REQUIRED) # use VC++ and Windows SDK include paths - INCLUDE_DIRECTORIES(${VC_INCLUDE_DIR} ${WINSDK_INCLUDE_DIR}) + INCLUDE_DIRECTORIES(${VC_INCLUDE_DIR} ${WINSDK_INCLUDE_DIRS}) ENDIF(MSVC) ENDIF(WITH_STLPORT) ENDMACRO(SETUP_EXTERNAL) diff --git a/code/nel/include/nel/georges/header.h b/code/nel/include/nel/georges/header.h index 769cc0568..3733f0707 100644 --- a/code/nel/include/nel/georges/header.h +++ b/code/nel/include/nel/georges/header.h @@ -19,6 +19,9 @@ #include "nel/misc/types_nl.h" +// Include from libxml2 +#include + namespace NLGEORGES { diff --git a/code/nel/include/nel/misc/big_file.h b/code/nel/include/nel/misc/big_file.h index 3043295a2..4c11b01b0 100644 --- a/code/nel/include/nel/misc/big_file.h +++ b/code/nel/include/nel/misc/big_file.h @@ -19,6 +19,7 @@ #include "types_nl.h" #include "tds.h" +#include "singleton.h" namespace NLMISC { diff --git a/code/nel/include/nel/misc/contiguous_block_allocator.h b/code/nel/include/nel/misc/contiguous_block_allocator.h index 2cdeeade9..7a15d296d 100644 --- a/code/nel/include/nel/misc/contiguous_block_allocator.h +++ b/code/nel/include/nel/misc/contiguous_block_allocator.h @@ -17,6 +17,7 @@ #ifndef NL_CONTIGUOUS_BLOCK_ALLOCATOR_H #define NL_CONTIGUOUS_BLOCK_ALLOCATOR_H +#include "types_nl.h" namespace NLMISC { diff --git a/code/nel/include/nel/misc/debug.h b/code/nel/include/nel/misc/debug.h index dcd9fe68d..8d469b133 100644 --- a/code/nel/include/nel/misc/debug.h +++ b/code/nel/include/nel/misc/debug.h @@ -17,14 +17,14 @@ #ifndef NL_DEBUG_H #define NL_DEBUG_H -#include - #include "common.h" #include "log.h" #include "mutex.h" #include "mem_displayer.h" #include "displayer.h" #include "app_context.h" + +#include #include namespace NLMISC @@ -169,7 +169,7 @@ void setCrashAlreadyReported(bool state); *\endcode */ #ifdef NL_NO_DEBUG -# if defined(NL_COMP_VC71) || defined(NL_COMP_VC8) || defined(NL_COMP_VC9) || defined(NL_COMP_VC10) +# if defined(NL_COMP_VC) && NL_COMP_VC_VERSION >= 71 # define nldebug __noop # else # define nldebug 0&& @@ -184,7 +184,7 @@ void setCrashAlreadyReported(bool state); * Same as nldebug but it will be display in debug and in release mode. */ #ifdef NL_NO_DEBUG -# if defined(NL_COMP_VC71) || defined(NL_COMP_VC8) || defined(NL_COMP_VC9) || defined(NL_COMP_VC10) +# if defined(NL_COMP_VC) && NL_COMP_VC_VERSION >= 71 # define nlinfo __noop # else # define nlinfo 0&& @@ -212,7 +212,7 @@ void setCrashAlreadyReported(bool state); */ #ifdef NL_NO_DEBUG -# if defined(NL_COMP_VC71) || defined(NL_COMP_VC8) || defined(NL_COMP_VC9) || defined(NL_COMP_VC10) +# if defined(NL_COMP_VC) && NL_COMP_VC_VERSION >= 71 # define nlwarning __noop # else # define nlwarning 0&& diff --git a/code/nel/include/nel/misc/file.h b/code/nel/include/nel/misc/file.h index 51d9d6cbc..17154e6be 100644 --- a/code/nel/include/nel/misc/file.h +++ b/code/nel/include/nel/misc/file.h @@ -17,6 +17,7 @@ #ifndef NL_FILE_H #define NL_FILE_H +#include "types_nl.h" #include "stream.h" diff --git a/code/nel/include/nel/misc/fixed_size_allocator.h b/code/nel/include/nel/misc/fixed_size_allocator.h index 02e4573a2..9eb1d8a10 100644 --- a/code/nel/include/nel/misc/fixed_size_allocator.h +++ b/code/nel/include/nel/misc/fixed_size_allocator.h @@ -17,6 +17,7 @@ #ifndef NL_FIXED_SIZE_ALLOCATOR_H #define NL_FIXED_SIZE_ALLOCATOR_H +#include "types_nl.h" namespace NLMISC { diff --git a/code/nel/include/nel/misc/grid_traversal.h b/code/nel/include/nel/misc/grid_traversal.h index 2e3f76a1e..893b3978a 100644 --- a/code/nel/include/nel/misc/grid_traversal.h +++ b/code/nel/include/nel/misc/grid_traversal.h @@ -17,6 +17,8 @@ #ifndef _GRID_TRAVERSAL_H #define _GRID_TRAVERSAL_H +#include "types_nl.h" + namespace NLMISC { diff --git a/code/nel/include/nel/misc/input_device_manager.h b/code/nel/include/nel/misc/input_device_manager.h index bb5e01e87..a23437696 100644 --- a/code/nel/include/nel/misc/input_device_manager.h +++ b/code/nel/include/nel/misc/input_device_manager.h @@ -19,7 +19,7 @@ #include "types_nl.h" #include "game_device.h" - +#include "common.h" namespace NLMISC { diff --git a/code/nel/include/nel/misc/inter_window_msg_queue.h b/code/nel/include/nel/misc/inter_window_msg_queue.h index 90fb720b4..f65767bce 100644 --- a/code/nel/include/nel/misc/inter_window_msg_queue.h +++ b/code/nel/include/nel/misc/inter_window_msg_queue.h @@ -17,6 +17,7 @@ #ifndef RY_INTER_WINDOW_MSG_QUEUE_H #define RY_INTER_WINDOW_MSG_QUEUE_H +#include "types_nl.h" #ifdef NL_OS_WINDOWS diff --git a/code/nel/include/nel/misc/mutex.h b/code/nel/include/nel/misc/mutex.h index 7659d05e6..adbc7e7e5 100644 --- a/code/nel/include/nel/misc/mutex.h +++ b/code/nel/include/nel/misc/mutex.h @@ -586,7 +586,7 @@ extern uint32 NbMutexes; /** - * This class ensure that the Value is accessed by only one thread. First you have to create a CSynchronized class with you type. + * This class ensure that the Value is accessed by only one thread. First you have to create a CSynchronized class with your type. * Then, if a thread want to modify or do anything on it, you create a CAccessor in a \b sub \b scope. You can modify the value * of the CUnfairSynchronized using the value() function \b until the end of the scope. So you have to put the smaller scope as you can. * diff --git a/code/nel/include/nel/misc/object_arena_allocator.h b/code/nel/include/nel/misc/object_arena_allocator.h index 6370b9834..6d318aca8 100644 --- a/code/nel/include/nel/misc/object_arena_allocator.h +++ b/code/nel/include/nel/misc/object_arena_allocator.h @@ -17,6 +17,7 @@ #ifndef NL_OBJECT_ARENA_ALLOCATOR_H #define NL_OBJECT_ARENA_ALLOCATOR_H +#include "types_nl.h" #include "singleton.h" namespace NLMISC diff --git a/code/nel/include/nel/misc/p_thread.h b/code/nel/include/nel/misc/p_thread.h index 0ef221760..4f0a9aa63 100644 --- a/code/nel/include/nel/misc/p_thread.h +++ b/code/nel/include/nel/misc/p_thread.h @@ -17,9 +17,10 @@ #ifndef NL_P_THREAD_H #define NL_P_THREAD_H +#include "types_nl.h" + #ifdef NL_OS_UNIX -#include "types_nl.h" #include "thread.h" #include diff --git a/code/nel/include/nel/misc/path.h b/code/nel/include/nel/misc/path.h index 2ac69c4e7..73652a581 100644 --- a/code/nel/include/nel/misc/path.h +++ b/code/nel/include/nel/misc/path.h @@ -19,14 +19,13 @@ #include "types_nl.h" #include "time_nl.h" +#include "common.h" +#include "string_mapper.h" #include #include #include -#include "common.h" -#include "string_mapper.h" - namespace NLMISC { /// Exception throw when a find is not found in a lookup() call diff --git a/code/nel/include/nel/misc/polygon.h b/code/nel/include/nel/misc/polygon.h index 9be40c189..a0183d20d 100644 --- a/code/nel/include/nel/misc/polygon.h +++ b/code/nel/include/nel/misc/polygon.h @@ -21,6 +21,7 @@ #include "matrix.h" #include "stream.h" #include "vector_2f.h" + #include diff --git a/code/nel/include/nel/misc/pool_memory.h b/code/nel/include/nel/misc/pool_memory.h index 05103a569..def4125dc 100644 --- a/code/nel/include/nel/misc/pool_memory.h +++ b/code/nel/include/nel/misc/pool_memory.h @@ -18,6 +18,7 @@ #define NL_POOL_MEMORY_H #include "types_nl.h" + #include #include diff --git a/code/nel/include/nel/misc/quat.h b/code/nel/include/nel/misc/quat.h index 73e6a43d3..3e8a70d5c 100644 --- a/code/nel/include/nel/misc/quat.h +++ b/code/nel/include/nel/misc/quat.h @@ -20,6 +20,7 @@ #include "types_nl.h" #include "vector.h" #include "stream.h" + #include namespace NLMISC diff --git a/code/nel/include/nel/misc/resource_ptr_inline.h b/code/nel/include/nel/misc/resource_ptr_inline.h index fde8da963..b287e9b18 100644 --- a/code/nel/include/nel/misc/resource_ptr_inline.h +++ b/code/nel/include/nel/misc/resource_ptr_inline.h @@ -18,6 +18,8 @@ #ifndef NL_RESOURCE_PTR_INLINE_H #define NL_RESOURCE_PTR_INLINE_H +#include "types_nl.h" + namespace NLMISC { diff --git a/code/nel/include/nel/misc/rgba.h b/code/nel/include/nel/misc/rgba.h index 944b453d8..7eeadaf99 100644 --- a/code/nel/include/nel/misc/rgba.h +++ b/code/nel/include/nel/misc/rgba.h @@ -17,11 +17,11 @@ #ifndef NL_RGBA_H #define NL_RGBA_H -#include - #include "types_nl.h" #include "common.h" +#include + namespace NLMISC { diff --git a/code/nel/include/nel/misc/sha1.h b/code/nel/include/nel/misc/sha1.h index 6fab640d3..d4c630c22 100644 --- a/code/nel/include/nel/misc/sha1.h +++ b/code/nel/include/nel/misc/sha1.h @@ -17,11 +17,12 @@ #ifndef NL_SHA1_H #define NL_SHA1_H -#include - +#include "types_nl.h" #include "common.h" #include "stream.h" +#include + struct CHashKey { CHashKey () { HashKeyString.resize(20); } diff --git a/code/nel/include/nel/misc/smart_ptr.h b/code/nel/include/nel/misc/smart_ptr.h index f345f7f6c..2bfb57cc3 100644 --- a/code/nel/include/nel/misc/smart_ptr.h +++ b/code/nel/include/nel/misc/smart_ptr.h @@ -352,7 +352,7 @@ public: } }; -#if defined(NL_COMP_VC8) || defined(NL_COMP_VC9) || defined(NL_COMP_VC10) +#if defined(NL_COMP_VC) && NL_COMP_VC_VERSION >= 80 // This operator only purpose is to compare with NULL value template diff --git a/code/nel/include/nel/misc/smart_ptr_inline.h b/code/nel/include/nel/misc/smart_ptr_inline.h index 6ea1f9bd4..f6665825a 100644 --- a/code/nel/include/nel/misc/smart_ptr_inline.h +++ b/code/nel/include/nel/misc/smart_ptr_inline.h @@ -18,6 +18,8 @@ #ifndef NL_SMARTPTR_INLINE_H #define NL_SMARTPTR_INLINE_H +#include "types_nl.h" + namespace NLMISC { diff --git a/code/nel/include/nel/misc/stl_block_list.h b/code/nel/include/nel/misc/stl_block_list.h index f901e516c..ccd207187 100644 --- a/code/nel/include/nel/misc/stl_block_list.h +++ b/code/nel/include/nel/misc/stl_block_list.h @@ -19,6 +19,7 @@ #include "types_nl.h" #include "stl_block_allocator.h" + #include diff --git a/code/nel/include/nel/misc/stop_watch.h b/code/nel/include/nel/misc/stop_watch.h index a3a56d51d..b519f4c82 100644 --- a/code/nel/include/nel/misc/stop_watch.h +++ b/code/nel/include/nel/misc/stop_watch.h @@ -19,6 +19,7 @@ #include "types_nl.h" #include "time_nl.h" + #include diff --git a/code/nel/include/nel/misc/stream.h b/code/nel/include/nel/misc/stream.h index b198bc890..ad0e8ddd4 100644 --- a/code/nel/include/nel/misc/stream.h +++ b/code/nel/include/nel/misc/stream.h @@ -21,6 +21,7 @@ #include "ucstring.h" #include "class_registry.h" #include "common.h" + #include #include #include diff --git a/code/nel/include/nel/misc/stream_inline.h b/code/nel/include/nel/misc/stream_inline.h index b36d1eae7..f0b1e3603 100644 --- a/code/nel/include/nel/misc/stream_inline.h +++ b/code/nel/include/nel/misc/stream_inline.h @@ -17,10 +17,11 @@ #ifndef NL_STREAM_INLINE_H #define NL_STREAM_INLINE_H -#include - +#include "types_nl.h" #include "debug.h" +#include + namespace NLMISC { diff --git a/code/nel/include/nel/misc/string_conversion.h b/code/nel/include/nel/misc/string_conversion.h index 0b1aa5487..2c19e0a80 100644 --- a/code/nel/include/nel/misc/string_conversion.h +++ b/code/nel/include/nel/misc/string_conversion.h @@ -19,6 +19,7 @@ #include "types_nl.h" #include "common.h" + #include namespace NLMISC diff --git a/code/nel/include/nel/misc/string_id_array.h b/code/nel/include/nel/misc/string_id_array.h index c1a1739e4..9ca01695e 100644 --- a/code/nel/include/nel/misc/string_id_array.h +++ b/code/nel/include/nel/misc/string_id_array.h @@ -18,6 +18,7 @@ #define NL_STRING_ID_ARRAY_H #include "types_nl.h" +#include "debug.h" #include #include @@ -25,8 +26,6 @@ #include #include -#include "debug.h" - namespace NLMISC { diff --git a/code/nel/include/nel/misc/string_mapper.h b/code/nel/include/nel/misc/string_mapper.h index c3ae832c4..36a73ed4d 100644 --- a/code/nel/include/nel/misc/string_mapper.h +++ b/code/nel/include/nel/misc/string_mapper.h @@ -18,13 +18,12 @@ #define STRING_MAPPER_H #include "types_nl.h" +#include "stream.h" +#include "mutex.h" #include #include -#include "stream.h" -#include "mutex.h" - namespace NLMISC { diff --git a/code/nel/include/nel/misc/win32_util.h b/code/nel/include/nel/misc/win32_util.h index 67fe69883..d040458c1 100644 --- a/code/nel/include/nel/misc/win32_util.h +++ b/code/nel/include/nel/misc/win32_util.h @@ -17,6 +17,7 @@ #ifndef NL_WIN32_UTIL_H #define NL_WIN32_UTIL_H +#include "types_nl.h" #ifdef NL_OS_WINDOWS diff --git a/code/nel/src/3d/driver/direct3d/driver_direct3d_shader.cpp b/code/nel/src/3d/driver/direct3d/driver_direct3d_shader.cpp index 419027577..b9b757de1 100644 --- a/code/nel/src/3d/driver/direct3d/driver_direct3d_shader.cpp +++ b/code/nel/src/3d/driver/direct3d/driver_direct3d_shader.cpp @@ -355,8 +355,8 @@ bool CDriverD3D::activeShader(CShader *shd) // Assemble the shader LPD3DXBUFFER pErrorMsgs; - if (D3DXCreateEffect(_DeviceInterface, shd->getText(), (UINT)strlen(shd->getText())+1, NULL, NULL, 0, NULL, &(shaderInfo->Effect), &pErrorMsgs) - == D3D_OK) + HRESULT hr = D3DXCreateEffect(_DeviceInterface, shd->getText(), (UINT)strlen(shd->getText())+1, NULL, NULL, 0, NULL, &(shaderInfo->Effect), &pErrorMsgs); + if (hr == D3D_OK) { // Get the texture handle uint i; @@ -374,7 +374,7 @@ bool CDriverD3D::activeShader(CShader *shd) } else { - nlwarning ("Can't create shader '%s':", shd->getName()); + nlwarning ("Can't create shader '%s' (0x%x):", shd->getName(), hr); if (pErrorMsgs) nlwarning ((const char*)pErrorMsgs->GetBufferPointer()); shd->_ShaderChanged = false; diff --git a/code/nel/src/3d/driver/opengl/CMakeLists.txt b/code/nel/src/3d/driver/opengl/CMakeLists.txt index 8fa99d488..aea202e8b 100644 --- a/code/nel/src/3d/driver/opengl/CMakeLists.txt +++ b/code/nel/src/3d/driver/opengl/CMakeLists.txt @@ -27,7 +27,7 @@ ENDIF(WIN32) NL_TARGET_DRIVER(${NLDRV_OGL_LIB} ${SRC}) -INCLUDE_DIRECTORIES(${OPENGL_INCLUDE_DIR}) +INCLUDE_DIRECTORIES(${OPENGL_INCLUDE_DIR} ${CMAKE_CURRENT_SOURCE_DIR}) TARGET_LINK_LIBRARIES(${NLDRV_OGL_LIB} nel3d nelmisc ${OPENGL_gl_LIBRARY}) NL_DEFAULT_PROPS(${NLDRV_OGL_LIB} "NeL, Driver, Video: OpenGL") diff --git a/code/nel/src/3d/driver/opengl/EGL/eglext.h b/code/nel/src/3d/driver/opengl/EGL/eglext.h index 0d318b258..a28f5b88e 100644 --- a/code/nel/src/3d/driver/opengl/EGL/eglext.h +++ b/code/nel/src/3d/driver/opengl/EGL/eglext.h @@ -34,8 +34,8 @@ extern "C" { /* Header file version number */ /* Current version at http://www.khronos.org/registry/egl/ */ -/* $Revision: 17614 $ on $Date: 2012-04-26 06:56:02 -0700 (Thu, 26 Apr 2012) $ */ -#define EGL_EGLEXT_VERSION 12 +/* $Revision: 19332 $ on $Date: 2012-09-28 17:56:20 -0700 (Fri, 28 Sep 2012) $ */ +#define EGL_EGLEXT_VERSION 14 #ifndef EGL_KHR_config_attribs #define EGL_KHR_config_attribs 1 @@ -293,6 +293,25 @@ EGLAPI EGLBoolean EGLAPIENTRY eglPostSubBufferNV (EGLDisplay dpy, EGLSurface sur typedef EGLBoolean (EGLAPIENTRYP PFNEGLPOSTSUBBUFFERNVPROC) (EGLDisplay dpy, EGLSurface surface, EGLint x, EGLint y, EGLint width, EGLint height); #endif +#ifndef EGL_ANDROID_image_native_buffer +#define EGL_ANDROID_image_native_buffer 1 +struct ANativeWindowBuffer; +#define EGL_NATIVE_BUFFER_ANDROID 0x3140 /* eglCreateImageKHR target */ +#endif + +#ifndef EGL_ANDROID_swap_rectangle +#define EGL_ANDROID_swap_rectangle 1 +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLBoolean EGLAPIENTRY eglSetSwapRectangleANDROID (EGLDisplay dpy, EGLSurface draw, EGLint left, EGLint top, EGLint width, EGLint height); +#endif /* EGL_EGLEXT_PROTOTYPES */ +typedef EGLBoolean (EGLAPIENTRYP PFNEGLSETSWAPRECTANGLEANDROIDPROC) (EGLDisplay dpy, EGLSurface draw, EGLint left, EGLint top, EGLint width, EGLint height); +#endif + +#ifndef EGL_ANDROID_recordable +#define EGL_ANDROID_recordable 1 +#define EGL_RECORDABLE_ANDROID 0x3142 /* EGLConfig attribute */ +#endif + #ifndef EGL_ANGLE_query_surface_pointer #define EGL_ANGLE_query_surface_pointer 1 #ifdef EGL_EGLEXT_PROTOTYPES @@ -333,38 +352,38 @@ typedef EGLuint64NV (EGLAPIENTRYP PFNEGLGETSYSTEMTIMENVPROC) (void); #define EGL_KHR_stream 1 typedef void* EGLStreamKHR; typedef khronos_uint64_t EGLuint64KHR; -#define EGL_NO_STREAM_KHR ((EGLStreamKHR)0) -#define EGL_CONSUMER_LATENCY_USEC_KHR 0x3210 -#define EGL_PRODUCER_FRAME_KHR 0x3212 -#define EGL_CONSUMER_FRAME_KHR 0x3213 -#define EGL_STREAM_STATE_KHR 0x3214 -#define EGL_STREAM_STATE_CREATED_KHR 0x3215 -#define EGL_STREAM_STATE_CONNECTING_KHR 0x3216 -#define EGL_STREAM_STATE_EMPTY_KHR 0x3217 +#define EGL_NO_STREAM_KHR ((EGLStreamKHR)0) +#define EGL_CONSUMER_LATENCY_USEC_KHR 0x3210 +#define EGL_PRODUCER_FRAME_KHR 0x3212 +#define EGL_CONSUMER_FRAME_KHR 0x3213 +#define EGL_STREAM_STATE_KHR 0x3214 +#define EGL_STREAM_STATE_CREATED_KHR 0x3215 +#define EGL_STREAM_STATE_CONNECTING_KHR 0x3216 +#define EGL_STREAM_STATE_EMPTY_KHR 0x3217 #define EGL_STREAM_STATE_NEW_FRAME_AVAILABLE_KHR 0x3218 #define EGL_STREAM_STATE_OLD_FRAME_AVAILABLE_KHR 0x3219 -#define EGL_STREAM_STATE_DISCONNECTED_KHR 0x321A -#define EGL_BAD_STREAM_KHR 0x321B -#define EGL_BAD_STATE_KHR 0x321C +#define EGL_STREAM_STATE_DISCONNECTED_KHR 0x321A +#define EGL_BAD_STREAM_KHR 0x321B +#define EGL_BAD_STATE_KHR 0x321C #ifdef EGL_EGLEXT_PROTOTYPES EGLAPI EGLStreamKHR EGLAPIENTRY eglCreateStreamKHR(EGLDisplay dpy, const EGLint *attrib_list); EGLAPI EGLBoolean EGLAPIENTRY eglDestroyStreamKHR(EGLDisplay dpy, EGLStreamKHR stream); EGLAPI EGLBoolean EGLAPIENTRY eglStreamAttribKHR(EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLint value); EGLAPI EGLBoolean EGLAPIENTRY eglQueryStreamKHR(EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLint *value); -EGLAPI EGLBoolean EGLAPIENTRY eglQueryStream64KHR(EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLuint64KHR *value); +EGLAPI EGLBoolean EGLAPIENTRY eglQueryStreamu64KHR(EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLuint64KHR *value); #endif /* EGL_EGLEXT_PROTOTYPES */ typedef EGLStreamKHR (EGLAPIENTRYP PFNEGLCREATESTREAMKHRPROC)(EGLDisplay dpy, const EGLint *attrib_list); typedef EGLBoolean (EGLAPIENTRYP PFNEGLDESTROYSTREAMKHRPROC)(EGLDisplay dpy, EGLStreamKHR stream); typedef EGLBoolean (EGLAPIENTRYP PFNEGLSTREAMATTRIBKHRPROC)(EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLint value); typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYSTREAMKHRPROC)(EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLint *value); -typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYSTREAM64KHRPROC)(EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLuint64KHR *value); +typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYSTREAMU64KHRPROC)(EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLuint64KHR *value); #endif #endif #ifdef EGL_KHR_stream /* Requires KHR_stream extension */ #ifndef EGL_KHR_stream_consumer_gltexture #define EGL_KHR_stream_consumer_gltexture 1 -#define EGL_CONSUMER_ACQUIRE_TIMEOUT_USEC_KHR 0x321E +#define EGL_CONSUMER_ACQUIRE_TIMEOUT_USEC_KHR 0x321E #ifdef EGL_EGLEXT_PROTOTYPES EGLAPI EGLBoolean EGLAPIENTRY eglStreamConsumerGLTextureExternalKHR(EGLDisplay dpy, EGLStreamKHR stream); EGLAPI EGLBoolean EGLAPIENTRY eglStreamConsumerAcquireKHR(EGLDisplay dpy, EGLStreamKHR stream); @@ -379,7 +398,7 @@ typedef EGLBoolean (EGLAPIENTRYP PFNEGLSTREAMCONSUMERRELEASEKHRPROC)(EGLDisplay #ifdef EGL_KHR_stream /* Requires KHR_stream extension */ #ifndef EGL_KHR_stream_producer_eglsurface #define EGL_KHR_stream_producer_eglsurface 1 -#define EGL_STREAM_BIT_KHR 0x0800 +#define EGL_STREAM_BIT_KHR 0x0800 #ifdef EGL_EGLEXT_PROTOTYPES EGLAPI EGLSurface EGLAPIENTRY eglCreateStreamProducerSurfaceKHR(EGLDisplay dpy, EGLConfig config, EGLStreamKHR stream, const EGLint *attrib_list); #endif /* EGL_EGLEXT_PROTOTYPES */ @@ -397,10 +416,10 @@ typedef EGLSurface (EGLAPIENTRYP PFNEGLCREATESTREAMPRODUCERSURFACEKHRPROC)(EGLDi #ifndef EGL_KHR_stream_fifo #define EGL_KHR_stream_fifo 1 /* reuse EGLTimeKHR */ -#define EGL_STREAM_FIFO_LENGTH_KHR 0x31FC -#define EGL_STREAM_TIME_NOW_KHR 0x31FD -#define EGL_STREAM_TIME_CONSUMER_KHR 0x31FE -#define EGL_STREAM_TIME_PRODUCER_KHR 0x31FF +#define EGL_STREAM_FIFO_LENGTH_KHR 0x31FC +#define EGL_STREAM_TIME_NOW_KHR 0x31FD +#define EGL_STREAM_TIME_CONSUMER_KHR 0x31FE +#define EGL_STREAM_TIME_PRODUCER_KHR 0x31FF #ifdef EGL_EGLEXT_PROTOTYPES EGLAPI EGLBoolean EGLAPIENTRY eglQueryStreamTimeKHR(EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLTimeKHR *value); #endif /* EGL_EGLEXT_PROTOTYPES */ @@ -421,6 +440,47 @@ typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYSTREAMTIMEKHRPROC)(EGLDisplay dpy, E /* reuse EGL_D3D_TEXTURE_2D_SHARE_HANDLE_ANGLE */ #endif +#ifndef EGL_KHR_create_context +#define EGL_KHR_create_context 1 +#define EGL_CONTEXT_MAJOR_VERSION_KHR EGL_CONTEXT_CLIENT_VERSION +#define EGL_CONTEXT_MINOR_VERSION_KHR 0x30FB +#define EGL_CONTEXT_FLAGS_KHR 0x30FC +#define EGL_CONTEXT_OPENGL_PROFILE_MASK_KHR 0x30FD +#define EGL_CONTEXT_OPENGL_RESET_NOTIFICATION_STRATEGY_KHR 0x31BD +#define EGL_NO_RESET_NOTIFICATION_KHR 0x31BE +#define EGL_LOSE_CONTEXT_ON_RESET_KHR 0x31BF +#define EGL_CONTEXT_OPENGL_DEBUG_BIT_KHR 0x00000001 +#define EGL_CONTEXT_OPENGL_FORWARD_COMPATIBLE_BIT_KHR 0x00000002 +#define EGL_CONTEXT_OPENGL_ROBUST_ACCESS_BIT_KHR 0x00000004 +#define EGL_CONTEXT_OPENGL_CORE_PROFILE_BIT_KHR 0x00000001 +#define EGL_CONTEXT_OPENGL_COMPATIBILITY_PROFILE_BIT_KHR 0x00000002 +#define EGL_OPENGL_ES3_BIT_KHR 0x00000040 +#endif + +#ifndef EGL_KHR_surfaceless_context +#define EGL_KHR_surfaceless_context 1 +/* No tokens/entry points, just relaxes an error condition */ +#endif + +#ifdef EGL_KHR_stream /* Requires KHR_stream extension */ +#ifndef EGL_KHR_stream_cross_process_fd +#define EGL_KHR_stream_cross_process_fd 1 +typedef int EGLNativeFileDescriptorKHR; +#define EGL_NO_FILE_DESCRIPTOR_KHR ((EGLNativeFileDescriptorKHR)(-1)) +#ifdef EGL_EGLEXT_PROTOTYPES +EGLAPI EGLNativeFileDescriptorKHR EGLAPIENTRY eglGetStreamFileDescriptorKHR(EGLDisplay dpy, EGLStreamKHR stream); +EGLAPI EGLStreamKHR EGLAPIENTRY eglCreateStreamFromFileDescriptorKHR(EGLDisplay dpy, EGLNativeFileDescriptorKHR file_descriptor); +#endif /* EGL_EGLEXT_PROTOTYPES */ +typedef EGLNativeFileDescriptorKHR (EGLAPIENTRYP PFNEGLGETSTREAMFILEDESCRIPTORKHRPROC)(EGLDisplay dpy, EGLStreamKHR stream); +typedef EGLStreamKHR (EGLAPIENTRYP PFNEGLCREATESTREAMFROMFILEDESCRIPTORKHRPROC)(EGLDisplay dpy, EGLNativeFileDescriptorKHR file_descriptor); +#endif +#endif + +#ifndef EGL_EXT_multiview_window +#define EGL_EXT_multiview_window 1 +#define EGL_MULTIVIEW_VIEW_COUNT_EXT 0x3134 +#endif + #ifdef __cplusplus } #endif diff --git a/code/nel/src/3d/driver/opengl/GL/glext.h b/code/nel/src/3d/driver/opengl/GL/glext.h index bd7b9b863..44ab7c62e 100644 --- a/code/nel/src/3d/driver/opengl/GL/glext.h +++ b/code/nel/src/3d/driver/opengl/GL/glext.h @@ -29,9 +29,9 @@ extern "C" { */ /* Header file version number, required by OpenGL ABI for Linux */ -/* glext.h last updated $Date: 2012-04-26 00:59:42 -0700 (Thu, 26 Apr 2012) $ */ +/* glext.h last updated $Date: 2012-09-19 19:02:24 -0700 (Wed, 19 Sep 2012) $ */ /* Current version at http://www.opengl.org/registry/ */ -#define GL_GLEXT_VERSION 81 +#define GL_GLEXT_VERSION 85 /* Function declaration macros - to move into glplatform.h */ #if defined(_WIN32) && !defined(APIENTRY) && !defined(__CYGWIN__) && !defined(__SCITECH_SNAP__) @@ -88,9 +88,6 @@ extern "C" { #define GL_SMOOTH_LINE_WIDTH_RANGE 0x0B22 #define GL_SMOOTH_LINE_WIDTH_GRANULARITY 0x0B23 #define GL_ALIASED_LINE_WIDTH_RANGE 0x846E -#endif - -#ifndef GL_VERSION_1_2_DEPRECATED #define GL_RESCALE_NORMAL 0x803A #define GL_LIGHT_MODEL_COLOR_CONTROL 0x81F8 #define GL_SINGLE_COLOR 0x81F9 @@ -110,9 +107,6 @@ extern "C" { #define GL_BLEND_EQUATION 0x8009 #define GL_FUNC_SUBTRACT 0x800A #define GL_FUNC_REVERSE_SUBTRACT 0x800B -#endif - -#ifndef GL_ARB_imaging_DEPRECATED #define GL_CONVOLUTION_1D 0x8010 #define GL_CONVOLUTION_2D 0x8011 #define GL_SEPARABLE_2D 0x8012 @@ -239,9 +233,6 @@ extern "C" { #define GL_NUM_COMPRESSED_TEXTURE_FORMATS 0x86A2 #define GL_COMPRESSED_TEXTURE_FORMATS 0x86A3 #define GL_CLAMP_TO_BORDER 0x812D -#endif - -#ifndef GL_VERSION_1_3_DEPRECATED #define GL_CLIENT_ACTIVE_TEXTURE 0x84E1 #define GL_MAX_TEXTURE_UNITS 0x84E2 #define GL_TRANSPOSE_MODELVIEW_MATRIX 0x84E3 @@ -298,9 +289,6 @@ extern "C" { #define GL_TEXTURE_DEPTH_SIZE 0x884A #define GL_TEXTURE_COMPARE_MODE 0x884C #define GL_TEXTURE_COMPARE_FUNC 0x884D -#endif - -#ifndef GL_VERSION_1_4_DEPRECATED #define GL_POINT_SIZE_MIN 0x8126 #define GL_POINT_SIZE_MAX 0x8127 #define GL_POINT_DISTANCE_ATTENUATION 0x8129 @@ -354,9 +342,7 @@ extern "C" { #define GL_DYNAMIC_READ 0x88E9 #define GL_DYNAMIC_COPY 0x88EA #define GL_SAMPLES_PASSED 0x8914 -#endif - -#ifndef GL_VERSION_1_5_DEPRECATED +#define GL_SRC1_ALPHA 0x8589 #define GL_VERTEX_ARRAY_BUFFER_BINDING 0x8896 #define GL_NORMAL_ARRAY_BUFFER_BINDING 0x8897 #define GL_COLOR_ARRAY_BUFFER_BINDING 0x8898 @@ -378,7 +364,6 @@ extern "C" { #define GL_SRC1_RGB 0x8581 #define GL_SRC2_RGB 0x8582 #define GL_SRC0_ALPHA 0x8588 -#define GL_SRC1_ALPHA 0x8589 #define GL_SRC2_ALPHA 0x858A #endif @@ -463,9 +448,6 @@ extern "C" { #define GL_STENCIL_BACK_REF 0x8CA3 #define GL_STENCIL_BACK_VALUE_MASK 0x8CA4 #define GL_STENCIL_BACK_WRITEMASK 0x8CA5 -#endif - -#ifndef GL_VERSION_2_0_DEPRECATED #define GL_VERTEX_PROGRAM_TWO_SIDE 0x8643 #define GL_POINT_SPRITE 0x8861 #define GL_COORD_REPLACE 0x8862 @@ -489,9 +471,6 @@ extern "C" { #define GL_SRGB8_ALPHA8 0x8C43 #define GL_COMPRESSED_SRGB 0x8C48 #define GL_COMPRESSED_SRGB_ALPHA 0x8C49 -#endif - -#ifndef GL_VERSION_2_1_DEPRECATED #define GL_CURRENT_RASTER_SECONDARY_COLOR 0x845F #define GL_SLUMINANCE_ALPHA 0x8C44 #define GL_SLUMINANCE8_ALPHA8 0x8C45 @@ -726,9 +705,6 @@ extern "C" { /* reuse GL_RG32UI */ /* Reuse tokens from ARB_vertex_array_object */ /* reuse GL_VERTEX_ARRAY_BINDING */ -#endif - -#ifndef GL_VERSION_3_0_DEPRECATED #define GL_CLAMP_VERTEX_COLOR 0x891A #define GL_CLAMP_FRAGMENT_COLOR 0x891B #define GL_ALPHA_INTEGER 0x8D97 @@ -749,7 +725,6 @@ extern "C" { #define GL_MAX_TEXTURE_BUFFER_SIZE 0x8C2B #define GL_TEXTURE_BINDING_BUFFER 0x8C2C #define GL_TEXTURE_BUFFER_DATA_STORE_BINDING 0x8C2D -#define GL_TEXTURE_BUFFER_FORMAT 0x8C2E #define GL_TEXTURE_RECTANGLE 0x84F5 #define GL_TEXTURE_BINDING_RECTANGLE 0x84F6 #define GL_PROXY_TEXTURE_RECTANGLE 0x84F7 @@ -1015,6 +990,7 @@ extern "C" { /* reuse GL_MEDIUM_INT */ /* reuse GL_HIGH_INT */ /* reuse GL_SHADER_COMPILER */ +/* reuse GL_SHADER_BINARY_FORMATS */ /* reuse GL_NUM_SHADER_BINARY_FORMATS */ /* reuse GL_MAX_VERTEX_UNIFORM_VECTORS */ /* reuse GL_MAX_VARYING_VECTORS */ @@ -1164,6 +1140,290 @@ extern "C" { /* reuse GL_TEXTURE_IMMUTABLE_FORMAT */ #endif +#ifndef GL_VERSION_4_3 +#define GL_NUM_SHADING_LANGUAGE_VERSIONS 0x82E9 +#define GL_VERTEX_ATTRIB_ARRAY_LONG 0x874E +/* Reuse tokens from ARB_arrays_of_arrays (none, GLSL only) */ +/* Reuse tokens from ARB_fragment_layer_viewport (none, GLSL only) */ +/* Reuse tokens from ARB_shader_image_size (none, GLSL only) */ +/* Reuse tokens from ARB_ES3_compatibility */ +/* reuse GL_COMPRESSED_RGB8_ETC2 */ +/* reuse GL_COMPRESSED_SRGB8_ETC2 */ +/* reuse GL_COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2 */ +/* reuse GL_COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2 */ +/* reuse GL_COMPRESSED_RGBA8_ETC2_EAC */ +/* reuse GL_COMPRESSED_SRGB8_ALPHA8_ETC2_EAC */ +/* reuse GL_COMPRESSED_R11_EAC */ +/* reuse GL_COMPRESSED_SIGNED_R11_EAC */ +/* reuse GL_COMPRESSED_RG11_EAC */ +/* reuse GL_COMPRESSED_SIGNED_RG11_EAC */ +/* reuse GL_PRIMITIVE_RESTART_FIXED_INDEX */ +/* reuse GL_ANY_SAMPLES_PASSED_CONSERVATIVE */ +/* reuse GL_MAX_ELEMENT_INDEX */ +/* Reuse tokens from ARB_clear_buffer_object (none) */ +/* Reuse tokens from ARB_compute_shader */ +/* reuse GL_COMPUTE_SHADER */ +/* reuse GL_MAX_COMPUTE_UNIFORM_BLOCKS */ +/* reuse GL_MAX_COMPUTE_TEXTURE_IMAGE_UNITS */ +/* reuse GL_MAX_COMPUTE_IMAGE_UNIFORMS */ +/* reuse GL_MAX_COMPUTE_SHARED_MEMORY_SIZE */ +/* reuse GL_MAX_COMPUTE_UNIFORM_COMPONENTS */ +/* reuse GL_MAX_COMPUTE_ATOMIC_COUNTER_BUFFERS */ +/* reuse GL_MAX_COMPUTE_ATOMIC_COUNTERS */ +/* reuse GL_MAX_COMBINED_COMPUTE_UNIFORM_COMPONENTS */ +/* reuse GL_MAX_COMPUTE_LOCAL_INVOCATIONS */ +/* reuse GL_MAX_COMPUTE_WORK_GROUP_COUNT */ +/* reuse GL_MAX_COMPUTE_WORK_GROUP_SIZE */ +/* reuse GL_COMPUTE_LOCAL_WORK_SIZE */ +/* reuse GL_UNIFORM_BLOCK_REFERENCED_BY_COMPUTE_SHADER */ +/* reuse GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_COMPUTE_SHADER */ +/* reuse GL_DISPATCH_INDIRECT_BUFFER */ +/* reuse GL_DISPATCH_INDIRECT_BUFFER_BINDING */ +/* Reuse tokens from ARB_copy_image (none) */ +/* Reuse tokens from KHR_debug */ +/* reuse GL_DEBUG_OUTPUT_SYNCHRONOUS */ +/* reuse GL_DEBUG_NEXT_LOGGED_MESSAGE_LENGTH */ +/* reuse GL_DEBUG_CALLBACK_FUNCTION */ +/* reuse GL_DEBUG_CALLBACK_USER_PARAM */ +/* reuse GL_DEBUG_SOURCE_API */ +/* reuse GL_DEBUG_SOURCE_WINDOW_SYSTEM */ +/* reuse GL_DEBUG_SOURCE_SHADER_COMPILER */ +/* reuse GL_DEBUG_SOURCE_THIRD_PARTY */ +/* reuse GL_DEBUG_SOURCE_APPLICATION */ +/* reuse GL_DEBUG_SOURCE_OTHER */ +/* reuse GL_DEBUG_TYPE_ERROR */ +/* reuse GL_DEBUG_TYPE_DEPRECATED_BEHAVIOR */ +/* reuse GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR */ +/* reuse GL_DEBUG_TYPE_PORTABILITY */ +/* reuse GL_DEBUG_TYPE_PERFORMANCE */ +/* reuse GL_DEBUG_TYPE_OTHER */ +/* reuse GL_MAX_DEBUG_MESSAGE_LENGTH */ +/* reuse GL_MAX_DEBUG_LOGGED_MESSAGES */ +/* reuse GL_DEBUG_LOGGED_MESSAGES */ +/* reuse GL_DEBUG_SEVERITY_HIGH */ +/* reuse GL_DEBUG_SEVERITY_MEDIUM */ +/* reuse GL_DEBUG_SEVERITY_LOW */ +/* reuse GL_DEBUG_TYPE_MARKER */ +/* reuse GL_DEBUG_TYPE_PUSH_GROUP */ +/* reuse GL_DEBUG_TYPE_POP_GROUP */ +/* reuse GL_DEBUG_SEVERITY_NOTIFICATION */ +/* reuse GL_MAX_DEBUG_GROUP_STACK_DEPTH */ +/* reuse GL_DEBUG_GROUP_STACK_DEPTH */ +/* reuse GL_BUFFER */ +/* reuse GL_SHADER */ +/* reuse GL_PROGRAM */ +/* reuse GL_QUERY */ +/* reuse GL_PROGRAM_PIPELINE */ +/* reuse GL_SAMPLER */ +/* reuse GL_DISPLAY_LIST */ +/* reuse GL_MAX_LABEL_LENGTH */ +/* reuse GL_DEBUG_OUTPUT */ +/* reuse GL_CONTEXT_FLAG_DEBUG_BIT */ +/* reuse GL_STACK_UNDERFLOW */ +/* reuse GL_STACK_OVERFLOW */ +/* Reuse tokens from ARB_explicit_uniform_location */ +/* reuse GL_MAX_UNIFORM_LOCATIONS */ +/* Reuse tokens from ARB_framebuffer_no_attachments */ +/* reuse GL_FRAMEBUFFER_DEFAULT_WIDTH */ +/* reuse GL_FRAMEBUFFER_DEFAULT_HEIGHT */ +/* reuse GL_FRAMEBUFFER_DEFAULT_LAYERS */ +/* reuse GL_FRAMEBUFFER_DEFAULT_SAMPLES */ +/* reuse GL_FRAMEBUFFER_DEFAULT_FIXED_SAMPLE_LOCATIONS */ +/* reuse GL_MAX_FRAMEBUFFER_WIDTH */ +/* reuse GL_MAX_FRAMEBUFFER_HEIGHT */ +/* reuse GL_MAX_FRAMEBUFFER_LAYERS */ +/* reuse GL_MAX_FRAMEBUFFER_SAMPLES */ +/* Reuse tokens from ARB_internalformat_query2 */ +/* reuse GL_INTERNALFORMAT_SUPPORTED */ +/* reuse GL_INTERNALFORMAT_PREFERRED */ +/* reuse GL_INTERNALFORMAT_RED_SIZE */ +/* reuse GL_INTERNALFORMAT_GREEN_SIZE */ +/* reuse GL_INTERNALFORMAT_BLUE_SIZE */ +/* reuse GL_INTERNALFORMAT_ALPHA_SIZE */ +/* reuse GL_INTERNALFORMAT_DEPTH_SIZE */ +/* reuse GL_INTERNALFORMAT_STENCIL_SIZE */ +/* reuse GL_INTERNALFORMAT_SHARED_SIZE */ +/* reuse GL_INTERNALFORMAT_RED_TYPE */ +/* reuse GL_INTERNALFORMAT_GREEN_TYPE */ +/* reuse GL_INTERNALFORMAT_BLUE_TYPE */ +/* reuse GL_INTERNALFORMAT_ALPHA_TYPE */ +/* reuse GL_INTERNALFORMAT_DEPTH_TYPE */ +/* reuse GL_INTERNALFORMAT_STENCIL_TYPE */ +/* reuse GL_MAX_WIDTH */ +/* reuse GL_MAX_HEIGHT */ +/* reuse GL_MAX_DEPTH */ +/* reuse GL_MAX_LAYERS */ +/* reuse GL_MAX_COMBINED_DIMENSIONS */ +/* reuse GL_COLOR_COMPONENTS */ +/* reuse GL_DEPTH_COMPONENTS */ +/* reuse GL_STENCIL_COMPONENTS */ +/* reuse GL_COLOR_RENDERABLE */ +/* reuse GL_DEPTH_RENDERABLE */ +/* reuse GL_STENCIL_RENDERABLE */ +/* reuse GL_FRAMEBUFFER_RENDERABLE */ +/* reuse GL_FRAMEBUFFER_RENDERABLE_LAYERED */ +/* reuse GL_FRAMEBUFFER_BLEND */ +/* reuse GL_READ_PIXELS */ +/* reuse GL_READ_PIXELS_FORMAT */ +/* reuse GL_READ_PIXELS_TYPE */ +/* reuse GL_TEXTURE_IMAGE_FORMAT */ +/* reuse GL_TEXTURE_IMAGE_TYPE */ +/* reuse GL_GET_TEXTURE_IMAGE_FORMAT */ +/* reuse GL_GET_TEXTURE_IMAGE_TYPE */ +/* reuse GL_MIPMAP */ +/* reuse GL_MANUAL_GENERATE_MIPMAP */ +/* reuse GL_AUTO_GENERATE_MIPMAP */ +/* reuse GL_COLOR_ENCODING */ +/* reuse GL_SRGB_READ */ +/* reuse GL_SRGB_WRITE */ +/* reuse GL_FILTER */ +/* reuse GL_VERTEX_TEXTURE */ +/* reuse GL_TESS_CONTROL_TEXTURE */ +/* reuse GL_TESS_EVALUATION_TEXTURE */ +/* reuse GL_GEOMETRY_TEXTURE */ +/* reuse GL_FRAGMENT_TEXTURE */ +/* reuse GL_COMPUTE_TEXTURE */ +/* reuse GL_TEXTURE_SHADOW */ +/* reuse GL_TEXTURE_GATHER */ +/* reuse GL_TEXTURE_GATHER_SHADOW */ +/* reuse GL_SHADER_IMAGE_LOAD */ +/* reuse GL_SHADER_IMAGE_STORE */ +/* reuse GL_SHADER_IMAGE_ATOMIC */ +/* reuse GL_IMAGE_TEXEL_SIZE */ +/* reuse GL_IMAGE_COMPATIBILITY_CLASS */ +/* reuse GL_IMAGE_PIXEL_FORMAT */ +/* reuse GL_IMAGE_PIXEL_TYPE */ +/* reuse GL_SIMULTANEOUS_TEXTURE_AND_DEPTH_TEST */ +/* reuse GL_SIMULTANEOUS_TEXTURE_AND_STENCIL_TEST */ +/* reuse GL_SIMULTANEOUS_TEXTURE_AND_DEPTH_WRITE */ +/* reuse GL_SIMULTANEOUS_TEXTURE_AND_STENCIL_WRITE */ +/* reuse GL_TEXTURE_COMPRESSED_BLOCK_WIDTH */ +/* reuse GL_TEXTURE_COMPRESSED_BLOCK_HEIGHT */ +/* reuse GL_TEXTURE_COMPRESSED_BLOCK_SIZE */ +/* reuse GL_CLEAR_BUFFER */ +/* reuse GL_TEXTURE_VIEW */ +/* reuse GL_VIEW_COMPATIBILITY_CLASS */ +/* reuse GL_FULL_SUPPORT */ +/* reuse GL_CAVEAT_SUPPORT */ +/* reuse GL_IMAGE_CLASS_4_X_32 */ +/* reuse GL_IMAGE_CLASS_2_X_32 */ +/* reuse GL_IMAGE_CLASS_1_X_32 */ +/* reuse GL_IMAGE_CLASS_4_X_16 */ +/* reuse GL_IMAGE_CLASS_2_X_16 */ +/* reuse GL_IMAGE_CLASS_1_X_16 */ +/* reuse GL_IMAGE_CLASS_4_X_8 */ +/* reuse GL_IMAGE_CLASS_2_X_8 */ +/* reuse GL_IMAGE_CLASS_1_X_8 */ +/* reuse GL_IMAGE_CLASS_11_11_10 */ +/* reuse GL_IMAGE_CLASS_10_10_10_2 */ +/* reuse GL_VIEW_CLASS_128_BITS */ +/* reuse GL_VIEW_CLASS_96_BITS */ +/* reuse GL_VIEW_CLASS_64_BITS */ +/* reuse GL_VIEW_CLASS_48_BITS */ +/* reuse GL_VIEW_CLASS_32_BITS */ +/* reuse GL_VIEW_CLASS_24_BITS */ +/* reuse GL_VIEW_CLASS_16_BITS */ +/* reuse GL_VIEW_CLASS_8_BITS */ +/* reuse GL_VIEW_CLASS_S3TC_DXT1_RGB */ +/* reuse GL_VIEW_CLASS_S3TC_DXT1_RGBA */ +/* reuse GL_VIEW_CLASS_S3TC_DXT3_RGBA */ +/* reuse GL_VIEW_CLASS_S3TC_DXT5_RGBA */ +/* reuse GL_VIEW_CLASS_RGTC1_RED */ +/* reuse GL_VIEW_CLASS_RGTC2_RG */ +/* reuse GL_VIEW_CLASS_BPTC_UNORM */ +/* reuse GL_VIEW_CLASS_BPTC_FLOAT */ +/* Reuse tokens from ARB_invalidate_subdata (none) */ +/* Reuse tokens from ARB_multi_draw_indirect (none) */ +/* Reuse tokens from ARB_program_interface_query */ +/* reuse GL_UNIFORM */ +/* reuse GL_UNIFORM_BLOCK */ +/* reuse GL_PROGRAM_INPUT */ +/* reuse GL_PROGRAM_OUTPUT */ +/* reuse GL_BUFFER_VARIABLE */ +/* reuse GL_SHADER_STORAGE_BLOCK */ +/* reuse GL_VERTEX_SUBROUTINE */ +/* reuse GL_TESS_CONTROL_SUBROUTINE */ +/* reuse GL_TESS_EVALUATION_SUBROUTINE */ +/* reuse GL_GEOMETRY_SUBROUTINE */ +/* reuse GL_FRAGMENT_SUBROUTINE */ +/* reuse GL_COMPUTE_SUBROUTINE */ +/* reuse GL_VERTEX_SUBROUTINE_UNIFORM */ +/* reuse GL_TESS_CONTROL_SUBROUTINE_UNIFORM */ +/* reuse GL_TESS_EVALUATION_SUBROUTINE_UNIFORM */ +/* reuse GL_GEOMETRY_SUBROUTINE_UNIFORM */ +/* reuse GL_FRAGMENT_SUBROUTINE_UNIFORM */ +/* reuse GL_COMPUTE_SUBROUTINE_UNIFORM */ +/* reuse GL_TRANSFORM_FEEDBACK_VARYING */ +/* reuse GL_ACTIVE_RESOURCES */ +/* reuse GL_MAX_NAME_LENGTH */ +/* reuse GL_MAX_NUM_ACTIVE_VARIABLES */ +/* reuse GL_MAX_NUM_COMPATIBLE_SUBROUTINES */ +/* reuse GL_NAME_LENGTH */ +/* reuse GL_TYPE */ +/* reuse GL_ARRAY_SIZE */ +/* reuse GL_OFFSET */ +/* reuse GL_BLOCK_INDEX */ +/* reuse GL_ARRAY_STRIDE */ +/* reuse GL_MATRIX_STRIDE */ +/* reuse GL_IS_ROW_MAJOR */ +/* reuse GL_ATOMIC_COUNTER_BUFFER_INDEX */ +/* reuse GL_BUFFER_BINDING */ +/* reuse GL_BUFFER_DATA_SIZE */ +/* reuse GL_NUM_ACTIVE_VARIABLES */ +/* reuse GL_ACTIVE_VARIABLES */ +/* reuse GL_REFERENCED_BY_VERTEX_SHADER */ +/* reuse GL_REFERENCED_BY_TESS_CONTROL_SHADER */ +/* reuse GL_REFERENCED_BY_TESS_EVALUATION_SHADER */ +/* reuse GL_REFERENCED_BY_GEOMETRY_SHADER */ +/* reuse GL_REFERENCED_BY_FRAGMENT_SHADER */ +/* reuse GL_REFERENCED_BY_COMPUTE_SHADER */ +/* reuse GL_TOP_LEVEL_ARRAY_SIZE */ +/* reuse GL_TOP_LEVEL_ARRAY_STRIDE */ +/* reuse GL_LOCATION */ +/* reuse GL_LOCATION_INDEX */ +/* reuse GL_IS_PER_PATCH */ +/* Reuse tokens from ARB_robust_buffer_access_behavior (none) */ +/* Reuse tokens from ARB_shader_storage_buffer_object */ +/* reuse GL_SHADER_STORAGE_BUFFER */ +/* reuse GL_SHADER_STORAGE_BUFFER_BINDING */ +/* reuse GL_SHADER_STORAGE_BUFFER_START */ +/* reuse GL_SHADER_STORAGE_BUFFER_SIZE */ +/* reuse GL_MAX_VERTEX_SHADER_STORAGE_BLOCKS */ +/* reuse GL_MAX_GEOMETRY_SHADER_STORAGE_BLOCKS */ +/* reuse GL_MAX_TESS_CONTROL_SHADER_STORAGE_BLOCKS */ +/* reuse GL_MAX_TESS_EVALUATION_SHADER_STORAGE_BLOCKS */ +/* reuse GL_MAX_FRAGMENT_SHADER_STORAGE_BLOCKS */ +/* reuse GL_MAX_COMPUTE_SHADER_STORAGE_BLOCKS */ +/* reuse GL_MAX_COMBINED_SHADER_STORAGE_BLOCKS */ +/* reuse GL_MAX_SHADER_STORAGE_BUFFER_BINDINGS */ +/* reuse GL_MAX_SHADER_STORAGE_BLOCK_SIZE */ +/* reuse GL_SHADER_STORAGE_BUFFER_OFFSET_ALIGNMENT */ +/* reuse GL_SHADER_STORAGE_BARRIER_BIT */ +/* reuse GL_MAX_COMBINED_SHADER_OUTPUT_RESOURCES */ +/* Reuse tokens from ARB_stencil_texturing */ +/* reuse GL_DEPTH_STENCIL_TEXTURE_MODE */ +/* Reuse tokens from ARB_texture_buffer_range */ +/* reuse GL_TEXTURE_BUFFER_OFFSET */ +/* reuse GL_TEXTURE_BUFFER_SIZE */ +/* reuse GL_TEXTURE_BUFFER_OFFSET_ALIGNMENT */ +/* Reuse tokens from ARB_texture_query_levels (none) */ +/* Reuse tokens from ARB_texture_storage_multisample (none) */ +/* Reuse tokens from ARB_texture_view */ +/* reuse GL_TEXTURE_VIEW_MIN_LEVEL */ +/* reuse GL_TEXTURE_VIEW_NUM_LEVELS */ +/* reuse GL_TEXTURE_VIEW_MIN_LAYER */ +/* reuse GL_TEXTURE_VIEW_NUM_LAYERS */ +/* reuse GL_TEXTURE_IMMUTABLE_LEVELS */ +/* Reuse tokens from ARB_vertex_attrib_binding */ +/* reuse GL_VERTEX_ATTRIB_BINDING */ +/* reuse GL_VERTEX_ATTRIB_RELATIVE_OFFSET */ +/* reuse GL_VERTEX_BINDING_DIVISOR */ +/* reuse GL_VERTEX_BINDING_OFFSET */ +/* reuse GL_VERTEX_BINDING_STRIDE */ +/* reuse GL_MAX_VERTEX_ATTRIB_RELATIVE_OFFSET */ +/* reuse GL_MAX_VERTEX_ATTRIB_BINDINGS */ +#endif + #ifndef GL_ARB_multitexture #define GL_TEXTURE0_ARB 0x84C0 #define GL_TEXTURE1_ARB 0x84C1 @@ -1746,9 +2006,6 @@ extern "C" { #define GL_RENDERBUFFER_STENCIL_SIZE 0x8D55 #define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE 0x8D56 #define GL_MAX_SAMPLES 0x8D57 -#endif - -#ifndef GL_ARB_framebuffer_object_DEPRECATED #define GL_INDEX 0x8222 #define GL_TEXTURE_LUMINANCE_TYPE 0x8C14 #define GL_TEXTURE_INTENSITY_TYPE 0x8C15 @@ -1980,6 +2237,7 @@ extern "C" { #ifndef GL_ARB_texture_gather #define GL_MIN_PROGRAM_TEXTURE_GATHER_OFFSET_ARB 0x8E5E #define GL_MAX_PROGRAM_TEXTURE_GATHER_OFFSET_ARB 0x8E5F +#define GL_MAX_PROGRAM_TEXTURE_GATHER_COMPONENTS_ARB 0x8F9F #endif #ifndef GL_ARB_texture_query_lod @@ -2157,6 +2415,7 @@ extern "C" { #define GL_MEDIUM_INT 0x8DF4 #define GL_HIGH_INT 0x8DF5 #define GL_SHADER_COMPILER 0x8DFA +#define GL_SHADER_BINARY_FORMATS 0x8DF8 #define GL_NUM_SHADER_BINARY_FORMATS 0x8DF9 #define GL_MAX_VERTEX_UNIFORM_VECTORS 0x8DFB #define GL_MAX_VARYING_VECTORS 0x8DFC @@ -2399,6 +2658,386 @@ extern "C" { #define GL_TEXTURE_IMMUTABLE_FORMAT 0x912F #endif +#ifndef GL_KHR_texture_compression_astc_ldr +#define GL_COMPRESSED_RGBA_ASTC_4x4_KHR 0x93B0 +#define GL_COMPRESSED_RGBA_ASTC_5x4_KHR 0x93B1 +#define GL_COMPRESSED_RGBA_ASTC_5x5_KHR 0x93B2 +#define GL_COMPRESSED_RGBA_ASTC_6x5_KHR 0x93B3 +#define GL_COMPRESSED_RGBA_ASTC_6x6_KHR 0x93B4 +#define GL_COMPRESSED_RGBA_ASTC_8x5_KHR 0x93B5 +#define GL_COMPRESSED_RGBA_ASTC_8x6_KHR 0x93B6 +#define GL_COMPRESSED_RGBA_ASTC_8x8_KHR 0x93B7 +#define GL_COMPRESSED_RGBA_ASTC_10x5_KHR 0x93B8 +#define GL_COMPRESSED_RGBA_ASTC_10x6_KHR 0x93B9 +#define GL_COMPRESSED_RGBA_ASTC_10x8_KHR 0x93BA +#define GL_COMPRESSED_RGBA_ASTC_10x10_KHR 0x93BB +#define GL_COMPRESSED_RGBA_ASTC_12x10_KHR 0x93BC +#define GL_COMPRESSED_RGBA_ASTC_12x12_KHR 0x93BD +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_4x4_KHR 0x93D0 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x4_KHR 0x93D1 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x5_KHR 0x93D2 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x5_KHR 0x93D3 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x6_KHR 0x93D4 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x5_KHR 0x93D5 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x6_KHR 0x93D6 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x8_KHR 0x93D7 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x5_KHR 0x93D8 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x6_KHR 0x93D9 +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x8_KHR 0x93DA +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x10_KHR 0x93DB +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_12x10_KHR 0x93DC +#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_12x12_KHR 0x93DD +#endif + +#ifndef GL_KHR_debug +#define GL_DEBUG_OUTPUT_SYNCHRONOUS 0x8242 +#define GL_DEBUG_NEXT_LOGGED_MESSAGE_LENGTH 0x8243 +#define GL_DEBUG_CALLBACK_FUNCTION 0x8244 +#define GL_DEBUG_CALLBACK_USER_PARAM 0x8245 +#define GL_DEBUG_SOURCE_API 0x8246 +#define GL_DEBUG_SOURCE_WINDOW_SYSTEM 0x8247 +#define GL_DEBUG_SOURCE_SHADER_COMPILER 0x8248 +#define GL_DEBUG_SOURCE_THIRD_PARTY 0x8249 +#define GL_DEBUG_SOURCE_APPLICATION 0x824A +#define GL_DEBUG_SOURCE_OTHER 0x824B +#define GL_DEBUG_TYPE_ERROR 0x824C +#define GL_DEBUG_TYPE_DEPRECATED_BEHAVIOR 0x824D +#define GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR 0x824E +#define GL_DEBUG_TYPE_PORTABILITY 0x824F +#define GL_DEBUG_TYPE_PERFORMANCE 0x8250 +#define GL_DEBUG_TYPE_OTHER 0x8251 +#define GL_DEBUG_TYPE_MARKER 0x8268 +#define GL_DEBUG_TYPE_PUSH_GROUP 0x8269 +#define GL_DEBUG_TYPE_POP_GROUP 0x826A +#define GL_DEBUG_SEVERITY_NOTIFICATION 0x826B +#define GL_MAX_DEBUG_GROUP_STACK_DEPTH 0x826C +#define GL_DEBUG_GROUP_STACK_DEPTH 0x826D +#define GL_BUFFER 0x82E0 +#define GL_SHADER 0x82E1 +#define GL_PROGRAM 0x82E2 +#define GL_QUERY 0x82E3 +#define GL_PROGRAM_PIPELINE 0x82E4 +#define GL_SAMPLER 0x82E6 +#define GL_DISPLAY_LIST 0x82E7 +/* DISPLAY_LIST used in compatibility profile only */ +#define GL_MAX_LABEL_LENGTH 0x82E8 +#define GL_MAX_DEBUG_MESSAGE_LENGTH 0x9143 +#define GL_MAX_DEBUG_LOGGED_MESSAGES 0x9144 +#define GL_DEBUG_LOGGED_MESSAGES 0x9145 +#define GL_DEBUG_SEVERITY_HIGH 0x9146 +#define GL_DEBUG_SEVERITY_MEDIUM 0x9147 +#define GL_DEBUG_SEVERITY_LOW 0x9148 +#define GL_DEBUG_OUTPUT 0x92E0 +#define GL_CONTEXT_FLAG_DEBUG_BIT 0x00000002 +/* reuse GL_STACK_UNDERFLOW */ +/* reuse GL_STACK_OVERFLOW */ +#endif + +#ifndef GL_ARB_arrays_of_arrays +#endif + +#ifndef GL_ARB_clear_buffer_object +#endif + +#ifndef GL_ARB_compute_shader +#define GL_COMPUTE_SHADER 0x91B9 +#define GL_MAX_COMPUTE_UNIFORM_BLOCKS 0x91BB +#define GL_MAX_COMPUTE_TEXTURE_IMAGE_UNITS 0x91BC +#define GL_MAX_COMPUTE_IMAGE_UNIFORMS 0x91BD +#define GL_MAX_COMPUTE_SHARED_MEMORY_SIZE 0x8262 +#define GL_MAX_COMPUTE_UNIFORM_COMPONENTS 0x8263 +#define GL_MAX_COMPUTE_ATOMIC_COUNTER_BUFFERS 0x8264 +#define GL_MAX_COMPUTE_ATOMIC_COUNTERS 0x8265 +#define GL_MAX_COMBINED_COMPUTE_UNIFORM_COMPONENTS 0x8266 +#define GL_MAX_COMPUTE_LOCAL_INVOCATIONS 0x90EB +#define GL_MAX_COMPUTE_WORK_GROUP_COUNT 0x91BE +#define GL_MAX_COMPUTE_WORK_GROUP_SIZE 0x91BF +#define GL_COMPUTE_LOCAL_WORK_SIZE 0x8267 +#define GL_UNIFORM_BLOCK_REFERENCED_BY_COMPUTE_SHADER 0x90EC +#define GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_COMPUTE_SHADER 0x90ED +#define GL_DISPATCH_INDIRECT_BUFFER 0x90EE +#define GL_DISPATCH_INDIRECT_BUFFER_BINDING 0x90EF +#define GL_COMPUTE_SHADER_BIT 0x00000020 +#endif + +#ifndef GL_ARB_copy_image +#endif + +#ifndef GL_ARB_texture_view +#define GL_TEXTURE_VIEW_MIN_LEVEL 0x82DB +#define GL_TEXTURE_VIEW_NUM_LEVELS 0x82DC +#define GL_TEXTURE_VIEW_MIN_LAYER 0x82DD +#define GL_TEXTURE_VIEW_NUM_LAYERS 0x82DE +#define GL_TEXTURE_IMMUTABLE_LEVELS 0x82DF +#endif + +#ifndef GL_ARB_vertex_attrib_binding +#define GL_VERTEX_ATTRIB_BINDING 0x82D4 +#define GL_VERTEX_ATTRIB_RELATIVE_OFFSET 0x82D5 +#define GL_VERTEX_BINDING_DIVISOR 0x82D6 +#define GL_VERTEX_BINDING_OFFSET 0x82D7 +#define GL_VERTEX_BINDING_STRIDE 0x82D8 +#define GL_MAX_VERTEX_ATTRIB_RELATIVE_OFFSET 0x82D9 +#define GL_MAX_VERTEX_ATTRIB_BINDINGS 0x82DA +#endif + +#ifndef GL_ARB_robustness_isolation +#endif + +#ifndef GL_ARB_ES3_compatibility +#define GL_COMPRESSED_RGB8_ETC2 0x9274 +#define GL_COMPRESSED_SRGB8_ETC2 0x9275 +#define GL_COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2 0x9276 +#define GL_COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2 0x9277 +#define GL_COMPRESSED_RGBA8_ETC2_EAC 0x9278 +#define GL_COMPRESSED_SRGB8_ALPHA8_ETC2_EAC 0x9279 +#define GL_COMPRESSED_R11_EAC 0x9270 +#define GL_COMPRESSED_SIGNED_R11_EAC 0x9271 +#define GL_COMPRESSED_RG11_EAC 0x9272 +#define GL_COMPRESSED_SIGNED_RG11_EAC 0x9273 +#define GL_PRIMITIVE_RESTART_FIXED_INDEX 0x8D69 +#define GL_ANY_SAMPLES_PASSED_CONSERVATIVE 0x8D6A +#define GL_MAX_ELEMENT_INDEX 0x8D6B +#endif + +#ifndef GL_ARB_explicit_uniform_location +#define GL_MAX_UNIFORM_LOCATIONS 0x826E +#endif + +#ifndef GL_ARB_fragment_layer_viewport +#endif + +#ifndef GL_ARB_framebuffer_no_attachments +#define GL_FRAMEBUFFER_DEFAULT_WIDTH 0x9310 +#define GL_FRAMEBUFFER_DEFAULT_HEIGHT 0x9311 +#define GL_FRAMEBUFFER_DEFAULT_LAYERS 0x9312 +#define GL_FRAMEBUFFER_DEFAULT_SAMPLES 0x9313 +#define GL_FRAMEBUFFER_DEFAULT_FIXED_SAMPLE_LOCATIONS 0x9314 +#define GL_MAX_FRAMEBUFFER_WIDTH 0x9315 +#define GL_MAX_FRAMEBUFFER_HEIGHT 0x9316 +#define GL_MAX_FRAMEBUFFER_LAYERS 0x9317 +#define GL_MAX_FRAMEBUFFER_SAMPLES 0x9318 +#endif + +#ifndef GL_ARB_internalformat_query2 +/* reuse GL_IMAGE_FORMAT_COMPATIBILITY_TYPE */ +/* reuse GL_NUM_SAMPLE_COUNTS */ +/* reuse GL_RENDERBUFFER */ +/* reuse GL_SAMPLES */ +/* reuse GL_TEXTURE_1D */ +/* reuse GL_TEXTURE_1D_ARRAY */ +/* reuse GL_TEXTURE_2D */ +/* reuse GL_TEXTURE_2D_ARRAY */ +/* reuse GL_TEXTURE_3D */ +/* reuse GL_TEXTURE_CUBE_MAP */ +/* reuse GL_TEXTURE_CUBE_MAP_ARRAY */ +/* reuse GL_TEXTURE_RECTANGLE */ +/* reuse GL_TEXTURE_BUFFER */ +/* reuse GL_TEXTURE_2D_MULTISAMPLE */ +/* reuse GL_TEXTURE_2D_MULTISAMPLE_ARRAY */ +/* reuse GL_TEXTURE_COMPRESSED */ +#define GL_INTERNALFORMAT_SUPPORTED 0x826F +#define GL_INTERNALFORMAT_PREFERRED 0x8270 +#define GL_INTERNALFORMAT_RED_SIZE 0x8271 +#define GL_INTERNALFORMAT_GREEN_SIZE 0x8272 +#define GL_INTERNALFORMAT_BLUE_SIZE 0x8273 +#define GL_INTERNALFORMAT_ALPHA_SIZE 0x8274 +#define GL_INTERNALFORMAT_DEPTH_SIZE 0x8275 +#define GL_INTERNALFORMAT_STENCIL_SIZE 0x8276 +#define GL_INTERNALFORMAT_SHARED_SIZE 0x8277 +#define GL_INTERNALFORMAT_RED_TYPE 0x8278 +#define GL_INTERNALFORMAT_GREEN_TYPE 0x8279 +#define GL_INTERNALFORMAT_BLUE_TYPE 0x827A +#define GL_INTERNALFORMAT_ALPHA_TYPE 0x827B +#define GL_INTERNALFORMAT_DEPTH_TYPE 0x827C +#define GL_INTERNALFORMAT_STENCIL_TYPE 0x827D +#define GL_MAX_WIDTH 0x827E +#define GL_MAX_HEIGHT 0x827F +#define GL_MAX_DEPTH 0x8280 +#define GL_MAX_LAYERS 0x8281 +#define GL_MAX_COMBINED_DIMENSIONS 0x8282 +#define GL_COLOR_COMPONENTS 0x8283 +#define GL_DEPTH_COMPONENTS 0x8284 +#define GL_STENCIL_COMPONENTS 0x8285 +#define GL_COLOR_RENDERABLE 0x8286 +#define GL_DEPTH_RENDERABLE 0x8287 +#define GL_STENCIL_RENDERABLE 0x8288 +#define GL_FRAMEBUFFER_RENDERABLE 0x8289 +#define GL_FRAMEBUFFER_RENDERABLE_LAYERED 0x828A +#define GL_FRAMEBUFFER_BLEND 0x828B +#define GL_READ_PIXELS 0x828C +#define GL_READ_PIXELS_FORMAT 0x828D +#define GL_READ_PIXELS_TYPE 0x828E +#define GL_TEXTURE_IMAGE_FORMAT 0x828F +#define GL_TEXTURE_IMAGE_TYPE 0x8290 +#define GL_GET_TEXTURE_IMAGE_FORMAT 0x8291 +#define GL_GET_TEXTURE_IMAGE_TYPE 0x8292 +#define GL_MIPMAP 0x8293 +#define GL_MANUAL_GENERATE_MIPMAP 0x8294 +#define GL_AUTO_GENERATE_MIPMAP 0x8295 +#define GL_COLOR_ENCODING 0x8296 +#define GL_SRGB_READ 0x8297 +#define GL_SRGB_WRITE 0x8298 +#define GL_SRGB_DECODE_ARB 0x8299 +#define GL_FILTER 0x829A +#define GL_VERTEX_TEXTURE 0x829B +#define GL_TESS_CONTROL_TEXTURE 0x829C +#define GL_TESS_EVALUATION_TEXTURE 0x829D +#define GL_GEOMETRY_TEXTURE 0x829E +#define GL_FRAGMENT_TEXTURE 0x829F +#define GL_COMPUTE_TEXTURE 0x82A0 +#define GL_TEXTURE_SHADOW 0x82A1 +#define GL_TEXTURE_GATHER 0x82A2 +#define GL_TEXTURE_GATHER_SHADOW 0x82A3 +#define GL_SHADER_IMAGE_LOAD 0x82A4 +#define GL_SHADER_IMAGE_STORE 0x82A5 +#define GL_SHADER_IMAGE_ATOMIC 0x82A6 +#define GL_IMAGE_TEXEL_SIZE 0x82A7 +#define GL_IMAGE_COMPATIBILITY_CLASS 0x82A8 +#define GL_IMAGE_PIXEL_FORMAT 0x82A9 +#define GL_IMAGE_PIXEL_TYPE 0x82AA +#define GL_SIMULTANEOUS_TEXTURE_AND_DEPTH_TEST 0x82AC +#define GL_SIMULTANEOUS_TEXTURE_AND_STENCIL_TEST 0x82AD +#define GL_SIMULTANEOUS_TEXTURE_AND_DEPTH_WRITE 0x82AE +#define GL_SIMULTANEOUS_TEXTURE_AND_STENCIL_WRITE 0x82AF +#define GL_TEXTURE_COMPRESSED_BLOCK_WIDTH 0x82B1 +#define GL_TEXTURE_COMPRESSED_BLOCK_HEIGHT 0x82B2 +#define GL_TEXTURE_COMPRESSED_BLOCK_SIZE 0x82B3 +#define GL_CLEAR_BUFFER 0x82B4 +#define GL_TEXTURE_VIEW 0x82B5 +#define GL_VIEW_COMPATIBILITY_CLASS 0x82B6 +#define GL_FULL_SUPPORT 0x82B7 +#define GL_CAVEAT_SUPPORT 0x82B8 +#define GL_IMAGE_CLASS_4_X_32 0x82B9 +#define GL_IMAGE_CLASS_2_X_32 0x82BA +#define GL_IMAGE_CLASS_1_X_32 0x82BB +#define GL_IMAGE_CLASS_4_X_16 0x82BC +#define GL_IMAGE_CLASS_2_X_16 0x82BD +#define GL_IMAGE_CLASS_1_X_16 0x82BE +#define GL_IMAGE_CLASS_4_X_8 0x82BF +#define GL_IMAGE_CLASS_2_X_8 0x82C0 +#define GL_IMAGE_CLASS_1_X_8 0x82C1 +#define GL_IMAGE_CLASS_11_11_10 0x82C2 +#define GL_IMAGE_CLASS_10_10_10_2 0x82C3 +#define GL_VIEW_CLASS_128_BITS 0x82C4 +#define GL_VIEW_CLASS_96_BITS 0x82C5 +#define GL_VIEW_CLASS_64_BITS 0x82C6 +#define GL_VIEW_CLASS_48_BITS 0x82C7 +#define GL_VIEW_CLASS_32_BITS 0x82C8 +#define GL_VIEW_CLASS_24_BITS 0x82C9 +#define GL_VIEW_CLASS_16_BITS 0x82CA +#define GL_VIEW_CLASS_8_BITS 0x82CB +#define GL_VIEW_CLASS_S3TC_DXT1_RGB 0x82CC +#define GL_VIEW_CLASS_S3TC_DXT1_RGBA 0x82CD +#define GL_VIEW_CLASS_S3TC_DXT3_RGBA 0x82CE +#define GL_VIEW_CLASS_S3TC_DXT5_RGBA 0x82CF +#define GL_VIEW_CLASS_RGTC1_RED 0x82D0 +#define GL_VIEW_CLASS_RGTC2_RG 0x82D1 +#define GL_VIEW_CLASS_BPTC_UNORM 0x82D2 +#define GL_VIEW_CLASS_BPTC_FLOAT 0x82D3 +#endif + +#ifndef GL_ARB_invalidate_subdata +#endif + +#ifndef GL_ARB_multi_draw_indirect +#endif + +#ifndef GL_ARB_program_interface_query +#define GL_UNIFORM 0x92E1 +#define GL_UNIFORM_BLOCK 0x92E2 +#define GL_PROGRAM_INPUT 0x92E3 +#define GL_PROGRAM_OUTPUT 0x92E4 +#define GL_BUFFER_VARIABLE 0x92E5 +#define GL_SHADER_STORAGE_BLOCK 0x92E6 +/* reuse GL_ATOMIC_COUNTER_BUFFER */ +#define GL_VERTEX_SUBROUTINE 0x92E8 +#define GL_TESS_CONTROL_SUBROUTINE 0x92E9 +#define GL_TESS_EVALUATION_SUBROUTINE 0x92EA +#define GL_GEOMETRY_SUBROUTINE 0x92EB +#define GL_FRAGMENT_SUBROUTINE 0x92EC +#define GL_COMPUTE_SUBROUTINE 0x92ED +#define GL_VERTEX_SUBROUTINE_UNIFORM 0x92EE +#define GL_TESS_CONTROL_SUBROUTINE_UNIFORM 0x92EF +#define GL_TESS_EVALUATION_SUBROUTINE_UNIFORM 0x92F0 +#define GL_GEOMETRY_SUBROUTINE_UNIFORM 0x92F1 +#define GL_FRAGMENT_SUBROUTINE_UNIFORM 0x92F2 +#define GL_COMPUTE_SUBROUTINE_UNIFORM 0x92F3 +#define GL_TRANSFORM_FEEDBACK_VARYING 0x92F4 +#define GL_ACTIVE_RESOURCES 0x92F5 +#define GL_MAX_NAME_LENGTH 0x92F6 +#define GL_MAX_NUM_ACTIVE_VARIABLES 0x92F7 +#define GL_MAX_NUM_COMPATIBLE_SUBROUTINES 0x92F8 +#define GL_NAME_LENGTH 0x92F9 +#define GL_TYPE 0x92FA +#define GL_ARRAY_SIZE 0x92FB +#define GL_OFFSET 0x92FC +#define GL_BLOCK_INDEX 0x92FD +#define GL_ARRAY_STRIDE 0x92FE +#define GL_MATRIX_STRIDE 0x92FF +#define GL_IS_ROW_MAJOR 0x9300 +#define GL_ATOMIC_COUNTER_BUFFER_INDEX 0x9301 +#define GL_BUFFER_BINDING 0x9302 +#define GL_BUFFER_DATA_SIZE 0x9303 +#define GL_NUM_ACTIVE_VARIABLES 0x9304 +#define GL_ACTIVE_VARIABLES 0x9305 +#define GL_REFERENCED_BY_VERTEX_SHADER 0x9306 +#define GL_REFERENCED_BY_TESS_CONTROL_SHADER 0x9307 +#define GL_REFERENCED_BY_TESS_EVALUATION_SHADER 0x9308 +#define GL_REFERENCED_BY_GEOMETRY_SHADER 0x9309 +#define GL_REFERENCED_BY_FRAGMENT_SHADER 0x930A +#define GL_REFERENCED_BY_COMPUTE_SHADER 0x930B +#define GL_TOP_LEVEL_ARRAY_SIZE 0x930C +#define GL_TOP_LEVEL_ARRAY_STRIDE 0x930D +#define GL_LOCATION 0x930E +#define GL_LOCATION_INDEX 0x930F +#define GL_IS_PER_PATCH 0x92E7 +/* reuse GL_NUM_COMPATIBLE_SUBROUTINES */ +/* reuse GL_COMPATIBLE_SUBROUTINES */ +#endif + +#ifndef GL_ARB_robust_buffer_access_behavior +#endif + +#ifndef GL_ARB_shader_image_size +#endif + +#ifndef GL_ARB_shader_storage_buffer_object +#define GL_SHADER_STORAGE_BUFFER 0x90D2 +#define GL_SHADER_STORAGE_BUFFER_BINDING 0x90D3 +#define GL_SHADER_STORAGE_BUFFER_START 0x90D4 +#define GL_SHADER_STORAGE_BUFFER_SIZE 0x90D5 +#define GL_MAX_VERTEX_SHADER_STORAGE_BLOCKS 0x90D6 +#define GL_MAX_GEOMETRY_SHADER_STORAGE_BLOCKS 0x90D7 +#define GL_MAX_TESS_CONTROL_SHADER_STORAGE_BLOCKS 0x90D8 +#define GL_MAX_TESS_EVALUATION_SHADER_STORAGE_BLOCKS 0x90D9 +#define GL_MAX_FRAGMENT_SHADER_STORAGE_BLOCKS 0x90DA +#define GL_MAX_COMPUTE_SHADER_STORAGE_BLOCKS 0x90DB +#define GL_MAX_COMBINED_SHADER_STORAGE_BLOCKS 0x90DC +#define GL_MAX_SHADER_STORAGE_BUFFER_BINDINGS 0x90DD +#define GL_MAX_SHADER_STORAGE_BLOCK_SIZE 0x90DE +#define GL_SHADER_STORAGE_BUFFER_OFFSET_ALIGNMENT 0x90DF +#define GL_SHADER_STORAGE_BARRIER_BIT 0x2000 +#define GL_MAX_COMBINED_SHADER_OUTPUT_RESOURCES GL_MAX_COMBINED_IMAGE_UNITS_AND_FRAGMENT_OUTPUTS +/* reuse GL_MAX_COMBINED_IMAGE_UNITS_AND_FRAGMENT_OUTPUTS */ +#endif + +#ifndef GL_ARB_stencil_texturing +#define GL_DEPTH_STENCIL_TEXTURE_MODE 0x90EA +#endif + +#ifndef GL_ARB_texture_buffer_range +#define GL_TEXTURE_BUFFER_OFFSET 0x919D +#define GL_TEXTURE_BUFFER_SIZE 0x919E +#define GL_TEXTURE_BUFFER_OFFSET_ALIGNMENT 0x919F +#endif + +#ifndef GL_ARB_texture_query_levels +#endif + +#ifndef GL_ARB_texture_storage_multisample +#endif + #ifndef GL_EXT_abgr #define GL_ABGR_EXT 0x8000 #endif @@ -4255,6 +4894,8 @@ extern "C" { #define GL_RGB4_S3TC 0x83A1 #define GL_RGBA_S3TC 0x83A2 #define GL_RGBA4_S3TC 0x83A3 +#define GL_RGBA_DXT5_S3TC 0x83A4 +#define GL_RGBA4_DXT5_S3TC 0x83A5 #endif #ifndef GL_ATI_draw_buffers @@ -4278,7 +4919,7 @@ extern "C" { #endif #ifndef GL_ATI_pixel_format_float -#define GL_TYPE_RGBA_FLOAT_ATI 0x8820 +#define GL_RGBA_FLOAT_MODE_ATI 0x8820 #define GL_COLOR_CLEAR_UNCLAMPED_VALUE_ATI 0x8835 #endif @@ -4738,7 +5379,7 @@ extern "C" { #define GL_PRIMITIVES_GENERATED_NV 0x8C87 #define GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN_NV 0x8C88 #define GL_RASTERIZER_DISCARD_NV 0x8C89 -#define GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_ATTRIBS_NV 0x8C8A +#define GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS_NV 0x8C8A #define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS_NV 0x8C8B #define GL_INTERLEAVED_ATTRIBS_NV 0x8C8C #define GL_SEPARATE_ATTRIBS_NV 0x8C8D @@ -5255,6 +5896,7 @@ extern "C" { #endif #ifndef GL_AMD_debug_output +#define GL_MAX_DEBUG_MESSAGE_LENGTH_AMD 0x9143 #define GL_MAX_DEBUG_LOGGED_MESSAGES_AMD 0x9144 #define GL_DEBUG_LOGGED_MESSAGES_AMD 0x9145 #define GL_DEBUG_SEVERITY_HIGH_AMD 0x9146 @@ -5478,6 +6120,24 @@ extern "C" { #ifndef GL_NV_shader_atomic_float #endif +#ifndef GL_AMD_query_buffer_object +#define GL_QUERY_BUFFER_AMD 0x9192 +#define GL_QUERY_BUFFER_BINDING_AMD 0x9193 +#define GL_QUERY_RESULT_NO_WAIT_AMD 0x9194 +#endif + +#ifndef GL_AMD_sparse_texture +#define GL_VIRTUAL_PAGE_SIZE_X_AMD 0x9195 +#define GL_VIRTUAL_PAGE_SIZE_Y_AMD 0x9196 +#define GL_VIRTUAL_PAGE_SIZE_Z_AMD 0x9197 +#define GL_MAX_SPARSE_TEXTURE_SIZE_AMD 0x9198 +#define GL_MAX_SPARSE_3D_TEXTURE_SIZE_AMD 0x9199 +#define GL_MAX_SPARSE_ARRAY_TEXTURE_LAYERS 0x919A +#define GL_MIN_SPARSE_LEVEL_AMD 0x919B +#define GL_MIN_LOD_WARNING_AMD 0x919C +#define GL_TEXTURE_STORAGE_SPARSE_BIT_AMD 0x00000001 +#endif + /*************************************************************/ @@ -5502,9 +6162,7 @@ typedef ptrdiff_t GLsizeiptrARB; #ifndef GL_ARB_shader_objects /* GL types for program/shader text and shader object handles */ typedef char GLcharARB; -//#if !defined(MAC_OS_X_VERSION_10_7) typedef unsigned int GLhandleARB; -//#endif #endif /* GL type for "half" precision (s10e5) float data in host memory */ @@ -5579,6 +6237,10 @@ typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLen typedef void (APIENTRY *GLDEBUGPROCAMD)(GLuint id,GLenum category,GLenum severity,GLsizei length,const GLchar *message,GLvoid *userParam); #endif +#ifndef GL_KHR_debug +typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,GLvoid *userParam); +#endif + #ifndef GL_NV_vdpau_interop typedef GLintptr GLvdpauSurfaceNV; #endif @@ -5592,18 +6254,6 @@ GLAPI void APIENTRY glDrawRangeElements (GLenum mode, GLuint start, GLuint end, GLAPI void APIENTRY glTexImage3D (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels); GLAPI void APIENTRY glTexSubImage3D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels); GLAPI void APIENTRY glCopyTexSubImage3D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBLENDCOLORPROC) (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha); -typedef void (APIENTRYP PFNGLBLENDEQUATIONPROC) (GLenum mode); -typedef void (APIENTRYP PFNGLDRAWRANGEELEMENTSPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices); -typedef void (APIENTRYP PFNGLTEXIMAGE3DPROC) (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels); -typedef void (APIENTRYP PFNGLTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels); -typedef void (APIENTRYP PFNGLCOPYTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height); -#endif - -#ifndef GL_VERSION_1_2_DEPRECATED -#define GL_VERSION_1_2_DEPRECATED 1 -#ifdef GL_GLEXT_PROTOTYPES GLAPI void APIENTRY glColorTable (GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table); GLAPI void APIENTRY glColorTableParameterfv (GLenum target, GLenum pname, const GLfloat *params); GLAPI void APIENTRY glColorTableParameteriv (GLenum target, GLenum pname, const GLint *params); @@ -5637,6 +6287,12 @@ GLAPI void APIENTRY glMinmax (GLenum target, GLenum internalformat, GLboolean si GLAPI void APIENTRY glResetHistogram (GLenum target); GLAPI void APIENTRY glResetMinmax (GLenum target); #endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLBLENDCOLORPROC) (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha); +typedef void (APIENTRYP PFNGLBLENDEQUATIONPROC) (GLenum mode); +typedef void (APIENTRYP PFNGLDRAWRANGEELEMENTSPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices); +typedef void (APIENTRYP PFNGLTEXIMAGE3DPROC) (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels); +typedef void (APIENTRYP PFNGLTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels); +typedef void (APIENTRYP PFNGLCOPYTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height); typedef void (APIENTRYP PFNGLCOLORTABLEPROC) (GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table); typedef void (APIENTRYP PFNGLCOLORTABLEPARAMETERFVPROC) (GLenum target, GLenum pname, const GLfloat *params); typedef void (APIENTRYP PFNGLCOLORTABLEPARAMETERIVPROC) (GLenum target, GLenum pname, const GLint *params); @@ -5683,21 +6339,6 @@ GLAPI void APIENTRY glCompressedTexSubImage3D (GLenum target, GLint level, GLint GLAPI void APIENTRY glCompressedTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data); GLAPI void APIENTRY glCompressedTexSubImage1D (GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data); GLAPI void APIENTRY glGetCompressedTexImage (GLenum target, GLint level, GLvoid *img); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLACTIVETEXTUREPROC) (GLenum texture); -typedef void (APIENTRYP PFNGLSAMPLECOVERAGEPROC) (GLfloat value, GLboolean invert); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE3DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE2DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE1DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE2DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE1DPROC) (GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLGETCOMPRESSEDTEXIMAGEPROC) (GLenum target, GLint level, GLvoid *img); -#endif - -#ifndef GL_VERSION_1_3_DEPRECATED -#define GL_VERSION_1_3_DEPRECATED 1 -#ifdef GL_GLEXT_PROTOTYPES GLAPI void APIENTRY glClientActiveTexture (GLenum texture); GLAPI void APIENTRY glMultiTexCoord1d (GLenum target, GLdouble s); GLAPI void APIENTRY glMultiTexCoord1dv (GLenum target, const GLdouble *v); @@ -5736,6 +6377,15 @@ GLAPI void APIENTRY glLoadTransposeMatrixd (const GLdouble *m); GLAPI void APIENTRY glMultTransposeMatrixf (const GLfloat *m); GLAPI void APIENTRY glMultTransposeMatrixd (const GLdouble *m); #endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLACTIVETEXTUREPROC) (GLenum texture); +typedef void (APIENTRYP PFNGLSAMPLECOVERAGEPROC) (GLfloat value, GLboolean invert); +typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE3DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data); +typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE2DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data); +typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE1DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data); +typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data); +typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE2DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data); +typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE1DPROC) (GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data); +typedef void (APIENTRYP PFNGLGETCOMPRESSEDTEXIMAGEPROC) (GLenum target, GLint level, GLvoid *img); typedef void (APIENTRYP PFNGLCLIENTACTIVETEXTUREPROC) (GLenum texture); typedef void (APIENTRYP PFNGLMULTITEXCOORD1DPROC) (GLenum target, GLdouble s); typedef void (APIENTRYP PFNGLMULTITEXCOORD1DVPROC) (GLenum target, const GLdouble *v); @@ -5779,25 +6429,12 @@ typedef void (APIENTRYP PFNGLMULTTRANSPOSEMATRIXDPROC) (const GLdouble *m); #define GL_VERSION_1_4 1 #ifdef GL_GLEXT_PROTOTYPES GLAPI void APIENTRY glBlendFuncSeparate (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha); -GLAPI void APIENTRY glMultiDrawArrays (GLenum mode, const GLint *first, const GLsizei *count, GLsizei primcount); -GLAPI void APIENTRY glMultiDrawElements (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei primcount); +GLAPI void APIENTRY glMultiDrawArrays (GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount); +GLAPI void APIENTRY glMultiDrawElements (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount); GLAPI void APIENTRY glPointParameterf (GLenum pname, GLfloat param); GLAPI void APIENTRY glPointParameterfv (GLenum pname, const GLfloat *params); GLAPI void APIENTRY glPointParameteri (GLenum pname, GLint param); GLAPI void APIENTRY glPointParameteriv (GLenum pname, const GLint *params); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBLENDFUNCSEPARATEPROC) (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha); -typedef void (APIENTRYP PFNGLMULTIDRAWARRAYSPROC) (GLenum mode, const GLint *first, const GLsizei *count, GLsizei primcount); -typedef void (APIENTRYP PFNGLMULTIDRAWELEMENTSPROC) (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei primcount); -typedef void (APIENTRYP PFNGLPOINTPARAMETERFPROC) (GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLPOINTPARAMETERFVPROC) (GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLPOINTPARAMETERIPROC) (GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLPOINTPARAMETERIVPROC) (GLenum pname, const GLint *params); -#endif - -#ifndef GL_VERSION_1_4_DEPRECATED -#define GL_VERSION_1_4_DEPRECATED 1 -#ifdef GL_GLEXT_PROTOTYPES GLAPI void APIENTRY glFogCoordf (GLfloat coord); GLAPI void APIENTRY glFogCoordfv (const GLfloat *coord); GLAPI void APIENTRY glFogCoordd (GLdouble coord); @@ -5837,6 +6474,13 @@ GLAPI void APIENTRY glWindowPos3iv (const GLint *v); GLAPI void APIENTRY glWindowPos3s (GLshort x, GLshort y, GLshort z); GLAPI void APIENTRY glWindowPos3sv (const GLshort *v); #endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLBLENDFUNCSEPARATEPROC) (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha); +typedef void (APIENTRYP PFNGLMULTIDRAWARRAYSPROC) (GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount); +typedef void (APIENTRYP PFNGLMULTIDRAWELEMENTSPROC) (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount); +typedef void (APIENTRYP PFNGLPOINTPARAMETERFPROC) (GLenum pname, GLfloat param); +typedef void (APIENTRYP PFNGLPOINTPARAMETERFVPROC) (GLenum pname, const GLfloat *params); +typedef void (APIENTRYP PFNGLPOINTPARAMETERIPROC) (GLenum pname, GLint param); +typedef void (APIENTRYP PFNGLPOINTPARAMETERIVPROC) (GLenum pname, const GLint *params); typedef void (APIENTRYP PFNGLFOGCOORDFPROC) (GLfloat coord); typedef void (APIENTRYP PFNGLFOGCOORDFVPROC) (const GLfloat *coord); typedef void (APIENTRYP PFNGLFOGCOORDDPROC) (GLdouble coord); @@ -6263,13 +6907,13 @@ typedef const GLubyte * (APIENTRYP PFNGLGETSTRINGIPROC) (GLenum name, GLuint ind /* ARB_copy_buffer */ /* ARB_uniform_buffer_object */ #ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glDrawArraysInstanced (GLenum mode, GLint first, GLsizei count, GLsizei primcount); -GLAPI void APIENTRY glDrawElementsInstanced (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei primcount); +GLAPI void APIENTRY glDrawArraysInstanced (GLenum mode, GLint first, GLsizei count, GLsizei instancecount); +GLAPI void APIENTRY glDrawElementsInstanced (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount); GLAPI void APIENTRY glTexBuffer (GLenum target, GLenum internalformat, GLuint buffer); GLAPI void APIENTRY glPrimitiveRestartIndex (GLuint index); #endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLDRAWARRAYSINSTANCEDPROC) (GLenum mode, GLint first, GLsizei count, GLsizei primcount); -typedef void (APIENTRYP PFNGLDRAWELEMENTSINSTANCEDPROC) (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei primcount); +typedef void (APIENTRYP PFNGLDRAWARRAYSINSTANCEDPROC) (GLenum mode, GLint first, GLsizei count, GLsizei instancecount); +typedef void (APIENTRYP PFNGLDRAWELEMENTSINSTANCEDPROC) (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount); typedef void (APIENTRYP PFNGLTEXBUFFERPROC) (GLenum target, GLenum internalformat, GLuint buffer); typedef void (APIENTRYP PFNGLPRIMITIVERESTARTINDEXPROC) (GLuint index); #endif @@ -6364,6 +7008,33 @@ typedef void (APIENTRYP PFNGLBLENDFUNCSEPARATEIPROC) (GLuint buf, GLenum srcRGB, /* ARB_texture_storage */ #endif +#ifndef GL_VERSION_4_3 +#define GL_VERSION_4_3 1 +/* OpenGL 4.3 reuses entry points from these extensions: */ +/* ARB_arrays_of_arrays (no entry points, GLSL only) */ +/* ARB_fragment_layer_viewport (no entry points, GLSL only) */ +/* ARB_shader_image_size (no entry points, GLSL only) */ +/* ARB_ES3_compatibility (no entry points) */ +/* ARB_clear_buffer_object */ +/* ARB_compute_shader */ +/* ARB_copy_image */ +/* KHR_debug (includes ARB_debug_output commands promoted to KHR without suffixes) */ +/* ARB_explicit_uniform_location (no entry points) */ +/* ARB_framebuffer_no_attachments */ +/* ARB_internalformat_query2 */ +/* ARB_invalidate_subdata */ +/* ARB_multi_draw_indirect */ +/* ARB_program_interface_query */ +/* ARB_robust_buffer_access_behavior (no entry points) */ +/* ARB_shader_storage_buffer_object */ +/* ARB_stencil_texturing (no entry points) */ +/* ARB_texture_buffer_range */ +/* ARB_texture_query_levels (no entry points) */ +/* ARB_texture_storage_multisample */ +/* ARB_texture_view */ +/* ARB_vertex_attrib_binding */ +#endif + #ifndef GL_ARB_multitexture #define GL_ARB_multitexture 1 #ifdef GL_GLEXT_PROTOTYPES @@ -7118,13 +7789,13 @@ typedef void (APIENTRYP PFNGLCOPYBUFFERSUBDATAPROC) (GLenum readTarget, GLenum w #ifdef GL_GLEXT_PROTOTYPES GLAPI void APIENTRY glDrawElementsBaseVertex (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex); GLAPI void APIENTRY glDrawRangeElementsBaseVertex (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex); -GLAPI void APIENTRY glDrawElementsInstancedBaseVertex (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei primcount, GLint basevertex); -GLAPI void APIENTRY glMultiDrawElementsBaseVertex (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei primcount, const GLint *basevertex); +GLAPI void APIENTRY glDrawElementsInstancedBaseVertex (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex); +GLAPI void APIENTRY glMultiDrawElementsBaseVertex (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex); #endif /* GL_GLEXT_PROTOTYPES */ typedef void (APIENTRYP PFNGLDRAWELEMENTSBASEVERTEXPROC) (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex); typedef void (APIENTRYP PFNGLDRAWRANGEELEMENTSBASEVERTEXPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex); -typedef void (APIENTRYP PFNGLDRAWELEMENTSINSTANCEDBASEVERTEXPROC) (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei primcount, GLint basevertex); -typedef void (APIENTRYP PFNGLMULTIDRAWELEMENTSBASEVERTEXPROC) (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei primcount, const GLint *basevertex); +typedef void (APIENTRYP PFNGLDRAWELEMENTSINSTANCEDBASEVERTEXPROC) (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex); +typedef void (APIENTRYP PFNGLMULTIDRAWELEMENTSBASEVERTEXPROC) (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex); #endif #ifndef GL_ARB_fragment_coord_conventions @@ -7802,13 +8473,13 @@ typedef void (APIENTRYP PFNGLGETNUNIFORMDVARBPROC) (GLuint program, GLint locati #ifndef GL_ARB_base_instance #define GL_ARB_base_instance 1 #ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glDrawArraysInstancedBaseInstance (GLenum mode, GLint first, GLsizei count, GLsizei primcount, GLuint baseinstance); -GLAPI void APIENTRY glDrawElementsInstancedBaseInstance (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount, GLuint baseinstance); -GLAPI void APIENTRY glDrawElementsInstancedBaseVertexBaseInstance (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount, GLint basevertex, GLuint baseinstance); +GLAPI void APIENTRY glDrawArraysInstancedBaseInstance (GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance); +GLAPI void APIENTRY glDrawElementsInstancedBaseInstance (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLuint baseinstance); +GLAPI void APIENTRY glDrawElementsInstancedBaseVertexBaseInstance (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance); #endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLDRAWARRAYSINSTANCEDBASEINSTANCEPROC) (GLenum mode, GLint first, GLsizei count, GLsizei primcount, GLuint baseinstance); -typedef void (APIENTRYP PFNGLDRAWELEMENTSINSTANCEDBASEINSTANCEPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount, GLuint baseinstance); -typedef void (APIENTRYP PFNGLDRAWELEMENTSINSTANCEDBASEVERTEXBASEINSTANCEPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount, GLint basevertex, GLuint baseinstance); +typedef void (APIENTRYP PFNGLDRAWARRAYSINSTANCEDBASEINSTANCEPROC) (GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance); +typedef void (APIENTRYP PFNGLDRAWELEMENTSINSTANCEDBASEINSTANCEPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLuint baseinstance); +typedef void (APIENTRYP PFNGLDRAWELEMENTSINSTANCEDBASEVERTEXBASEINSTANCEPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance); #endif #ifndef GL_ARB_shading_language_420pack @@ -7818,11 +8489,11 @@ typedef void (APIENTRYP PFNGLDRAWELEMENTSINSTANCEDBASEVERTEXBASEINSTANCEPROC) (G #ifndef GL_ARB_transform_feedback_instanced #define GL_ARB_transform_feedback_instanced 1 #ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glDrawTransformFeedbackInstanced (GLenum mode, GLuint id, GLsizei primcount); -GLAPI void APIENTRY glDrawTransformFeedbackStreamInstanced (GLenum mode, GLuint id, GLuint stream, GLsizei primcount); +GLAPI void APIENTRY glDrawTransformFeedbackInstanced (GLenum mode, GLuint id, GLsizei instancecount); +GLAPI void APIENTRY glDrawTransformFeedbackStreamInstanced (GLenum mode, GLuint id, GLuint stream, GLsizei instancecount); #endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLDRAWTRANSFORMFEEDBACKINSTANCEDPROC) (GLenum mode, GLuint id, GLsizei primcount); -typedef void (APIENTRYP PFNGLDRAWTRANSFORMFEEDBACKSTREAMINSTANCEDPROC) (GLenum mode, GLuint id, GLuint stream, GLsizei primcount); +typedef void (APIENTRYP PFNGLDRAWTRANSFORMFEEDBACKINSTANCEDPROC) (GLenum mode, GLuint id, GLsizei instancecount); +typedef void (APIENTRYP PFNGLDRAWTRANSFORMFEEDBACKSTREAMINSTANCEDPROC) (GLenum mode, GLuint id, GLuint stream, GLsizei instancecount); #endif #ifndef GL_ARB_compressed_texture_pixel_storage @@ -7885,6 +8556,242 @@ typedef void (APIENTRYP PFNGLTEXTURESTORAGE2DEXTPROC) (GLuint texture, GLenum ta typedef void (APIENTRYP PFNGLTEXTURESTORAGE3DEXTPROC) (GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth); #endif +#ifndef GL_KHR_texture_compression_astc_ldr +#define GL_KHR_texture_compression_astc_ldr 1 +#endif + +#ifndef GL_KHR_debug +#define GL_KHR_debug 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glDebugMessageControl (GLenum source, GLenum type, GLenum severity, GLsizei count, const GLuint *ids, GLboolean enabled); +GLAPI void APIENTRY glDebugMessageInsert (GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar *buf); +GLAPI void APIENTRY glDebugMessageCallback (GLDEBUGPROC callback, const void *userParam); +GLAPI GLuint APIENTRY glGetDebugMessageLog (GLuint count, GLsizei bufsize, GLenum *sources, GLenum *types, GLuint *ids, GLenum *severities, GLsizei *lengths, GLchar *messageLog); +GLAPI void APIENTRY glPushDebugGroup (GLenum source, GLuint id, GLsizei length, const GLchar *message); +GLAPI void APIENTRY glPopDebugGroup (void); +GLAPI void APIENTRY glObjectLabel (GLenum identifier, GLuint name, GLsizei length, const GLchar *label); +GLAPI void APIENTRY glGetObjectLabel (GLenum identifier, GLuint name, GLsizei bufSize, GLsizei *length, GLchar *label); +GLAPI void APIENTRY glObjectPtrLabel (const void *ptr, GLsizei length, const GLchar *label); +GLAPI void APIENTRY glGetObjectPtrLabel (const void *ptr, GLsizei bufSize, GLsizei *length, GLchar *label); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLDEBUGMESSAGECONTROLPROC) (GLenum source, GLenum type, GLenum severity, GLsizei count, const GLuint *ids, GLboolean enabled); +typedef void (APIENTRYP PFNGLDEBUGMESSAGEINSERTPROC) (GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar *buf); +typedef void (APIENTRYP PFNGLDEBUGMESSAGECALLBACKPROC) (GLDEBUGPROC callback, const void *userParam); +typedef GLuint (APIENTRYP PFNGLGETDEBUGMESSAGELOGPROC) (GLuint count, GLsizei bufsize, GLenum *sources, GLenum *types, GLuint *ids, GLenum *severities, GLsizei *lengths, GLchar *messageLog); +typedef void (APIENTRYP PFNGLPUSHDEBUGGROUPPROC) (GLenum source, GLuint id, GLsizei length, const GLchar *message); +typedef void (APIENTRYP PFNGLPOPDEBUGGROUPPROC) (void); +typedef void (APIENTRYP PFNGLOBJECTLABELPROC) (GLenum identifier, GLuint name, GLsizei length, const GLchar *label); +typedef void (APIENTRYP PFNGLGETOBJECTLABELPROC) (GLenum identifier, GLuint name, GLsizei bufSize, GLsizei *length, GLchar *label); +typedef void (APIENTRYP PFNGLOBJECTPTRLABELPROC) (const void *ptr, GLsizei length, const GLchar *label); +typedef void (APIENTRYP PFNGLGETOBJECTPTRLABELPROC) (const void *ptr, GLsizei bufSize, GLsizei *length, GLchar *label); +#endif + +#ifndef GL_ARB_arrays_of_arrays +#define GL_ARB_arrays_of_arrays 1 +#endif + +#ifndef GL_ARB_clear_buffer_object +#define GL_ARB_clear_buffer_object 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glClearBufferData (GLenum target, GLenum internalformat, GLenum format, GLenum type, const void *data); +GLAPI void APIENTRY glClearBufferSubData (GLenum target, GLenum internalformat, GLintptr offset, GLsizeiptr size, GLenum format, GLenum type, const void *data); +GLAPI void APIENTRY glClearNamedBufferDataEXT (GLuint buffer, GLenum internalformat, GLenum format, GLenum type, const void *data); +GLAPI void APIENTRY glClearNamedBufferSubDataEXT (GLuint buffer, GLenum internalformat, GLenum format, GLenum type, GLsizeiptr offset, GLsizeiptr size, const void *data); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLCLEARBUFFERDATAPROC) (GLenum target, GLenum internalformat, GLenum format, GLenum type, const void *data); +typedef void (APIENTRYP PFNGLCLEARBUFFERSUBDATAPROC) (GLenum target, GLenum internalformat, GLintptr offset, GLsizeiptr size, GLenum format, GLenum type, const void *data); +typedef void (APIENTRYP PFNGLCLEARNAMEDBUFFERDATAEXTPROC) (GLuint buffer, GLenum internalformat, GLenum format, GLenum type, const void *data); +typedef void (APIENTRYP PFNGLCLEARNAMEDBUFFERSUBDATAEXTPROC) (GLuint buffer, GLenum internalformat, GLenum format, GLenum type, GLsizeiptr offset, GLsizeiptr size, const void *data); +#endif + +#ifndef GL_ARB_compute_shader +#define GL_ARB_compute_shader 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glDispatchCompute (GLuint num_groups_x, GLuint num_groups_y, GLuint num_groups_z); +GLAPI void APIENTRY glDispatchComputeIndirect (GLintptr indirect); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLDISPATCHCOMPUTEPROC) (GLuint num_groups_x, GLuint num_groups_y, GLuint num_groups_z); +typedef void (APIENTRYP PFNGLDISPATCHCOMPUTEINDIRECTPROC) (GLintptr indirect); +#endif + +#ifndef GL_ARB_copy_image +#define GL_ARB_copy_image 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glCopyImageSubData (GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei srcWidth, GLsizei srcHeight, GLsizei srcDepth); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLCOPYIMAGESUBDATAPROC) (GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei srcWidth, GLsizei srcHeight, GLsizei srcDepth); +#endif + +#ifndef GL_ARB_texture_view +#define GL_ARB_texture_view 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glTextureView (GLuint texture, GLenum target, GLuint origtexture, GLenum internalformat, GLuint minlevel, GLuint numlevels, GLuint minlayer, GLuint numlayers); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLTEXTUREVIEWPROC) (GLuint texture, GLenum target, GLuint origtexture, GLenum internalformat, GLuint minlevel, GLuint numlevels, GLuint minlayer, GLuint numlayers); +#endif + +#ifndef GL_ARB_vertex_attrib_binding +#define GL_ARB_vertex_attrib_binding 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glBindVertexBuffer (GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride); +GLAPI void APIENTRY glVertexAttribFormat (GLuint attribindex, GLint size, GLenum type, GLboolean normalized, GLuint relativeoffset); +GLAPI void APIENTRY glVertexAttribIFormat (GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset); +GLAPI void APIENTRY glVertexAttribLFormat (GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset); +GLAPI void APIENTRY glVertexAttribBinding (GLuint attribindex, GLuint bindingindex); +GLAPI void APIENTRY glVertexBindingDivisor (GLuint bindingindex, GLuint divisor); +GLAPI void APIENTRY glVertexArrayBindVertexBufferEXT (GLuint vaobj, GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride); +GLAPI void APIENTRY glVertexArrayVertexAttribFormatEXT (GLuint vaobj, GLuint attribindex, GLint size, GLenum type, GLboolean normalized, GLuint relativeoffset); +GLAPI void APIENTRY glVertexArrayVertexAttribIFormatEXT (GLuint vaobj, GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset); +GLAPI void APIENTRY glVertexArrayVertexAttribLFormatEXT (GLuint vaobj, GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset); +GLAPI void APIENTRY glVertexArrayVertexAttribBindingEXT (GLuint vaobj, GLuint attribindex, GLuint bindingindex); +GLAPI void APIENTRY glVertexArrayVertexBindingDivisorEXT (GLuint vaobj, GLuint bindingindex, GLuint divisor); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLBINDVERTEXBUFFERPROC) (GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride); +typedef void (APIENTRYP PFNGLVERTEXATTRIBFORMATPROC) (GLuint attribindex, GLint size, GLenum type, GLboolean normalized, GLuint relativeoffset); +typedef void (APIENTRYP PFNGLVERTEXATTRIBIFORMATPROC) (GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset); +typedef void (APIENTRYP PFNGLVERTEXATTRIBLFORMATPROC) (GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset); +typedef void (APIENTRYP PFNGLVERTEXATTRIBBINDINGPROC) (GLuint attribindex, GLuint bindingindex); +typedef void (APIENTRYP PFNGLVERTEXBINDINGDIVISORPROC) (GLuint bindingindex, GLuint divisor); +typedef void (APIENTRYP PFNGLVERTEXARRAYBINDVERTEXBUFFEREXTPROC) (GLuint vaobj, GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride); +typedef void (APIENTRYP PFNGLVERTEXARRAYVERTEXATTRIBFORMATEXTPROC) (GLuint vaobj, GLuint attribindex, GLint size, GLenum type, GLboolean normalized, GLuint relativeoffset); +typedef void (APIENTRYP PFNGLVERTEXARRAYVERTEXATTRIBIFORMATEXTPROC) (GLuint vaobj, GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset); +typedef void (APIENTRYP PFNGLVERTEXARRAYVERTEXATTRIBLFORMATEXTPROC) (GLuint vaobj, GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset); +typedef void (APIENTRYP PFNGLVERTEXARRAYVERTEXATTRIBBINDINGEXTPROC) (GLuint vaobj, GLuint attribindex, GLuint bindingindex); +typedef void (APIENTRYP PFNGLVERTEXARRAYVERTEXBINDINGDIVISOREXTPROC) (GLuint vaobj, GLuint bindingindex, GLuint divisor); +#endif + +#ifndef GL_ARB_robustness_isolation +#define GL_ARB_robustness_isolation 1 +#endif + +#ifndef GL_ARB_ES3_compatibility +#define GL_ARB_ES3_compatibility 1 +#endif + +#ifndef GL_ARB_explicit_uniform_location +#define GL_ARB_explicit_uniform_location 1 +#endif + +#ifndef GL_ARB_fragment_layer_viewport +#define GL_ARB_fragment_layer_viewport 1 +#endif + +#ifndef GL_ARB_framebuffer_no_attachments +#define GL_ARB_framebuffer_no_attachments 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glFramebufferParameteri (GLenum target, GLenum pname, GLint param); +GLAPI void APIENTRY glGetFramebufferParameteriv (GLenum target, GLenum pname, GLint *params); +GLAPI void APIENTRY glNamedFramebufferParameteriEXT (GLuint framebuffer, GLenum pname, GLint param); +GLAPI void APIENTRY glGetNamedFramebufferParameterivEXT (GLuint framebuffer, GLenum pname, GLint *params); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLFRAMEBUFFERPARAMETERIPROC) (GLenum target, GLenum pname, GLint param); +typedef void (APIENTRYP PFNGLGETFRAMEBUFFERPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLNAMEDFRAMEBUFFERPARAMETERIEXTPROC) (GLuint framebuffer, GLenum pname, GLint param); +typedef void (APIENTRYP PFNGLGETNAMEDFRAMEBUFFERPARAMETERIVEXTPROC) (GLuint framebuffer, GLenum pname, GLint *params); +#endif + +#ifndef GL_ARB_internalformat_query2 +#define GL_ARB_internalformat_query2 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glGetInternalformati64v (GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint64 *params); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLGETINTERNALFORMATI64VPROC) (GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint64 *params); +#endif + +#ifndef GL_ARB_invalidate_subdata +#define GL_ARB_invalidate_subdata 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glInvalidateTexSubImage (GLuint texture, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth); +GLAPI void APIENTRY glInvalidateTexImage (GLuint texture, GLint level); +GLAPI void APIENTRY glInvalidateBufferSubData (GLuint buffer, GLintptr offset, GLsizeiptr length); +GLAPI void APIENTRY glInvalidateBufferData (GLuint buffer); +GLAPI void APIENTRY glInvalidateFramebuffer (GLenum target, GLsizei numAttachments, const GLenum *attachments); +GLAPI void APIENTRY glInvalidateSubFramebuffer (GLenum target, GLsizei numAttachments, const GLenum *attachments, GLint x, GLint y, GLsizei width, GLsizei height); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLINVALIDATETEXSUBIMAGEPROC) (GLuint texture, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth); +typedef void (APIENTRYP PFNGLINVALIDATETEXIMAGEPROC) (GLuint texture, GLint level); +typedef void (APIENTRYP PFNGLINVALIDATEBUFFERSUBDATAPROC) (GLuint buffer, GLintptr offset, GLsizeiptr length); +typedef void (APIENTRYP PFNGLINVALIDATEBUFFERDATAPROC) (GLuint buffer); +typedef void (APIENTRYP PFNGLINVALIDATEFRAMEBUFFERPROC) (GLenum target, GLsizei numAttachments, const GLenum *attachments); +typedef void (APIENTRYP PFNGLINVALIDATESUBFRAMEBUFFERPROC) (GLenum target, GLsizei numAttachments, const GLenum *attachments, GLint x, GLint y, GLsizei width, GLsizei height); +#endif + +#ifndef GL_ARB_multi_draw_indirect +#define GL_ARB_multi_draw_indirect 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glMultiDrawArraysIndirect (GLenum mode, const void *indirect, GLsizei drawcount, GLsizei stride); +GLAPI void APIENTRY glMultiDrawElementsIndirect (GLenum mode, GLenum type, const void *indirect, GLsizei drawcount, GLsizei stride); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLMULTIDRAWARRAYSINDIRECTPROC) (GLenum mode, const void *indirect, GLsizei drawcount, GLsizei stride); +typedef void (APIENTRYP PFNGLMULTIDRAWELEMENTSINDIRECTPROC) (GLenum mode, GLenum type, const void *indirect, GLsizei drawcount, GLsizei stride); +#endif + +#ifndef GL_ARB_program_interface_query +#define GL_ARB_program_interface_query 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glGetProgramInterfaceiv (GLuint program, GLenum programInterface, GLenum pname, GLint *params); +GLAPI GLuint APIENTRY glGetProgramResourceIndex (GLuint program, GLenum programInterface, const GLchar *name); +GLAPI void APIENTRY glGetProgramResourceName (GLuint program, GLenum programInterface, GLuint index, GLsizei bufSize, GLsizei *length, GLchar *name); +GLAPI void APIENTRY glGetProgramResourceiv (GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei bufSize, GLsizei *length, GLint *params); +GLAPI GLint APIENTRY glGetProgramResourceLocation (GLuint program, GLenum programInterface, const GLchar *name); +GLAPI GLint APIENTRY glGetProgramResourceLocationIndex (GLuint program, GLenum programInterface, const GLchar *name); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLGETPROGRAMINTERFACEIVPROC) (GLuint program, GLenum programInterface, GLenum pname, GLint *params); +typedef GLuint (APIENTRYP PFNGLGETPROGRAMRESOURCEINDEXPROC) (GLuint program, GLenum programInterface, const GLchar *name); +typedef void (APIENTRYP PFNGLGETPROGRAMRESOURCENAMEPROC) (GLuint program, GLenum programInterface, GLuint index, GLsizei bufSize, GLsizei *length, GLchar *name); +typedef void (APIENTRYP PFNGLGETPROGRAMRESOURCEIVPROC) (GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei bufSize, GLsizei *length, GLint *params); +typedef GLint (APIENTRYP PFNGLGETPROGRAMRESOURCELOCATIONPROC) (GLuint program, GLenum programInterface, const GLchar *name); +typedef GLint (APIENTRYP PFNGLGETPROGRAMRESOURCELOCATIONINDEXPROC) (GLuint program, GLenum programInterface, const GLchar *name); +#endif + +#ifndef GL_ARB_robust_buffer_access_behavior +#define GL_ARB_robust_buffer_access_behavior 1 +#endif + +#ifndef GL_ARB_shader_image_size +#define GL_ARB_shader_image_size 1 +#endif + +#ifndef GL_ARB_shader_storage_buffer_object +#define GL_ARB_shader_storage_buffer_object 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glShaderStorageBlockBinding (GLuint program, GLuint storageBlockIndex, GLuint storageBlockBinding); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLSHADERSTORAGEBLOCKBINDINGPROC) (GLuint program, GLuint storageBlockIndex, GLuint storageBlockBinding); +#endif + +#ifndef GL_ARB_stencil_texturing +#define GL_ARB_stencil_texturing 1 +#endif + +#ifndef GL_ARB_texture_buffer_range +#define GL_ARB_texture_buffer_range 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glTexBufferRange (GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size); +GLAPI void APIENTRY glTextureBufferRangeEXT (GLuint texture, GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLTEXBUFFERRANGEPROC) (GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size); +typedef void (APIENTRYP PFNGLTEXTUREBUFFERRANGEEXTPROC) (GLuint texture, GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size); +#endif + +#ifndef GL_ARB_texture_query_levels +#define GL_ARB_texture_query_levels 1 +#endif + +#ifndef GL_ARB_texture_storage_multisample +#define GL_ARB_texture_storage_multisample 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glTexStorage2DMultisample (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations); +GLAPI void APIENTRY glTexStorage3DMultisample (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations); +GLAPI void APIENTRY glTextureStorage2DMultisampleEXT (GLuint texture, GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations); +GLAPI void APIENTRY glTextureStorage3DMultisampleEXT (GLuint texture, GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLTEXSTORAGE2DMULTISAMPLEPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations); +typedef void (APIENTRYP PFNGLTEXSTORAGE3DMULTISAMPLEPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations); +typedef void (APIENTRYP PFNGLTEXTURESTORAGE2DMULTISAMPLEEXTPROC) (GLuint texture, GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations); +typedef void (APIENTRYP PFNGLTEXTURESTORAGE3DMULTISAMPLEEXTPROC) (GLuint texture, GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations); +#endif + #ifndef GL_EXT_abgr #define GL_EXT_abgr 1 #endif @@ -8626,11 +9533,15 @@ GLAPI void APIENTRY glPixelTransformParameteriEXT (GLenum target, GLenum pname, GLAPI void APIENTRY glPixelTransformParameterfEXT (GLenum target, GLenum pname, GLfloat param); GLAPI void APIENTRY glPixelTransformParameterivEXT (GLenum target, GLenum pname, const GLint *params); GLAPI void APIENTRY glPixelTransformParameterfvEXT (GLenum target, GLenum pname, const GLfloat *params); +GLAPI void APIENTRY glGetPixelTransformParameterivEXT (GLenum target, GLenum pname, GLint *params); +GLAPI void APIENTRY glGetPixelTransformParameterfvEXT (GLenum target, GLenum pname, GLfloat *params); #endif /* GL_GLEXT_PROTOTYPES */ typedef void (APIENTRYP PFNGLPIXELTRANSFORMPARAMETERIEXTPROC) (GLenum target, GLenum pname, GLint param); typedef void (APIENTRYP PFNGLPIXELTRANSFORMPARAMETERFEXTPROC) (GLenum target, GLenum pname, GLfloat param); typedef void (APIENTRYP PFNGLPIXELTRANSFORMPARAMETERIVEXTPROC) (GLenum target, GLenum pname, const GLint *params); typedef void (APIENTRYP PFNGLPIXELTRANSFORMPARAMETERFVEXTPROC) (GLenum target, GLenum pname, const GLfloat *params); +typedef void (APIENTRYP PFNGLGETPIXELTRANSFORMPARAMETERIVEXTPROC) (GLenum target, GLenum pname, GLint *params); +typedef void (APIENTRYP PFNGLGETPIXELTRANSFORMPARAMETERFVEXTPROC) (GLenum target, GLenum pname, GLfloat *params); #endif #ifndef GL_EXT_pixel_transform_color_table @@ -8982,11 +9893,11 @@ typedef void (APIENTRYP PFNGLBLENDFUNCSEPARATEINGRPROC) (GLenum sfactorRGB, GLen #ifdef GL_GLEXT_PROTOTYPES GLAPI void APIENTRY glVertexWeightfEXT (GLfloat weight); GLAPI void APIENTRY glVertexWeightfvEXT (const GLfloat *weight); -GLAPI void APIENTRY glVertexWeightPointerEXT (GLsizei size, GLenum type, GLsizei stride, const GLvoid *pointer); +GLAPI void APIENTRY glVertexWeightPointerEXT (GLint size, GLenum type, GLsizei stride, const GLvoid *pointer); #endif /* GL_GLEXT_PROTOTYPES */ typedef void (APIENTRYP PFNGLVERTEXWEIGHTFEXTPROC) (GLfloat weight); typedef void (APIENTRYP PFNGLVERTEXWEIGHTFVEXTPROC) (const GLfloat *weight); -typedef void (APIENTRYP PFNGLVERTEXWEIGHTPOINTEREXTPROC) (GLsizei size, GLenum type, GLsizei stride, const GLvoid *pointer); +typedef void (APIENTRYP PFNGLVERTEXWEIGHTPOINTEREXTPROC) (GLint size, GLenum type, GLsizei stride, const GLvoid *pointer); #endif #ifndef GL_NV_light_max_exponent @@ -10050,10 +10961,10 @@ typedef void (APIENTRYP PFNGLVERTEXATTRIBS4HVNVPROC) (GLuint index, GLsizei n, c #ifndef GL_NV_pixel_data_range #define GL_NV_pixel_data_range 1 #ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glPixelDataRangeNV (GLenum target, GLsizei length, GLvoid *pointer); +GLAPI void APIENTRY glPixelDataRangeNV (GLenum target, GLsizei length, const GLvoid *pointer); GLAPI void APIENTRY glFlushPixelDataRangeNV (GLenum target); #endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPIXELDATARANGENVPROC) (GLenum target, GLsizei length, GLvoid *pointer); +typedef void (APIENTRYP PFNGLPIXELDATARANGENVPROC) (GLenum target, GLsizei length, const GLvoid *pointer); typedef void (APIENTRYP PFNGLFLUSHPIXELDATARANGENVPROC) (GLenum target); #endif @@ -11562,7 +12473,7 @@ typedef GLuint (APIENTRYP PFNGLGETDEBUGMESSAGELOGAMDPROC) (GLuint count, GLsizei #ifdef GL_GLEXT_PROTOTYPES GLAPI void APIENTRY glVDPAUInitNV (const GLvoid *vdpDevice, const GLvoid *getProcAddress); GLAPI void APIENTRY glVDPAUFiniNV (void); -GLAPI GLvdpauSurfaceNV APIENTRY glVDPAURegisterVideoSurfaceNV (GLvoid *vdpSurface, GLenum target, GLsizei numTextureNames, const GLuint *textureNames); +GLAPI GLvdpauSurfaceNV APIENTRY glVDPAURegisterVideoSurfaceNV (const GLvoid *vdpSurface, GLenum target, GLsizei numTextureNames, const GLuint *textureNames); GLAPI GLvdpauSurfaceNV APIENTRY glVDPAURegisterOutputSurfaceNV (GLvoid *vdpSurface, GLenum target, GLsizei numTextureNames, const GLuint *textureNames); GLAPI void APIENTRY glVDPAUIsSurfaceNV (GLvdpauSurfaceNV surface); GLAPI void APIENTRY glVDPAUUnregisterSurfaceNV (GLvdpauSurfaceNV surface); @@ -11573,7 +12484,7 @@ GLAPI void APIENTRY glVDPAUUnmapSurfacesNV (GLsizei numSurface, const GLvdpauSur #endif /* GL_GLEXT_PROTOTYPES */ typedef void (APIENTRYP PFNGLVDPAUINITNVPROC) (const GLvoid *vdpDevice, const GLvoid *getProcAddress); typedef void (APIENTRYP PFNGLVDPAUFININVPROC) (void); -typedef GLvdpauSurfaceNV (APIENTRYP PFNGLVDPAUREGISTERVIDEOSURFACENVPROC) (GLvoid *vdpSurface, GLenum target, GLsizei numTextureNames, const GLuint *textureNames); +typedef GLvdpauSurfaceNV (APIENTRYP PFNGLVDPAUREGISTERVIDEOSURFACENVPROC) (const GLvoid *vdpSurface, GLenum target, GLsizei numTextureNames, const GLuint *textureNames); typedef GLvdpauSurfaceNV (APIENTRYP PFNGLVDPAUREGISTEROUTPUTSURFACENVPROC) (GLvoid *vdpSurface, GLenum target, GLsizei numTextureNames, const GLuint *textureNames); typedef void (APIENTRYP PFNGLVDPAUISSURFACENVPROC) (GLvdpauSurfaceNV surface); typedef void (APIENTRYP PFNGLVDPAUUNREGISTERSURFACENVPROC) (GLvdpauSurfaceNV surface); @@ -11807,6 +12718,20 @@ typedef GLboolean (APIENTRYP PFNGLISIMAGEHANDLERESIDENTNVPROC) (GLuint64 handle) #define GL_NV_shader_atomic_float 1 #endif +#ifndef GL_AMD_query_buffer_object +#define GL_AMD_query_buffer_object 1 +#endif + +#ifndef GL_AMD_sparse_texture +#define GL_AMD_sparse_texture 1 +#ifdef GL_GLEXT_PROTOTYPES +GLAPI void APIENTRY glTexStorageSparseAMD (GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLsizei layers, GLbitfield flags); +GLAPI void APIENTRY glTextureStorageSparseAMD (GLuint texture, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLsizei layers, GLbitfield flags); +#endif /* GL_GLEXT_PROTOTYPES */ +typedef void (APIENTRYP PFNGLTEXSTORAGESPARSEAMDPROC) (GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLsizei layers, GLbitfield flags); +typedef void (APIENTRYP PFNGLTEXTURESTORAGESPARSEAMDPROC) (GLuint texture, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLsizei layers, GLbitfield flags); +#endif + #ifdef __cplusplus } diff --git a/code/nel/src/3d/driver/opengl/GL/glxext.h b/code/nel/src/3d/driver/opengl/GL/glxext.h index e640ff7e3..580ba347d 100644 --- a/code/nel/src/3d/driver/opengl/GL/glxext.h +++ b/code/nel/src/3d/driver/opengl/GL/glxext.h @@ -444,6 +444,10 @@ extern "C" { #define GLX_LATE_SWAPS_TEAR_EXT 0x20F3 #endif +#ifndef GLX_EXT_buffer_age +#define GLX_BACK_BUFFER_AGE_EXT 0x20F4 +#endif + /*************************************************************/ @@ -993,6 +997,10 @@ typedef void ( * PFNGLXCOPYIMAGESUBDATANVPROC) (Display *dpy, GLXContext srcCtx, #define GLX_EXT_swap_control_tear 1 #endif +#ifndef GLX_EXT_buffer_age +#define GLX_EXT_buffer_age 1 +#endif + #ifdef __cplusplus } diff --git a/code/nel/src/3d/driver/opengl/GLES/glext.h b/code/nel/src/3d/driver/opengl/GLES/glext.h index d591832bf..5b46ae6d0 100644 --- a/code/nel/src/3d/driver/opengl/GLES/glext.h +++ b/code/nel/src/3d/driver/opengl/GLES/glext.h @@ -1,7 +1,7 @@ #ifndef __glext_h_ #define __glext_h_ -/* $Revision: 16481 $ on $Date:: 2012-01-04 10:43:56 -0800 #$ */ +/* $Revision: 19260 $ on $Date:: 2012-09-20 11:30:36 -0700 #$ */ #ifdef __cplusplus extern "C" { @@ -165,6 +165,9 @@ typedef void* GLeglImageOES; #define GL_DEPTH24_STENCIL8_OES 0x88F0 #endif +/* GL_OES_required_internalformat */ +/* No new tokens introduced by this extension. */ + /* GL_OES_rgb8_rgba8 */ #ifndef GL_OES_rgb8_rgba8 #define GL_RGB8_OES 0x8051 @@ -240,7 +243,7 @@ typedef void* GLeglImageOES; * APPLE extension tokens *------------------------------------------------------------------------*/ -/* GL_APPLE_texture_2D_limited_npot */ +/* GL_APPLE_copy_texture_levels */ /* No new tokens introduced by this extension. */ /* GL_APPLE_framebuffer_multisample */ @@ -254,6 +257,41 @@ typedef void* GLeglImageOES; #define GL_READ_FRAMEBUFFER_BINDING_APPLE 0x8CAA #endif +/* GL_APPLE_sync */ +#ifndef GL_APPLE_sync + +/* These types are defined with reference to + * in the Apple extension spec, but here we use the Khronos + * portable types in khrplatform.h, and assume those types + * are always defined. + * If any other extensions using these types are defined, + * the typedefs must move out of this block and be shared. + */ +typedef khronos_int64_t GLint64; +typedef khronos_uint64_t GLuint64; +typedef struct __GLsync *GLsync; + +#define GL_SYNC_OBJECT_APPLE 0x8A53 +#define GL_MAX_SERVER_WAIT_TIMEOUT_APPLE 0x9111 +#define GL_OBJECT_TYPE_APPLE 0x9112 +#define GL_SYNC_CONDITION_APPLE 0x9113 +#define GL_SYNC_STATUS_APPLE 0x9114 +#define GL_SYNC_FLAGS_APPLE 0x9115 +#define GL_SYNC_FENCE_APPLE 0x9116 +#define GL_SYNC_GPU_COMMANDS_COMPLETE_APPLE 0x9117 +#define GL_UNSIGNALED_APPLE 0x9118 +#define GL_SIGNALED_APPLE 0x9119 +#define GL_ALREADY_SIGNALED_APPLE 0x911A +#define GL_TIMEOUT_EXPIRED_APPLE 0x911B +#define GL_CONDITION_SATISFIED_APPLE 0x911C +#define GL_WAIT_FAILED_APPLE 0x911D +#define GL_SYNC_FLUSH_COMMANDS_BIT_APPLE 0x00000001 +#define GL_TIMEOUT_IGNORED_APPLE 0xFFFFFFFFFFFFFFFFull +#endif + +/* GL_APPLE_texture_2D_limited_npot */ +/* No new tokens introduced by this extension. */ + /* GL_APPLE_texture_format_BGRA8888 */ #ifndef GL_APPLE_texture_format_BGRA8888 #define GL_BGRA_EXT 0x80E1 @@ -288,12 +326,23 @@ typedef void* GLeglImageOES; #define GL_STENCIL_EXT 0x1802 #endif +/* GL_EXT_map_buffer_range */ +#ifndef GL_EXT_map_buffer_range +#define GL_MAP_READ_BIT_EXT 0x0001 +#define GL_MAP_WRITE_BIT_EXT 0x0002 +#define GL_MAP_INVALIDATE_RANGE_BIT_EXT 0x0004 +#define GL_MAP_INVALIDATE_BUFFER_BIT_EXT 0x0008 +#define GL_MAP_FLUSH_EXPLICIT_BIT_EXT 0x0010 +#define GL_MAP_UNSYNCHRONIZED_BIT_EXT 0x0020 +#endif + /* GL_EXT_multisampled_render_to_texture */ #ifndef GL_EXT_multisampled_render_to_texture #define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_SAMPLES_EXT 0x8D6C -#define GL_RENDERBUFFER_SAMPLES_EXT 0x9133 -#define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_EXT 0x9134 -#define GL_MAX_SAMPLES_EXT 0x9135 +/* reuse values from GL_EXT_framebuffer_multisample (desktop extension) */ +#define GL_RENDERBUFFER_SAMPLES_EXT 0x8CAB +#define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_EXT 0x8D56 +#define GL_MAX_SAMPLES_EXT 0x8D57 #endif /* GL_EXT_multi_draw_arrays */ @@ -353,10 +402,10 @@ typedef void* GLeglImageOES; /* GL_EXT_texture_storage */ #ifndef GL_EXT_texture_storage #define GL_TEXTURE_IMMUTABLE_FORMAT_EXT 0x912F -#define GL_ALPHA8_EXT 0x803C +#define GL_ALPHA8_EXT 0x803C #define GL_LUMINANCE8_EXT 0x8040 #define GL_LUMINANCE8_ALPHA8_EXT 0x8045 -#define GL_RGBA32F_EXT 0x8814 +#define GL_RGBA32F_EXT 0x8814 #define GL_RGB32F_EXT 0x8815 #define GL_ALPHA32F_EXT 0x8816 #define GL_LUMINANCE32F_EXT 0x8818 @@ -366,7 +415,7 @@ typedef void* GLeglImageOES; #define GL_ALPHA16F_EXT 0x881C #define GL_LUMINANCE16F_EXT 0x881E #define GL_LUMINANCE_ALPHA16F_EXT 0x881F -#define GL_RGB10_A2_EXT 0x8059 +#define GL_RGB10_A2_EXT 0x8059 #define GL_RGB10_EXT 0x8052 #define GL_BGRA8_EXT 0x93A1 #endif @@ -771,6 +820,11 @@ typedef void (GL_APIENTRYP PFNGLWEIGHTPOINTEROESPROC) (GLint size, GLenum type, #define GL_OES_packed_depth_stencil 1 #endif +/* GL_OES_required_internalformat */ +#ifndef GL_OES_required_internalformat +#define GL_OES_required_internalformat 1 +#endif + /* GL_OES_query_matrix */ #ifndef GL_OES_query_matrix #define GL_OES_query_matrix 1 @@ -892,9 +946,13 @@ typedef GLboolean (GL_APIENTRYP PFNGLISVERTEXARRAYOESPROC) (GLuint array); * APPLE extension functions *------------------------------------------------------------------------*/ -/* GL_APPLE_texture_2D_limited_npot */ -#ifndef GL_APPLE_texture_2D_limited_npot -#define GL_APPLE_texture_2D_limited_npot 1 +/* GL_APPLE_copy_texture_levels */ +#ifndef GL_APPLE_copy_texture_levels +#define GL_APPLE_copy_texture_levels 1 +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY glCopyTextureLevelsAPPLE (GLuint destinationTexture, GLuint sourceTexture, GLint sourceBaseLevel, GLsizei sourceLevelCount); +#endif +typedef void (GL_APIENTRYP PFNGLCOPYTEXTURELEVELSAPPLEPROC) (GLuint destinationTexture, GLuint sourceTexture, GLint sourceBaseLevel, GLsizei sourceLevelCount); #endif /* GL_APPLE_framebuffer_multisample */ @@ -908,6 +966,32 @@ typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEAPPLEPROC) (GLenum typedef void (GL_APIENTRYP PFNGLRESOLVEMULTISAMPLEFRAMEBUFFERAPPLEPROC) (void); #endif +/* GL_APPLE_sync */ +#ifndef GL_APPLE_sync +#define GL_APPLE_sync 1 +#ifdef GL_GLEXT_PROTOTYPES +GL_API GLsync GL_APIENTRY glFenceSyncAPPLE (GLenum condition, GLbitfield flags); +GL_API GLboolean GL_APIENTRY glIsSyncAPPLE (GLsync sync); +GL_API void GL_APIENTRY glDeleteSyncAPPLE (GLsync sync); +GL_API GLenum GL_APIENTRY glClientWaitSyncAPPLE (GLsync sync, GLbitfield flags, GLuint64 timeout); +GL_API void GL_APIENTRY glWaitSyncAPPLE (GLsync sync, GLbitfield flags, GLuint64 timeout); +GL_API void GL_APIENTRY glGetInteger64vAPPLE (GLenum pname, GLint64 *params); +GL_API void GL_APIENTRY glGetSyncivAPPLE (GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values); +#endif +typedef GLsync (GL_APIENTRYP PFNGLFENCESYNCAPPLEPROC) (GLenum condition, GLbitfield flags); +typedef GLboolean (GL_APIENTRYP PFNGLISSYNCAPPLEPROC) (GLsync sync); +typedef void (GL_APIENTRYP PFNGLDELETESYNCAPPLEPROC) (GLsync sync); +typedef GLenum (GL_APIENTRYP PFNGLCLIENTWAITSYNCAPPLEPROC) (GLsync sync, GLbitfield flags, GLuint64 timeout); +typedef void (GL_APIENTRYP PFNGLWAITSYNCAPPLEPROC) (GLsync sync, GLbitfield flags, GLuint64 timeout); +typedef void (GL_APIENTRYP PFNGLGETINTEGER64VAPPLEPROC) (GLenum pname, GLint64 *params); +typedef void (GL_APIENTRYP PFNGLGETSYNCIVAPPLEPROC) (GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values); +#endif + +/* GL_APPLE_texture_2D_limited_npot */ +#ifndef GL_APPLE_texture_2D_limited_npot +#define GL_APPLE_texture_2D_limited_npot 1 +#endif + /* GL_APPLE_texture_format_BGRA8888 */ #ifndef GL_APPLE_texture_format_BGRA8888 #define GL_APPLE_texture_format_BGRA8888 1 @@ -945,6 +1029,17 @@ GL_API void GL_APIENTRY glDiscardFramebufferEXT (GLenum target, GLsizei numAttac typedef void (GL_APIENTRYP PFNGLDISCARDFRAMEBUFFEREXTPROC) (GLenum target, GLsizei numAttachments, const GLenum *attachments); #endif +/* GL_EXT_map_buffer_range */ +#ifndef GL_EXT_map_buffer_range +#define GL_EXT_map_buffer_range 1 +#ifdef GL_GLEXT_PROTOTYPES +GL_API void GL_APIENTRY *glMapBufferRangeEXT (GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access); +GL_API void GL_APIENTRY glFlushMappedBufferRangeEXT (GLenum target, GLintptr offset, GLsizeiptr length); +#endif +typedef void* (GL_APIENTRYP PFNGLMAPBUFFERRANGEEXTPROC) (GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access); +typedef void (GL_APIENTRYP PFNGLFLUSHMAPPEDBUFFERRANGEEXTPROC) (GLenum target, GLintptr offset, GLsizeiptr length); +#endif + /* GL_EXT_multisampled_render_to_texture */ #ifndef GL_EXT_multisampled_render_to_texture #define GL_EXT_multisampled_render_to_texture 1 @@ -1068,8 +1163,8 @@ typedef void (GL_APIENTRYP PFNGLCLIPPLANEXIMGPROC) (GLenum p, const GLfixed *eqn GL_API void GL_APIENTRY glRenderbufferStorageMultisampleIMG (GLenum, GLsizei, GLenum, GLsizei, GLsizei); GL_API void GL_APIENTRY glFramebufferTexture2DMultisampleIMG (GLenum, GLenum, GLenum, GLuint, GLint, GLsizei); #endif -typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEIMG) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); -typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTURE2DMULTISAMPLEIMG) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples); +typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEIMGPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height); +typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTURE2DMULTISAMPLEIMGPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples); #endif /*------------------------------------------------------------------------* diff --git a/code/nel/src/3d/driver/opengl/driver_opengl.cpp b/code/nel/src/3d/driver/opengl/driver_opengl.cpp index c00c8aece..29e14a1a0 100644 --- a/code/nel/src/3d/driver/opengl/driver_opengl.cpp +++ b/code/nel/src/3d/driver/opengl/driver_opengl.cpp @@ -161,21 +161,12 @@ const uint CDriverGL::_EVSNumConstant = 97; GLenum CDriverGL::NLCubeFaceToGLCubeFace[6] = { -#ifdef USE_OPENGLES - GL_TEXTURE_CUBE_MAP_POSITIVE_X_OES, - GL_TEXTURE_CUBE_MAP_NEGATIVE_X_OES, - GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_OES, - GL_TEXTURE_CUBE_MAP_POSITIVE_Z_OES, - GL_TEXTURE_CUBE_MAP_POSITIVE_Y_OES, - GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_OES -#else GL_TEXTURE_CUBE_MAP_POSITIVE_X_ARB, GL_TEXTURE_CUBE_MAP_NEGATIVE_X_ARB, GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_ARB, GL_TEXTURE_CUBE_MAP_POSITIVE_Z_ARB, GL_TEXTURE_CUBE_MAP_POSITIVE_Y_ARB, GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_ARB -#endif }; // *************************************************************************** diff --git a/code/nel/src/3d/driver/opengl/driver_opengl_extension_def.h b/code/nel/src/3d/driver/opengl/driver_opengl_extension_def.h index a9df7c4bc..a11d0cd1c 100644 --- a/code/nel/src/3d/driver/opengl/driver_opengl_extension_def.h +++ b/code/nel/src/3d/driver/opengl/driver_opengl_extension_def.h @@ -77,6 +77,13 @@ typedef void (APIENTRY * NEL_PFNGLGETTEXGENXVOESPROC) (GLenum coord, GLenum pnam #define GL_INTERPOLATE_EXT GL_INTERPOLATE #define GL_BUMP_ENVMAP_ATI GL_INTERPOLATE +#define GL_TEXTURE_CUBE_MAP_POSITIVE_X_ARB GL_TEXTURE_CUBE_MAP_POSITIVE_X_OES +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_X_ARB GL_TEXTURE_CUBE_MAP_NEGATIVE_X_OES +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_ARB GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_OES +#define GL_TEXTURE_CUBE_MAP_POSITIVE_Z_ARB GL_TEXTURE_CUBE_MAP_POSITIVE_Z_OES +#define GL_TEXTURE_CUBE_MAP_POSITIVE_Y_ARB GL_TEXTURE_CUBE_MAP_POSITIVE_Y_OES +#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_ARB GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_OES + #else // *************************************************************************** diff --git a/code/nel/src/3d/driver/opengl/driver_opengl_vertex_program.cpp b/code/nel/src/3d/driver/opengl/driver_opengl_vertex_program.cpp index dc2a4243a..5392bcbdd 100644 --- a/code/nel/src/3d/driver/opengl/driver_opengl_vertex_program.cpp +++ b/code/nel/src/3d/driver/opengl/driver_opengl_vertex_program.cpp @@ -205,8 +205,8 @@ bool CDriverGL::activeNVVertexProgram (CVertexProgram *program) return false; } - // *************************************************************************** +#ifndef USE_OPENGLES static inline GLenum convSwizzleToGLFormat(CVPSwizzle::EComp comp, bool negate) { @@ -216,16 +216,11 @@ inline GLenum convSwizzleToGLFormat(CVPSwizzle::EComp comp, bool negate) { switch(comp) { -#ifdef USE_OPENGLES - case CVPSwizzle::X: return GL_TEXTURE_CUBE_MAP_POSITIVE_X_OES; - case CVPSwizzle::Y: return GL_TEXTURE_CUBE_MAP_POSITIVE_Y_OES; - case CVPSwizzle::Z: return GL_TEXTURE_CUBE_MAP_POSITIVE_Z_OES; -#else case CVPSwizzle::X: return GL_X_EXT; case CVPSwizzle::Y: return GL_Y_EXT; case CVPSwizzle::Z: return GL_Z_EXT; case CVPSwizzle::W: return GL_W_EXT; -#endif + default: nlstop; return 0; @@ -236,16 +231,11 @@ inline GLenum convSwizzleToGLFormat(CVPSwizzle::EComp comp, bool negate) { switch(comp) { -#ifdef USE_OPENGLES - case CVPSwizzle::X: return GL_TEXTURE_CUBE_MAP_NEGATIVE_X_OES; - case CVPSwizzle::Y: return GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_OES; - case CVPSwizzle::Z: return GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_OES; -#else case CVPSwizzle::X: return GL_NEGATIVE_X_EXT; case CVPSwizzle::Y: return GL_NEGATIVE_Y_EXT; case CVPSwizzle::Z: return GL_NEGATIVE_Z_EXT; case CVPSwizzle::W: return GL_NEGATIVE_W_EXT; -#endif + default: nlstop; return 0; @@ -253,6 +243,7 @@ inline GLenum convSwizzleToGLFormat(CVPSwizzle::EComp comp, bool negate) } } } +#endif // *************************************************************************** /** Convert an output register to a EXTVertexShader register diff --git a/code/nel/src/3d/fasthls_modifier.cpp b/code/nel/src/3d/fasthls_modifier.cpp index 3203587c0..5195ddb5a 100644 --- a/code/nel/src/3d/fasthls_modifier.cpp +++ b/code/nel/src/3d/fasthls_modifier.cpp @@ -109,7 +109,7 @@ CRGBA CFastHLSModifier::convert(uint H, uint L, uint S) return col; } -#if defined(NL_COMP_VC71) || defined(NL_COMP_VC8) || defined(NL_COMP_VC9) || defined(NL_COMP_VC10) +#if defined(NL_COMP_VC) && NL_COMP_VC_VERSION >= 71 # pragma warning( push ) # pragma warning( disable : 4799 ) #endif @@ -262,7 +262,7 @@ uint16 CFastHLSModifier::applyHLSMod(uint16 colorIn, uint8 dHue, uint dLum, uin #pragma managed(pop) #endif -#if defined(NL_COMP_VC71) || defined(NL_COMP_VC8) || defined(NL_COMP_VC9) || defined(NL_COMP_VC10) +#if defined(NL_COMP_VC) && NL_COMP_VC_VERSION >= 71 # pragma warning( pop ) #endif diff --git a/code/nel/src/3d/zone.cpp b/code/nel/src/3d/zone.cpp index b075e477e..4acca80f5 100644 --- a/code/nel/src/3d/zone.cpp +++ b/code/nel/src/3d/zone.cpp @@ -127,7 +127,7 @@ void CZone::build(const CZoneInfo &zoneInfo, uint32 numVertices) // Compute the bbox and the bias/scale. //===================================== CAABBox bb; - if(patchs.size()) + if(!patchs.empty()) bb.setCenter(patchs[0].Patch.Vertices[0]); bb.setHalfSize(CVector::Null); for(j=0;j<(sint)patchs.size();j++) diff --git a/code/nel/src/misc/aabbox.cpp b/code/nel/src/misc/aabbox.cpp index 6e1a9e428..3636552d1 100644 --- a/code/nel/src/misc/aabbox.cpp +++ b/code/nel/src/misc/aabbox.cpp @@ -21,6 +21,10 @@ #include "nel/misc/bsphere.h" #include "nel/misc/matrix.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/algo.cpp b/code/nel/src/misc/algo.cpp index 71fd14347..6a3ef62dd 100644 --- a/code/nel/src/misc/algo.cpp +++ b/code/nel/src/misc/algo.cpp @@ -21,6 +21,9 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/app_context.cpp b/code/nel/src/misc/app_context.cpp index 1213a6559..a0b35b35a 100644 --- a/code/nel/src/misc/app_context.cpp +++ b/code/nel/src/misc/app_context.cpp @@ -19,6 +19,10 @@ #include "nel/misc/dynloadlib.h" #include "nel/misc/command.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/async_file_manager.cpp b/code/nel/src/misc/async_file_manager.cpp index b9be77f45..366237722 100644 --- a/code/nel/src/misc/async_file_manager.cpp +++ b/code/nel/src/misc/async_file_manager.cpp @@ -23,6 +23,10 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/big_file.cpp b/code/nel/src/misc/big_file.cpp index e2d64d052..f5ee067f4 100644 --- a/code/nel/src/misc/big_file.cpp +++ b/code/nel/src/misc/big_file.cpp @@ -22,6 +22,9 @@ using namespace std; using namespace NLMISC; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/bit_mem_stream.cpp b/code/nel/src/misc/bit_mem_stream.cpp index c8ae37163..ed282786e 100644 --- a/code/nel/src/misc/bit_mem_stream.cpp +++ b/code/nel/src/misc/bit_mem_stream.cpp @@ -25,6 +25,9 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/bit_set.cpp b/code/nel/src/misc/bit_set.cpp index c19b8d35d..79eda0c13 100644 --- a/code/nel/src/misc/bit_set.cpp +++ b/code/nel/src/misc/bit_set.cpp @@ -20,6 +20,9 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/bitmap.cpp b/code/nel/src/misc/bitmap.cpp index aa426d47a..cfe8cab89 100644 --- a/code/nel/src/misc/bitmap.cpp +++ b/code/nel/src/misc/bitmap.cpp @@ -26,6 +26,9 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/bitmap_jpeg.cpp b/code/nel/src/misc/bitmap_jpeg.cpp index cae1f9700..799d659d6 100644 --- a/code/nel/src/misc/bitmap_jpeg.cpp +++ b/code/nel/src/misc/bitmap_jpeg.cpp @@ -32,6 +32,9 @@ extern "C" using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/bitmap_png.cpp b/code/nel/src/misc/bitmap_png.cpp index 768619e76..cea0b7d0c 100644 --- a/code/nel/src/misc/bitmap_png.cpp +++ b/code/nel/src/misc/bitmap_png.cpp @@ -27,6 +27,9 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/block_memory.cpp b/code/nel/src/misc/block_memory.cpp index d6abdffe6..d7c8e445c 100644 --- a/code/nel/src/misc/block_memory.cpp +++ b/code/nel/src/misc/block_memory.cpp @@ -21,6 +21,9 @@ // remove stupid VC6 warnings void foo_block_memory_cpp() {} +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/bsphere.cpp b/code/nel/src/misc/bsphere.cpp index 8e3494514..1fcf359e7 100644 --- a/code/nel/src/misc/bsphere.cpp +++ b/code/nel/src/misc/bsphere.cpp @@ -21,6 +21,9 @@ using namespace NLMISC; using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/buf_fifo.cpp b/code/nel/src/misc/buf_fifo.cpp index 2f39bd098..6c377f078 100644 --- a/code/nel/src/misc/buf_fifo.cpp +++ b/code/nel/src/misc/buf_fifo.cpp @@ -26,6 +26,10 @@ using namespace std; // if 0, don't stat the time of different function #define STAT_FIFO 1 +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { #ifdef BUFFIFO_TRACK_ALL_BUFFERS diff --git a/code/nel/src/misc/class_id.cpp b/code/nel/src/misc/class_id.cpp index f89b33176..35a2e4b0e 100644 --- a/code/nel/src/misc/class_id.cpp +++ b/code/nel/src/misc/class_id.cpp @@ -23,6 +23,9 @@ #include "nel/misc/stream.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/class_registry.cpp b/code/nel/src/misc/class_registry.cpp index 74e3e24b9..91c603c90 100644 --- a/code/nel/src/misc/class_registry.cpp +++ b/code/nel/src/misc/class_registry.cpp @@ -17,9 +17,14 @@ #include "stdmisc.h" #include "nel/misc/class_registry.h" +#include "nel/misc/debug.h" using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/cmd_args.cpp b/code/nel/src/misc/cmd_args.cpp index c42473027..2ef32a6c9 100644 --- a/code/nel/src/misc/cmd_args.cpp +++ b/code/nel/src/misc/cmd_args.cpp @@ -24,6 +24,10 @@ #include "nel/misc/cmd_args.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/command.cpp b/code/nel/src/misc/command.cpp index 1fff9627b..30e3defe2 100644 --- a/code/nel/src/misc/command.cpp +++ b/code/nel/src/misc/command.cpp @@ -22,6 +22,10 @@ using namespace std; using namespace NLMISC; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { //ICommand::TCategorySet* ICommand::_Categories; diff --git a/code/nel/src/misc/cpu_time_stat.cpp b/code/nel/src/misc/cpu_time_stat.cpp index a1f9bc23f..861ab8e56 100644 --- a/code/nel/src/misc/cpu_time_stat.cpp +++ b/code/nel/src/misc/cpu_time_stat.cpp @@ -15,9 +15,10 @@ // along with this program. If not, see . #include "stdmisc.h" -#include "nel/misc/cpu_time_stat.h" +#include "nel/misc/cpu_time_stat.h" #include "nel/misc/common.h" +#include "nel/misc/debug.h" #ifdef NL_OS_UNIX #include @@ -27,6 +28,10 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/di_event_emitter.cpp b/code/nel/src/misc/di_event_emitter.cpp index c0894e381..8f41f6453 100644 --- a/code/nel/src/misc/di_event_emitter.cpp +++ b/code/nel/src/misc/di_event_emitter.cpp @@ -28,7 +28,9 @@ #ifdef NL_OS_WINDOWS - +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/di_game_device.cpp b/code/nel/src/misc/di_game_device.cpp index 22a9d57fd..6574b5cde 100644 --- a/code/nel/src/misc/di_game_device.cpp +++ b/code/nel/src/misc/di_game_device.cpp @@ -21,6 +21,10 @@ #ifdef NL_OS_WINDOWS +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/di_keyboard_device.cpp b/code/nel/src/misc/di_keyboard_device.cpp index dffc1f4da..0802019a4 100644 --- a/code/nel/src/misc/di_keyboard_device.cpp +++ b/code/nel/src/misc/di_keyboard_device.cpp @@ -27,6 +27,10 @@ #include "Mmsystem.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/di_mouse_device.cpp b/code/nel/src/misc/di_mouse_device.cpp index cce2650dc..2dfcf95f0 100644 --- a/code/nel/src/misc/di_mouse_device.cpp +++ b/code/nel/src/misc/di_mouse_device.cpp @@ -23,6 +23,10 @@ #ifdef NL_OS_WINDOWS +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/diff_tool.cpp b/code/nel/src/misc/diff_tool.cpp index 9422e2a79..15a91cdb8 100644 --- a/code/nel/src/misc/diff_tool.cpp +++ b/code/nel/src/misc/diff_tool.cpp @@ -22,6 +22,9 @@ using namespace NLMISC; using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace STRING_MANAGER { diff --git a/code/nel/src/misc/dummy_window.cpp b/code/nel/src/misc/dummy_window.cpp index 90c36d55b..a0d807ac5 100644 --- a/code/nel/src/misc/dummy_window.cpp +++ b/code/nel/src/misc/dummy_window.cpp @@ -21,6 +21,10 @@ #ifdef NL_OS_WINDOWS +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/dynloadlib.cpp b/code/nel/src/misc/dynloadlib.cpp index 7153643fc..6dcb7e4cf 100644 --- a/code/nel/src/misc/dynloadlib.cpp +++ b/code/nel/src/misc/dynloadlib.cpp @@ -21,6 +21,10 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/eid_translator.cpp b/code/nel/src/misc/eid_translator.cpp index 710acb440..acf4046e5 100644 --- a/code/nel/src/misc/eid_translator.cpp +++ b/code/nel/src/misc/eid_translator.cpp @@ -31,6 +31,10 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { // diff --git a/code/nel/src/misc/entity_id.cpp b/code/nel/src/misc/entity_id.cpp index b90a25ea3..b62bf1f1c 100644 --- a/code/nel/src/misc/entity_id.cpp +++ b/code/nel/src/misc/entity_id.cpp @@ -20,6 +20,10 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { const uint64 CEntityId::MaxEntityId = ((uint64)1 << (CEntityId::ID_SIZE + 1)) - (uint64)1; diff --git a/code/nel/src/misc/eval_num_expr.cpp b/code/nel/src/misc/eval_num_expr.cpp index de7f3b2bf..c47309498 100644 --- a/code/nel/src/misc/eval_num_expr.cpp +++ b/code/nel/src/misc/eval_num_expr.cpp @@ -17,6 +17,11 @@ #include "stdmisc.h" #include "nel/misc/eval_num_expr.h" +#include "nel/misc/debug.h" + +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/event_emitter.cpp b/code/nel/src/misc/event_emitter.cpp index 946efd75c..0cf3aad72 100644 --- a/code/nel/src/misc/event_emitter.cpp +++ b/code/nel/src/misc/event_emitter.cpp @@ -19,6 +19,10 @@ // remove stupid VC6 warnings void foo_event_emitter_cpp() {} +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/event_emitter_multi.cpp b/code/nel/src/misc/event_emitter_multi.cpp index f119601f5..52bc235cd 100644 --- a/code/nel/src/misc/event_emitter_multi.cpp +++ b/code/nel/src/misc/event_emitter_multi.cpp @@ -18,6 +18,10 @@ #include "nel/misc/event_emitter_multi.h" #include "nel/misc/system_utils.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/event_listener.cpp b/code/nel/src/misc/event_listener.cpp index 1b8b29017..14bb5d73d 100644 --- a/code/nel/src/misc/event_listener.cpp +++ b/code/nel/src/misc/event_listener.cpp @@ -20,6 +20,9 @@ #include "nel/misc/event_server.h" #include "nel/misc/events.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/event_server.cpp b/code/nel/src/misc/event_server.cpp index 21ed8c576..eceb783fe 100644 --- a/code/nel/src/misc/event_server.cpp +++ b/code/nel/src/misc/event_server.cpp @@ -21,6 +21,9 @@ #include "nel/misc/event_emitter.h" #include "nel/misc/events.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/events.cpp b/code/nel/src/misc/events.cpp index 1d88be177..daa651ed7 100644 --- a/code/nel/src/misc/events.cpp +++ b/code/nel/src/misc/events.cpp @@ -19,6 +19,9 @@ #include "nel/misc/events.h" #include "nel/misc/string_conversion.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/fast_floor.cpp b/code/nel/src/misc/fast_floor.cpp index 614ad3474..29411492b 100644 --- a/code/nel/src/misc/fast_floor.cpp +++ b/code/nel/src/misc/fast_floor.cpp @@ -18,6 +18,10 @@ #include "nel/misc/fast_floor.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { int OptFastFloorCWStack[OptFastFloorCWStackSize]; diff --git a/code/nel/src/misc/fast_id_map.cpp b/code/nel/src/misc/fast_id_map.cpp index 3d434066c..5ba919b09 100644 --- a/code/nel/src/misc/fast_id_map.cpp +++ b/code/nel/src/misc/fast_id_map.cpp @@ -35,6 +35,10 @@ // Project includes +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { void dummytoavoidthecompilerwarningfastidmap() { } diff --git a/code/nel/src/misc/fast_mem.cpp b/code/nel/src/misc/fast_mem.cpp index 6d7ca97ff..c957195b3 100644 --- a/code/nel/src/misc/fast_mem.cpp +++ b/code/nel/src/misc/fast_mem.cpp @@ -19,6 +19,9 @@ #include "nel/misc/fast_mem.h" #include "nel/misc/system_info.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/file.cpp b/code/nel/src/misc/file.cpp index 4c8501a17..842d9ea51 100644 --- a/code/nel/src/misc/file.cpp +++ b/code/nel/src/misc/file.cpp @@ -15,9 +15,7 @@ // along with this program. If not, see . #include "stdmisc.h" -#ifndef NL_OS_WINDOWS -#include -#endif + #include "nel/misc/file.h" #include "nel/misc/debug.h" #include "nel/misc/big_file.h" @@ -26,10 +24,18 @@ #include "nel/misc/sstring.h" #include "nel/misc/xml_pack.h" +#ifndef NL_OS_WINDOWS +#include +#endif + using namespace std; #define NLMISC_DONE_FILE_OPENED 40 +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/game_device.cpp b/code/nel/src/misc/game_device.cpp index ee0924a1a..2ba49367f 100644 --- a/code/nel/src/misc/game_device.cpp +++ b/code/nel/src/misc/game_device.cpp @@ -17,6 +17,10 @@ #include "stdmisc.h" #include "nel/misc/game_device.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/game_device_events.cpp b/code/nel/src/misc/game_device_events.cpp index 59cc115d5..bf64a1c4b 100644 --- a/code/nel/src/misc/game_device_events.cpp +++ b/code/nel/src/misc/game_device_events.cpp @@ -18,6 +18,10 @@ #include "nel/misc/game_device_events.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/geom_ext.cpp b/code/nel/src/misc/geom_ext.cpp index 0b1735099..32dba1d60 100644 --- a/code/nel/src/misc/geom_ext.cpp +++ b/code/nel/src/misc/geom_ext.cpp @@ -24,6 +24,10 @@ void dummyToAvoidStupidCompilerWarning_misc_geom_ext_cpp() { } +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/grid_traversal.cpp b/code/nel/src/misc/grid_traversal.cpp index 19e59e7c2..a88267331 100644 --- a/code/nel/src/misc/grid_traversal.cpp +++ b/code/nel/src/misc/grid_traversal.cpp @@ -19,6 +19,10 @@ #include "nel/misc/grid_traversal.h" #include "nel/misc/vector_2f.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/gtk_displayer.cpp b/code/nel/src/misc/gtk_displayer.cpp index d348bab79..f558a4909 100644 --- a/code/nel/src/misc/gtk_displayer.cpp +++ b/code/nel/src/misc/gtk_displayer.cpp @@ -15,6 +15,7 @@ // along with this program. If not, see . #include "stdmisc.h" +#include "nel/misc/gtk_displayer.h" #ifdef NL_USE_GTK @@ -35,10 +36,12 @@ #include "nel/misc/command.h" #include "nel/misc/thread.h" -#include "nel/misc/gtk_displayer.h" - using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { // diff --git a/code/nel/src/misc/hierarchical_timer.cpp b/code/nel/src/misc/hierarchical_timer.cpp index 9d3c40c44..62dc0786a 100644 --- a/code/nel/src/misc/hierarchical_timer.cpp +++ b/code/nel/src/misc/hierarchical_timer.cpp @@ -26,6 +26,10 @@ #include "nel/misc/time_nl.h" #endif +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/i18n.cpp b/code/nel/src/misc/i18n.cpp index c68b190c5..cf1803c76 100644 --- a/code/nel/src/misc/i18n.cpp +++ b/code/nel/src/misc/i18n.cpp @@ -22,6 +22,10 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { CI18N::StrMapContainer CI18N::_StrMap; diff --git a/code/nel/src/misc/i_xml.cpp b/code/nel/src/misc/i_xml.cpp index 6cd675ace..d8925ddef 100644 --- a/code/nel/src/misc/i_xml.cpp +++ b/code/nel/src/misc/i_xml.cpp @@ -28,6 +28,10 @@ using namespace std; #define NLMISC_READ_BUFFER_SIZE 1024 +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/input_device.cpp b/code/nel/src/misc/input_device.cpp index 03e8f8c39..3825935a6 100644 --- a/code/nel/src/misc/input_device.cpp +++ b/code/nel/src/misc/input_device.cpp @@ -20,6 +20,10 @@ // remove stupid VC6 warnings void foo_input_device_cpp() {} +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/input_device_server.cpp b/code/nel/src/misc/input_device_server.cpp index 2b713d836..253b68e71 100644 --- a/code/nel/src/misc/input_device_server.cpp +++ b/code/nel/src/misc/input_device_server.cpp @@ -15,10 +15,14 @@ // along with this program. If not, see . #include "stdmisc.h" + #include "nel/misc/input_device_server.h" #include "nel/misc/input_device.h" +#include "nel/misc/debug.h" - +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/inter_window_msg_queue.cpp b/code/nel/src/misc/inter_window_msg_queue.cpp index 2526f1449..77e72e654 100644 --- a/code/nel/src/misc/inter_window_msg_queue.cpp +++ b/code/nel/src/misc/inter_window_msg_queue.cpp @@ -16,12 +16,16 @@ #include "stdmisc.h" -#ifdef NL_OS_WINDOWS #include "nel/misc/inter_window_msg_queue.h" -// + +#ifdef NL_OS_WINDOWS #include "nel/misc/mem_stream.h" #include "nel/misc/shared_memory.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/keyboard_device.cpp b/code/nel/src/misc/keyboard_device.cpp index 3fc0e07a1..4c7f353bc 100644 --- a/code/nel/src/misc/keyboard_device.cpp +++ b/code/nel/src/misc/keyboard_device.cpp @@ -18,6 +18,9 @@ //#include "nel/3d/u_keyboard_device.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NL3D { diff --git a/code/nel/src/misc/line.cpp b/code/nel/src/misc/line.cpp index b8148dfb5..aba33734c 100644 --- a/code/nel/src/misc/line.cpp +++ b/code/nel/src/misc/line.cpp @@ -18,6 +18,10 @@ #include "nel/misc/line.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/matrix.cpp b/code/nel/src/misc/matrix.cpp index 6fac71aa2..dd884f4d5 100644 --- a/code/nel/src/misc/matrix.cpp +++ b/code/nel/src/misc/matrix.cpp @@ -23,6 +23,9 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/md5.cpp b/code/nel/src/misc/md5.cpp index 363bc09f4..eaf9df6cc 100644 --- a/code/nel/src/misc/md5.cpp +++ b/code/nel/src/misc/md5.cpp @@ -52,6 +52,10 @@ documentation and/or software. using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { // **************************************************************************** diff --git a/code/nel/src/misc/mem_displayer.cpp b/code/nel/src/misc/mem_displayer.cpp index 1dc156913..52d399350 100644 --- a/code/nel/src/misc/mem_displayer.cpp +++ b/code/nel/src/misc/mem_displayer.cpp @@ -37,6 +37,10 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/mem_stream.cpp b/code/nel/src/misc/mem_stream.cpp index 7396dbbab..49e19f523 100644 --- a/code/nel/src/misc/mem_stream.cpp +++ b/code/nel/src/misc/mem_stream.cpp @@ -18,6 +18,10 @@ #include "nel/misc/mem_stream.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/mouse_smoother.cpp b/code/nel/src/misc/mouse_smoother.cpp index e8389119d..a92cbca6e 100644 --- a/code/nel/src/misc/mouse_smoother.cpp +++ b/code/nel/src/misc/mouse_smoother.cpp @@ -17,6 +17,10 @@ #include "stdmisc.h" #include "nel/misc/mouse_smoother.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/mutex.cpp b/code/nel/src/misc/mutex.cpp index fb337fab6..f8a75d2ea 100644 --- a/code/nel/src/misc/mutex.cpp +++ b/code/nel/src/misc/mutex.cpp @@ -22,6 +22,7 @@ #include "nel/misc/mutex.h" #include "nel/misc/time_nl.h" +#include "nel/misc/debug.h" using namespace std; @@ -47,6 +48,9 @@ using namespace std; #define NOMINMAX #include +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/noise_value.cpp b/code/nel/src/misc/noise_value.cpp index 5b6507be3..28fe24001 100644 --- a/code/nel/src/misc/noise_value.cpp +++ b/code/nel/src/misc/noise_value.cpp @@ -20,6 +20,9 @@ #include "nel/misc/fast_floor.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/o_xml.cpp b/code/nel/src/misc/o_xml.cpp index 1bd5d3d7b..005ef8000 100644 --- a/code/nel/src/misc/o_xml.cpp +++ b/code/nel/src/misc/o_xml.cpp @@ -25,6 +25,10 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/object_vector.cpp b/code/nel/src/misc/object_vector.cpp index c547dfc8d..7a863342b 100644 --- a/code/nel/src/misc/object_vector.cpp +++ b/code/nel/src/misc/object_vector.cpp @@ -23,6 +23,9 @@ void dummyToAvoidStupidCompilerWarning_misc_object_vector_cpp() { } +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/p_thread.cpp b/code/nel/src/misc/p_thread.cpp index ab5530342..e4deab4ca 100644 --- a/code/nel/src/misc/p_thread.cpp +++ b/code/nel/src/misc/p_thread.cpp @@ -24,6 +24,10 @@ #include #include +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { /* Key for thread specific storage holding IThread pointer. */ diff --git a/code/nel/src/misc/path.cpp b/code/nel/src/misc/path.cpp index bcef9bdeb..c59aabf0c 100644 --- a/code/nel/src/misc/path.cpp +++ b/code/nel/src/misc/path.cpp @@ -17,8 +17,8 @@ #include "stdmisc.h" -#include "nel/misc/big_file.h" #include "nel/misc/path.h" +#include "nel/misc/big_file.h" #include "nel/misc/hierarchical_timer.h" #include "nel/misc/progress_callback.h" #include "nel/misc/file.h" @@ -48,6 +48,10 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { // diff --git a/code/nel/src/misc/plane.cpp b/code/nel/src/misc/plane.cpp index 505a5cb62..7da917459 100644 --- a/code/nel/src/misc/plane.cpp +++ b/code/nel/src/misc/plane.cpp @@ -19,6 +19,9 @@ #include "nel/misc/plane.h" #include "nel/misc/uv.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/polygon.cpp b/code/nel/src/misc/polygon.cpp index 2942fb66b..b541d2eba 100644 --- a/code/nel/src/misc/polygon.cpp +++ b/code/nel/src/misc/polygon.cpp @@ -24,6 +24,9 @@ using namespace std; using namespace NLMISC; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/progress_callback.cpp b/code/nel/src/misc/progress_callback.cpp index 965f25ec1..c4d4841ea 100644 --- a/code/nel/src/misc/progress_callback.cpp +++ b/code/nel/src/misc/progress_callback.cpp @@ -15,8 +15,13 @@ // along with this program. If not, see . #include "stdmisc.h" + #include "nel/misc/progress_callback.h" +#include "nel/misc/debug.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/quad.cpp b/code/nel/src/misc/quad.cpp index 6486bb5c1..8fced3318 100644 --- a/code/nel/src/misc/quad.cpp +++ b/code/nel/src/misc/quad.cpp @@ -24,6 +24,10 @@ void dummyToAvoidStupidCompilerWarning_misc_quad_cpp() { } +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/quat.cpp b/code/nel/src/misc/quat.cpp index 950870842..c1b441df9 100644 --- a/code/nel/src/misc/quat.cpp +++ b/code/nel/src/misc/quat.cpp @@ -18,6 +18,9 @@ #include "nel/misc/quat.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/reader_writer.cpp b/code/nel/src/misc/reader_writer.cpp index 22019aaa3..57c5c517d 100644 --- a/code/nel/src/misc/reader_writer.cpp +++ b/code/nel/src/misc/reader_writer.cpp @@ -18,6 +18,9 @@ #include "nel/misc/reader_writer.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/rect.cpp b/code/nel/src/misc/rect.cpp index 40acd9456..d4347b7e9 100644 --- a/code/nel/src/misc/rect.cpp +++ b/code/nel/src/misc/rect.cpp @@ -19,6 +19,9 @@ #include "nel/misc/rect.h" #include "nel/misc/vector_2f.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/report.cpp b/code/nel/src/misc/report.cpp index cf60f3441..64871e6a3 100644 --- a/code/nel/src/misc/report.cpp +++ b/code/nel/src/misc/report.cpp @@ -33,6 +33,10 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/rgba.cpp b/code/nel/src/misc/rgba.cpp index 1d7a88f6b..8075d78b2 100644 --- a/code/nel/src/misc/rgba.cpp +++ b/code/nel/src/misc/rgba.cpp @@ -21,6 +21,9 @@ #include "nel/misc/system_info.h" #include "nel/misc/common.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/sha1.cpp b/code/nel/src/misc/sha1.cpp index 64c94ee6f..19e8a440a 100644 --- a/code/nel/src/misc/sha1.cpp +++ b/code/nel/src/misc/sha1.cpp @@ -31,6 +31,10 @@ using namespace std; using namespace NLMISC; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + // // Types // diff --git a/code/nel/src/misc/shared_memory.cpp b/code/nel/src/misc/shared_memory.cpp index 544ba882a..2a7f85a8b 100644 --- a/code/nel/src/misc/shared_memory.cpp +++ b/code/nel/src/misc/shared_memory.cpp @@ -15,7 +15,9 @@ // along with this program. If not, see . #include "stdmisc.h" + #include "nel/misc/shared_memory.h" +#include "nel/misc/debug.h" #ifdef NL_OS_WINDOWS # define NOMINMAX @@ -28,6 +30,9 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/sheet_id.cpp b/code/nel/src/misc/sheet_id.cpp index 9a9b8813f..7bc9c7c61 100644 --- a/code/nel/src/misc/sheet_id.cpp +++ b/code/nel/src/misc/sheet_id.cpp @@ -29,6 +29,10 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { CSheetId::CChar CSheetId::_AllStrings; diff --git a/code/nel/src/misc/smart_ptr.cpp b/code/nel/src/misc/smart_ptr.cpp index a85edfbe9..e5c31fcd7 100644 --- a/code/nel/src/misc/smart_ptr.cpp +++ b/code/nel/src/misc/smart_ptr.cpp @@ -18,6 +18,9 @@ #include "nel/misc/smart_ptr.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/stl_block_allocator.cpp b/code/nel/src/misc/stl_block_allocator.cpp index 3b519f736..f57d0c238 100644 --- a/code/nel/src/misc/stl_block_allocator.cpp +++ b/code/nel/src/misc/stl_block_allocator.cpp @@ -21,6 +21,9 @@ // remove stupid VC6 warnings void foo_stl_block_allocator_cpp() {} +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/stl_block_list.cpp b/code/nel/src/misc/stl_block_list.cpp index a4474d65f..628b79371 100644 --- a/code/nel/src/misc/stl_block_list.cpp +++ b/code/nel/src/misc/stl_block_list.cpp @@ -21,6 +21,10 @@ // remove stupid VC6 warnings void foo_stl_block_list_cpp() {} +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/stop_watch.cpp b/code/nel/src/misc/stop_watch.cpp index 420f29914..59b62150e 100644 --- a/code/nel/src/misc/stop_watch.cpp +++ b/code/nel/src/misc/stop_watch.cpp @@ -20,6 +20,10 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/stream.cpp b/code/nel/src/misc/stream.cpp index e592e4d4a..c652d6fe9 100644 --- a/code/nel/src/misc/stream.cpp +++ b/code/nel/src/misc/stream.cpp @@ -21,6 +21,9 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/string_common.cpp b/code/nel/src/misc/string_common.cpp index f06258893..dd8d1fe96 100644 --- a/code/nel/src/misc/string_common.cpp +++ b/code/nel/src/misc/string_common.cpp @@ -20,6 +20,10 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/string_id_array.cpp b/code/nel/src/misc/string_id_array.cpp index 5dfc5d318..b9489e3f9 100644 --- a/code/nel/src/misc/string_id_array.cpp +++ b/code/nel/src/misc/string_id_array.cpp @@ -24,6 +24,10 @@ void dummyToAvoidStupidCompilerWarning_misc_string_id_array_cpp() { } +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/string_mapper.cpp b/code/nel/src/misc/string_mapper.cpp index 9b896f206..cf8a38e49 100644 --- a/code/nel/src/misc/string_mapper.cpp +++ b/code/nel/src/misc/string_mapper.cpp @@ -20,6 +20,10 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/system_info.cpp b/code/nel/src/misc/system_info.cpp index a6c1c4bf3..7ef96ec58 100644 --- a/code/nel/src/misc/system_info.cpp +++ b/code/nel/src/misc/system_info.cpp @@ -16,6 +16,8 @@ #include "stdmisc.h" +#include "nel/misc/system_info.h" + #ifdef NL_OS_WINDOWS # define NOMINMAX # include @@ -42,6 +44,10 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { #ifdef NL_OS_UNIX diff --git a/code/nel/src/misc/system_utils.cpp b/code/nel/src/misc/system_utils.cpp index c62f0b46d..c60364741 100644 --- a/code/nel/src/misc/system_utils.cpp +++ b/code/nel/src/misc/system_utils.cpp @@ -28,6 +28,10 @@ #endif #endif +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + using namespace std; // Key in registry diff --git a/code/nel/src/misc/task_manager.cpp b/code/nel/src/misc/task_manager.cpp index 13af3e4ac..4cdb16bd0 100644 --- a/code/nel/src/misc/task_manager.cpp +++ b/code/nel/src/misc/task_manager.cpp @@ -23,6 +23,10 @@ using namespace std; #define NLMISC_DONE_TASK_SIZE 20 +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { /* diff --git a/code/nel/src/misc/tds.cpp b/code/nel/src/misc/tds.cpp index bfc3b6af0..13105f98d 100644 --- a/code/nel/src/misc/tds.cpp +++ b/code/nel/src/misc/tds.cpp @@ -17,12 +17,17 @@ #include "stdmisc.h" #include "nel/misc/tds.h" +#include "nel/misc/debug.h" #ifdef NL_OS_WINDOWS # define NOMINMAX # include #endif // NL_OS_WINDOWS +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/time_nl.cpp b/code/nel/src/misc/time_nl.cpp index 422ba192f..0ba60c8e2 100644 --- a/code/nel/src/misc/time_nl.cpp +++ b/code/nel/src/misc/time_nl.cpp @@ -16,6 +16,10 @@ #include "stdmisc.h" +#include "nel/misc/time_nl.h" +#include "nel/misc/sstring.h" +#include "nel/misc/thread.h" + #ifdef NL_OS_WINDOWS # define NOMINMAX # include @@ -29,10 +33,9 @@ #include #endif -#include "nel/misc/time_nl.h" -#include "nel/misc/sstring.h" - -#include +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/triangle.cpp b/code/nel/src/misc/triangle.cpp index 3fcde2ec9..234eb0506 100644 --- a/code/nel/src/misc/triangle.cpp +++ b/code/nel/src/misc/triangle.cpp @@ -20,6 +20,9 @@ #include "nel/misc/plane.h" #include "nel/misc/matrix.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/unicode.cpp b/code/nel/src/misc/unicode.cpp index ac58580ee..00bf6a226 100644 --- a/code/nel/src/misc/unicode.cpp +++ b/code/nel/src/misc/unicode.cpp @@ -17,6 +17,10 @@ #include "stdmisc.h" #include "nel/misc/ucstring.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/uv.cpp b/code/nel/src/misc/uv.cpp index f25643300..9926efcc7 100644 --- a/code/nel/src/misc/uv.cpp +++ b/code/nel/src/misc/uv.cpp @@ -24,6 +24,10 @@ void dummyToAvoidStupidCompilerWarning_misc_uv_cpp() { } +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/variable.cpp b/code/nel/src/misc/variable.cpp index 48c775c9c..16953f990 100644 --- a/code/nel/src/misc/variable.cpp +++ b/code/nel/src/misc/variable.cpp @@ -21,6 +21,10 @@ using namespace std; using namespace NLMISC; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/vector.cpp b/code/nel/src/misc/vector.cpp index 7230a75c6..dc64925b7 100644 --- a/code/nel/src/misc/vector.cpp +++ b/code/nel/src/misc/vector.cpp @@ -20,6 +20,9 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/vector_2d.cpp b/code/nel/src/misc/vector_2d.cpp index 5ab0ffdec..939e41239 100644 --- a/code/nel/src/misc/vector_2d.cpp +++ b/code/nel/src/misc/vector_2d.cpp @@ -24,6 +24,10 @@ void dummyToAvoidStupidCompilerWarning_misc_vector_2d_cpp() { } +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/vector_2f.cpp b/code/nel/src/misc/vector_2f.cpp index 0e9621601..08bd0d096 100644 --- a/code/nel/src/misc/vector_2f.cpp +++ b/code/nel/src/misc/vector_2f.cpp @@ -18,6 +18,9 @@ #include "nel/misc/vector_2f.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/vector_h.cpp b/code/nel/src/misc/vector_h.cpp index 528f5f4cc..67eb41f6b 100644 --- a/code/nel/src/misc/vector_h.cpp +++ b/code/nel/src/misc/vector_h.cpp @@ -24,6 +24,10 @@ void dummyToAvoidStupidCompilerWarning_misc_vector_h_cpp() { } +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/vectord.cpp b/code/nel/src/misc/vectord.cpp index 1273f190a..aa14a3828 100644 --- a/code/nel/src/misc/vectord.cpp +++ b/code/nel/src/misc/vectord.cpp @@ -18,6 +18,9 @@ #include "nel/misc/vectord.h" +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/win32_util.cpp b/code/nel/src/misc/win32_util.cpp index 17601797b..63315e1b2 100644 --- a/code/nel/src/misc/win32_util.cpp +++ b/code/nel/src/misc/win32_util.cpp @@ -22,6 +22,10 @@ #include +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { diff --git a/code/nel/src/misc/win_displayer.cpp b/code/nel/src/misc/win_displayer.cpp index d016b4106..f5c0d9545 100644 --- a/code/nel/src/misc/win_displayer.cpp +++ b/code/nel/src/misc/win_displayer.cpp @@ -15,6 +15,7 @@ // along with this program. If not, see . #include "stdmisc.h" +#include "nel/misc/win_displayer.h" #ifdef NL_OS_WINDOWS @@ -33,10 +34,12 @@ #include "nel/misc/thread.h" #include "nel/misc/ucstring.h" -#include "nel/misc/win_displayer.h" - using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { static CHARFORMAT2 CharFormat; diff --git a/code/nel/src/misc/win_event_emitter.cpp b/code/nel/src/misc/win_event_emitter.cpp index cf3ff2197..b330d7e57 100644 --- a/code/nel/src/misc/win_event_emitter.cpp +++ b/code/nel/src/misc/win_event_emitter.cpp @@ -32,6 +32,9 @@ */ #include +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/misc/win_thread.cpp b/code/nel/src/misc/win_thread.cpp index eec462d3c..d90d081ff 100644 --- a/code/nel/src/misc/win_thread.cpp +++ b/code/nel/src/misc/win_thread.cpp @@ -15,16 +15,20 @@ // along with this program. If not, see . #include "stdmisc.h" +#include "nel/misc/win_thread.h" #ifdef NL_OS_WINDOWS -#include "nel/misc/win_thread.h" #include "nel/misc/path.h" #define NOMINMAX #include #include +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { CWinThread MainThread ((void*)GetCurrentThread (), GetCurrentThreadId()); diff --git a/code/nel/src/misc/window_displayer.cpp b/code/nel/src/misc/window_displayer.cpp index f54c82505..5c9227933 100644 --- a/code/nel/src/misc/window_displayer.cpp +++ b/code/nel/src/misc/window_displayer.cpp @@ -24,6 +24,10 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { class CUpdateThread : public IRunnable diff --git a/code/nel/src/misc/words_dictionary.cpp b/code/nel/src/misc/words_dictionary.cpp index f35c41abe..e2113e62d 100644 --- a/code/nel/src/misc/words_dictionary.cpp +++ b/code/nel/src/misc/words_dictionary.cpp @@ -25,6 +25,10 @@ using namespace std; const string DefaultColTitle = "name"; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif + namespace NLMISC { NL_INSTANCE_COUNTER_IMPL(CWordsDictionary); diff --git a/code/nel/src/misc/xml_pack.cpp b/code/nel/src/misc/xml_pack.cpp index feab06775..4494be062 100644 --- a/code/nel/src/misc/xml_pack.cpp +++ b/code/nel/src/misc/xml_pack.cpp @@ -20,6 +20,9 @@ using namespace std; +#ifdef DEBUG_NEW + #define new DEBUG_NEW +#endif namespace NLMISC { diff --git a/code/nel/src/net/login_server.cpp b/code/nel/src/net/login_server.cpp index 736f0f7ef..5bd6dfd34 100644 --- a/code/nel/src/net/login_server.cpp +++ b/code/nel/src/net/login_server.cpp @@ -53,7 +53,7 @@ static string ListenAddr; static bool AcceptInvalidCookie = false; -static string DefaultUserPriv = ""; +static string DefaultUserPriv; static TDisconnectClientCallback DisconnectClientCallback = NULL; diff --git a/code/nel/src/sound/driver/openal/buffer_al.cpp b/code/nel/src/sound/driver/openal/buffer_al.cpp index 63a0a19d9..b63e39fa2 100644 --- a/code/nel/src/sound/driver/openal/buffer_al.cpp +++ b/code/nel/src/sound/driver/openal/buffer_al.cpp @@ -120,7 +120,7 @@ bool CBufferAL::unlock(uint size) // Error handling if (alGetError() == AL_NO_ERROR) - _IsLoaded = true; + _IsLoaded = true; // ->lock() set it to false return _IsLoaded; } @@ -161,8 +161,7 @@ bool CBufferAL::fill(const uint8 *src, uint size) alBufferData(_BufferName, _SampleFormat, src, size, _Frequency); // Error handling - if (alGetError() == AL_NO_ERROR) - _IsLoaded = true; + _IsLoaded = (alGetError() == AL_NO_ERROR); return _IsLoaded; } diff --git a/code/nel/src/sound/driver/openal/source_al.cpp b/code/nel/src/sound/driver/openal/source_al.cpp index 154bcebe1..1f8d2219f 100644 --- a/code/nel/src/sound/driver/openal/source_al.cpp +++ b/code/nel/src/sound/driver/openal/source_al.cpp @@ -162,6 +162,13 @@ void CSourceAL::submitStreamingBuffer(IBuffer *buffer) CBufferAL *bufferAL = static_cast(buffer); ALuint bufferName = bufferAL->bufferName(); nlassert(bufferName); + + if (!bufferAL->isBufferLoaded()) + { + nlwarning("AL: MUSICBUG: Streaming buffer was not loaded, skipping buffer. This should not happen."); + return; + } + alSourceQueueBuffers(_Source, 1, &bufferName); alTestError(); _QueuedBuffers.push(bufferAL); @@ -242,11 +249,31 @@ bool CSourceAL::play() else if (_IsStreaming) { _IsPaused = false; + /* NEW */ + // called by user as well as by code to resume after buffer underrun + if (!_IsPlaying) // set start time if not playing yet + _StartTime = CTime::getLocalTime(); + _IsPlaying = true; // this play always virtually succeed but may not actually be playing + if (_QueuedBuffers.size()) // ensure buffers have actually queued + { + alSourcePlay(_Source); + if (alGetError() != AL_NO_ERROR) + { + nlwarning("AL: MUSICBUG: Unknown error while trying to play streaming source."); + } + } + else + { + nlwarning("AL: MUSICBUG: Trying to play stream with no buffers queued."); + } + return true; + /* OLD alSourcePlay(_Source); _IsPlaying = (alGetError() == AL_NO_ERROR); if (_IsPlaying) _StartTime = CTime::getLocalTime(); // TODO: Played time should freeze when buffering fails, and be calculated based on the number of buffers played plus passed time. This is necessary for synchronizing animation with sound. return _IsPlaying; + */ // Streaming mode //nlwarning("AL: Cannot play null buffer; streaming not implemented" ); //nlstop; diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/CMakeLists.txt b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/CMakeLists.txt index 514657535..9f705e604 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/CMakeLists.txt +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/CMakeLists.txt @@ -47,3 +47,6 @@ ADD_DEFINITIONS(${LIBXML2_DEFINITIONS} -DQT_PLUGIN -DQT_SHARED ${QT_DEFINITIONS} INSTALL(TARGETS ovqt_plugin_georges_editor LIBRARY DESTINATION ${OVQT_PLUGIN_DIR} RUNTIME DESTINATION ${NL_BIN_PREFIX} ARCHIVE DESTINATION ${OVQT_PLUGIN_DIR} COMPONENT tools3d) INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/ovqt_plugin_georges_editor.xml DESTINATION ${OVQT_PLUGIN_SPECS_DIR} COMPONENT tools3d) +IF(WITH_PCH) + ADD_NATIVE_PRECOMPILED_HEADER(ovqt_plugin_georges_editor ${CMAKE_CURRENT_SOURCE_DIR}/stdpch.h ${CMAKE_CURRENT_SOURCE_DIR}/stdpch.cpp) +ENDIF(WITH_PCH) diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/expandable_headerview.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/expandable_headerview.cpp index 731fa8d16..cbe4bc0d7 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/expandable_headerview.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/expandable_headerview.cpp @@ -14,6 +14,7 @@ // You should have received a copy of the GNU Affero General Public License // along with this program. If not, see . +#include "stdpch.h" // Project includes #include "expandable_headerview.h" diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/formdelegate.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/formdelegate.cpp index 7cbfe9616..91f62c24b 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/formdelegate.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/formdelegate.cpp @@ -14,6 +14,7 @@ // You should have received a copy of the GNU Affero General Public License // along with this program. If not, see . +#include "stdpch.h" #include "formdelegate.h" // NeL includes diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/formitem.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/formitem.cpp index 950825e71..744bb58da 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/formitem.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/formitem.cpp @@ -14,6 +14,7 @@ // You should have received a copy of the GNU Affero General Public License // along with this program. If not, see . +#include "stdpch.h" #include "formitem.h" // Qt includes diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georges.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georges.cpp index b340869ad..ce577bfab 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georges.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georges.cpp @@ -14,6 +14,7 @@ // You should have received a copy of the GNU Affero General Public License // along with this program. If not, see . +#include "stdpch.h" #include "georges.h" #include "nel/misc/o_xml.h" diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georges_dirtree_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georges_dirtree_dialog.cpp index 264026b1f..0a467aac5 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georges_dirtree_dialog.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georges_dirtree_dialog.cpp @@ -14,6 +14,7 @@ // You should have received a copy of the GNU Affero General Public License // along with this program. If not, see . +#include "stdpch.h" // Project includes #include "georges_dirtree_dialog.h" diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georges_editor_form.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georges_editor_form.cpp index 5a3f5a625..6c46d4964 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georges_editor_form.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georges_editor_form.cpp @@ -15,6 +15,7 @@ // along with this program. If not, see . // Project includes +#include "stdpch.h" #include "georges_editor_form.h" #include "georges_editor_constants.h" #include "georges_dirtree_dialog.h" diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georges_editor_plugin.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georges_editor_plugin.cpp index ec20e6b35..075ac41b2 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georges_editor_plugin.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georges_editor_plugin.cpp @@ -15,6 +15,7 @@ // along with this program. If not, see . // Project includes +#include "stdpch.h" #include "georges_editor_plugin.h" #include "georges_editor_form.h" @@ -22,7 +23,7 @@ #include "../core/core_constants.h" // NeL includes -#include "nel/misc/debug.h" +#include // Qt includes #include diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georges_filesystem_model.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georges_filesystem_model.cpp index 762d79ff4..56a5856ae 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georges_filesystem_model.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georges_filesystem_model.cpp @@ -14,6 +14,7 @@ // You should have received a copy of the GNU Affero General Public License // along with this program. If not, see . +#include "stdpch.h" #include "georges_filesystem_model.h" #include diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georges_treeview_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georges_treeview_dialog.cpp index 2fe19ad02..0dda2c9a9 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georges_treeview_dialog.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georges_treeview_dialog.cpp @@ -14,7 +14,14 @@ // You should have received a copy of the GNU Affero General Public License // along with this program. If not, see . +#include "stdpch.h" #include "georges_treeview_dialog.h" +#include "georges.h" +#include "georgesform_model.h" +#include "georgesform_proxy_model.h" +#include "formitem.h" +#include "formdelegate.h" +#include "expandable_headerview.h" // Qt includes #include @@ -36,14 +43,6 @@ #include "../core/icore.h" #include "../core/core_constants.h" -// Project includes -#include "georges.h" -#include "georgesform_model.h" -#include "georgesform_proxy_model.h" -#include "formitem.h" -#include "formdelegate.h" -#include "expandable_headerview.h" - using namespace NLMISC; using namespace NLGEORGES; diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georgesform_model.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georgesform_model.cpp index 83548c7d3..dd0220bbf 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georgesform_model.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georgesform_model.cpp @@ -14,7 +14,9 @@ // You should have received a copy of the GNU Affero General Public License // along with this program. If not, see . +#include "stdpch.h" #include "georgesform_model.h" +#include "formitem.h" // NeL includes #include @@ -35,9 +37,6 @@ #include #include -// project includes -#include "formitem.h" - using namespace NLGEORGES; namespace GeorgesQt @@ -406,7 +405,7 @@ namespace GeorgesQt //uint value_uint; //sint value_sint; //double value_double; - QString elmtType = ""; + QString elmtType; UFormElm *elmt = 0; if(root->getNodeByName(&elmt, elmName.c_str(), whereN, true)) { @@ -428,13 +427,23 @@ namespace GeorgesQt switch (type->getType()) { case UType::UnsignedInt: - value = QString("%1").arg(QString("%1").arg(value.c_str()).toDouble()).toUtf8(); + { + uint v; + NLMISC::fromString(value, v); + value = NLMISC::toString(v); elmtType.append("_uint");break; + } case UType::SignedInt: - value = QString("%1").arg(QString("%1").arg(value.c_str()).toDouble()).toUtf8(); + { + sint v; + NLMISC::fromString(value, v); + value = NLMISC::toString(v); elmtType.append("_sint");break; + } case UType::Double: - value = QString("%1").arg(QString("%1").arg(value.c_str()).toDouble(),0,'f',1).toUtf8(); + float v; + NLMISC::fromString(value, v); + value = NLMISC::toString(v); elmtType.append("_double");break; case UType::String: elmtType.append("_string");break; @@ -569,7 +578,7 @@ namespace GeorgesQt { QList columnData; std::string value; - QString elmtType = ""; + QString elmtType; UFormElm *elmt = 0; if(root->getArrayNode(&elmt,0) && elmt) diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georgesform_proxy_model.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georgesform_proxy_model.cpp index 8b13ca8ba..2792699b0 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georgesform_proxy_model.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/georgesform_proxy_model.cpp @@ -14,15 +14,15 @@ // You should have received a copy of the GNU Affero General Public License // along with this program. If not, see . +#include "stdpch.h" +#include "georgesform_proxy_model.h" +#include "formitem.h" +#include "georgesform_model.h" + // NeL includes #include #include -// project includes -#include "formitem.h" -#include "georgesform_proxy_model.h" -#include "georgesform_model.h" - namespace GeorgesQt { diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/stdpch.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/stdpch.cpp new file mode 100644 index 000000000..85c10995f --- /dev/null +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/stdpch.cpp @@ -0,0 +1,17 @@ +// Object Viewer Qt - Georges Editor Plugin - MMORPG Framework +// Copyright (C) 2011 Adrian Jaekel +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as +// published by the Free Software Foundation, either version 3 of the +// License, or (at your option) any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with this program. If not, see . + +#include "stdpch.h" diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/stdpch.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/stdpch.h new file mode 100644 index 000000000..e5279839b --- /dev/null +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/stdpch.h @@ -0,0 +1,39 @@ +// Object Viewer Qt - Georges Editor Plugin - MMORPG Framework +// Copyright (C) 2011 Adrian Jaekel +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as +// published by the Free Software Foundation, either version 3 of the +// License, or (at your option) any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with this program. If not, see . + +#ifndef NL_STDPCH_H +#define NL_STDPCH_H + +#include + +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#endif diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/CMakeLists.txt b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/CMakeLists.txt index b5af7f1e9..0ebc8a0b1 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/CMakeLists.txt +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/CMakeLists.txt @@ -1,129 +1,149 @@ INCLUDE_DIRECTORIES( ${CMAKE_CURRENT_BINARY_DIR} ${CMAKE_CURRENT_SOURCE_DIR} ${LIBXML2_INCLUDE_DIR} - ${QT_INCLUDES}) + ${QT_INCLUDES} + ${CMAKE_CURRENT_SOURCE_DIR}/scene/ + ${CMAKE_CURRENT_SOURCE_DIR}/particle_system/ + ${CMAKE_CURRENT_SOURCE_DIR}/vegetable/ + ${CMAKE_CURRENT_SOURCE_DIR}/widgets/ +) FILE(GLOB SRC *.cpp *.h) +FILE(GLOB OVQT_SCENE_SRC scene/*.cpp scene/*.h) +FILE(GLOB OVQT_PS_SRC particle_system/*.h particle_system/*.cpp) +FILE(GLOB OVQT_VEGETABLE_SRC vegetable/*.h vegetable/*.cpp) +FILE(GLOB OVQT_WIDGETS_SRC widgets/*.h widgets/*.cpp) + SET(OVQT_EXT_SYS_SRC ${CMAKE_CURRENT_SOURCE_DIR}/../../extension_system/iplugin.h ${CMAKE_CURRENT_SOURCE_DIR}/../../extension_system/iplugin_manager.h ${CMAKE_CURRENT_SOURCE_DIR}/../../extension_system/iplugin_spec.h) -SET(OBJECT_VIEWER_PLUGIN_HDR object_viewer_plugin.h - main_window.h - graphics_viewport.h - animation_dialog.h - animation_set_dialog.h - setup_fog_dialog.h - slot_manager_dialog.h - particle_control_dialog.h - particle_workspace_dialog.h - particle_tree_model.h - particle_system_page.h - particle_workspace_page.h - edit_range_widget.h - emitter_page.h - attrib_widget.h - located_bindable_page.h - located_page.h - particle_force_page.h - particle_light_page.h - particle_zone_page.h - particle_sound_page.h - basic_edit_widget.h - direction_widget.h - color_edit_widget.h - particle_property_dialog.h - ps_mover_page.h - value_blender_dialog.h - value_gradient_dialog.h - value_from_emitter_dialog.h - curve_dialog.h - bin_op_dialog.h - hoverpoints.h - mesh_widget.h - morph_mesh_dialog.h - constraint_mesh_widget.h - tail_particle_widget.h - auto_lod_dialog.h - particle_texture_widget.h - particle_texture_anim_widget.h - multi_tex_dialog.h - spinner_dialog.h - follow_path_dialog.h - water_pool_dialog.h - skeleton_scale_dialog.h - skeleton_tree_model.h - particle_link_skeleton_dialog.h - vegetable_dialog.h - global_wind_dialog.h - day_night_dialog.h - sun_color_dialog.h - vegetable_noise_value_widget.h - vegetable_density_page.h - vegetable_landscape_page.h - vegetable_scale_page.h - vegetable_appearance_page.h - vegetable_rotate_page.h - tune_mrm_dialog.h - tune_timer_dialog.h - camera_control.h +SET(OBJECT_VIEWER_PLUGIN_QT_HDR object_viewer_plugin.h + main_window.h + graphics_viewport.h graphics_settings_page.h sound_settings_page.h vegetable_settings_page.h - scheme_bank_dialog.h) - -SET(OBJECT_VIEWER_PLUGIN_UIS animation_form.ui - animation_set_form.ui - setup_fog_form.ui - slot_form.ui - particle_control_form.ui - particle_workspace_form.ui - edit_range_float_form.ui - edit_range_uint_form.ui - particle_system_form.ui - workspace_form.ui - attrib_form.ui - emitter_form.ui - located_bindable_form.ui - located_form.ui - particle_force_form.ui - particle_light_form.ui - particle_zone_form.ui - particle_sound_form.ui - basic_edit_form.ui - direction_form.ui - color_edit_form.ui - ps_mover_form.ui - curve_form.ui - mesh_form.ui - morph_mesh_form.ui - constraint_mesh_form.ui - tail_form.ui - auto_lod_form.ui - particle_texture_form.ui - particle_texture_anim_form.ui - multi_tex_form.ui - skeleton_scale_form.ui - particle_link_skeleton_form.ui - water_pool_form.ui - vegetable_dialog_form.ui - vegetable_noise_value_form.ui - global_wind_form.ui - sun_color_form.ui - day_night_form.ui - vegetable_density_form.ui - vegetable_apperance_form.ui - vegetable_landscape_form.ui - vegetable_rotate_form.ui - vegetable_scale_form.ui - tune_mrm_form.ui - tune_timer_form.ui + + scene/animation_dialog.h + scene/animation_set_dialog.h + scene/setup_fog_dialog.h + scene/slot_manager_dialog.h + scene/water_pool_dialog.h + scene/skeleton_scale_dialog.h + scene/skeleton_tree_model.h + scene/global_wind_dialog.h + scene/day_night_dialog.h + scene/sun_color_dialog.h + scene/tune_mrm_dialog.h + scene/tune_timer_dialog.h + scene/camera_control.h + + particle_system/particle_control_dialog.h + particle_system/particle_workspace_dialog.h + particle_system/particle_tree_model.h + particle_system/particle_system_page.h + particle_system/particle_workspace_page.h + particle_system/emitter_page.h + particle_system/attrib_widget.h + particle_system/located_bindable_page.h + particle_system/located_page.h + particle_system/particle_force_page.h + particle_system/particle_light_page.h + particle_system/particle_zone_page.h + particle_system/particle_sound_page.h + particle_system/basic_edit_widget.h + particle_system/direction_widget.h + particle_system/scheme_bank_dialog.h + particle_system/particle_property_dialog.h + particle_system/ps_mover_page.h + particle_system/value_blender_dialog.h + particle_system/value_gradient_dialog.h + particle_system/value_from_emitter_dialog.h + particle_system/curve_dialog.h + particle_system/bin_op_dialog.h + particle_system/mesh_widget.h + particle_system/morph_mesh_dialog.h + particle_system/constraint_mesh_widget.h + particle_system/tail_particle_widget.h + particle_system/auto_lod_dialog.h + particle_system/particle_texture_widget.h + particle_system/particle_texture_anim_widget.h + particle_system/multi_tex_dialog.h + particle_system/spinner_dialog.h + particle_system/follow_path_dialog.h + particle_system/particle_link_skeleton_dialog.h + + vegetable/vegetable_dialog.h + vegetable/vegetable_noise_value_widget.h + vegetable/vegetable_density_page.h + vegetable/vegetable_landscape_page.h + vegetable/vegetable_scale_page.h + vegetable/vegetable_appearance_page.h + vegetable/vegetable_rotate_page.h + + widgets/edit_range_widget.h + widgets/color_edit_widget.h + widgets/hoverpoints.h +) + +SET(OBJECT_VIEWER_PLUGIN_UIS scene/animation_form.ui + scene/animation_set_form.ui + scene/setup_fog_form.ui + scene/slot_form.ui + scene/skeleton_scale_form.ui + scene/water_pool_form.ui + scene/global_wind_form.ui + scene/sun_color_form.ui + scene/day_night_form.ui + scene/tune_mrm_form.ui + scene/tune_timer_form.ui + + particle_system/particle_control_form.ui + particle_system/particle_workspace_form.ui + particle_system/particle_system_form.ui + particle_system/workspace_form.ui + particle_system/attrib_form.ui + particle_system/emitter_form.ui + particle_system/located_bindable_form.ui + particle_system/located_form.ui + particle_system/particle_force_form.ui + particle_system/particle_light_form.ui + particle_system/particle_zone_form.ui + particle_system/particle_sound_form.ui + particle_system/basic_edit_form.ui + particle_system/direction_form.ui + particle_system/ps_mover_form.ui + particle_system/curve_form.ui + particle_system/mesh_form.ui + particle_system/morph_mesh_form.ui + particle_system/constraint_mesh_form.ui + particle_system/tail_form.ui + particle_system/auto_lod_form.ui + particle_system/particle_texture_form.ui + particle_system/particle_texture_anim_form.ui + particle_system/multi_tex_form.ui + particle_system/particle_link_skeleton_form.ui + particle_system/scheme_bank_form.ui + particle_system/value_gradient_form.ui + + vegetable/vegetable_dialog_form.ui + vegetable/vegetable_noise_value_form.ui + vegetable/vegetable_density_form.ui + vegetable/vegetable_apperance_form.ui + vegetable/vegetable_landscape_form.ui + vegetable/vegetable_rotate_form.ui + vegetable/vegetable_scale_form.ui + + widgets/color_edit_form.ui + widgets/edit_range_float_form.ui + widgets/edit_range_uint_form.ui + graphics_settings_page.ui sound_settings_page.ui vegetable_settings_page.ui - scheme_bank_form.ui - value_gradient_form.ui) +) SET(OBJECT_VIEWER_PLUGIN_RCS object_viewer.qrc) @@ -131,16 +151,29 @@ SET(QT_USE_QTGUI TRUE) SET(QT_USE_QTOPENGL TRUE) QT4_ADD_RESOURCES(OBJECT_VIEWER_PLUGIN_RC_SRCS ${OBJECT_VIEWER_PLUGIN_RCS}) -QT4_WRAP_CPP(OBJECT_VIEWER_PLUGIN_MOC_SRC ${OBJECT_VIEWER_PLUGIN_HDR}) +QT4_WRAP_CPP(OBJECT_VIEWER_PLUGIN_MOC_SRC ${OBJECT_VIEWER_PLUGIN_QT_HDR}) QT4_WRAP_UI(OBJECT_VIEWER_PLUGIN_UI_HDRS ${OBJECT_VIEWER_PLUGIN_UIS}) SOURCE_GROUP(QtResources FILES ${OBJECT_VIEWER_PLUGIN_UIS}) SOURCE_GROUP(QtGeneratedUiHdr FILES ${OBJECT_VIEWER_PLUGIN_UI_HDRS}) SOURCE_GROUP(QtGeneratedMocSrc FILES ${OBJECT_VIEWER_PLUGIN_MOC_SRC}) -SOURCE_GROUP("Object Viewer Plugin" FILES ${SRC}) -SOURCE_GROUP("OVQT Extension System" FILES ${OVQT_EXT_SYS_SRC}) -ADD_LIBRARY(ovqt_plugin_object_viewer MODULE ${SRC} ${OBJECT_VIEWER_PLUGIN_MOC_SRC} ${OVQT_EXT_SYS_SRC} ${OBJECT_VIEWER_PLUGIN_UI_HDRS} ${OBJECT_VIEWER_PLUGIN_RC_SRCS}) +SOURCE_GROUP("ovqt Extension System" FILES ${OVQT_EXT_SYS_SRC}) +SOURCE_GROUP("ovqt Plugin Src" FILES ${SRC}) +SOURCE_GROUP("ovqt Plugin Scene Src" FILES ${OVQT_SCENE_SRC}) +SOURCE_GROUP("ovqt Plugin PS Src" FILES ${OVQT_PS_SRC}) +SOURCE_GROUP("ovqt Plugin Vegetable Src" FILES ${OVQT_VEGETABLE_SRC}) +SOURCE_GROUP("ovqt Plugin Widgets Src" FILES ${OVQT_WIDGETS_SRC}) + +ADD_LIBRARY(ovqt_plugin_object_viewer MODULE ${SRC} + ${OVQT_SCENE_SRC} + ${OVQT_PS_SRC} + ${OVQT_VEGETABLE_SRC} + ${OVQT_WIDGETS_SRC} + ${OBJECT_VIEWER_PLUGIN_MOC_SRC} + ${OVQT_EXT_SYS_SRC} + ${OBJECT_VIEWER_PLUGIN_UI_HDRS} + ${OBJECT_VIEWER_PLUGIN_RC_SRCS}) TARGET_LINK_LIBRARIES(ovqt_plugin_object_viewer ovqt_plugin_core @@ -154,15 +187,15 @@ TARGET_LINK_LIBRARIES(ovqt_plugin_object_viewer NL_DEFAULT_PROPS(ovqt_plugin_object_viewer "NeL, Tools, 3D: Object Viewer Qt Plugin: Object Viewer") -IF(WITH_PCH) - ADD_NATIVE_PRECOMPILED_HEADER(ovqt_plugin_object_viewer ${CMAKE_CURRENT_SOURCE_DIR}/stdpch.h ${CMAKE_CURRENT_SOURCE_DIR}/stdpch.cpp) -ENDIF(WITH_PCH) - NL_ADD_RUNTIME_FLAGS(ovqt_plugin_object_viewer) NL_ADD_LIB_SUFFIX(ovqt_plugin_object_viewer) ADD_DEFINITIONS(-DQT_NO_KEYWORDS ${LIBXML2_DEFINITIONS} -DQT_PLUGIN -DQT_SHARED ${QT_DEFINITIONS}) +IF(WITH_PCH) + ADD_NATIVE_PRECOMPILED_HEADER(ovqt_plugin_object_viewer ${CMAKE_CURRENT_SOURCE_DIR}/stdpch.h ${CMAKE_CURRENT_SOURCE_DIR}/stdpch.cpp) +ENDIF(WITH_PCH) + INSTALL(TARGETS ovqt_plugin_object_viewer LIBRARY DESTINATION ${OVQT_PLUGIN_DIR} RUNTIME DESTINATION ${NL_BIN_PREFIX} ARCHIVE DESTINATION ${OVQT_PLUGIN_DIR} COMPONENT tools3d) INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/ovqt_plugin_object_viewer.xml DESTINATION ${OVQT_PLUGIN_SPECS_DIR} COMPONENT tools3d) diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/object_viewer.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/object_viewer.cpp index a07623cde..48c679455 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/object_viewer.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/object_viewer.cpp @@ -468,7 +468,7 @@ void CObjectViewer::loadConfig() #endif _CameraFocal = settings->value("CameraFocal", 75).toInt(); - _FontName = settings->value(Constants::FONT, "andbasr.ttf").toString().toUtf8(); + _FontName = settings->value(Constants::FONT, "andbasr.ttf").toString().toUtf8().constData(); _BloomEffect = settings->value(Constants::ENABLE_BLOOM, false).toBool(); _BloomDensity = settings->value(Constants::BLOOM_DENSITY, 0).toInt(); _BloomSquare = settings->value(Constants::ENABLE_SQUARE_BLOOM, false).toBool(); diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/attrib_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/attrib_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/attrib_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/attrib_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/attrib_widget.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/attrib_widget.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/attrib_widget.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/attrib_widget.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/attrib_widget.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/attrib_widget.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/attrib_widget.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/attrib_widget.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/auto_lod_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/auto_lod_dialog.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/auto_lod_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/auto_lod_dialog.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/auto_lod_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/auto_lod_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/auto_lod_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/auto_lod_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/auto_lod_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/auto_lod_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/auto_lod_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/auto_lod_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/basic_edit_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/basic_edit_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/basic_edit_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/basic_edit_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/basic_edit_widget.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/basic_edit_widget.cpp similarity index 99% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/basic_edit_widget.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/basic_edit_widget.cpp index b3816a034..771568550 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/basic_edit_widget.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/basic_edit_widget.cpp @@ -202,15 +202,15 @@ void CBasicEditWidget::updateGraphics() } bool CBasicEditWidget::eventFilter(QObject *object, QEvent *event) -{ - if( event->type() == QEvent::Paint ) - { +{ + if( event->type() == QEvent::Paint ) + { QPainter painter(_ui.graphicsWidget); painter.setRenderHint(QPainter::Antialiasing, true); painter.setBrush(QBrush(Qt::white)); painter.setPen(QPen(Qt::black, 2, Qt::SolidLine)); - painter.drawRoundedRect(QRect(3, 3, _ui.graphicsWidget->width() - 6, _ui.graphicsWidget->height() - 6), 3.0, 3.0); - } + painter.drawRoundedRect(QRect(3, 3, _ui.graphicsWidget->width() - 6, _ui.graphicsWidget->height() - 6), 3.0, 3.0); + } return QWidget::eventFilter(object, event); } -} /* namespace NLQT */ \ No newline at end of file +} /* namespace NLQT */ diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/basic_edit_widget.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/basic_edit_widget.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/basic_edit_widget.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/basic_edit_widget.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/bin_op_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/bin_op_dialog.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/bin_op_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/bin_op_dialog.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/bin_op_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/bin_op_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/bin_op_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/bin_op_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/constraint_mesh_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/constraint_mesh_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/constraint_mesh_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/constraint_mesh_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/constraint_mesh_widget.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/constraint_mesh_widget.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/constraint_mesh_widget.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/constraint_mesh_widget.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/constraint_mesh_widget.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/constraint_mesh_widget.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/constraint_mesh_widget.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/constraint_mesh_widget.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/curve_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/curve_dialog.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/curve_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/curve_dialog.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/curve_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/curve_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/curve_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/curve_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/curve_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/curve_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/curve_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/curve_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/direction_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/direction_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/direction_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/direction_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/direction_widget.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/direction_widget.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/direction_widget.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/direction_widget.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/direction_widget.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/direction_widget.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/direction_widget.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/direction_widget.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/dup_ps.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/dup_ps.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/dup_ps.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/dup_ps.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/dup_ps.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/dup_ps.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/dup_ps.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/dup_ps.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/emitter_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/emitter_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/emitter_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/emitter_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/emitter_page.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/emitter_page.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/emitter_page.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/emitter_page.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/emitter_page.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/emitter_page.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/emitter_page.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/emitter_page.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/follow_path_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/follow_path_dialog.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/follow_path_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/follow_path_dialog.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/follow_path_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/follow_path_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/follow_path_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/follow_path_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/located_bindable_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/located_bindable_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/located_bindable_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/located_bindable_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/located_bindable_page.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/located_bindable_page.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/located_bindable_page.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/located_bindable_page.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/located_bindable_page.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/located_bindable_page.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/located_bindable_page.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/located_bindable_page.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/located_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/located_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/located_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/located_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/located_page.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/located_page.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/located_page.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/located_page.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/located_page.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/located_page.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/located_page.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/located_page.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/mesh_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/mesh_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/mesh_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/mesh_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/mesh_widget.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/mesh_widget.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/mesh_widget.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/mesh_widget.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/mesh_widget.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/mesh_widget.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/mesh_widget.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/mesh_widget.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/morph_mesh_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/morph_mesh_dialog.cpp similarity index 98% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/morph_mesh_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/morph_mesh_dialog.cpp index b6b1ec14c..20e19b539 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/morph_mesh_dialog.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/morph_mesh_dialog.cpp @@ -110,7 +110,7 @@ void CMorphMeshDialog::add() shapeNames.resize(_CM->getNumShapes() + 1); _CM->getShapesNames(&shapeNames[0]); uint index = (uint)shapeNames.size() - 1; - shapeNames[index] = fileName.toUtf8(); + shapeNames[index] = fileName.toUtf8().constData(); _CM->setShapes(&shapeNames[0], (uint)shapeNames.size()); std::vector numVerts; _CM->getShapeNumVerts(numVerts); diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/morph_mesh_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/morph_mesh_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/morph_mesh_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/morph_mesh_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/morph_mesh_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/morph_mesh_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/morph_mesh_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/morph_mesh_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/multi_tex_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/multi_tex_dialog.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/multi_tex_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/multi_tex_dialog.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/multi_tex_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/multi_tex_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/multi_tex_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/multi_tex_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/multi_tex_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/multi_tex_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/multi_tex_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/multi_tex_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_control_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_control_dialog.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_control_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_control_dialog.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_control_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_control_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_control_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_control_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_control_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_control_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_control_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_control_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_editor.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_editor.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_editor.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_editor.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_editor.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_editor.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_editor.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_editor.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_force_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_force_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_force_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_force_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_force_page.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_force_page.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_force_page.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_force_page.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_force_page.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_force_page.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_force_page.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_force_page.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_light_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_light_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_light_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_light_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_light_page.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_light_page.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_light_page.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_light_page.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_light_page.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_light_page.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_light_page.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_light_page.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_link_skeleton_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_link_skeleton_dialog.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_link_skeleton_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_link_skeleton_dialog.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_link_skeleton_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_link_skeleton_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_link_skeleton_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_link_skeleton_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_link_skeleton_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_link_skeleton_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_link_skeleton_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_link_skeleton_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_node.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_node.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_node.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_node.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_node.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_node.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_node.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_node.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_property_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_property_dialog.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_property_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_property_dialog.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_property_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_property_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_property_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_property_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_sound_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_sound_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_sound_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_sound_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_sound_page.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_sound_page.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_sound_page.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_sound_page.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_sound_page.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_sound_page.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_sound_page.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_sound_page.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_system_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_system_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system_page.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_system_page.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system_page.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_system_page.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system_page.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_system_page.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system_page.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_system_page.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_texture_anim_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_texture_anim_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_texture_anim_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_texture_anim_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_texture_anim_widget.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_texture_anim_widget.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_texture_anim_widget.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_texture_anim_widget.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_texture_anim_widget.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_texture_anim_widget.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_texture_anim_widget.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_texture_anim_widget.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_texture_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_texture_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_texture_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_texture_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_texture_widget.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_texture_widget.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_texture_widget.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_texture_widget.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_texture_widget.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_texture_widget.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_texture_widget.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_texture_widget.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_tree_model.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_tree_model.cpp similarity index 99% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_tree_model.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_tree_model.cpp index fc284f865..1d9574b6d 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_tree_model.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_tree_model.cpp @@ -319,7 +319,7 @@ bool CParticleTreeModel::setData(const QModelIndex &index, const QVariant &value QList listData; listData << value; item->replace(listData); - std::string name = value.toString().toUtf8(); + std::string name = value.toString().toUtf8().constData(); if (item->itemType() == ItemType::Located) item->getLoc()->setName(name); else diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_tree_model.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_tree_model.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_tree_model.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_tree_model.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_workspace_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_workspace_dialog.cpp similarity index 99% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_workspace_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_workspace_dialog.cpp index c006e7066..4c92a5fc4 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_workspace_dialog.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_workspace_dialog.cpp @@ -770,12 +770,13 @@ NL3D::CPSLocated *CParticleWorkspaceDialog::createLocated(NL3D::CParticleSystem { // build new name std::string name; - if (_PSElementIdentifiers.count(std::string("located"))) - name = (QString("located %1").arg(++_PSElementIdentifiers[std::string("located")])).toUtf8(); - + if (_PSElementIdentifiers.count("located")) + { + name = NLMISC::toString("located %u", ++_PSElementIdentifiers["located"]); + } else { - name = std::string("located 0"); + name = "located 0"; _PSElementIdentifiers["located"] = 0; } NL3D::CPSLocated *loc = new NL3D::CPSLocated; diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_workspace_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_workspace_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_workspace_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_workspace_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_workspace_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_workspace_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_workspace_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_workspace_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_workspace_page.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_workspace_page.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_workspace_page.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_workspace_page.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_workspace_page.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_workspace_page.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_workspace_page.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_workspace_page.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_zone_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_zone_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_zone_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_zone_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_zone_page.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_zone_page.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_zone_page.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_zone_page.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_zone_page.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_zone_page.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_zone_page.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/particle_zone_page.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/ps_initial_pos.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/ps_initial_pos.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/ps_initial_pos.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/ps_initial_pos.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/ps_initial_pos.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/ps_initial_pos.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/ps_initial_pos.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/ps_initial_pos.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/ps_mover_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/ps_mover_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/ps_mover_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/ps_mover_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/ps_mover_page.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/ps_mover_page.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/ps_mover_page.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/ps_mover_page.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/ps_mover_page.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/ps_mover_page.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/ps_mover_page.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/ps_mover_page.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/ps_wrapper.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/ps_wrapper.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/ps_wrapper.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/ps_wrapper.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scheme_bank_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/scheme_bank_dialog.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scheme_bank_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/scheme_bank_dialog.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scheme_bank_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/scheme_bank_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scheme_bank_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/scheme_bank_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scheme_bank_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/scheme_bank_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scheme_bank_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/scheme_bank_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scheme_manager.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/scheme_manager.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scheme_manager.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/scheme_manager.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scheme_manager.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/scheme_manager.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scheme_manager.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/scheme_manager.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/spinner_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/spinner_dialog.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/spinner_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/spinner_dialog.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/spinner_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/spinner_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/spinner_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/spinner_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/tail_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/tail_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/tail_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/tail_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/tail_particle_widget.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/tail_particle_widget.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/tail_particle_widget.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/tail_particle_widget.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/tail_particle_widget.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/tail_particle_widget.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/tail_particle_widget.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/tail_particle_widget.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/value_blender_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/value_blender_dialog.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/value_blender_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/value_blender_dialog.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/value_blender_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/value_blender_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/value_blender_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/value_blender_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/value_from_emitter_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/value_from_emitter_dialog.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/value_from_emitter_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/value_from_emitter_dialog.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/value_from_emitter_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/value_from_emitter_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/value_from_emitter_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/value_from_emitter_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/value_gradient_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/value_gradient_dialog.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/value_gradient_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/value_gradient_dialog.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/value_gradient_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/value_gradient_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/value_gradient_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/value_gradient_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/value_gradient_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/value_gradient_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/value_gradient_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/value_gradient_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/workspace_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/workspace_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/workspace_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/particle_system/workspace_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/animation_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/animation_dialog.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/animation_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/animation_dialog.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/animation_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/animation_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/animation_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/animation_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/animation_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/animation_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/animation_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/animation_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/animation_set_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/animation_set_dialog.cpp similarity index 96% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/animation_set_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/animation_set_dialog.cpp index f73aa4055..f2d5e6567 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/animation_set_dialog.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/animation_set_dialog.cpp @@ -161,8 +161,7 @@ void CAnimationSetDialog::loadAnim() QStringList::Iterator it = list.begin(); while(it != list.end()) { - std::string animName = it->toUtf8(); - entity.loadAnimation(animName); + entity.loadAnimation(it->toUtf8().constData()); ++it; } updateListAnim(); @@ -187,8 +186,7 @@ void CAnimationSetDialog::loadSwt() QStringList::Iterator it = list.begin(); while(it != list.end()) { - std::string swtName = it->toUtf8(); - entity.loadSWT(swtName); + entity.loadSWT(it->toUtf8().constData()); ++it; } updateListAnim(); @@ -212,8 +210,7 @@ void CAnimationSetDialog::addAnim() Q_FOREACH(QTreeWidgetItem *item, list) { - std::string animName = item->text(0).toUtf8(); - entity.addAnimToPlayList(animName); + entity.addAnimToPlayList(item->text(0).toUtf8().constData()); ui.animPlaylistWidget->addItem(item->text(0)); } } diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/animation_set_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/animation_set_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/animation_set_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/animation_set_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/animation_set_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/animation_set_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/animation_set_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/animation_set_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/camera_control.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/camera_control.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/camera_control.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/camera_control.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/camera_control.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/camera_control.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/camera_control.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/camera_control.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/day_night_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/day_night_dialog.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/day_night_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/day_night_dialog.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/day_night_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/day_night_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/day_night_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/day_night_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/day_night_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/day_night_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/day_night_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/day_night_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/entity.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/entity.cpp similarity index 97% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/entity.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/entity.cpp index 1aaacbf6e..f5a1b5094 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/entity.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/entity.cpp @@ -117,7 +117,7 @@ CEntity::~CEntity(void) } } -void CEntity::loadAnimation(std::string &fileName) +void CEntity::loadAnimation(const std::string &fileName) { uint id = _AnimationSet->addAnimation(fileName.c_str(),CFile::getFilenameWithoutExtension(fileName).c_str()); _AnimationList.push_back(_AnimationSet->getAnimationName(id)); @@ -128,13 +128,13 @@ void CEntity::loadAnimation(std::string &fileName) _PlayList->registerTransform(_Instance); } -void CEntity::loadSWT(std::string &fileName) +void CEntity::loadSWT(const std::string &fileName) { uint id = _AnimationSet->addSkeletonWeight(fileName.c_str(),CFile::getFilenameWithoutExtension(fileName).c_str()); _SWTList.push_back(_AnimationSet->getSkeletonWeightName(id)); } -void CEntity::addAnimToPlayList(std::string &name) +void CEntity::addAnimToPlayList(const std::string &name) { _PlayListAnimation.push_back(name); @@ -176,7 +176,7 @@ void CEntity::reset() _PlayList->resetAllChannels(); } -float CEntity::getPlayListLength() +float CEntity::getPlayListLength() const { // Accumul all the time float time = 0; @@ -185,7 +185,7 @@ float CEntity::getPlayListLength() return time; } -float CEntity::getAnimLength(std::string name) +float CEntity::getAnimLength(const std::string &name) const { uint id = _AnimationSet->getAnimationIdByName(name.c_str()); NL3D::UAnimation *anim = _AnimationSet->getAnimation(id); diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/entity.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/entity.h similarity index 93% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/entity.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/entity.h index ea1d53e25..47dad0386 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/entity.h +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/entity.h @@ -109,14 +109,14 @@ public: /// Loads a file animations /// @param fileName - name animation file - void loadAnimation(std::string &fileName); + void loadAnimation(const std::string &fileName); /// Loads a file skeleton weight - void loadSWT(std::string &fileName); + void loadSWT(const std::string &fileName); /// Adds an animation to a playlist /// @param name - name loaded animations - void addAnimToPlayList(std::string &name); + void addAnimToPlayList(const std::string &name); /// Removes the animation from a playlist /// @param row - number of animations in the playlist @@ -135,10 +135,10 @@ public: /// Get the total time of animation playlist /// @return total time of animation - float getPlayListLength(); + float getPlayListLength() const; /// get time length single animation - float getAnimLength(std::string name); + float getAnimLength(const std::string &name) const; /// Get slot infomation void setSlotInfo(uint num, CSlotInfo &slotInfo) @@ -159,7 +159,7 @@ public: } /// Get in place mode - bool getInPlace() + bool getInPlace() const { return _inPlace; } @@ -171,35 +171,35 @@ public: } /// Get inc position - bool getIncPos() + bool getIncPos() const { return _incPos; } /// Get information about the current status of playing a playlist /// @return struct containing current information playback - SAnimationStatus getStatus() + SAnimationStatus getStatus() const { return _AnimationStatus; } /// Get name entity /// @return name entity - std::string getName() + std::string getName() const { return _Name; } /// Get file name shape /// @return file name shape - std::string getFileNameShape() + std::string getFileNameShape() const { return _FileNameShape; } /// Get file name skeleton /// @return file name skeleton - std::string getFileNameSkeleton() + std::string getFileNameSkeleton() const { return _FileNameSkeleton; } diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/global_wind_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/global_wind_dialog.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/global_wind_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/global_wind_dialog.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/global_wind_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/global_wind_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/global_wind_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/global_wind_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/global_wind_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/global_wind_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/global_wind_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/global_wind_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/setup_fog_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/setup_fog_dialog.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/setup_fog_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/setup_fog_dialog.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/setup_fog_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/setup_fog_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/setup_fog_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/setup_fog_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/setup_fog_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/setup_fog_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/setup_fog_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/setup_fog_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/skeleton_scale_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/skeleton_scale_dialog.cpp similarity index 99% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/skeleton_scale_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/skeleton_scale_dialog.cpp index 2d1d92dd1..8145c0bcc 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/skeleton_scale_dialog.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/skeleton_scale_dialog.cpp @@ -300,7 +300,7 @@ void CSkeletonScaleDialog::clickSaveAsSkel() } // bkup the valid fileName (new file edited) - _SkeletonFileName = fileName.toUtf8(); + _SkeletonFileName = fileName.toUtf8().constData(); } else { diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/skeleton_scale_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/skeleton_scale_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/skeleton_scale_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/skeleton_scale_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/skeleton_scale_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/skeleton_scale_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/skeleton_scale_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/skeleton_scale_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/skeleton_tree_model.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/skeleton_tree_model.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/skeleton_tree_model.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/skeleton_tree_model.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/skeleton_tree_model.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/skeleton_tree_model.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/skeleton_tree_model.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/skeleton_tree_model.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/slot_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/slot_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/slot_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/slot_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/slot_manager_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/slot_manager_dialog.cpp similarity index 98% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/slot_manager_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/slot_manager_dialog.cpp index e9c23779a..f846bdf4a 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/slot_manager_dialog.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/slot_manager_dialog.cpp @@ -111,8 +111,8 @@ void CSlotGroupBox::updateUi() void CSlotGroupBox::saveSlotInfo() { CSlotInfo slotInfo; - slotInfo.Animation = _animName.toUtf8(); - slotInfo.Skeleton = _skelName.toUtf8(); + slotInfo.Animation = _animName.toUtf8().constData(); + slotInfo.Skeleton = _skelName.toUtf8().constData(); slotInfo.EndBlend = _ui.endBlendSpinBox->value(); slotInfo.EndTime = float(_ui.endFrameSpinBox->value()) / Modules::mainWin().getFrameRate(); slotInfo.Offset = float(_ui.offsetSpinBox->value()) / Modules::mainWin().getFrameRate(); diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/slot_manager_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/slot_manager_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/slot_manager_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/slot_manager_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/sun_color_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/sun_color_dialog.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/sun_color_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/sun_color_dialog.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/sun_color_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/sun_color_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/sun_color_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/sun_color_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/sun_color_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/sun_color_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/sun_color_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/sun_color_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/tune_mrm_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/tune_mrm_dialog.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/tune_mrm_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/tune_mrm_dialog.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/tune_mrm_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/tune_mrm_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/tune_mrm_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/tune_mrm_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/tune_mrm_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/tune_mrm_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/tune_mrm_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/tune_mrm_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/tune_timer_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/tune_timer_dialog.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/tune_timer_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/tune_timer_dialog.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/tune_timer_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/tune_timer_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/tune_timer_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/tune_timer_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/tune_timer_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/tune_timer_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/tune_timer_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/tune_timer_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/water_pool_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/water_pool_dialog.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/water_pool_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/water_pool_dialog.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/water_pool_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/water_pool_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/water_pool_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/water_pool_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/water_pool_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/water_pool_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/water_pool_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/scene/water_pool_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/sound_system.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/sound_system.cpp index 361b0100c..afa315e0f 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/sound_system.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/sound_system.cpp @@ -86,8 +86,8 @@ void CSoundSystem::init() QSettings *settings = Core::ICore::instance()->settings(); settings->beginGroup(Constants::OBJECT_VIEWER_SECTION); - _PackedSheetPath = settings->value(Constants::SOUND_PACKED_SHEET_PATH, "").toString().toUtf8(); - _SamplePath = settings->value(Constants::SOUND_SAMPLE_PATH, "").toString().toUtf8(); + _PackedSheetPath = settings->value(Constants::SOUND_PACKED_SHEET_PATH, "").toString().toUtf8().constData(); + _SamplePath = settings->value(Constants::SOUND_SAMPLE_PATH, "").toString().toUtf8().constData(); _AudioMixer->setSamplePath(_SamplePath); _AudioMixer->setPackedSheetOption(_PackedSheetPath, true); std::vector devices; diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/stdpch.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/stdpch.h index d9dcf4d58..fbb367fc8 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/stdpch.h +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/stdpch.h @@ -20,7 +20,8 @@ #ifndef NL_STDPCH_H #define NL_STDPCH_H -#include +#include +#include #include #include @@ -28,6 +29,97 @@ #include #include +#include +#include +#include +#include #include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include #endif diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_appearance_page.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_appearance_page.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_appearance_page.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_appearance_page.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_appearance_page.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_appearance_page.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_appearance_page.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_appearance_page.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_apperance_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_apperance_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_apperance_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_apperance_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_density_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_density_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_density_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_density_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_density_page.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_density_page.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_density_page.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_density_page.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_density_page.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_density_page.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_density_page.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_density_page.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_dialog.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_dialog.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_dialog.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_dialog.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_dialog.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_dialog.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_dialog.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_dialog.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_dialog_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_dialog_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_dialog_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_dialog_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_editor.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_editor.cpp similarity index 98% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_editor.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_editor.cpp index cdd311302..73b639647 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_editor.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_editor.cpp @@ -596,10 +596,10 @@ void CVegetableEditor::loadLandscapeSetup() QSettings *settings = Core::ICore::instance()->settings(); settings->beginGroup(Constants::OBJECT_VIEWER_SECTION); - _VegetableLandscapeTileBank = settings->value(Constants::VEGET_TILE_BANK, "").toString().toUtf8(); - _VegetableLandscapeTileFarBank = settings->value(Constants::VEGET_TILE_FAR_BANK, "").toString().toUtf8(); - _CoarseMeshTexture = settings->value(Constants::COARSE_MESH_TEXTURE, "").toString().toUtf8(); - _VegetableTexture = settings->value(Constants::VEGET_TEXTURE, "").toString().toUtf8(); + _VegetableLandscapeTileBank = settings->value(Constants::VEGET_TILE_BANK, "").toString().toUtf8().constData(); + _VegetableLandscapeTileFarBank = settings->value(Constants::VEGET_TILE_FAR_BANK, "").toString().toUtf8().constData(); + _CoarseMeshTexture = settings->value(Constants::COARSE_MESH_TEXTURE, "").toString().toUtf8().constData(); + _VegetableTexture = settings->value(Constants::VEGET_TEXTURE, "").toString().toUtf8().constData(); QStringList list = settings->value(Constants::VEGET_LANDSCAPE_ZONES).toStringList(); _VegetableLandscapeZoneNames.clear(); diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_editor.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_editor.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_editor.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_editor.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_landscape_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_landscape_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_landscape_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_landscape_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_landscape_page.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_landscape_page.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_landscape_page.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_landscape_page.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_landscape_page.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_landscape_page.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_landscape_page.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_landscape_page.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_node.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_node.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_node.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_node.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_node.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_node.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_node.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_node.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_noise_value_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_noise_value_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_noise_value_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_noise_value_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_noise_value_widget.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_noise_value_widget.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_noise_value_widget.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_noise_value_widget.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_noise_value_widget.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_noise_value_widget.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_noise_value_widget.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_noise_value_widget.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_rotate_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_rotate_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_rotate_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_rotate_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_rotate_page.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_rotate_page.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_rotate_page.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_rotate_page.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_rotate_page.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_rotate_page.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_rotate_page.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_rotate_page.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_scale_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_scale_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_scale_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_scale_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_scale_page.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_scale_page.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_scale_page.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_scale_page.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_scale_page.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_scale_page.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable_scale_page.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/vegetable/vegetable_scale_page.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/color_edit_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/widgets/color_edit_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/color_edit_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/widgets/color_edit_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/color_edit_widget.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/widgets/color_edit_widget.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/color_edit_widget.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/widgets/color_edit_widget.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/color_edit_widget.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/widgets/color_edit_widget.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/color_edit_widget.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/widgets/color_edit_widget.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/edit_range_float_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/widgets/edit_range_float_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/edit_range_float_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/widgets/edit_range_float_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/edit_range_uint_form.ui b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/widgets/edit_range_uint_form.ui similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/edit_range_uint_form.ui rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/widgets/edit_range_uint_form.ui diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/edit_range_widget.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/widgets/edit_range_widget.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/edit_range_widget.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/widgets/edit_range_widget.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/edit_range_widget.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/widgets/edit_range_widget.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/edit_range_widget.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/widgets/edit_range_widget.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/hoverpoints.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/widgets/hoverpoints.cpp similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/hoverpoints.cpp rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/widgets/hoverpoints.cpp diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/hoverpoints.h b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/widgets/hoverpoints.h similarity index 100% rename from code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/hoverpoints.h rename to code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/widgets/hoverpoints.h diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/translation_manager/translation_manager_main_window.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/translation_manager/translation_manager_main_window.cpp index 6da8bba7b..9fcb9626a 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/translation_manager/translation_manager_main_window.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/translation_manager/translation_manager_main_window.cpp @@ -357,34 +357,34 @@ void CMainWindow::extractWords(QString typeq) { column_name = "item ID"; builderS.SheetExt = "sitem"; - builderS.SheetPath = level_design_path.append("/game_element/sitem").toUtf8(); + builderS.SheetPath = level_design_path.append("/game_element/sitem").toUtf8().constData(); isSheet = true; } else if(typeq.toAscii() == Constants::WK_CREATURE) { column_name = "creature ID"; builderS.SheetExt = "creature"; - builderS.SheetPath = level_design_path.append("/Game_elem/Creature/fauna").toUtf8(); + builderS.SheetPath = level_design_path.append("/Game_elem/Creature/fauna").toUtf8().constData(); isSheet = true; } else if(typeq.toAscii() == Constants::WK_SBRICK) { column_name = "sbrick ID"; builderS.SheetExt = "sbrick"; - builderS.SheetPath = level_design_path.append("/game_element/sbrick").toUtf8(); + builderS.SheetPath = level_design_path.append("/game_element/sbrick").toUtf8().constData(); isSheet = true; } else if(typeq.toAscii() == Constants::WK_SPHRASE) { column_name = "sphrase ID"; builderS.SheetExt = "sphrase"; - builderS.SheetPath = level_design_path.append("/game_element/sphrase").toUtf8(); + builderS.SheetPath = level_design_path.append("/game_element/sphrase").toUtf8().constData(); isSheet = true; } else if(typeq.toAscii() == Constants::WK_PLACE) { column_name = "placeId"; - builderP.PrimPath = primitives_path.toUtf8(); + builderP.PrimPath = primitives_path.toUtf8().constData(); builderP.PrimFilter.push_back("region_*.primitive"); builderP.PrimFilter.push_back("indoors_*.primitive"); isSheet = false; diff --git a/code/nel/tools/3d/tile_edit_qt/tile_edit_dlg.cpp b/code/nel/tools/3d/tile_edit_qt/tile_edit_dlg.cpp index 45c5b389c..595067cd2 100644 --- a/code/nel/tools/3d/tile_edit_qt/tile_edit_dlg.cpp +++ b/code/nel/tools/3d/tile_edit_qt/tile_edit_dlg.cpp @@ -383,7 +383,7 @@ void CTile_edit_dlg::on_loadPushButton_clicked() void CTile_edit_dlg::on_savePushButton_clicked() { - string fullPath = this->mainFile.absoluteFilePath().toUtf8(); + string fullPath = this->mainFile.absoluteFilePath().toUtf8().constData(); if ( !fullPath.empty() ) { COFile stream; @@ -411,7 +411,7 @@ void CTile_edit_dlg::on_saveAsPushButton_clicked() ui.savePushButton->setEnabled(true); - string fullPath = this->mainFile.absoluteFilePath().toUtf8(); + string fullPath = this->mainFile.absoluteFilePath().toUtf8().constData(); if ( !fullPath.empty() ) { COFile stream; @@ -445,7 +445,7 @@ void CTile_edit_dlg::on_exportPushButton_clicked() copy.cleanUnusedData (); QFileInfo fileInfo(fileName); - string fullPath = fileInfo.absoluteFilePath().toUtf8(); + string fullPath = fileInfo.absoluteFilePath().toUtf8().constData(); if ( !fullPath.empty() ) { COFile stream; diff --git a/code/nel/tools/misc/extract_filename/extract_filename.cpp b/code/nel/tools/misc/extract_filename/extract_filename.cpp index 33a8a7249..7708f9031 100644 --- a/code/nel/tools/misc/extract_filename/extract_filename.cpp +++ b/code/nel/tools/misc/extract_filename/extract_filename.cpp @@ -23,7 +23,7 @@ using namespace NLMISC; #ifdef NL_DEBUG #define INFO nlinfo #else // NL_DEBUG -# if defined(NL_COMP_VC71) || defined(NL_COMP_VC8) || defined(NL_COMP_VC9) || defined(NL_COMP_VC10) +# if defined(NL_COMP_VC) && NL_COMP_VC_VERSION >= 71 # define INFO __noop # else # define INFO 0&& diff --git a/code/ryzom/client/src/attached_fx.cpp b/code/ryzom/client/src/attached_fx.cpp index 0934d9a15..0f520f689 100644 --- a/code/ryzom/client/src/attached_fx.cpp +++ b/code/ryzom/client/src/attached_fx.cpp @@ -197,7 +197,7 @@ void CAttachedFX::create(CCharacterCL &parent, if (targeterInfo.StickMode.UserBoneName != 0) { CEntityCL *targeter = EntitiesMngr.entity(TargeterInfo.Slot); - if (targeter && targeter->skeleton()) + if (parent.skeleton() && targeter && targeter->skeleton()) { TargeterUserBoneID = parent.skeleton()->getBoneIdByName(NLMISC::CStringMapper::unmap(TargeterInfo.StickMode.UserBoneName)); } diff --git a/code/ryzom/client/src/client_sheets/attack_id_sheet.h b/code/ryzom/client/src/client_sheets/attack_id_sheet.h index 2eaaabed8..1dfe1b790 100644 --- a/code/ryzom/client/src/client_sheets/attack_id_sheet.h +++ b/code/ryzom/client/src/client_sheets/attack_id_sheet.h @@ -14,8 +14,6 @@ // You should have received a copy of the GNU Affero General Public License // along with this program. If not, see . - - #ifndef CL_ATTACK_ID_H #define CL_ATTACK_ID_H diff --git a/code/ryzom/client/src/client_sheets/body_to_bone_sheet.cpp b/code/ryzom/client/src/client_sheets/body_to_bone_sheet.cpp index ea08a9747..fb065e6df 100644 --- a/code/ryzom/client/src/client_sheets/body_to_bone_sheet.cpp +++ b/code/ryzom/client/src/client_sheets/body_to_bone_sheet.cpp @@ -19,6 +19,7 @@ #include "stdpch.h" // #include "body_to_bone_sheet.h" +#include "client_sheets.h" // #include "nel/georges/u_form_elm.h" diff --git a/code/ryzom/client/src/client_sheets/body_to_bone_sheet.h b/code/ryzom/client/src/client_sheets/body_to_bone_sheet.h index f71356c5b..10e59ba72 100644 --- a/code/ryzom/client/src/client_sheets/body_to_bone_sheet.h +++ b/code/ryzom/client/src/client_sheets/body_to_bone_sheet.h @@ -21,6 +21,8 @@ #include "game_share/body.h" +#include + namespace NLGEORGES { class UFormElm; diff --git a/code/ryzom/client/src/client_sheets/faction_sheet.h b/code/ryzom/client/src/client_sheets/faction_sheet.h index babdb78e9..1b1a3f3e5 100644 --- a/code/ryzom/client/src/client_sheets/faction_sheet.h +++ b/code/ryzom/client/src/client_sheets/faction_sheet.h @@ -14,11 +14,10 @@ // You should have received a copy of the GNU Affero General Public License // along with this program. If not, see . - - #ifndef RY_FACTION_SHEET_H #define RY_FACTION_SHEET_H +#include "entity_sheet.h" /** Sheet of a faction * NB : it doesn't derives from CEntitySheet, because its instances are aggragated in a CContinentSheet diff --git a/code/ryzom/client/src/client_sheets/item_fx_sheet.cpp b/code/ryzom/client/src/client_sheets/item_fx_sheet.cpp index ce1912897..c58bc601f 100644 --- a/code/ryzom/client/src/client_sheets/item_fx_sheet.cpp +++ b/code/ryzom/client/src/client_sheets/item_fx_sheet.cpp @@ -14,10 +14,10 @@ // You should have received a copy of the GNU Affero General Public License // along with this program. If not, see . - - #include "stdpch.h" #include "item_fx_sheet.h" +#include "client_sheets.h" + #include "nel/georges/u_form_elm.h" // ******************************************************************************************* diff --git a/code/ryzom/client/src/client_sheets/outpost_building_sheet.h b/code/ryzom/client/src/client_sheets/outpost_building_sheet.h index f1bccc371..e753f3352 100644 --- a/code/ryzom/client/src/client_sheets/outpost_building_sheet.h +++ b/code/ryzom/client/src/client_sheets/outpost_building_sheet.h @@ -18,7 +18,7 @@ #define RY_OUTPOST_BUILDING_H #include "entity_sheet.h" - +#include "client_sheets.h" /** * Outpost building definition for client side management (buy building upgrades ...) diff --git a/code/ryzom/client/src/client_sheets/stdpch.h b/code/ryzom/client/src/client_sheets/stdpch.h index 6656b4553..3421b031d 100644 --- a/code/ryzom/client/src/client_sheets/stdpch.h +++ b/code/ryzom/client/src/client_sheets/stdpch.h @@ -14,7 +14,8 @@ // You should have received a copy of the GNU Affero General Public License // along with this program. If not, see . -#include +#ifndef CL_STDPCH_H +#define CL_STDPCH_H #include #include @@ -33,15 +34,21 @@ #include #include +#include #include #include - #include #include #include #include #include #include +#include +#include + +#include +#include +#include +#include -#include "client_sheets.h" -#include "entity_sheet.h" +#endif diff --git a/code/ryzom/client/src/client_sheets/text_emot_list_sheet.h b/code/ryzom/client/src/client_sheets/text_emot_list_sheet.h index ccfdb8f9e..8533e14f5 100644 --- a/code/ryzom/client/src/client_sheets/text_emot_list_sheet.h +++ b/code/ryzom/client/src/client_sheets/text_emot_list_sheet.h @@ -14,8 +14,6 @@ // You should have received a copy of the GNU Affero General Public License // along with this program. If not, see . - - #ifndef CL_TEXT_EMOT_LIST_SHEET_H #define CL_TEXT_EMOT_LIST_SHEET_H diff --git a/code/ryzom/common/src/game_share/scenario.cpp b/code/ryzom/common/src/game_share/scenario.cpp index 5320f0918..6911df31a 100644 --- a/code/ryzom/common/src/game_share/scenario.cpp +++ b/code/ryzom/common/src/game_share/scenario.cpp @@ -989,7 +989,7 @@ bool CScenarioValidator::setScenarioToSave(const std::string& filename, CObject* return true; } -std::string CScenarioValidator::AutoSaveSignature = ""; +std::string CScenarioValidator::AutoSaveSignature; bool CScenarioValidator::applySave(const std::string& signature) { @@ -1252,7 +1252,7 @@ bool CUserComponentValidator::setUserComponentToSave(const std::string& filename return true; } -std::string CUserComponentValidator::AutoSaveSignature = ""; +std::string CUserComponentValidator::AutoSaveSignature; bool CUserComponentValidator::applySave(const std::string& signature) { diff --git a/code/ryzom/common/src/game_share/server_animation_module.cpp b/code/ryzom/common/src/game_share/server_animation_module.cpp index 3758dbf53..51d7ce19e 100644 --- a/code/ryzom/common/src/game_share/server_animation_module.cpp +++ b/code/ryzom/common/src/game_share/server_animation_module.cpp @@ -2017,7 +2017,7 @@ bool CServerAnimationModule::doMakeAnimationSession(CAnimationSession* animSessi //first <=> actId CPrimitives *primDoc = &primDocs[first]; - std::string streamFileName = ""; + std::string streamFileName; if (first==0) { streamFileName= toString("r2.%04d.base.primitive", aiInstance); diff --git a/code/ryzom/common/src/game_share/welcome_service_itf.h b/code/ryzom/common/src/game_share/welcome_service_itf.h index fded04c26..410204cd8 100644 --- a/code/ryzom/common/src/game_share/welcome_service_itf.h +++ b/code/ryzom/common/src/game_share/welcome_service_itf.h @@ -6,9 +6,6 @@ #ifndef WELCOME_SERVICE_ITF #define WELCOME_SERVICE_ITF #include "nel/misc/types_nl.h" -#ifdef NL_COMP_VC8 - #include -#endif #include "nel/misc/hierarchical_timer.h" #include "nel/misc/string_conversion.h" #include "nel/net/message.h" @@ -18,7 +15,9 @@ #include "nel/net/module_gateway.h" #include "nel/net/login_cookie.h" - + +#include + namespace WS { diff --git a/code/ryzom/server/ai_service.cfg b/code/ryzom/server/ai_service.cfg index 55f168607..1a11d9507 100644 --- a/code/ryzom/server/ai_service.cfg +++ b/code/ryzom/server/ai_service.cfg @@ -13,15 +13,10 @@ SUAddress = SUHost+":"+SUPort; AESAliasName= "ais_newbyland"; -GraphVars += { "TickSpeedLoop", "0" }; GraphVars += { "TickSpeedLoop", "60000" }; -GraphVars += { "L5CallbackCount", "0" }; GraphVars += { "L5CallbackCount", "60000" }; -GraphVars += { "L5CallbackTime", "0" }; GraphVars += { "L5CallbackTime", "60000" }; -GraphVars += { "MirrorCallbackCount", "0" }; GraphVars += { "MirrorCallbackCount", "60000" }; -GraphVars += { "MirrorCallbackTime", "0" }; GraphVars += { "MirrorCallbackTime", "60000" }; Paths = { @@ -50,7 +45,7 @@ UsedPrimitives = // of the packed sheet reader GeorgePaths = { "" }; - // ---- service custom variables (used by CVariable class) +// ---- service custom variables (used by CVariable class) NbPlayersLimit = PlayerLimit; diff --git a/code/ryzom/server/entities_game_service.cfg b/code/ryzom/server/entities_game_service.cfg index 8835d9cd2..4ec5fc63d 100644 --- a/code/ryzom/server/entities_game_service.cfg +++ b/code/ryzom/server/entities_game_service.cfg @@ -32,19 +32,12 @@ StartCommands += { "setShardExchangeLimit 302 250" }; StartCommands += { "displayShardExchangeLimits" }; StartCommands += { "EnableStlAllocatorChecker 0" }; -GraphVars += { "CharacterLoadPerTick", "0" }; GraphVars += { "CharacterLoadPerTick", "60000" }; -GraphVars += { "CharacterSavePerTick", "0" }; GraphVars += { "CharacterSavePerTick", "60000" }; -GraphVars += { "TickSpeedLoop", "0" }; GraphVars += { "TickSpeedLoop", "60000" }; -GraphVars += { "L5CallbackCount", "0" }; GraphVars += { "L5CallbackCount", "60000" }; -GraphVars += { "L5CallbackTime", "0" }; GraphVars += { "L5CallbackTime", "60000" }; -GraphVars += { "MirrorCallbackCount", "0" }; GraphVars += { "MirrorCallbackCount", "60000" }; -GraphVars += { "MirrorCallbackTime", "0" }; GraphVars += { "MirrorCallbackTime", "60000" }; NSHost = "localhost"; diff --git a/code/ryzom/server/frontend_service.cfg b/code/ryzom/server/frontend_service.cfg index c9392bd51..36a4103c5 100644 --- a/code/ryzom/server/frontend_service.cfg +++ b/code/ryzom/server/frontend_service.cfg @@ -14,15 +14,10 @@ FSListenHost = "open.ryzom.com"; AESAliasName= "fes"; -GraphVars += { "TickSpeedLoop", "0" }; GraphVars += { "TickSpeedLoop", "60000" }; -GraphVars += { "L5CallbackCount", "0" }; GraphVars += { "L5CallbackCount", "60000" }; -GraphVars += { "L5CallbackTime", "0" }; GraphVars += { "L5CallbackTime", "60000" }; -GraphVars += { "MirrorCallbackCount", "0" }; GraphVars += { "MirrorCallbackCount", "60000" }; -GraphVars += { "MirrorCallbackTime", "0" }; GraphVars += { "MirrorCallbackTime", "60000" }; Paths = { diff --git a/code/ryzom/server/gpm_service.cfg b/code/ryzom/server/gpm_service.cfg index b3d254734..3d06bf73b 100644 --- a/code/ryzom/server/gpm_service.cfg +++ b/code/ryzom/server/gpm_service.cfg @@ -8,15 +8,10 @@ AESAliasName= "gpms"; -GraphVars += { "TickSpeedLoop", "0" }; GraphVars += { "TickSpeedLoop", "60000" }; -GraphVars += { "L5CallbackCount", "0" }; GraphVars += { "L5CallbackCount", "60000" }; -GraphVars += { "L5CallbackTime", "0" }; GraphVars += { "L5CallbackTime", "60000" }; -GraphVars += { "MirrorCallbackCount", "0" }; GraphVars += { "MirrorCallbackCount", "60000" }; -GraphVars += { "MirrorCallbackTime", "0" }; GraphVars += { "MirrorCallbackTime", "60000" }; Paths = { diff --git a/code/ryzom/server/mirror_service.cfg b/code/ryzom/server/mirror_service.cfg index eafe07456..6bfaef14f 100644 --- a/code/ryzom/server/mirror_service.cfg +++ b/code/ryzom/server/mirror_service.cfg @@ -8,11 +8,8 @@ AESAliasName= "ms"; -GraphVars += { "UserSpeedLoop", "0" }; GraphVars += { "UserSpeedLoop", "60000" }; -GraphVars += { "L5CallbackCount", "0" }; GraphVars += { "L5CallbackCount", "60000" }; -GraphVars += { "L5CallbackTime", "0" }; GraphVars += { "L5CallbackTime", "60000" }; Paths = { diff --git a/code/ryzom/server/monitor_service.cfg b/code/ryzom/server/monitor_service.cfg index 478333649..91119f9f5 100644 --- a/code/ryzom/server/monitor_service.cfg +++ b/code/ryzom/server/monitor_service.cfg @@ -10,11 +10,8 @@ AESAliasName= "mos"; -GraphVars += { "UserSpeedLoop", "0" }; GraphVars += { "UserSpeedLoop", "60000" }; -GraphVars += { "L5CallbackCount", "0" }; GraphVars += { "L5CallbackCount", "60000" }; -GraphVars += { "L5CallbackTime", "0" }; GraphVars += { "L5CallbackTime", "60000" }; Paths = { diff --git a/code/ryzom/server/session_browser_server.cfg b/code/ryzom/server/session_browser_server.cfg index c784e581e..9dc54e077 100644 --- a/code/ryzom/server/session_browser_server.cfg +++ b/code/ryzom/server/session_browser_server.cfg @@ -20,11 +20,8 @@ StartCommands += "sbs.plug gw", }; -GraphVars += { "NetSpeedLoop", "0" }; GraphVars += { "NetSpeedLoop", "60000" }; -GraphVars += { "L5CallbackCount", "0" }; GraphVars += { "L5CallbackCount", "60000" }; -GraphVars += { "L5CallbackTime", "0" }; GraphVars += { "L5CallbackTime", "60000" }; Paths = { diff --git a/code/ryzom/server/shard.screen.rc b/code/ryzom/server/shard.screen.rc index ba8d7f2b7..5d7dab6d1 100644 --- a/code/ryzom/server/shard.screen.rc +++ b/code/ryzom/server/shard.screen.rc @@ -12,60 +12,62 @@ bind K kill bind I login on bind O login off +hardstatus alwayslastline "%w" + chdir $RYZOM_PATH/server -screen -t aes /bin/sh service_launcher.sh aes src/ryzom_admin_service/ryzom_admin_service -A. -C. -L. --nobreak --fulladminname=admin_executor_service --shortadminname=AES +screen -t aes /bin/sh service_launcher.sh aes $RYZOM_PATH/../build/bin/ryzom_admin_service -A. -C. -L. --nobreak --fulladminname=admin_executor_service --shortadminname=AES # bms_master -screen -t bms_master /bin/sh service_launcher.sh bms_master src/backup_service/backup_service -C. -L. --nobreak --writepid -P49990 +screen -t bms_master /bin/sh service_launcher.sh bms_master $RYZOM_PATH/../build/bin/ryzom_backup_service -C. -L. --nobreak --writepid -P49990 # bms_pd_master -#screen -t bms_pd_master /bin/sh service_launcher.sh bms_pd_master src/backup_service/backup_service -C. -L. --nobreak --writepid -P49992 +#screen -t bms_pd_master /bin/sh service_launcher.sh bms_pd_master $RYZOM_PATH/../build/bin/ryzom_backup_service -C. -L. --nobreak --writepid -P49992 # egs -screen -t egs /bin/sh service_launcher.sh egs src/entities_game_service/entities_game_service -C. -L. --nobreak --writepid +screen -t egs /bin/sh service_launcher.sh egs $RYZOM_PATH/../build/bin/ryzom_entities_game_service -C. -L. --nobreak --writepid # gpms -screen -t gpms /bin/sh service_launcher.sh gpms src/gpm_service/gpm_service -C. -L. --nobreak --writepid +screen -t gpms /bin/sh service_launcher.sh gpms $RYZOM_PATH/../build/bin/ryzom_gpm_service -C. -L. --nobreak --writepid # ios -screen -t ios /bin/sh service_launcher.sh ios src/input_output_service/input_output_service -C. -L. --nobreak --writepid +screen -t ios /bin/sh service_launcher.sh ios $RYZOM_PATH/../build/bin/ryzom_ios_service -C. -L. --nobreak --writepid # rns -screen -t rns /bin/sh service_launcher.sh rns src/ryzom_naming_service/ryzom_naming_service -C. -L. --nobreak --writepid +screen -t rns /bin/sh service_launcher.sh rns $RYZOM_PATH/../build/bin/ryzom_naming_service -C. -L. --nobreak --writepid # rws -screen -t rws /bin/sh service_launcher.sh rws src/ryzom_welcome_service/ryzom_welcome_service -C. -L. --nobreak --writepid +screen -t rws /bin/sh service_launcher.sh rws $RYZOM_PATH/../build/bin/ryzom_welcome_service -C. -L. --nobreak --writepid # ts -screen -t ts /bin/sh service_launcher.sh ts src/tick_service/tick_service -C. -L. --nobreak --writepid +screen -t ts /bin/sh service_launcher.sh ts $RYZOM_PATH/../build/bin/ryzom_tick_service -C. -L. --nobreak --writepid # ms -screen -t ms /bin/sh service_launcher.sh ms src/mirror_service/mirror_service -C. -L. --nobreak --writepid +screen -t ms /bin/sh service_launcher.sh ms $RYZOM_PATH/../build/bin/ryzom_mirror_service -C. -L. --nobreak --writepid # ais_newbyland -screen -t ais_newbyland /bin/sh service_launcher.sh ais_newbyland src/ai_service/ai_service -C. -L. --nobreak --writepid -mCommon:Newbieland:Post +screen -t ais_newbyland /bin/sh service_launcher.sh ais_newbyland $RYZOM_PATH/../build/bin/ryzom_ai_service -C. -L. --nobreak --writepid -mCommon:Newbieland:Post # mfs -screen -t mfs /bin/sh service_launcher.sh mfs src/mail_forum_service/mail_forum_service -C. -L. --nobreak --writepid +screen -t mfs /bin/sh service_launcher.sh mfs $RYZOM_PATH/../build/bin/ryzom_mail_forum_service -C. -L. --nobreak --writepid # su -screen -t su /bin/sh service_launcher.sh su src/shard_unifier_service/shard_unifier_service -C. -L. --nobreak --writepid +screen -t su /bin/sh service_launcher.sh su $RYZOM_PATH/../build/bin/ryzom_shard_unifier_service -C. -L. --nobreak --writepid # fes -screen -t fes /bin/sh service_launcher.sh fes src/frontend_service/frontend_service -C. -L. --nobreak --writepid +screen -t fes /bin/sh service_launcher.sh fes $RYZOM_PATH/../build/bin/ryzom_frontend_service -C. -L. --nobreak --writepid # sbs -screen -t sbs /bin/sh service_launcher.sh sbs src/session_browser_server/session_browser_server -C. -L. --nobreak --writepid +screen -t sbs /bin/sh service_launcher.sh sbs $RYZOM_PATH/../build/bin/ryzom_session_browser_service -C. -L. --nobreak --writepid # lgs -screen -t lgs /bin/sh service_launcher.sh lgs src/logger_service/logger_service -C. -L. --nobreak --writepid +screen -t lgs /bin/sh service_launcher.sh lgs $RYZOM_PATH/../build/bin/ryzom_logger_service -C. -L. --nobreak --writepid # mos -#screen -t mos /bin/sh service_launcher.sh mos src/monitor_service/monitor_service -C. -L. --nobreak --writepid +#screen -t mos /bin/sh service_launcher.sh mos $RYZOM_PATH/../build/bin/ryzom_monitor_service -C. -L. --nobreak --writepid # pdss -#screen -t pdss /bin/sh service_launcher.sh pdss src/pd_support_service/pd_support_service -C. -L. --nobreak --writepid +#screen -t pdss /bin/sh service_launcher.sh pdss $RYZOM_PATH/../build/bin/ryzom_pd_support_service -C. -L. --nobreak --writepid # ras -screen -t ras /bin/sh service_launcher.sh ras src/ryzom_admin_service/ryzom_admin_service --fulladminname=admin_service --shortadminname=AS -C. -L. --nobreak --writepid +screen -t ras /bin/sh service_launcher.sh ras $RYZOM_PATH/../build/bin/ryzom_admin_service --fulladminname=admin_service --shortadminname=AS -C. -L. --nobreak --writepid diff --git a/code/ryzom/server/shard_unifier_service.cfg b/code/ryzom/server/shard_unifier_service.cfg index 4e0cab244..9b37f063b 100644 --- a/code/ryzom/server/shard_unifier_service.cfg +++ b/code/ryzom/server/shard_unifier_service.cfg @@ -20,11 +20,8 @@ StartCommands += }; GraphVars += { "TotalConcurentUser", "60000" }; -GraphVars += { "NetSpeedLoop", "0" }; GraphVars += { "NetSpeedLoop", "60000" }; -GraphVars += { "L5CallbackCount", "0" }; GraphVars += { "L5CallbackCount", "60000" }; -GraphVars += { "L5CallbackTime", "0" }; GraphVars += { "L5CallbackTime", "60000" }; Paths = { diff --git a/code/ryzom/server/src/ai_service/stdpch.h b/code/ryzom/server/src/ai_service/stdpch.h index 1dcb7b4ff..d0978b2f7 100644 --- a/code/ryzom/server/src/ai_service/stdpch.h +++ b/code/ryzom/server/src/ai_service/stdpch.h @@ -174,8 +174,8 @@ namespace MULTI_LINE_FORMATER { #include "game_share/ryzom_entity_id.h" #include "game_share/mode_and_behaviour.h" #include "game_share/player_visual_properties.h" -#include "../ai_share/ai_event.h" -#include "../server_share/msg_ai_service.h" +#include "ai_share/ai_event.h" +#include "server_share/msg_ai_service.h" //---------------------------------------------------------------- // ai share diff --git a/code/ryzom/server/src/frontend_service/entity_container.h b/code/ryzom/server/src/frontend_service/entity_container.h index d07cdbc76..75ae8250d 100644 --- a/code/ryzom/server/src/frontend_service/entity_container.h +++ b/code/ryzom/server/src/frontend_service/entity_container.h @@ -25,6 +25,7 @@ #include "game_share/tick_event_handler.h" #include "game_share/ryzom_mirror_properties.h" #include "client_id_lookup.h" +#include "fe_types.h" #include #include diff --git a/code/ryzom/server/src/frontend_service/frontend_service.h b/code/ryzom/server/src/frontend_service/frontend_service.h index 301e34506..12fa4df5c 100644 --- a/code/ryzom/server/src/frontend_service/frontend_service.h +++ b/code/ryzom/server/src/frontend_service/frontend_service.h @@ -33,6 +33,7 @@ #include "fe_receive_sub.h" #include "fe_send_sub.h" +#include "fe_types.h" #include "history.h" #include "prio_sub.h" #include "client_id_lookup.h" diff --git a/code/ryzom/server/src/frontend_service/id_impulsions.h b/code/ryzom/server/src/frontend_service/id_impulsions.h index 449a1da2c..e4cd1b407 100644 --- a/code/ryzom/server/src/frontend_service/id_impulsions.h +++ b/code/ryzom/server/src/frontend_service/id_impulsions.h @@ -19,6 +19,7 @@ #ifndef ID_IMPULSIONS_H #define ID_IMPULSIONS_H +#include "fe_types.h" // misc #include "nel/misc/types_nl.h" diff --git a/code/ryzom/server/src/frontend_service/stdpch.h b/code/ryzom/server/src/frontend_service/stdpch.h index dd904c1bc..7702d9717 100644 --- a/code/ryzom/server/src/frontend_service/stdpch.h +++ b/code/ryzom/server/src/frontend_service/stdpch.h @@ -67,7 +67,6 @@ #include "game_share/entity_types.h" -#include "fe_types.h" #ifndef NL_RELEASE #ifndef TRACE_SHARD_MESSAGES diff --git a/code/ryzom/server/src/pd_support_service/hourly_commands.cpp b/code/ryzom/server/src/pd_support_service/hourly_commands.cpp index 835bb8cb7..6f77396ae 100644 --- a/code/ryzom/server/src/pd_support_service/hourly_commands.cpp +++ b/code/ryzom/server/src/pd_support_service/hourly_commands.cpp @@ -46,7 +46,7 @@ public: } return; } - + // get the start time time_t startTime; time( &startTime ); @@ -73,7 +73,7 @@ public: // execute hourly tasks NLMISC::CConfigFile::CVar *commandsVar = NLNET::IService::getInstance()->ConfigFile.getVarPtr("HourlyCommands"); WARN_IF(commandsVar == NULL,"'HourlyCommands' not found in cfg file"); - + // if we have hourly commands... if (commandsVar!=NULL) { @@ -104,7 +104,7 @@ public: FILE* fileHandle= fopen(HourlyActivityLogFileName,"ab"); nlassert(fileHandle!=NULL); fprintf(fileHandle,"%02u/%02u/%u CHourlyTaskScheduler: Started: %02u:%02u, Finished: %02u:%02u, Executed %u commands Started %u Jobs\n", - ptm->tm_mday, ptm->tm_mon+1, ptm->tm_year+1900, startTime/3600%24, startTime/60%60, endTime/3600%24, endTime/60%60, commandsVar==NULL?0:commandsVar->size(), jobsRemaining ); + ptm->tm_mday, ptm->tm_mon+1, ptm->tm_year+1900, (uint)startTime/3600%24, (uint)startTime/60%60, (uint)endTime/3600%24, (uint)endTime/60%60, commandsVar==NULL?0:commandsVar->size(), jobsRemaining ); nlinfo("JobManager state: %s",CJobManager::getInstance()->getStatus().c_str()); fclose(fileHandle); } diff --git a/code/ryzom/tools/leveldesign/export/export.cpp b/code/ryzom/tools/leveldesign/export/export.cpp index c451ac094..b15e48a59 100644 --- a/code/ryzom/tools/leveldesign/export/export.cpp +++ b/code/ryzom/tools/leveldesign/export/export.cpp @@ -2023,7 +2023,7 @@ void CExport::writeFloraIG (const string &LandFile, bool bTestForWriting) // Make the .IG - string ZoneName = ""; + string ZoneName; ZoneName += NLMISC::toString(-j) + "_"; ZoneName += 'a' + (i/26); ZoneName += 'a' + (i%26); diff --git a/code/ryzom/tools/leveldesign/georges_dll/edit_list_ctrl.cpp b/code/ryzom/tools/leveldesign/georges_dll/edit_list_ctrl.cpp index 8e565dd5e..aac663c1f 100644 --- a/code/ryzom/tools/leveldesign/georges_dll/edit_list_ctrl.cpp +++ b/code/ryzom/tools/leveldesign/georges_dll/edit_list_ctrl.cpp @@ -52,7 +52,7 @@ bool CEditListCtrl::create (DWORD wStyle, RECT &rect, CWnd *parent, uint dialog_ subRect.top = 0; subRect.right = rect.right-rect.left; subRect.bottom = rect.bottom-rect.top; -#if defined(NL_COMP_VC8) || defined(NL_COMP_VC9) +#if defined(NL_COMP_VC) && NL_COMP_VC_VERSION >= 80 if (ListCtrl.CreateEx ( WS_EX_CLIENTEDGE, /*WC_LISTVIEW, "",*/ WS_CHILD|LVS_REPORT, subRect, this, 0)) #else if (ListCtrl.CreateEx ( WS_EX_CLIENTEDGE, WC_LISTVIEW, "", WS_CHILD|LVS_REPORT, subRect, this, 0)) diff --git a/code/ryzom/tools/leveldesign/georges_dll/file_tree_view.cpp b/code/ryzom/tools/leveldesign/georges_dll/file_tree_view.cpp index 9eb467b97..90b742860 100644 --- a/code/ryzom/tools/leveldesign/georges_dll/file_tree_view.cpp +++ b/code/ryzom/tools/leveldesign/georges_dll/file_tree_view.cpp @@ -54,7 +54,7 @@ bool CFileTreeCtrl::create( const RECT& rect, CWnd* pParentWnd, UINT nID ) if (CWnd::Create (className, "empty", WS_CHILD, rect, pParentWnd, nID )) -#if defined(NL_COMP_VC8) || defined(NL_COMP_VC9) +#if defined(NL_COMP_VC) && NL_COMP_VC_VERSION >= 80 if (_TreeCtrl.CreateEx (WS_EX_CLIENTEDGE, /*_T("SysTreeView32"), "",*/ TVS_HASLINES|TVS_LINESATROOT|TVS_HASBUTTONS|TVS_EDITLABELS|WS_CHILD|WS_TABSTOP, rect, this, 0)) #else if (_TreeCtrl.CreateEx (WS_EX_CLIENTEDGE, _T("SysTreeView32"), "", TVS_HASLINES|TVS_LINESATROOT|TVS_HASBUTTONS|TVS_EDITLABELS|WS_CHILD|WS_TABSTOP, rect, this, 0)) diff --git a/code/ryzom/tools/leveldesign/georges_editor_qt/CMakeLists.txt b/code/ryzom/tools/leveldesign/georges_editor_qt/CMakeLists.txt index 3edbb69fb..96dc03d06 100644 --- a/code/ryzom/tools/leveldesign/georges_editor_qt/CMakeLists.txt +++ b/code/ryzom/tools/leveldesign/georges_editor_qt/CMakeLists.txt @@ -6,12 +6,24 @@ #----------------------------------------------------------------------------- # This tells the application(s) where to find the installed data. -ADD_DEFINITIONS(-DDATA_DIR="\\"${RYZOM_SHARE_ABSOLUTE_PREFIX}/georges_editor_qt/\\"") +IF(WIN32) + SET(GEQT_DATA_DIR ".") +ELSEIF(APPLE) + # TODO: under Mac OS X, don't install but copy files in application package + SET(GEQT_DATA_DIR ".") +ELSE(WIN32) + SET(GEQT_DATA_DIR ${RYZOM_SHARE_PREFIX}/georges_editor_qt/data) + + CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/geqt_config.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/geqt_config.h) + INCLUDE_DIRECTORIES(${CMAKE_CURRENT_BINARY_DIR}) + + ADD_DEFINITIONS(-DHAVE_GEQT_CONFIG_H) +ENDIF(WIN32) ADD_SUBDIRECTORY(src) INSTALL(DIRECTORY data/ - DESTINATION ${RYZOM_SHARE_PREFIX}/georges_editor_qt/data + DESTINATION ${GEQT_DATA_DIR} COMPONENT data PATTERN "CVS" EXCLUDE PATTERN ".svn" EXCLUDE diff --git a/code/ryzom/tools/leveldesign/georges_editor_qt/geqt_config.h.cmake b/code/ryzom/tools/leveldesign/georges_editor_qt/geqt_config.h.cmake new file mode 100644 index 000000000..6f31bc7d0 --- /dev/null +++ b/code/ryzom/tools/leveldesign/georges_editor_qt/geqt_config.h.cmake @@ -0,0 +1,6 @@ +#ifndef GEQT_CONFIG_H +#define GEQT_CONFIG_H + +#define DATA_DIR "${RYZOM_SHARE_ABSOLUTE_PREFIX}/georges_editor_qt" + +#endif diff --git a/code/ryzom/tools/leveldesign/georges_editor_qt/src/georgesform_model.cpp b/code/ryzom/tools/leveldesign/georges_editor_qt/src/georgesform_model.cpp index b0c309efd..89cba843c 100644 --- a/code/ryzom/tools/leveldesign/georges_editor_qt/src/georgesform_model.cpp +++ b/code/ryzom/tools/leveldesign/georges_editor_qt/src/georgesform_model.cpp @@ -380,7 +380,7 @@ namespace NLQT //uint value_uint; //sint value_sint; //double value_double; - QString elmtType = ""; + QString elmtType; UFormElm *elmt = 0; if(root->getNodeByName(&elmt, elmName.c_str(), whereN, true)) { @@ -542,7 +542,7 @@ namespace NLQT { QList columnData; std::string value; - QString elmtType = ""; + QString elmtType; UFormElm *elmt = 0; if(root->getArrayNode(&elmt,0) && elmt) diff --git a/code/ryzom/tools/leveldesign/georges_editor_qt/src/main.cpp b/code/ryzom/tools/leveldesign/georges_editor_qt/src/main.cpp index fc6f5b849..3b0d606d3 100644 --- a/code/ryzom/tools/leveldesign/georges_editor_qt/src/main.cpp +++ b/code/ryzom/tools/leveldesign/georges_editor_qt/src/main.cpp @@ -21,6 +21,10 @@ #include "modules.h" #include "georges_splash.h" +#ifdef HAVE_GEQT_CONFIG_H +#include "geqt_config.h" +#endif + // nel_qt log file name #define NLQT_LOG_FILE "nel_qt.log" diff --git a/code/ryzom/tools/leveldesign/georges_editor_qt/src/settings_dialog.cpp b/code/ryzom/tools/leveldesign/georges_editor_qt/src/settings_dialog.cpp index 66cd03937..bb4fafd2e 100644 --- a/code/ryzom/tools/leveldesign/georges_editor_qt/src/settings_dialog.cpp +++ b/code/ryzom/tools/leveldesign/georges_editor_qt/src/settings_dialog.cpp @@ -152,7 +152,7 @@ namespace NLQT QString oldLdPath = Modules::config().getValue("LeveldesignPath", std::string("")).c_str(); if (oldLdPath != ui.leveldesignPath->text()) { - std::string ldPath = ui.leveldesignPath->text().toUtf8(); + std::string ldPath = ui.leveldesignPath->text().toUtf8().constData(); Modules::config().getConfigFile().getVar("LeveldesignPath").forceAsString(ldPath); Q_EMIT ldPathChanged(ldPath.c_str()); // TODO: remove old Path from CPath @@ -171,8 +171,8 @@ namespace NLQT std::vector addList; for (sint i = 0; i < ui.pathsListWidget->count(); ++i) { - std::string str = ui.pathsListWidget->item(i)->text().toUtf8(); - if (str != "") + std::string str = ui.pathsListWidget->item(i)->text().toUtf8().constData(); + if (!str.empty()) { list.push_back(str); if (!sl.contains(str.c_str())) diff --git a/code/ryzom/tools/leveldesign/mission_compiler_lib/step_content.cpp b/code/ryzom/tools/leveldesign/mission_compiler_lib/step_content.cpp index 13e2d0a5b..adcf6c680 100644 --- a/code/ryzom/tools/leveldesign/mission_compiler_lib/step_content.cpp +++ b/code/ryzom/tools/leveldesign/mission_compiler_lib/step_content.cpp @@ -1809,7 +1809,7 @@ string CContentObjective::genCode(CMissionData &md) // --------------------------------------------------------------------------- /*std::string CContentObjective::genNbGuildMembersNeededOption(CMissionData &md) { - string ret = ""; + string ret; // If we are in a guild mission we add the 'nb_guild_members_needed' option to the script if (md.isGuildMission()) { diff --git a/code/ryzom/tools/leveldesign/mp_generator/main.cpp b/code/ryzom/tools/leveldesign/mp_generator/main.cpp index e61546a8d..decb9b766 100644 --- a/code/ryzom/tools/leveldesign/mp_generator/main.cpp +++ b/code/ryzom/tools/leveldesign/mp_generator/main.cpp @@ -1455,7 +1455,7 @@ void GenerateDoc() AltDocs[c].write( "" + string(DataColStr[cc]) + "" ); AltDocs[c].write( "" ); string previousKey = "[NO PREVIOUS]"; // not a blank string, because it may be a valid value - string previousName = ""; + string previousName; for ( CRMData::CLookup::const_iterator isd=SortableData.lookup( c ).begin(); isd!=SortableData.lookup( c ).end(); ++isd ) { const TRMItem& item = SortableData.getRow( (*isd).second ); diff --git a/code/ryzom/tools/pd_parser/parse_node.h b/code/ryzom/tools/pd_parser/parse_node.h index b1c43fa4a..ad2b6a8f2 100644 --- a/code/ryzom/tools/pd_parser/parse_node.h +++ b/code/ryzom/tools/pd_parser/parse_node.h @@ -870,7 +870,7 @@ public: std::string getIndexName(uint32 value) const { - std::string result = ""; + std::string result; uint i; for (i=0; iName; return res; @@ -1078,7 +1078,7 @@ public: std::string getDebugCallStringFmt() { uint i, idx=0; - std::string res = ""; + std::string res; for (i=0; i