mmp / pbrt-v3

Source code for pbrt, the renderer described in the third edition of "Physically Based Rendering: From Theory To Implementation", by Matt Pharr, Wenzel Jakob, and Greg Humphreys.
http://pbrt.org
BSD 2-Clause "Simplified" License
4.88k stars 1.19k forks source link

pbrt namespace issue #98

Closed herculesyuan closed 7 years ago

herculesyuan commented 7 years ago

after you add namespace to master branch, the code can be built by vs2015, the reason is that compiler can not recognize c++ standard library, such as std::string, std::unique_ptr etc.

following is the part of log from vs.

13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(872): error C2065: 'numeric_limits': undeclared identifier 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(872): error C2275: 'pbrt::Float': illegal use of this type as an expression 13> D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\pbrt.h(141): note: see declaration of 'pbrt::Float' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(872): error C2039: 'infinity': is not a member of 'global namespace'' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(872): error C3861: 'infinity': identifier not found 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(896): error C2039: 'numeric_limits': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(896): error C2039: 'infinity': is not a member of 'global namespace'' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(914): error C2039: 'ostream': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(914): error C2143: syntax error: missing ';' before '&' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(914): error C2433: 'pbrt::ostream': 'friend' not permitted on data declarations 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(914): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(914): error C2334: unexpected token(s) preceding '{'; skipping apparent function body 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(1461): error C2039: 'cos': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(1461): error C2039: 'sin': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(1468): error C2039: 'cos': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(1468): error C2039: 'sin': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(1473): error C2039: 'acos': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(1477): error C2039: 'atan2': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(77): error C2039: 'atomic': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(77): error C2143: syntax error: missing ';' before '<' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(77): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(77): error C2238: unexpected token(s) preceding ';' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(55): error C2065: 'bits': undeclared identifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(56): error C2065: 'bits': undeclared identifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(58): error C2065: 'bits': undeclared identifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(65): error C2065: 'bits': undeclared identifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(69): error C2065: 'bits': undeclared identifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(69): error C2228: left of '.compare_exchange_weak' must have class/struct/union 13> D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(69): note: type is 'unknown-type' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(96): error C2039: 'mutex': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(96): error C3646: 'mutex': unknown override specifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(96): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(97): error C2039: 'condition_variable': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(97): error C3646: 'cv': unknown override specifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(97): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(101): error C2039: 'function': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(101): error C2065: 'function': undeclared identifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(101): error C2275: 'int64_t': illegal use of this type as an expression 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\stdint.h(20): note: see declaration of 'int64_t' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(101): error C2065: 'func': undeclared identifier 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\stdint.h(20): note: see declaration of 'int64_t' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(101): error C2146: syntax error: missing ')' before identifier 'count' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(104): error C2039: 'function': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(104): error C2065: 'function': undeclared identifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(104): error C2275: 'pbrt::Point2i': illegal use of this type as an expression 13> d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(551): note: see declaration of 'pbrt::Point2i' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(104): error C2065: 'func': undeclared identifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(104): error C2059: syntax error: 'const' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\main\pbrt.cpp(79): error C2872: 'std': ambiguous symbol 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\atomic(38): note: could be 'std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: or 'pbrt::std' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\main\pbrt.cpp(156): error C2872: 'std': ambiguous symbol 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\atomic(38): note: could be 'std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: or 'pbrt::std'

mmp commented 7 years ago

Sorry for the inconvenience! (It worked on the compiler I tested with.) This patch fixes it; I'll get it committed tomorrow.

diff --git a/src/core/geometry.h b/src/core/geometry.h
index f27d6f4..d1ec159 100644
--- a/src/core/geometry.h
+++ b/src/core/geometry.h
@@ -41,6 +41,7 @@
 // core/geometry.h*
 #include "pbrt.h"
 #include "stringprint.h"
