APIDb_RoomReductionsID
현재 데이터베이스의 룸(room)에 할당된 축소 데이터를 리턴합니다.
GSErrCode ACAPI_Database ( APIDb_RoomReductionsID, const API_Guid *guid, RoomReductionPolyProc* roomReductionPolyProc );
파라미터
- guid
- 참조된 구역(zone) GUID 식별자입니다.
- roomReductionPolyProc
- 축소 정보를 내보내기 위한 콜백 함수입니다.
리턴 값
NoError
- 함수가 성공적으로 완료되었습니다.
APIERR_BADPARS
- 파라미터들 중 하나 이상이
NULL
입니다. APIERR_NESTING
- 함수가
RoomReductionPolyProc
의 본문으로부터 호출되었습니다. APIERR_BADID
- 구역(zone) 레퍼런스가 유효하지 않습니다.
APIERR_DELETED
- 구역(zone)이 제거되었습니다.
다른 공통 API 오류들에 대해서는 API 오류 문서를 보십시오.
설명
구역(zone)들은 다른 요소들과의 매우 복잡한 관계들을 갖고 있습니다. 이 함수는 어떤 요소들이 구역 넓이를 줄이는지, 어떻게 줄이는지 쉽게 찾기 위해 사용합니다. 이 요소들은 벽, 기둥, 해치(hatch), 박공(gable)과 나머지가 될 수 있습니다. 중첩하는 장소들은 그것들 중 하나만 리턴합니다. (아래 이미지를 보십시오) 축소 폴리곤들은 RoomReductionPolyProc 콜백 함수로 가져올 수 있습니다.
예제
static void __ACENV_CALL RoomRedCallBack (const API_RoomReductionPolyType *roomRed) { char s[32]; GSErrCode err; switch (roomRed->type) { case APIRoomReduction_Rest: sprintf (s, "Rest"); break; case APIRoomReduction_Wall: sprintf (s, "Wall"); break; case APIRoomReduction_Column: sprintf (s, "Column"); break; case APIRoomReduction_Hatch: sprintf (s, "Hatch"); break; case APIRoomReduction_Gable: sprintf (s, "Gable"); break; } ACAPI_WriteReport (s, false); /* roomRed->nCoords, roomRed->coords로 폴리곤 그리기, ... */ BMKillHandle ((GSHandle*) &roomRed->coords); BMKillHandle ((GSHandle*) &roomRed->subPolys); BMKillHandle ((GSHandle*) &roomRed->arcs); return; } ... GSErrCode err = ACAPI_Database (APIDb_RoomReductionsID, &element.header.guid, (void *) RoomRedCallBack);
요구사항
- 버전: API 4.1 또는 이후
- 헤더: APIdefs_Database.h