package vendor:ENet

⌘K
Ctrl+K
or
/

    Index

    Constants (45)
    Variables (0)

    This section is empty.

    Procedures (70)
    Procedure Groups (0)

    This section is empty.

    Types

    Acknowledgment ¶

    Acknowledgment :: struct {
    	acknowledgementList: ListNode,
    	sentTime:            u32,
    	command:             Protocol,
    }

    Buffer ¶

    Buffer :: struct {
    	data:       rawptr,
    	dataLength: uint,
    }

    Callbacks ¶

    Callbacks :: struct {
    	malloc:    proc "c" (size: uint) -> rawptr,
    	free:      proc "c" (memory: rawptr),
    	no_memory: proc "c" (),
    }
    Related Procedures With Parameters

    Channel ¶

    Channel :: struct {
    	outgoingReliableSequenceNumber:   u16,
    	outgoingUnreliableSequenceNumber: u16,
    	usedReliableWindows:              u16,
    	reliableWindows:                  [16]u16,
    	incomingReliableSequenceNumber:   u16,
    	incomingUnreliableSequenceNumber: u16,
    	incomingReliableCommands:         List,
    	incomingUnreliableCommands:       List,
    }

    ChecksumCallback ¶

    ChecksumCallback :: proc "c" (buffers: [^]Buffer, bufferCount: uint) -> u32

    Compressor ¶

    Compressor :: struct {
    	context_:   rawptr,
    	compress:   proc "c" (context_: rawptr, inBuffers: [^]Buffer, inBufferCount: uint, inLimit: uint, outData: [^]u8, outLimit: uint) -> uint,
    	decompress: proc "c" (context_: rawptr, inData: [^]u8, inLimit: uint, outData: [^]u8, outLimit: uint) -> uint,
    	destroy:    proc "c" (context_: rawptr),
    }
    Related Procedures With Parameters

    Event ¶

    Event :: struct {
    	type:      EventType,
    	peer:      ^Peer,
    	channelID: u8,
    	data:      u32,
    	packet:    ^Packet,
    }
    Related Procedures With Parameters

    EventType ¶

    EventType :: enum i32 {
    	NONE       = 0, 
    	CONNECT    = 1, 
    	DISCONNECT = 2, 
    	RECEIVE    = 3, 
    }

    Host ¶

    Host :: struct {
    	socket:                     Socket,
    	address:                    Address,
    	incomingBandwidth:          u32,
    	outgoingBandwidth:          u32,
    	bandwidthThrottleEpoch:     u32,
    	mtu:                        u32,
    	randomSeed:                 u32,
    	recalculateBandwidthLimits: i32,
    	peers:                      [^]Peer,
    	peerCount:                  uint,
    	channelLimit:               uint,
    	serviceTime:                u32,
    	dispatchQueue:              List,
    	continueSending:            i32,
    	packetSize:                 uint,
    	headerFlags:                u16,
    	commands:                   [32]Protocol,
    	commandCount:               uint,
    	buffers:                    [65]Buffer,
    	bufferCount:                uint,
    	checksum:                   ChecksumCallback,
    	compressor:                 Compressor,
    	packetData:                 [2][4096]u8,
    	receivedAddress:            Address,
    	receivedData:               [^]u8,
    	receivedDataLength:         uint,
    	totalSentData:              u32,
    	totalSentPackets:           u32,
    	totalReceivedData:          u32,
    	totalReceivedPackets:       u32,
    	intercept:                  InterceptCallback,
    	connectedPeers:             uint,
    	bandwidthLimitedPeers:      uint,
    	duplicatePeers:             uint,
    	maximumPacketSize:          uint,
    	maximumWaitingData:         uint,
    }
    Related Procedures With Parameters
    Related Procedures With Returns

    IncomingCommand ¶

    IncomingCommand :: struct {
    	incomingCommandList:      ListNode,
    	reliableSequenceNumber:   u16,
    	unreliableSequenceNumber: u16,
    	command:                  Protocol,
    	fragmentCount:            u32,
    	fragmentsRemaining:       u32,
    	fragments:                [^]u32,
    	packet:                   ^Packet,
    }

    InterceptCallback ¶

    InterceptCallback :: proc "c" (host: ^Host, event: ^Event) -> i32

    List ¶

    List :: struct {
    	sentinel: ListNode,
    }

    ListNode ¶

    ListNode :: struct {
    	next:     ^ListNode,
    	previous: ^ListNode,
    }

    OutgoingCommand ¶

    OutgoingCommand :: struct {
    	outgoingCommandList:      ListNode,
    	reliableSequenceNumber:   u16,
    	unreliableSequenceNumber: u16,
    	sentTime:                 u32,
    	roundTripTimeout:         u32,
    	roundTripTimeoutLimit:    u32,
    	fragmentOffset:           u32,
    	fragmentLength:           u16,
    	sendAttempts:             u16,
    	command:                  Protocol,
    	packet:                   ^Packet,
    }

    Packet ¶

    Packet :: struct {
    	referenceCount: uint,
    	flags:          u32,
    	data:           [^]u8,
    	dataLength:     uint,
    	freeCallback:   PacketFreeCallback,
    	userData:       rawptr,
    }
    Related Procedures With Parameters
    Related Procedures With Returns

    PacketFlag ¶

    PacketFlag :: enum i32 {
    	RELIABLE            = 0, 
    	UNSEQUENCED         = 1, 
    	NO_ALLOCATE         = 2, 
    	UNRELIABLE_FRAGMENT = 3, 
    	FLAG_SENT           = 8, 
    }

    PacketFlags ¶

    PacketFlags :: bit_set[PacketFlag; i32]

    PacketFreeCallback ¶

    PacketFreeCallback :: proc "c" (packet: ^Packet)

    Peer ¶

    Peer :: struct {
    	dispatchList:                   ListNode,
    	host:                           ^Host,
    	outgoingPeerID:                 u16,
    	incomingPeerID:                 u16,
    	connectID:                      u32,
    	outgoingSessionID:              u8,
    	incomingSessionID:              u8,
    	address:                        Address,
    	data:                           rawptr,
    	state:                          PeerState,
    	channels:                       [^]Channel,
    	channelCount:                   uint,
    	incomingBandwidth:              u32,
    	outgoingBandwidth:              u32,
    	incomingBandwidthThrottleEpoch: u32,
    	outgoingBandwidthThrottleEpoch: u32,
    	incomingDataTotal:              u32,
    	outgoingDataTotal:              u32,
    	lastSendTime:                   u32,
    	lastReceiveTime:                u32,
    	nextTimeout:                    u32,
    	earliestTimeout:                u32,
    	packetLossEpoch:                u32,
    	packetsSent:                    u32,
    	packetsLost:                    u32,
    	packetLoss:                     u32,
    	packetLossVariance:             u32,
    	packetThrottle:                 u32,
    	packetThrottleLimit:            u32,
    	packetThrottleCounter:          u32,
    	packetThrottleEpoch:            u32,
    	packetThrottleAcceleration:     u32,
    	packetThrottleDeceleration:     u32,
    	packetThrottleInterval:         u32,
    	pingInterval:                   u32,
    	timeoutLimit:                   u32,
    	timeoutMinimum:                 u32,
    	timeoutMaximum:                 u32,
    	lastRoundTripTime:              u32,
    	lowestRoundTripTime:            u32,
    	lastRoundTripTimeVariance:      u32,
    	highestRoundTripTimeVariance:   u32,
    	roundTripTime:                  u32,
    	roundTripTimeVariance:          u32,
    	mtu:                            u32,
    	windowSize:                     u32,
    	reliableDataInTransit:          u32,
    	outgoingReliableSequenceNumber: u16,
    	acknowledgements:               List,
    	sentReliableCommands:           List,
    	sentUnreliableCommands:         List,
    	outgoingCommands:               List,
    	dispatchedCommands:             List,
    	flags:                          u16,
    	reserved:                       u16,
    	incomingUnsequencedGroup:       u16,
    	outgoingUnsequencedGroup:       u16,
    	unsequencedWindow:              [32]u32,
    	eventData:                      u32,
    	totalWaitingData:               uint,
    }
    Related Procedures With Parameters
    Related Procedures With Returns

    PeerFlag ¶

    PeerFlag :: enum i32 {
    	NEEDS_DISPATCH, 
    }

    PeerState ¶

    PeerState :: enum i32 {
    	DISCONNECTED, 
    	CONNECTING, 
    	ACKNOWLEDGING_CONNECT, 
    	CONNECTION_PENDING, 
    	CONNECTION_SUCCEEDED, 
    	CONNECTED, 
    	DISCONNECT_LATER, 
    	DISCONNECTING, 
    	ACKNOWLEDGING_DISCONNECT, 
    	ZOMBIE, 
    }

    Protocol ¶

    Protocol :: struct #raw_union {
    	header:            ProtocolCommandHeader,
    	acknowledge:       ProtocolAcknowledge,
    	connect:           ProtocolConnect,
    	verifyConnect:     ProtocolVerifyConnect,
    	disconnect:        ProtocolDisconnect,
    	ping:              ProtocolPing,
    	sendReliable:      ProtocolSendReliable,
    	sendUnreliable:    ProtocolSendUnreliable,
    	sendUnsequenced:   ProtocolSendUnsequenced,
    	sendFragment:      ProtocolSendFragment,
    	bandwidthLimit:    ProtocolBandwidthLimit,
    	throttleConfigure: ProtocolThrottleConfigure,
    }

    ProtocolAcknowledge ¶

    ProtocolAcknowledge :: struct #packed {
    	header:                     ProtocolCommandHeader,
    	outgoingPeerID:             u16,
    	incomingSessionID:          u8,
    	outgoingSessionID:          u8,
    	mtu:                        u32,
    	windowSize:                 u32,
    	channelCount:               u32,
    	incomingBandwidth:          u32,
    	outgoingBandwidth:          u32,
    	packetThrottleInterval:     u32,
    	packetThrottleAcceleration: u32,
    	packetThrottleDeceleration: u32,
    	connectID:                  u32,
    	data:                       u32,
    }

    ProtocolBandwidthLimit ¶

    ProtocolBandwidthLimit :: struct #packed {
    	header:            ProtocolCommandHeader,
    	incomingBandwidth: u32,
    	outgoingBandwidth: u32,
    }

    ProtocolCommand ¶

    ProtocolCommand :: enum i32 {
    	NONE                     = 0, 
    	ACKNOWLEDGE              = 1, 
    	CONNECT                  = 2, 
    	VERIFY_CONNECT           = 3, 
    	DISCONNECT               = 4, 
    	PING                     = 5, 
    	SEND_RELIABLE            = 6, 
    	SEND_UNRELIABLE          = 7, 
    	SEND_FRAGMENT            = 8, 
    	SEND_UNSEQUENCED         = 9, 
    	BANDWIDTH_LIMIT          = 10, 
    	THROTTLE_CONFIGURE       = 11, 
    	SEND_UNRELIABLE_FRAGMENT = 12, 
    	COUNT                    = 13, 
    	MASK                     = 15, 
    }

    ProtocolCommandHeader ¶

    ProtocolCommandHeader :: struct #packed {
    	command:                u8,
    	channelID:              u8,
    	reliableSequenceNumber: u16,
    }

    ProtocolConnect ¶

    ProtocolConnect :: struct #packed {
    	header:                     ProtocolCommandHeader,
    	outgoingPeerID:             u16,
    	incomingSessionID:          u8,
    	outgoingSessionID:          u8,
    	mtu:                        u32,
    	windowSize:                 u32,
    	channelCount:               u32,
    	incomingBandwidth:          u32,
    	outgoingBandwidth:          u32,
    	packetThrottleInterval:     u32,
    	packetThrottleAcceleration: u32,
    	packetThrottleDeceleration: u32,
    	connectID:                  u32,
    	data:                       u32,
    }

    ProtocolDisconnect ¶

    ProtocolDisconnect :: struct #packed {
    	header: ProtocolCommandHeader,
    	data:   u32,
    }

    ProtocolFlag ¶

    ProtocolFlag :: enum i32 {
    	COMMAND_ACKNOWLEDGE  = 128, 
    	COMMAND_UNSEQUENCED  = 64, 
    	HEADER_COMPRESSED    = 16384, 
    	HEADER_SENT_TIME     = 32768, 
    	HEADER_MASK          = 49152, 
    	HEADER_SESSION_MASK  = 12288, 
    	HEADER_SESSION_SHIFT = 12, 
    }

    ProtocolHeader ¶

    ProtocolHeader :: struct #packed {
    	peerID:   u16,
    	sentTime: u16,
    }

    ProtocolPing ¶

    ProtocolPing :: struct #packed {
    	header: ProtocolCommandHeader,
    }

    ProtocolSendFragment ¶

    ProtocolSendFragment :: struct #packed {
    	header:              ProtocolCommandHeader,
    	startSequenceNumber: u16,
    	dataLength:          u16,
    	fragmentCount:       u32,
    	fragmentNumber:      u32,
    	totalLength:         u32,
    	fragmentOffset:      u32,
    }

    ProtocolSendReliable ¶

    ProtocolSendReliable :: struct #packed {
    	header:     ProtocolCommandHeader,
    	dataLength: u16,
    }

    ProtocolSendUnreliable ¶

    ProtocolSendUnreliable :: struct #packed {
    	header:                   ProtocolCommandHeader,
    	unreliableSequenceNumber: u16,
    	dataLength:               u16,
    }

    ProtocolSendUnsequenced ¶

    ProtocolSendUnsequenced :: struct #packed {
    	header:           ProtocolCommandHeader,
    	unsequencedGroup: u16,
    	dataLength:       u16,
    }

    ProtocolThrottleConfigure ¶

    ProtocolThrottleConfigure :: struct #packed {
    	header:                     ProtocolCommandHeader,
    	packetThrottleInterval:     u32,
    	packetThrottleAcceleration: u32,
    	packetThrottleDeceleration: u32,
    }

    ProtocolVerifyConnect ¶

    ProtocolVerifyConnect :: struct #packed {
    	header:                     ProtocolCommandHeader,
    	outgoingPeerID:             u16,
    	incomingSessionID:          u8,
    	outgoingSessionID:          u8,
    	mtu:                        u32,
    	windowSize:                 u32,
    	channelCount:               u32,
    	incomingBandwidth:          u32,
    	outgoingBandwidth:          u32,
    	packetThrottleInterval:     u32,
    	packetThrottleAcceleration: u32,
    	packetThrottleDeceleration: u32,
    	connectID:                  u32,
    }

    SocketOption ¶

    SocketOption :: enum i32 {
    	NONBLOCK  = 1, 
    	BROADCAST = 2, 
    	RCVBUF    = 3, 
    	SNDBUF    = 4, 
    	REUSEADDR = 5, 
    	RCVTIMEO  = 6, 
    	SNDTIMEO  = 7, 
    	ERROR     = 8, 
    	NODELAY   = 9, 
    }
    Related Procedures With Parameters

    SocketSet ¶

    SocketSet :: struct {
    	fd_count: u32,
    	fd_array: [64]uintptr,
    }
    Related Procedures With Parameters

    SocketShutdown ¶

    SocketShutdown :: enum i32 {
    	READ       = 0, 
    	WRITE      = 1, 
    	READ_WRITE = 2, 
    }
    Related Procedures With Parameters

    SocketType ¶

    SocketType :: enum i32 {
    	STREAM   = 1, 
    	DATAGRAM = 2, 
    }
    Related Procedures With Parameters

    SocketWait ¶

    SocketWait :: enum i32 {
    	NONE      = 0, 
    	SEND      = 1, 
    	RECEIVE   = 2, 
    	INTERRUPT = 4, 
    }

    Version ¶

    Version :: u32

    Constants

    BUFFER_MAXIMUM ¶

    BUFFER_MAXIMUM :: 1 + 2 * PROTOCOL_MAXIMUM_PACKET_COMMANDS

    HOST_ANY ¶

    HOST_ANY :: u32(0)

    HOST_BANDWIDTH_THROTTLE_INTERVAL ¶

    HOST_BANDWIDTH_THROTTLE_INTERVAL :: 1000

    HOST_BROADCAST ¶

    HOST_BROADCAST :: u32(0xffffffff)

    HOST_DEFAULT_MAXIMUM_PACKET_SIZE ¶

    HOST_DEFAULT_MAXIMUM_PACKET_SIZE :: 32 * 1024 * 1024

    HOST_DEFAULT_MAXIMUM_WAITING_DATA ¶

    HOST_DEFAULT_MAXIMUM_WAITING_DATA :: 32 * 1024 * 1024

    HOST_DEFAULT_MTU ¶

    HOST_DEFAULT_MTU :: 1400

    HOST_RECEIVE_BUFFER_SIZE ¶

    HOST_RECEIVE_BUFFER_SIZE :: 256 * 1024

    HOST_SEND_BUFFER_SIZE ¶

    HOST_SEND_BUFFER_SIZE :: 256 * 1024

    PEER_DEFAULT_PACKET_THROTTLE ¶

    PEER_DEFAULT_PACKET_THROTTLE :: 32

    PEER_DEFAULT_ROUND_TRIP_TIME ¶

    PEER_DEFAULT_ROUND_TRIP_TIME :: 500

    PEER_FREE_RELIABLE_WINDOWS ¶

    PEER_FREE_RELIABLE_WINDOWS :: 8

    PEER_FREE_UNSEQUENCED_WINDOWS ¶

    PEER_FREE_UNSEQUENCED_WINDOWS :: 32

    PEER_PACKET_LOSS_INTERVAL ¶

    PEER_PACKET_LOSS_INTERVAL :: 10000

    PEER_PACKET_LOSS_SCALE ¶

    PEER_PACKET_LOSS_SCALE :: 1 << 16

    PEER_PACKET_THROTTLE_ACCELERATION ¶

    PEER_PACKET_THROTTLE_ACCELERATION :: 2

    PEER_PACKET_THROTTLE_COUNTER ¶

    PEER_PACKET_THROTTLE_COUNTER :: 7

    PEER_PACKET_THROTTLE_DECELERATION ¶

    PEER_PACKET_THROTTLE_DECELERATION :: 2

    PEER_PACKET_THROTTLE_INTERVAL ¶

    PEER_PACKET_THROTTLE_INTERVAL :: 5000

    PEER_PACKET_THROTTLE_SCALE ¶

    PEER_PACKET_THROTTLE_SCALE :: 32

    PEER_PING_INTERVAL ¶

    PEER_PING_INTERVAL :: 500

    PEER_RELIABLE_WINDOWS ¶

    PEER_RELIABLE_WINDOWS :: 16

    PEER_RELIABLE_WINDOW_SIZE ¶

    PEER_RELIABLE_WINDOW_SIZE :: 0x1000

    PEER_TIMEOUT_LIMIT ¶

    PEER_TIMEOUT_LIMIT :: 32

    PEER_TIMEOUT_MAXIMUM ¶

    PEER_TIMEOUT_MAXIMUM :: 30000

    PEER_TIMEOUT_MINIMUM ¶

    PEER_TIMEOUT_MINIMUM :: 5000

    PEER_UNSEQUENCED_WINDOWS ¶

    PEER_UNSEQUENCED_WINDOWS :: 64

    PEER_UNSEQUENCED_WINDOW_SIZE ¶

    PEER_UNSEQUENCED_WINDOW_SIZE :: 1024

    PEER_WINDOW_SIZE_SCALE ¶

    PEER_WINDOW_SIZE_SCALE :: 64 * 1024

    PORT_ANY ¶

    PORT_ANY :: u16(0)

    PROTOCOL_MAXIMUM_CHANNEL_COUNT ¶

    PROTOCOL_MAXIMUM_CHANNEL_COUNT :: 255

    PROTOCOL_MAXIMUM_FRAGMENT_COUNT ¶

    PROTOCOL_MAXIMUM_FRAGMENT_COUNT :: 1024 * 1024

    PROTOCOL_MAXIMUM_MTU ¶

    PROTOCOL_MAXIMUM_MTU :: 4096

    PROTOCOL_MAXIMUM_PACKET_COMMANDS ¶

    PROTOCOL_MAXIMUM_PACKET_COMMANDS :: 32

    PROTOCOL_MAXIMUM_PEER_ID ¶

    PROTOCOL_MAXIMUM_PEER_ID :: 0xFFF

    PROTOCOL_MAXIMUM_WINDOW_SIZE ¶

    PROTOCOL_MAXIMUM_WINDOW_SIZE :: 65536

    PROTOCOL_MINIMUM_CHANNEL_COUNT ¶

    PROTOCOL_MINIMUM_CHANNEL_COUNT :: 1

    PROTOCOL_MINIMUM_MTU ¶

    PROTOCOL_MINIMUM_MTU :: 576

    PROTOCOL_MINIMUM_WINDOW_SIZE ¶

    PROTOCOL_MINIMUM_WINDOW_SIZE :: 4096

    SOCKET_NULL ¶

    SOCKET_NULL :: Socket(~uintptr(0))

    TIME_OVERFLOW ¶

    TIME_OVERFLOW :: u32(86400000)

    VERSION ¶

    VERSION: u32 : (u32(VERSION_MAJOR) << 16) | (u32(VERSION_MINOR) << 8) | u32(VERSION_PATCH)
     

    Odin does not have "macros" or compile-time evaluation of functions, so the following is just the same as. VERSION :: VERSION_CREATE(VERSION_MAJOR, VERSION_MINOR, VERSION_PATCH);

    VERSION_MAJOR ¶

    VERSION_MAJOR :: u8(1)

    VERSION_MINOR ¶

    VERSION_MINOR :: u8(3)

    VERSION_PATCH ¶

    VERSION_PATCH :: u8(17)

    Variables

    This section is empty.

    Procedures

    HOST_TO_NET_16 ¶

    HOST_TO_NET_16 :: proc(value: u16) -> u16 {…}
     

    Network byte order is always Big Endian. Instead of using the method ENet uses (leveraging {n,h}to{n,h}{s,l}), we can just use Odin's endianess types to get the correct byte swaps, if any.

    HOST_TO_NET_32 ¶

    HOST_TO_NET_32 :: proc(value: u32) -> u32 {…}

    NET_TO_HOST_16 ¶

    NET_TO_HOST_16 :: proc(value: u16) -> u16 {…}

    NET_TO_HOST_32 ¶

    NET_TO_HOST_32 :: proc(value: u32) -> u32 {…}

    SOCKETSET_ADD ¶

    SOCKETSET_ADD :: proc(sockset: ^SocketSet, socket: Socket) {…}

    SOCKETSET_EMPTY ¶

    SOCKETSET_EMPTY :: proc(sockset: ^SocketSet) {…}

    SOCKETSET_REMOVE ¶

    SOCKETSET_REMOVE :: proc(sockset: ^SocketSet, socket: Socket) {…}

    SOCKSET_CHECK ¶

    SOCKSET_CHECK :: proc(sockset: ^SocketSet, socket: Socket) -> bool {…}

    TIME_DIFFERENCE ¶

    TIME_DIFFERENCE :: proc(a, b: u32) -> u32 {…}

    TIME_GREATER ¶

    TIME_GREATER :: proc(a, b: u32) -> bool {…}

    TIME_GREATER_EQUAL ¶

    TIME_GREATER_EQUAL :: proc(a, b: u32) -> bool {…}

    TIME_LESS ¶

    TIME_LESS :: proc(a, b: u32) -> bool {…}

    TIME_LESS_EQUAL ¶

    TIME_LESS_EQUAL :: proc(a, b: u32) -> bool {…}

    VERSION_CREATE ¶

    VERSION_CREATE :: proc(major, minor, patch: u8) -> u32 {…}

    VERSION_GET_MAJOR ¶

    VERSION_GET_MAJOR :: proc(version: u32) -> u8 {…}

    VERSION_GET_MINOR ¶

    VERSION_GET_MINOR :: proc(version: u32) -> u8 {…}

    VERSION_GET_PATCH ¶

    VERSION_GET_PATCH :: proc(version: u32) -> u8 {…}

    address_get_host ¶

    address_get_host :: proc "c" (address: ^Address, hostName: [^]u8, nameLength: uint) -> i32 ---

    address_get_host_ip ¶

    address_get_host_ip :: proc "c" (address: ^Address, hostName: [^]u8, nameLength: uint) -> i32 ---

    address_set_host ¶

    address_set_host :: proc "c" (address: ^Address, hostName: cstring) -> i32 ---

    address_set_host_ip ¶

    address_set_host_ip :: proc "c" (address: ^Address, hostName: cstring) -> i32 ---

    crc32 ¶

    crc32 :: proc "c" (buffers: [^]Buffer, bufferCount: uint) -> u32 ---

    deinitialize ¶

    deinitialize :: proc "c" () ---

    host_bandwidth_limit ¶

    host_bandwidth_limit :: proc "c" (host: ^Host, incomingBandwidth: u32, outgoingBandwidth: u32) ---

    host_broadcast ¶

    host_broadcast :: proc "c" (host: ^Host, channelID: u8, packet: ^Packet) ---

    host_channel_limit ¶

    host_channel_limit :: proc "c" (host: ^Host, channelLimit: uint) ---

    host_check_events ¶

    host_check_events :: proc "c" (host: ^Host, event: ^Event) -> i32 ---

    host_compress ¶

    host_compress :: proc "c" (host: ^Host, compressor: ^Compressor) ---

    host_compress_with_range_coder ¶

    host_compress_with_range_coder :: proc "c" (host: ^Host) -> i32 ---

    host_connect ¶

    host_connect :: proc "c" (host: ^Host, address: ^Address, channelCount: uint, data: u32) -> ^Peer ---

    host_create ¶

    host_create :: proc "c" (address: ^Address, peerCount: uint, channelLimit: uint, incomingBandwidth: u32, outgoingBandwidth: u32) -> ^Host ---

    host_destroy ¶

    host_destroy :: proc "c" (host: ^Host) ---

    host_flush ¶

    host_flush :: proc "c" (host: ^Host) ---

    host_service ¶

    host_service :: proc "c" (host: ^Host, event: ^Event, timeout: u32) -> i32 ---

    initialize ¶

    initialize :: proc "c" () -> i32 ---

    initialize_with_callbacks ¶

    initialize_with_callbacks :: proc "c" (version: u32, inits: ^Callbacks) -> i32 ---

    linked_version ¶

    linked_version :: proc "c" () -> u32 ---

    packet_create ¶

    packet_create :: proc "c" (data: rawptr, dataLength: uint, flags: bit_set[PacketFlag; i32]) -> ^Packet ---

    packet_destroy ¶

    packet_destroy :: proc "c" (packet: ^Packet) ---

    packet_resize ¶

    packet_resize :: proc "c" (packet: ^Packet, dataLength: uint) -> i32 ---

    peer_disconnect ¶

    peer_disconnect :: proc "c" (peer: ^Peer, data: u32) ---

    peer_disconnect_later ¶

    peer_disconnect_later :: proc "c" (peer: ^Peer, data: u32) ---

    peer_disconnect_now ¶

    peer_disconnect_now :: proc "c" (peer: ^Peer, data: u32) ---

    peer_ping ¶

    peer_ping :: proc "c" (peer: ^Peer) ---

    peer_ping_interval ¶

    peer_ping_interval :: proc "c" (peer: ^Peer, pingInterval: u32) ---

    peer_receive ¶

    peer_receive :: proc "c" (peer: ^Peer, channelID: ^u8) -> ^Packet ---

    peer_reset ¶

    peer_reset :: proc "c" (peer: ^Peer) ---

    peer_send ¶

    peer_send :: proc "c" (peer: ^Peer, channelID: u8, packet: ^Packet) -> i32 ---

    peer_throttle_configure ¶

    peer_throttle_configure :: proc "c" (peer: ^Peer, interval: u32, acceleration: u32, deceleration: u32) ---

    peer_timeout ¶

    peer_timeout :: proc "c" (peer: ^Peer, timoutLimit: u32, timeoutMinimum: u32, timeoutMaximum: u32) ---

    range_coder_compress ¶

    range_coder_compress :: proc "c" (
    	ctx:           rawptr, 
    	inBuffers:     [^]Buffer, 
    	inBufferCount: uint, 
    	inLimit:       uint, 
    	outData:       [^]u8, 
    	outLimit:      uint, 
    ) -> uint ---

    range_coder_create ¶

    range_coder_create :: proc "c" () -> rawptr ---

    range_coder_decompress ¶

    range_coder_decompress :: proc "c" (ctx: rawptr, inData: [^]u8, inLimit: uint, outData: [^]u8, outLimit: uint) -> uint ---

    range_coder_destroy ¶

    range_coder_destroy :: proc "c" (ctx: rawptr) ---

    socket_accept ¶

    socket_accept :: proc "c" (socket: Socket, address: ^Address) -> Socket ---

    socket_bind ¶

    socket_bind :: proc "c" (socket: Socket, address: ^Address) -> i32 ---

    socket_connect ¶

    socket_connect :: proc "c" (socket: Socket, address: ^Address) -> i32 ---

    socket_create ¶

    socket_create :: proc "c" (_: SocketType) -> Socket ---

    socket_destroy ¶

    socket_destroy :: proc "c" (socket: Socket) ---

    socket_get_address ¶

    socket_get_address :: proc "c" (socket: Socket, address: ^Address) -> i32 ---

    socket_get_option ¶

    socket_get_option :: proc "c" (socket: Socket, option: SocketOption, value: ^i32) -> i32 ---

    socket_listen ¶

    socket_listen :: proc "c" (socket: Socket, backlog: i32) -> i32 ---

    socket_receive ¶

    socket_receive :: proc "c" (socket: Socket, address: ^Address, buffers: [^]Buffer, bufferCount: uint) -> i32 ---

    socket_send ¶

    socket_send :: proc "c" (socket: Socket, address: ^Address, buffers: [^]Buffer, bufferCount: uint) -> i32 ---

    socket_set_option ¶

    socket_set_option :: proc "c" (socket: Socket, option: SocketOption, value: i32) -> i32 ---

    socket_shutdown ¶

    socket_shutdown :: proc "c" (socket: Socket, how: SocketShutdown) -> i32 ---

    socket_wait ¶

    socket_wait :: proc "c" (socket: Socket, condition: ^u32, timeout: u32) -> i32 ---

    socketset_select ¶

    socketset_select :: proc "c" (socket: Socket, readSet: ^SocketSet, writeSet: ^SocketSet, timeout: u32) -> i32 ---

    time_get ¶

    time_get :: proc "c" () -> u32 ---

    time_set ¶

    time_set :: proc "c" (newTimeBase: u32) ---

    Procedure Groups

    This section is empty.

    Source Files

    Generation Information

    Generated with odin version dev-2024-04 (vendor "odin") Windows_amd64 @ 2024-04-23 21:09:31.201801600 +0000 UTC