POV-Ray : Newsgroups : povray.macintosh : Any Mac C++ programmers here? Server Time
26 Jun 2024 13:04:35 EDT (-0400)
  Any Mac C++ programmers here? (Message 1 to 6 of 6)  
From: Steve
Subject: Any Mac C++ programmers here?
Date: 18 Apr 1999 08:01:49
Message: <3719BC84.62BF2619@puzzlecraft.com>
I'm a beginner at C++ using CodeWarrior. As one of my first things to do
I am writing a postscript-2-bezier_spline converter. I could use a bit
of help with a few C++ basics that we haven't gotten to in school just
yet - mostly string manipulations and data type conversions.

I really like the POV Mac Unofficial version in all ways except for 1
little thing - batch rendering. Maybe someday I can write a new method
to make batch rendering a little easier. Other than that it's clearly a
better POV variant for the powermac.

I am retired from a career in high end graphics, including electronic
prepress since the Mac Plus came out. This allows me to help others in
the area of post-rendering image processing.

steve


Post a reply to this message

From: Thorsten Froehlich
Subject: Re: Any Mac C++ programmers here?
Date: 18 Apr 1999 10:38:30
Message: <3719e056.0@news.povray.org>
In article <3719BC84.62BF2619@puzzlecraft.com> , Steve 
<ste### [at] puzzlecraftcom>  wrote:

> I'm a beginner at C++ using CodeWarrior. As one of my first things to do
> I am writing a postscript-2-bezier_spline converter. I could use a bit
> of help with a few C++ basics that we haven't gotten to in school just
> yet - mostly string manipulations and data type conversions.

C++ is a powerful language and it takes years to learn it in all details.
For learning C++ yourself you will need another book, there are lots out
there. Addison Wesley has published a few...
If you have previous programming experience you may want to read "The C++
Programming Language, 3rd Edition" by Bjarne Stroustrup (ISBN
0-201-88954-4). However, this book already starts on a fair level and you
may want to understand at least C first (The book is also a useful
reference).

In general C++ is simply to complex to explain it in a few sentences (even
only details like type conversions). As a tip I would suggest to start with
something less difficult than a "postscript-2-bezier_spline converter" - get
used to the language first :-)

> I really like the POV Mac Unofficial version in all ways except for 1
> little thing - batch rendering. Maybe someday I can write a new method
> to make batch rendering a little easier. Other than that it's clearly a
> better POV variant for the powermac.

Just curious: What is better then the official version? Knowing this could
improve the official version...


    Thorsten


____________________________________________________
Thorsten Froehlich, Duisburg, Germany
e-mail: Tho### [at] csicom

Visit POV-Ray on the web: http://mac.povray.org


Post a reply to this message

From: Chris Huff
Subject: Re: Any Mac C++ programmers here?
Date: 18 Apr 1999 10:51:52
Message: <3719E3A6.89B908ED@compuserve.com>
I am also starting in C++ with Apple MPW and MacZoop, which is a very nice
and easy to use framework, which is free.
I also use POV Mac Unofficial, and especially like the spline editors and
templates.

Steve wrote:

> I'm a beginner at C++ using CodeWarrior. As one of my first things to do
> I am writing a postscript-2-bezier_spline converter. I could use a bit
> of help with a few C++ basics that we haven't gotten to in school just
> yet - mostly string manipulations and data type conversions.
>
> I really like the POV Mac Unofficial version in all ways except for 1
> little thing - batch rendering. Maybe someday I can write a new method
> to make batch rendering a little easier. Other than that it's clearly a
> better POV variant for the powermac.
>
> I am retired from a career in high end graphics, including electronic
> prepress since the Mac Plus came out. This allows me to help others in
> the area of post-rendering image processing.
>
> steve


Post a reply to this message

From: Steve
Subject: Re: Any Mac C++ programmers here?
Date: 18 Apr 1999 19:11:49
Message: <371A5965.C2074B43@puzzlecraft.com>
Thorsten Froehlich wrote:

>
> C++ is a powerful language and it takes years to learn it in all details.
> For learning C++ yourself you will need another book, there are lots out
> there. Addison Wesley has published a few...
> If you have previous programming experience you may want to read "The C++
> Programming Language, 3rd Edition" by Bjarne Stroustrup (ISBN
> 0-201-88954-4). However, this book already starts on a fair level and you
> may want to understand at least C first (The book is also a useful
> reference).

