diff --git a/include/light/entities.h b/include/light/entities.hh similarity index 97% rename from include/light/entities.h rename to include/light/entities.hh index 81427995..d4a27925 100644 --- a/include/light/entities.h +++ b/include/light/entities.hh @@ -22,12 +22,8 @@ #include #include -#include +#include -#ifdef __cplusplus -extern "C" { -#endif - #define DEFAULTLIGHTLEVEL 300 typedef struct epair_s { @@ -138,9 +134,5 @@ void WriteEntitiesToString(bsp2_t *bsp); vec_t GetLightValue(const lightsample_t *light, const entity_t *entity, vec_t dist); bool Light_PointInSolid(const bsp2_t *bsp, const vec3_t point ); - -#ifdef __cplusplus -} -#endif #endif /* __LIGHT_ENTITIES_H__ */ diff --git a/include/light/light.h b/include/light/light.hh similarity index 99% rename from include/light/light.h rename to include/light/light.hh index 58746388..a1106b96 100644 --- a/include/light/light.h +++ b/include/light/light.hh @@ -26,11 +26,8 @@ #include #include #include -#include -#ifdef __cplusplus -extern "C" { -#endif +#include #define ON_EPSILON 0.1 #define ANGLE_EPSILON 0.001 @@ -357,9 +354,5 @@ bool Pvs_LeafVisible(const bsp2_t *bsp, const byte *pvs, const bsp2_dleaf_t *lea bool Leaf_HasSky(const bsp2_t *bsp, const bsp2_dleaf_t *leaf); const bsp2_dleaf_t **Face_CopyLeafList(const bsp2_t *bsp, const bsp2_dface_t *face); qboolean VisCullEntity(const bsp2_t *bsp, const byte *pvs, const bsp2_dleaf_t *entleaf); - -#ifdef __cplusplus -} -#endif #endif /* __LIGHT_LIGHT_H__ */ diff --git a/include/light/litfile.h b/include/light/litfile.hh similarity index 95% rename from include/light/litfile.h rename to include/light/litfile.hh index 1974d082..28892a41 100644 --- a/include/light/litfile.h +++ b/include/light/litfile.hh @@ -22,10 +22,6 @@ #include -#ifdef __cplusplus -extern "C" { -#endif - #define LIT_VERSION 1 typedef struct litheader_s { @@ -50,8 +46,4 @@ typedef struct { void WriteLitFile(const bsp2_t *bsp, facesup_t *facesup, const char *filename, int version); void WriteLuxFile(const bsp2_t *bsp, const char *filename, int version); -#ifdef __cplusplus -} -#endif - #endif /* __LIGHT_LITFILE_H__ */ diff --git a/light/CMakeLists.txt b/light/CMakeLists.txt index a3c9b841..3fd480d5 100644 --- a/light/CMakeLists.txt +++ b/light/CMakeLists.txt @@ -2,9 +2,9 @@ cmake_minimum_required (VERSION 2.6) project (light CXX C) set(LIGHT_INCLUDES - ${CMAKE_SOURCE_DIR}/include/light/entities.h - ${CMAKE_SOURCE_DIR}/include/light/light.h - ${CMAKE_SOURCE_DIR}/include/light/litfile.h) + ${CMAKE_SOURCE_DIR}/include/light/entities.hh + ${CMAKE_SOURCE_DIR}/include/light/light.hh + ${CMAKE_SOURCE_DIR}/include/light/litfile.hh) set(LIGHT_SOURCES entities.cc diff --git a/light/entities.cc b/light/entities.cc index aaf08527..1edc62f4 100644 --- a/light/entities.cc +++ b/light/entities.cc @@ -17,11 +17,11 @@ See file, 'COPYING', for details. */ -#include +#include #include -#include -#include +#include +#include entity_t *entities; static entity_t *entities_tail; diff --git a/light/light.cc b/light/light.cc index f6112fe7..16adfef1 100644 --- a/light/light.cc +++ b/light/light.cc @@ -17,12 +17,12 @@ See file, 'COPYING', for details. */ -#include -#include -#include +#include +#include +#include -#include -#include +#include +#include #include diff --git a/light/litfile.cc b/light/litfile.cc index 5488ebe8..e4e5bae4 100644 --- a/light/litfile.cc +++ b/light/litfile.cc @@ -17,8 +17,9 @@ See file, 'COPYING', for details. */ -#include -#include +#include +#include + #include #include diff --git a/light/ltface.cc b/light/ltface.cc index fcfee481..f6b8bfb9 100644 --- a/light/ltface.cc +++ b/light/ltface.cc @@ -17,9 +17,10 @@ See file, 'COPYING', for details. */ -#include -#include -#include +#include +#include + +#include /* ======================================================================== */ diff --git a/light/trace.cc b/light/trace.cc index 2a6ac8d1..c22a0b9d 100644 --- a/light/trace.cc +++ b/light/trace.cc @@ -17,7 +17,7 @@ See file, 'COPYING', for details. */ -#include +#include #define TRACE_HIT_NONE 0 #define TRACE_HIT_SOLID (1 << 0) diff --git a/light/trace_embree.cc b/light/trace_embree.cc index 9d99b619..22e52962 100644 --- a/light/trace_embree.cc +++ b/light/trace_embree.cc @@ -17,7 +17,7 @@ See file, 'COPYING', for details. */ -#include +#include #include #include #include