POV-Ray : Newsgroups : povray.general : How to permit null objects? Server Time
8 Aug 2024 12:18:11 EDT (-0400)
  How to permit null objects? (Message 5 to 14 of 14)  
<<< Previous 4 Messages Goto Initial 10 Messages
From: Warp
Subject: Re: How to permit null objects?
Date: 6 Feb 2001 07:40:55
Message: <3a7ff0d6@news.povray.org>
Greg M. Johnson <gre### [at] my-dejanewscom> wrote:
:> Use a macro.

: Thanks but no.

  Why not?

-- 
char*i="b[7FK@`3NB6>B:b3O6>:B:b3O6><`3:;8:6f733:>::b?7B>:>^B>C73;S1";
main(_,c,m){for(m=32;c=*i++-49;c&m?puts(""):m)for(_=(
c/4)&7;putchar(m),_--?m:(_=(1<<(c&3))-1,(m^=3)&3););}    /*- Warp -*/


Post a reply to this message

From: Greg M  Johnson
Subject: Re: How to permit null objects?
Date: 6 Feb 2001 08:38:30
Message: <3A7FFCFB.B092B543@my-dejanews.com>
"Mr. Art" wrote:

> sphere{0,0}

Cool, I didn't know this was legal.


Post a reply to this message

From: Greg M  Johnson
Subject: Re: How to permit null objects?
Date: 6 Feb 2001 08:47:20
Message: <3A7FFF03.36D3DC92@my-dejanews.com>
Warp wrote:

> Greg M. Johnson <gre### [at] my-dejanewscom> wrote:
> :> Use a macro.
> : Thanks but no.
>   Why not?

I am setting up a modular system for movement of characters. It
comprises:

1) One file for information on posing the character (rotation of neck,
wrist_position_point for IK, etc.)
2) Several files where a list of objects are declared (headobj, neckobj,
thighobj, wristobj, fingersegment1L3, fingersegment1L2, etc.)  Each of
these files can be a different character.
3) A file that performs transforms on the objects in #2 using the
information in #1,  and then displays the union of them.

Thus, I can have two very different characters walking with the same
style, or two versions of the same character with different walk styles.

The problem is that I wanted to show off the system with two characters:
1) a stick figure made of cylinders connecting all the joints, and
2) a figure like that I see in some anatomy art books made of blocks (no
articulated fingers).

The problem is how do I keep this modular approach if I'm missing some
objects in the file.  Perhaps Art's suggestion of defining these fingers
as sphere{0,0} is the best.


Post a reply to this message

From: Wlodzimierz ABX Skiba
Subject: Re: How to permit null objects?
Date: 6 Feb 2001 10:19:06
Message: <3a8015ea@news.povray.org>
Greg M. Johnson wrote in message <3A7FFF03.36D3DC92@my-dejanews.com>...
> The problem is how do I keep this modular approach if I'm missing some
> objects in the file.  Perhaps Art's suggestion of defining these fingers
> as sphere{0,0} is the best.


did you compared your idea with blobman ?
http://members.xoom.com/_XOOM/HoustonGraph/POV-Ray/index.htm

ABX


Post a reply to this message

From: Greg M  Johnson
Subject: Re: How to permit null objects?
Date: 6 Feb 2001 11:56:22
Message: <3A802B51.CC97C5D2@my-dejanews.com>
Wlodzimierz ABX Skiba wrote:

> did you compared your idea with blobman ?
> http://members.xoom.com/_XOOM/HoustonGraph/POV-Ray/index.htm

I have great respect for what he's done, but its main problem is that it
wasn't created by me. I get greater personal satisfaction out of something I
can model from scratch than something that is pre-fab, no matter how
ingenious.  I'd rather make something crappy with my own figure than
photorealistic with Poser.  My goal is someday to have some cool, extremely
expressive characters that I can just reuse again and again ala'  JvS'
"Rusty"  or  perhaps closer to NA's "Pool Shark Guy".  I've tinkered with
Peter's code, but didn't find it all that interchangeable, didn't like the
faces, didn't think it had as much mobility to do all the things I was
interested in.