I have learned that there are very few C++ books out that encompass the new
ANSI standards. The Stroustrup book is pretty much a must-have for a referrence
work. There are 2 good tutorial level books that I have found. "Learn C++ in 21
Days" and "Thinking in C++" are both good ones for the beginner ( make certain
they are the latest edition). Most available books were published prior to the
adoption of the new ANSI standards and therefore contain numerous errors that
will not compile on a brand new compiler.

>
>
> In general C++ is simply to complex to explain it in a few sentences (even
> only details like type conversions). As a tip I would suggest to start with
> something less difficult than a "postscript-2-bezier_spline converter" - get
> used to the language first :-)

This is an understatement! C++ is a very complex language. That's why I finally
enrolled in classes, I just couldn't learn it on my own from books. However,
the ps-2-pov converter is progressing. I can read in a the disk file and test
it for validity. My current problem is locating 2 strings in the disk file and
using their addresses as begin() and end() to extract a portion of the file and
write it to disk.

>
> Just curious: What is better then the official version? Knowing this could
> improve the official version...

#1. Being able to have multiple editing windows open and active is the
outstanding feature.
#2. Being able to link an external editor to POV-Ray (BBEdit is superb).
#3. Being able to select includes, functions and objects from a menu (very
nice).
#4. Faster rendering speed ( about 30% speed gain on 210 mhz 604 cpu).

The multiple editors feature alone makes Unofficial preferrable to Regular. The
feature is so useful that I cannot bring myself to go back to using a single
editing window.

I'm not sure how the faster speed is achieved. Perhaps some of the code has
been rewritten for native PPC or perhaps the authors have found some optimal
compiler settings. I just don't know how it's done. There will be no doubt
about which version a PPC user will choose - faster is always better.

1 more improvement that all versions MIGHT benefit from is the ability to
render animation previews in QuickDraw 3D, which is 100's of times faster. This
might be impossible to achieve considering the POV scene description language.

Another useful improvement would be to add a full blown aete resource so that
POV-Ray would be fully scriptable with Frontier. This would allow for a fully
automated method for creating and rendering POV jobs. The Unofficial team is
working on this.

Another needed upgrade is support for TrueType fonts in native Mac. After all,
Apple invented TrueType. Also, we really should add support for Postscript
fonts because they are the lingua franca of the professional graphics industry.

Of course, the importing of postscript paths into POV will be useful, I'm
working on this at my own slow rate. Importing EPS would be even more useful
but this is an extremely difficult project to tackle.

I'd like to remark on splines a bit. The bezier_spline is the same thing as a
bezier path in postscript. However, I was dismayed to learn that the control
points are reversed in POV from the industry standard. I wish POV would just
use accepted standards where possible. It's pretty simple to write a function
to convert, but it is counterintuitive to have to reverse 15 years of
experience - my poor old brain just won't do it.

The standard version has it's strong points, too. For instance, the
preferrences for an animation are either saved in the file itself or use the
application settings. This is a nice feature that allows global revision of the
animation preferrences for batch jobs. I do a lot of batch rendering. The
documentation for batch rendering is, well, terrible. I'd be happy to
contribute a rewrite for this.

My current technique is to author and preview my batch animations in Unofficial
and then do the final batch renderings in Regular. The batch editing feature is
more valuable to me than the faster speed.

I am deeply committed to learning C++ and POV-Ray. I hope to be able to make a
small contribution some day in improving the functionality of POV.

Steve Strickland


Post a reply to this message

From: Thorsten Froehlich
Subject: Re: Any Mac C++ programmers here?
Date: 18 Apr 1999 20:18:54
Message: <371a685e.0@news.povray.org>
In article <371A5965.C2074B43@puzzlecraft.com> , Steve 
<ste### [at] puzzlecraftcom>  wrote:

> I have learned that there are very few C++ books out that encompass the new
> ANSI standards. The Stroustrup book is pretty much a must-have for a
> referrence work. There are 2 good tutorial level books that I have found.
> "Learn C++ in 21 Days" and "Thinking in C++" are both good ones for the
> beginner ( make certain they are the latest edition). Most available books
> were published prior to the adoption of the new ANSI standards and therefore
> contain numerous errors that will not compile on a brand new compiler.

