yafray-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [Yafray-devel] Compiling yafray, error in basictex.cc


From: Deuss Mario
Subject: RE: [Yafray-devel] Compiling yafray, error in basictex.cc
Date: Thu, 8 Feb 2007 09:50:56 +0100

I know Maxwell, used its testversion some time ago. But as I studying computer 
science and we implemented a simple raytracer in c++, I'm more interested in a 
opensource project. For sure my problem is not really a serious one, but I have 
to start somewhere.
I was also wondering about platform compatibility, and thought this problem 
could interest someone, as read of the goal to make
yafray compile without any interaction of the user. Hope I didnt bother you,

                Mario 


-----Original Message-----
From: address@hidden on behalf of Laurence Mehlhorn
Sent: Thu 2/8/2007 3:41 AM
To: Yafray development mailing list
Subject: Re: [Yafray-devel] Compiling yafray, error in basictex.cc
 
Try Maxwell Render, It quite far ahead of Yafray, There is a  Free test 
download for the software.
  It retails a 900 dollers US>
  L.M
   
  

Austin Benesh <address@hidden> wrote:
  Deuss Mario wrote:
> Hi there,
>
> as I got very interested in the topic of photorealistic rendering and 
> raytracing in a course at my university, I want
> to take a closer look on yafray. First step would be to compile the source, 
> but I get problems with "line 262 in basictex.cc":
>
> char *ext = strrchr(filename, '.');
>
> I`m compiling it with visual studio 2005, and get the error: 
>
> cl : Command line warning D9035 : option 'Og' has been deprecated and will be 
> re
> moved in a future release
> cl : Command line warning D9002 : ignoring unknown option '/Op'
> basictex.cc
> src\shaders\basictex.cc(262) : error C2440: 'initializing' : cannot convert 
> from
> 'const char *' to 'char *'
> Conversion loses qualifiers
> scons: *** [src\shaders\basictex.obj] Error 2
> scons: building terminated because of errors.
>
> As I look up a reference on strrchr, this error makes sense, because filename 
> is a const char*:
>
> at http://www.cplusplus.com/reference/clibrary/cstring/strrchr.html, strrchr 
> is declared as following:
>
> const char * strrchr ( const char * str, int character );
> char * strrchr ( char * str, int character );
>
> I tried to add a const: "const char *ext = strrchr(filename, '.');" but then 
> I get errors with the jpeg_librabry.
>
> To keep it short, I would just be happy, if someone could tell me what to do 
> to get it compiled. 
>
> thanks, Mario 
>
>
>
> _______________________________________________
> Yafray-devel mailing list
> address@hidden
> http://lists.nongnu.org/mailman/listinfo/yafray-devel
>
> 
Try casting filename to char*. Like this:

char *ext = strrchr( (char*) filename, '.');





_______________________________________________
Yafray-devel mailing list
address@hidden
http://lists.nongnu.org/mailman/listinfo/yafray-devel






reply via email to

[Prev in Thread] Current Thread [Next in Thread]