Re: improvement of index-calculation
- From: "Guenther Wimpassinger" <gw_spam@xxxxxxxxx>
- Date: Wed, 27 Jul 2005 20:42:59 +0200
"Eric Grange" <egrangeNO@xxxxxxxxxxxxxxx> schrieb
>
> > I think this is not possible because this is a
> > Getter mehtod for a property
> >
> > property Cells[const x,y,z:integer]:boolean
> > read GetVoxelFromXYZ
> > write SetVoxelFromXYZ;
>
> It's possible to use an array, a record or any type in getter/setter
> method for a property as long as these match the indexes for the
> property (you're not limited to native types).
Ok. Never needed something like this.
>
> If everywhere else in the code you manipulate coordinates as independant
> variables (as in "x,y,z:integer"), then there is no benefit to using a
> record or array here, but if you use something like xyz:TVector,
> then this would benefit here (and using a structure might benefit the
> rest of the code as well for the same reasons).
Ah. No in that case I don't have a "ready" vectormade Variable that holds
the values. The Cell-Items are accessed during ray-tracing and shading.
But I have to say, I have not written the shading code so I don't know
which is the best way to access the items from the view of the shading
algo.
thanks
Guenther
.
- References:
- improvement of index-calculation
- From: Guenther Wimpassinger
- Re: improvement of index-calculation
- From: Eric Grange
- Re: improvement of index-calculation
- From: Guenther Wimpassinger
- Re: improvement of index-calculation
- From: Eric Grange
- improvement of index-calculation
- Prev by Date: Re: improvement of index-calculation
- Next by Date: Re: NAFCQY [Not A FastCode Question, Yay!]: Int64 DivMod
- Previous by thread: Re: improvement of index-calculation
- Next by thread: Re: improvement of index-calculation
- Index(es):