Yes, some examples won't work, but still most examples are ISO C++
compliant. That is why I suggested to learn C first - the selection of good
_and_ up-to-date books is much greater and the C code that is _not_ C++ code
is unlikely to be in a good book about C anyway.

> This is an understatement! C++ is a very complex language.

I did not want to discurrage you ;-)

> That's why I finally enrolled in classes, I just couldn't learn it on my own
> from books. However, the ps-2-pov converter is progressing. I can read in a
> the disk file and test it for validity. My current problem is locating 2
> strings in the disk file and using their addresses as begin() and end() to
> extract a portion of the file and write it to disk.

Good luck!

>> Just curious: What is better then the official version? Knowing this could
>> improve the official version...
>
> Being able to have multiple editing windows open and active is the
> outstanding feature.
>
> The multiple editors feature alone makes Unofficial preferrable to Regular.
> The feature is so useful that I cannot bring myself to go back to using a
> single editing window.

Yes, that is a feature that needed to be added to the official version for a
long time...the 9+ year history of the code wasn't any help and the official
Mac 3.5 will offer at least a clear cut on this (and some other long overdue
features :-)

> Being able to link an external editor to POV-Ray (BBEdit is superb).

BBEdit is a good tool...also a good (specialised) editor is enough in most
cases.

> Faster rendering speed ( about 30% speed gain on 210 mhz 604 cpu).

Hmm, this claim only holds when comparing the unofficial version with 3.1.
As CW Pro 4 came out sortly after the release of the official version they
had the advantage to use for their unofficial version. You will find that
this argument no longer holds with 3.1d :-)   (Except for the preview, but
that is very technical...)

> I'm not sure how the faster speed is achieved. Perhaps some of the code has
> been rewritten for native PPC or perhaps the authors have found some optimal
> compiler settings. I just don't know how it's done. There will be no doubt
> about which version a PPC user will choose - faster is always better.

No, it is the same code and (now) the same compiler with no (30% worth)
different settings.

> 1 more improvement that all versions MIGHT benefit from is the ability to
> render animation previews in QuickDraw 3D, which is 100's of times faster.
> This might be impossible to achieve considering the POV scene description
> language.

Well, doing this for only one platform is nearly impossible - it is a lot of
work and some primitives are very hard to map to anything "easy" to
display/view as triangles :-(

> Another useful improvement would be to add a full blown aete resource so that
> POV-Ray would be fully scriptable with Frontier. This would allow for a fully
> automated method for creating and rendering POV jobs. The Unofficial team is
> working on this.

The official 3.5 version will have multiple-text editors and will be
recordable - anything else is to early to say.

> Another needed upgrade is support for TrueType fonts in native Mac. After all,
> Apple invented TrueType. Also, we really should add support for Postscript
> fonts because they are the lingua franca of the professional graphics
> industry.

The TrueType font text objects are part of the core code - Mac store fonts
in resources while all other platforms use what is the data fork for the Mac
(since Mac OS 8.5 data fork fonts are at least, finally supported). I have
included an experimental converter with the official 3.1d, it works on at
least with 95% of all fonts (converts them from resource fork representation
to data fork representation).

> Of course, the importing of postscript paths into POV will be useful, I'm
> working on this at my own slow rate. Importing EPS would be even more useful
> but this is an extremely difficult project to tackle.
>
> I'd like to remark on splines a bit. The bezier_spline is the same thing as a
> bezier path in postscript. However, I was dismayed to learn that the control
> points are reversed in POV from the industry standard. I wish POV would just
> use accepted standards where possible. It's pretty simple to write a function
> to convert, but it is counterintuitive to have to reverse 15 years of
> experience - my poor old brain just won't do it.

I have to admit that I never used bezier splines. I guess that whoever wrote
the original code knew more about the math involved the bezier splines than
about standards :-)

