Manta Interactive Ray Tracer Development Mailing List

Text archives Help


[Manta] Re: Re: Re: Re: Compiling with VS2008


Chronological Thread 
  • From: Carson Brownlee < >
  • To:
  • Subject: [Manta] Re: Re: Re: Re: Compiling with VS2008
  • Date: Thu, 22 Jul 2010 13:08:13 -0600

sorry I think that might have been my fault actually one of the
revisions wasn't compiling and I naively fixed it.
Carson

On Thu, 2010-07-22 at 12:02 -0700, Solomon Boulos wrote:
> wtf... 
> 
> I'd do an svn blame and figured out who changed that...
> 
> This is my local version from r2313 (July 30, 2008):
> 
> // Stack allocation equivalent to type[size]                                
>                                             
> #define MANTA_STACK_ALLOC(type, size) ((type*)alloca((size) * sizeof(type)))
> 
> On Jul 22, 2010, at 12:00 PM, Thiago Ize wrote:
> 
> > I took a look at this and I see:
> > 
> > // Stack allocation equivalent to type[size]
> > #define MANTA_STACK_ALLOC(type, size) ((type*)malloc((size) * 
> > sizeof(type)))
> > 
> > Was this supposed to be alloca instead of malloc?
> > 
> > Thiago
> > 
> > Solomon Boulos wrote:
> >> Looks like an annoying gcc varying length array usage. Please replace it 
> >> by using the MANTA_STACK_ALLOC or whatever it's called from 
> >> Core/Util/Preprocessor.h . There are a few places in Manta where it's 
> >> used if you need an example.
> >> 
> >> Solomon
> >> 
> >> On Jul 21, 2010, at 18:37, Raymond Cohen 
> >> < >
> >>  wrote:
> >> 
> >>> Hi Manta developers,
> >>> 
> >>> Firstly, great work on the ray-tracer. I am trying to compile under 
> >>> windows using Visual Studio 2008. Currently I get the compile error 
> >>> shown below. Do you have any suggestions for how to proceed? The source 
> >>> line in question is:
> >>> 
> >>> Model/AmbientLights/.svn/text-base/AmbientOcclusion.cc.svn-base:68:    
> >>> pair<float, float> sortedSamples[num_directions];
> >>> 
> >>> The compiler doesn't seem to like the non-constant "num_directions" 
> >>> here. Please let me know if you have any suggestions.
> >>> 
> >>> Cheers,
> >>> Ray
> >>> 
> >>> ---- SNIP
> >>> 
> >>> D:\Manta_src\Manta\Build>nmake
> >>> 
> >>> Microsoft (R) Program Maintenance Utility Version 9.00.21022.08
> >>> Copyright (C) Microsoft Corporation.  All rights reserved.
> >>> 
> >>> [  0%] Built target About
> >>> [ 23%] Built target Manta_Core
> >>> [ 34%] Built target Manta_Interface
> >>> [ 38%] Built target Manta_Image
> >>> [ 38%] Building CXX object 
> >>> Model/CMakeFiles/Manta_Model.dir/AmbientLights/AmbientOcclusion.obj
> >>> AmbientOcclusion.cc
> >>> D:\Manta_src\Manta\Core/Color/RGBTraits.h(51) : warning C4244: 'return' 
> >>> : conversion from 'double' to 'Manta::RGBTraits:
> >>> :ComponentType', possible loss of data
> >>> D:\Manta_src\Manta\Core/Color/RGBTraits.h(53) : warning C4244: 'return' 
> >>> : conversion from 'double' to 'Manta::RGBTraits:
> >>> :ComponentType', possible loss of data
> >>> D:\Manta_src\Manta\Model/AmbientLights/AmbientOcclusion.h(21) : warning 
> >>> C4244: '=' : conversion from 'double' to 'Manta:
> >>> :ColorComponent', possible loss of data
> >>> D:\Manta_src\Manta\Model\AmbientLights\AmbientOcclusion.cc(27) : 
> >>> warning C4244: '=' : conversion from 'double' to 'Manta
> >>> ::ColorComponent', possible loss of data
> >>> D:\Manta_src\Manta\Model\AmbientLights\AmbientOcclusion.cc(54) : 
> >>> warning C4244: '=' : conversion from 'double' to 'Manta
> >>> ::ColorComponent', possible loss of data
> >>> D:\Manta_src\Manta\Model\AmbientLights\AmbientOcclusion.cc(68) : error 
> >>> C2057: expected constant expression
> >>> D:\Manta_src\Manta\Model\AmbientLights\AmbientOcclusion.cc(68) : error 
> >>> C2466: cannot allocate an array of constant size
> >>> 0
> >>> D:\Manta_src\Manta\Model\AmbientLights\AmbientOcclusion.cc(68) : error 
> >>> C2133: 'sortedSamples' : unknown size
> >>> D:\Manta_src\Manta\Model\AmbientLights\AmbientOcclusion.cc(103) : 
> >>> warning C4244: 'initializing' : conversion from 'doubl
> >>> e' to 'float', possible loss of data
> >>> D:\Manta_src\Manta\Model\AmbientLights\AmbientOcclusion.cc(109) : 
> >>> warning C4244: 'initializing' : conversion from 'doubl
> >>> e' to 'float', possible loss of data
> >>> D:\Manta_src\Manta\Model\AmbientLights\AmbientOcclusion.cc(110) : 
> >>> warning C4244: '=' : conversion from 'double' to 'floa
> >>> t', possible loss of data
> >>> NMAKE : fatal error U1077: 'C:\PROGRA~1\MICROS~1.0\VC\bin\cl.exe' : 
> >>> return code '0x2'
> >>> Stop.
> >>> NMAKE : fatal error U1077: '"C:\Program Files\Microsoft Visual Studio 
> >>> 9.0\VC\BIN\nmake.exe"' : return code '0x2'
> >>> Stop.
> >>> NMAKE : fatal error U1077: '"C:\Program Files\Microsoft Visual Studio 
> >>> 9.0\VC\BIN\nmake.exe"' : return code '0x2'
> >>> Stop.
> >>> 
> >>> 
> >>> 





Archive powered by MHonArc 2.6.16.

Top of page