The version with a single repeated field (which presumably you expect to
always have size 16) will be slightly more efficient on the wire and
significantly more efficient in-memory (assuming you're using C++).
I think you'll find the single repeated field version more usable, too --
you can actually iterate through the contents rather than having to identify
the all by name.

On Fri, Oct 31, 2008 at 1:51 PM, ketan <[EMAIL PROTECTED]> wrote:

>
> Hi,
>
> Which would be more compact representation for matrix:
>
> message MatrixR
> {
>   repeated double mat;  // has to ensure that it passes values
> correctly etc.
> }
>
> OR
>
> message RowVector
> {
>  required double rx = 1;
>  required double ry = 2;
>  required double rz = 3;
>  required double rw = 4;
> }
>
> message Matrix
> {
>  required RowVector r0 = 1;
>  required RowVector r1 = 2;
>  required RowVector r2 = 3;
>  required RowVector r3 = 4;
> }
>
> or any other efficient method?
>
> thx
> Ketan
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Protocol Buffers" group.
To post to this group, send email to protobuf@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/protobuf?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to