> The standard version has it's strong points, too. For instance, the
> preferrences for an animation are either saved in the file itself or use the
> application settings. This is a nice feature that allows global revision of
> the animation preferrences for batch jobs. I do a lot of batch rendering. The
> documentation for batch rendering is, well, terrible. I'd be happy to
> contribute a rewrite for this.
>
> My current technique is to author and preview my batch animations in
> Unofficial and then do the final batch renderings in Regular. The batch
> editing feature is more valuable to me than the faster speed.

There will change a lot in the Mac part of 3.5 - it will be a total C++
rewrite, but it is still some time ahead.  3.1f will come first and clean up
the docs (CompuServe changes...), perhaps CW Pro 5 comes out in the next few
weeks - I hope it will improve speed a bit more again.


    Thorsten


____________________________________________________
Thorsten Froehlich, Duisburg, Germany
e-mail: Tho### [at] csicom

Visit POV-Ray on the web: http://mac.povray.org


Post a reply to this message

From: Steve
Subject: Re: Any Mac C++ programmers here?
Date: 19 Apr 1999 02:31:30
Message: <371AC07B.DA2758AA@puzzlecraft.com>
Thanks for a very well written response!

Thorsten Froehlich wrote:

> In article <371A5965.C2074B43@puzzlecraft.com> , Steve
> <ste### [at] puzzlecraftcom>  wrote:
> >
> > The multiple editors feature alone makes Unofficial preferrable to Regular.
> > The feature is so useful that I cannot bring myself to go back to using a
> > single editing window.
>
> Yes, that is a feature that needed to be added to the official version for a
> long time...the 9+ year history of the code wasn't any help and the official
> Mac 3.5 will offer at least a clear cut on this (and some other long overdue
> features :-)

Awrite! I know the PC folks will love this, too. It's an improvement that ALL
povray users will enjoy. However, us Mac users will lose our big advantage.

>
> > Faster rendering speed ( about 30% speed gain on 210 mhz 604 cpu).
>
> Hmm, this claim only holds when comparing the unofficial version with 3.1.
> As CW Pro 4 came out sortly after the release of the official version they
> had the advantage to use for their unofficial version. You will find that
> this argument no longer holds with 3.1d :-)   (Except for the preview, but
> that is very technical...)

Ahhh. I haven't tried 3.1d. I have been very pleased with 3.1 in general - it was a
very MAJOR upgrade that shows a tremendous amount of thoughtful work. I'm glad
ya'll used CodeWarrior 4 since that is what I'm currently using.

> > Another useful improvement would be to add a full blown aete resource so that
> > POV-Ray would be fully scriptable with Frontier. This would allow for a fully
> > automated method for creating and rendering POV jobs. The Unofficial team is
> > working on this.
>
> The official 3.5 version will have multiple-text editors and will be
> recordable - anything else is to early to say.

Actually, this is important to advanced Mac users. Quite a few Mac applications are
now scriptable through the aete resource. One problem with being simply recordable
the way Photoshop is - the application cannot be used by another application.
Adding an aete resource would make POV-Ray recordable as well as scriptable in a
more valuable way. After all, we can record scriptable applications in Frontier. I
consider this to be the only major shortcoming that Photoshop has. I hope that we
can avoid making the same mistake in POV-Ray.

> The TrueType font text objects are part of the core code - Mac store fonts
> in resources while all other platforms use what is the data fork for the Mac
> (since Mac OS 8.5 data fork fonts are at least, finally supported). I have
> included an experimental converter with the official 3.1d, it works on at
> least with 95% of all fonts (converts them from resource fork representation
> to data fork representation).
>
This is valuable and very useful work! The demand for 3D effects in typography
cannot be overestimated because there seems to be no limit. POV-Ray could make an
extraordinary 3D typesetter with very little enhancement. Keep up the good work
here!



> There will change a lot in the Mac part of 3.5 - it will be a total C++
> rewrite, but it is still some time ahead.  3.1f will come first and clean up
> the docs (CompuServe changes...), perhaps CW Pro 5 comes out in the next few
> weeks - I hope it will improve speed a bit more again.
>
>     Thorsten

Yes, CW5 is much anticipated. Rewriting POV into C++ is a much desirable goal as
well. This will signal a major breakthrough to further development. The properties
of OO seem particularly useful in future POV-Ray development. Authors can write
code that will not interfere with existing code. Perhaps with C++, POV can
eventually support plug-ins!

steve


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.