In my code, I will be able to have the figure shrug its shoulders: a rotation
of the clavicle bone. I'll also have non-slipping feet with bending at the
toe, am laboring on a true three-point foot structure.  With just a few lines
of code, I'll be able to include both a stick figure, a cool modelled figure,
and a robotic figure all doing the same walk. Can anyone say, "T2" ?  I'm also
spending a lot of time "digitizing" the xyz points off of skeletons & heads
from anatomy books to give it a more realistic shape, something sorely lacking
in my first two versions.

ANOTHER vision I have is that my "bones" could serve as the model for some
genius' coding of a "bones + bicubic patch" system ala' Hash's
Animation:Master.

Again, with great respect to Peter H,  it's quite likely I'll make something
less user-friendly than his is, but it at least will be designed around *my*
objectives . . .


Post a reply to this message

From: Rune
Subject: Re: How to permit null objects?
Date: 6 Feb 2001 17:59:51
Message: <3a8081e7@news.povray.org>
Hehe, our thoughts, ideas and approaches regarding to this seem to have
quite some things in common! :)

Rune
--
\ Include files, tutorials, 3D images, raytracing jokes,
/ The POV Desktop Theme, and The POV-Ray Logo Contest can
\ all be found at http://rsj.mobilixnet.dk (updated January 28)
/ Also visit http://www.povrayusers.org


Post a reply to this message

From: Wlodzimierz ABX Skiba
Subject: Re: How to permit null objects?
Date: 7 Feb 2001 05:38:44
Message: <3a8125b4@news.povray.org>
Greg M. Johnson wrote in message <3A802B51.CC97C5D2@my-dejanews.com>...
> Again, with great respect to Peter H,  it's quite likely I'll make something
> less user-friendly than his is, but it at least will be designed around *my*
> objectives . . .


you have great ideas
but instead of null objects can't you use #if defined() syntax ?

ABX


Post a reply to this message

From: Warp
Subject: Re: How to permit null objects?
Date: 7 Feb 2001 08:15:34
Message: <3a814a75@news.povray.org>
Greg M. Johnson <gre### [at] my-dejanewscom> wrote:
:> :> Use a macro.
:> : Thanks but no.
:>   Why not?

: The problem is how do I keep this modular approach if I'm missing some
: objects in the file.  Perhaps Art's suggestion of defining these fingers
: as sphere{0,0} is the best.

  I really don't understand why this excludes using macros.

-- 
char*i="b[7FK@`3NB6>B:b3O6>:B:b3O6><`3:;8:6f733:>::b?7B>:>^B>C73;S1";
main(_,c,m){for(m=32;c=*i++-49;c&m?puts(""):m)for(_=(
c/4)&7;putchar(m),_--?m:(_=(1<<(c&3))-1,(m^=3)&3););}    /*- Warp -*/


Post a reply to this message

From: Greg M  Johnson
Subject: Re: How to permit null objects?
Date: 7 Feb 2001 08:35:35
Message: <3A814DCC.CE8DA7E4@my-dejanews.com>
Warp wrote:
:>  I really don't understand why this excludes using macros.

I don't understand what a macro would help with in this situation.


Post a reply to this message

From: Disnel
Subject: Re: How to permit null objects?
Date: 9 Feb 2001 06:03:10
Message: <3A83DE66.38DF64BC@hlavacek-partner.cz>
When I want use something like null object in macro parameters I use
array instead of variable:

#macro SomethingWithPossibleNullObject(Object)
  #ifdef (Object[0])
    // Work with it
  #else
    // No object
  #end
#end

SomethingWithPossibleNullObject(array[1])  // Null object
SomethingWithPossibleNullObject(array[1] { sphere{<0, 0, 0>, 1 }) //
Work with sphere

Regards

Disnel


Post a reply to this message

<<< Previous 4 Messages Goto Initial 10 Messages

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