+#include <iterator>

 namespace pbrt {

@@ -829,7 +830,6 @@ typedef Bounds2<Float> Bounds2f;
 typedef Bounds2<int> Bounds2i;
 typedef Bounds3<Float> Bounds3f;
 typedef Bounds3<int> Bounds3i;
-#include <iterator>

 class Bounds2iIterator : public std::forward_iterator_tag {
   public:

On Tue, Nov 29, 2016 at 10:11 PM, herculesyuan notifications@github.com wrote:

after you add namespace to master branch, the code can be built by vs2015, the reason is that compiler can not recognize c++ standard library, such as std::string, std::unique_ptr etc.

following is the part of log from vs.

13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(872): error C2065: 'numeric_limits': undeclared identifier 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(872): error C2275: 'pbrt::Float': illegal use of this type as an expression 13> D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\pbrt.h(141): note: see declaration of 'pbrt::Float' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(872): error C2039: 'infinity': is not a member of 'global namespace'' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(872): error C3861: 'infinity': identifier not found 13>d:\phd\research\cg\pbrt\v3\ pbrt-v3\src\core\geometry.h(896): error C2039: 'numeric_limits': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(896): error C2039: 'infinity': is not a member of 'global namespace'' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(914): error C2039: 'ostream': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(914): error C2143: syntax error: missing ';' before '&' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(914): error C2433: 'pbrt::ostream': 'friend' not permitted on data declarations 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(914): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(914): error C2334: unexpected token(s) preceding '{'; skipping apparent function body 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(1461): error C2039: 'cos': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(1461): error C2039: 'sin': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(1468): error C2039: 'cos': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(1468): error C2039: 'sin': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(1473): error C2039: 'acos': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(1477): error C2039: 'atan2': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(77): error C2039: 'atomic': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(77): error C2143: syntax error: missing ';' before '<' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(77): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(77): error C2238: unexpected token(s) preceding ';' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(55): error C2065: 'bits': undeclared identifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(56): error C2065: 'bits': undeclared identifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(58): error C2065: 'bits': undeclared identifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(65): error C2065: 'bits': undeclared identifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(69): error C2065: 'bits': undeclared identifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(69): error C2228: left of '.compare_exchange_weak' must have class/struct/union 13> D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(69): note: type is 'unknown-type' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(96): error C2039: 'mutex': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(96): error C3646: 'mutex': unknown override specifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(96): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(97): error C2039: 'condition_variable': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(97): error C3646: 'cv': unknown override specifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(97): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(101): error C2039: 'function': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(101): error C2065: 'function': undeclared identifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(101): error C2275: 'int64_t': illegal use of this type as an expression 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\stdint.h(20): note: see declaration of 'int64_t' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(101): error C2065: 'func': undeclared identifier 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\stdint.h(20): note: see declaration of 'int64_t' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(101): error C2146: syntax error: missing ')' before identifier 'count' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(104): error C2039: 'function': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(104): error C2065: 'function': undeclared identifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(104): error C2275: 'pbrt::Point2i': illegal use of this type as an expression 13> d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(551): note: see declaration of 'pbrt::Point2i' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(104): error C2065: 'func': undeclared identifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(104): error C2059: syntax error: 'const' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\main\pbrt.cpp(79): error C2872: 'std': ambiguous symbol 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\atomic(38): note: could be 'std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: or 'pbrt::std' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\main\pbrt.cpp(156): error C2872: 'std': ambiguous symbol 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\atomic(38): note: could be 'std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: or 'pbrt::std'

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/mmp/pbrt-v3/issues/98, or mute the thread https://github.com/notifications/unsubscribe-auth/AAGQp8KFEl-YSaaVzItwX9JvI1IE7f0Kks5rDROLgaJpZM4K_1vw .

herculesyuan commented 7 years ago

thanks for your quick response. it works.

2016-11-30 14:13 GMT+08:00 Matt Pharr notifications@github.com:

Sorry for the inconvenience! (It worked on the compiler I tested with.) This patch fixes it; I'll get it committed tomorrow.

diff --git a/src/core/geometry.h b/src/core/geometry.h
index f27d6f4..d1ec159 100644
--- a/src/core/geometry.h
+++ b/src/core/geometry.h
@@ -41,6 +41,7 @@
// core/geometry.h*
#include "pbrt.h"
#include "stringprint.h"
+#include <iterator>

namespace pbrt {

@@ -829,7 +830,6 @@ typedef Bounds2<Float> Bounds2f;
typedef Bounds2<int> Bounds2i;
typedef Bounds3<Float> Bounds3f;
typedef Bounds3<int> Bounds3i;
-#include <iterator>

class Bounds2iIterator : public std::forward_iterator_tag {
public:

On Tue, Nov 29, 2016 at 10:11 PM, herculesyuan notifications@github.com wrote:

after you add namespace to master branch, the code can be built by vs2015, the reason is that compiler can not recognize c++ standard library, such as std::string, std::unique_ptr etc.

following is the part of log from vs.

13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(872): error C2065: 'numeric_limits': undeclared identifier 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(872): error C2275: 'pbrt::Float': illegal use of this type as an expression 13> D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\pbrt.h(141): note: see declaration of 'pbrt::Float' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(872): error C2039: 'infinity': is not a member of 'global namespace'' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(872): error C3861: 'infinity': identifier not found 13>d:\phd\research\cg\pbrt\v3\ pbrt-v3\src\core\geometry.h(896): error C2039: 'numeric_limits': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(896): error C2039: 'infinity': is not a member of 'global namespace'' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(914): error C2039: 'ostream': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(914): error C2143: syntax error: missing ';' before '&' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(914): error C2433: 'pbrt::ostream': 'friend' not permitted on data declarations 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(914): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(914): error C2334: unexpected token(s) preceding '{'; skipping apparent function body 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(1461): error C2039: 'cos': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(1461): error C2039: 'sin': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(1468): error C2039: 'cos': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(1468): error C2039: 'sin': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(1473): error C2039: 'acos': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(1477): error C2039: 'atan2': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(77): error C2039: 'atomic': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(77): error C2143: syntax error: missing ';' before '<' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(77): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(77): error C2238: unexpected token(s) preceding ';' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(55): error C2065: 'bits': undeclared identifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(56): error C2065: 'bits': undeclared identifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(58): error C2065: 'bits': undeclared identifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(65): error C2065: 'bits': undeclared identifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(69): error C2065: 'bits': undeclared identifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(69): error C2228: left of '.compare_exchange_weak' must have class/struct/union 13> D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(69): note: type is 'unknown-type' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(96): error C2039: 'mutex': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(96): error C3646: 'mutex': unknown override specifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(96): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(97): error C2039: 'condition_variable': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(97): error C3646: 'cv': unknown override specifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(97): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(101): error C2039: 'function': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(101): error C2065: 'function': undeclared identifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(101): error C2275: 'int64_t': illegal use of this type as an expression 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\stdint.h(20): note: see declaration of 'int64_t' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(101): error C2065: 'func': undeclared identifier 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\stdint.h(20): note: see declaration of 'int64_t' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(101): error C2146: syntax error: missing ')' before identifier 'count' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(104): error C2039: 'function': is not a member of 'pbrt::std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: see declaration of 'pbrt::std' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(104): error C2065: 'function': undeclared identifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(104): error C2275: 'pbrt::Point2i': illegal use of this type as an expression 13> d:\phd\research\cg\pbrt\v3\pbrt-v3\src\core\geometry.h(551): note: see declaration of 'pbrt::Point2i' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(104): error C2065: 'func': undeclared identifier 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\core\parallel.h(104): error C2059: syntax error: 'const' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\main\pbrt.cpp(79): error C2872: 'std': ambiguous symbol 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\atomic(38): note: could be 'std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: or 'pbrt::std' 13>D:\PhD\Research\CG\pbrt\v3\pbrt-v3\src\main\pbrt.cpp(156): error C2872: 'std': ambiguous symbol 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\atomic(38): note: could be 'std' 13> C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\iterator(14): note: or 'pbrt::std'

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/mmp/pbrt-v3/issues/98, or mute the thread https://github.com/notifications/unsubscribe-auth/AAGQp8KFEl- YSaaVzItwX9JvI1IE7f0Kks5rDROLgaJpZM4K_1vw .

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/mmp/pbrt-v3/issues/98#issuecomment-263792313, or mute the thread https://github.com/notifications/unsubscribe-auth/ADMcypZHmxfiBt4k9qToIUCHcTwWR6nFks5rDRQSgaJpZM4K_1vw .

mmp commented 7 years ago

Fixed in f6f7a235e6b93c371653c96fed94657134e439fa