본문 바로가기

;

검색하기
;
프로필사진 WindowsHyun

  • Category (49)
    • Programing (8)
    • Linux (9)
    • PHP (2)
    • C, C++, C# (10)
    • Mobile (3)
    • 잡다한 이야기 (17)
Guestbook
Notice
Recent Posts
Recent Comments
Link
«   2025/07   »
일 월 화 수 목 금 토
1 2 3 4 5
6 7 8 9 10 11 12
13 14 15 16 17 18 19
20 21 22 23 24 25 26
27 28 29 30 31
Tags
  • .netCore Install
  • 도커마운트
  • Wake On Lan
  • mongodb pss
  • wol
  • docker
  • IOCP 서버
  • 윈도우10 Wake On Lan
  • MySQL
  • n8n설치
  • IOCP 클라이언트
  • Docker오류
  • docker desktop
  • 닷넷코어
  • DockerDesktop
  • .dotnet Core 3.1 Install
  • mongodb readonly
  • DockerWindows
  • 가계부
  • mongo docker
  • docker-compose
  • DockerVolume
  • IOCP
  • Winsock
  • ubuntu .net Core
  • n8n
  • Firefly
  • 윈도우10 WOL
  • firefly3
  • Volume Mount
more
Archives
Today
Total
관리 메뉴
  • 글쓰기
  • 방명록
  • RSS
  • 관리

목록Winsock 구조체 (1)

;

Winsock 구조체 데이터 보내고 받기

1. 우선 자신이 원하는 구조체를 만들고, 구조체를 선언 한다. typedef struct Player_Socket { float x, y, z; float camxrotate, camyrotate; bool live; bool team; char nickName[16]; int character_down_state; }Player_Socket; Player_Socket player; 2. 구조체를 보내는 방법 ( 고정+가변 길이 ) - 먼저 데이터의 크기를 보낸후, 실제 구조체를 보낸다.int retval; // 데이터 보내기( 구조체 크기를 먼저 보낸다. ) int len = sizeof( player ); retval = send( sock, (char *)&len, sizeof( int ), 0 ..

C, C++, C# 2016. 12. 1. 03:49
Prev 1 Next

Blog is powered by kakao / Designed by Tistory

티스토리툴바