Ignore:
Timestamp:
Jul 11, 2010, 9:39:56 AM (14 years ago)
Author:
Torben Dannhauer
Message:

new cluster implementation added: ENet
ENet is a reliable UDP implementation with quite simple usage and high performance for transmission with small or medium size packet.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • osgVisual/CMakeLists.txt

    r60 r65  
    154154
    155155# Module cluster
    156 SET(USE_CLUSTER_UDP ON CACHE BOOL "Enable to use the UDP Implementation for the cluster interface")
    157 SET(USE_CLUSTER_ASIO_TCP_IOSTREAM ON CACHE BOOL "Enable to use the Boost ASIO TCP iostream Implementation for the cluster interface")
     156SET(USE_CLUSTER_UDP OFF CACHE BOOL "Enable to use the UDP Implementation for the cluster interface")
     157SET(USE_CLUSTER_ASIO_TCP_IOSTREAM OFF CACHE BOOL "Enable to use the Boost ASIO TCP iostream implementation for the cluster interface")
     158SET(USE_CLUSTER_ENET ON CACHE BOOL "Enable to use the ENet reliable UDP library implementation for the cluster interface")
    158159IF( USE_CLUSTER_UDP   )
    159160                SET(SOURCES
     
    186187ENDIF()
    187188
    188 IF(NOT USE_CLUSTER_UDP AND NOT USE_CLUSTER_ASIO_TCP_IOSTREAM)
     189IF( USE_CLUSTER_ENET )
     190                SET(SOURCES
     191                        ${SOURCES}
     192                        include/cluster/dataIO_cluster.h
     193                        include/cluster/dataIO_clusterENet.h
     194                        src/cluster/dataIO_clusterENet.cpp
     195                        include/cluster/dataIO_clusterENet_implementation.h
     196                        src/cluster/dataIO_clusterENet_implementation.cpp
     197                        src/cluster/enet/callbacks.c
     198                        src/cluster/enet/compress.c
     199                        src/cluster/enet/host.c
     200                        src/cluster/enet/list.c
     201                        src/cluster/enet/packet.c
     202                        src/cluster/enet/peer.c
     203                        src/cluster/enet/protocol.c
     204                        src/cluster/enet/unix.c
     205                        src/cluster/enet/win32.c
     206                        include/cluster/enet/callbacks.h
     207                        include/cluster/enet/enet.h
     208                        include/cluster/enet/list.h
     209                        include/cluster/enet/protocol.h
     210                        include/cluster/enet/time.h
     211                        include/cluster/enet/types.h
     212                        include/cluster/enet/unix.h
     213                        include/cluster/enet/utility.h
     214                        include/cluster/enet/win32.h
     215                )
     216                ADD_DEFINITIONS( "-DUSE_CLUSTER_ENET" )
     217               
     218ENDIF()
     219
     220IF(NOT USE_CLUSTER_UDP AND NOT USE_CLUSTER_ASIO_TCP_IOSTREAM AND NOT USE_CLUSTER_ENET)
    189221                SET(SOURCES
    190222                        ${SOURCES}
     
    297329ENDIF(USE_VISTA2D)
    298330
    299 
     331IF(USE_CLUSTER_ENET)
     332        TARGET_LINK_LIBRARIES(osgVisual "winmm.lib" "ws2_32.lib" )
     333ENDIF(USE_CLUSTER_ENET)
    300334
    301335# CMAKE Fix for VS to not prepend build type to path.
Note: See TracChangeset for help on using the changeset viewer.