Like Tree1Likes
  • 1 Post By laserlight

Transferring vector data to an array

This is a discussion on Transferring vector data to an array within the C++ Programming forums, part of the General Programming Boards category; I'm reading an obj file to get its vertex and index data, but the file I was reading didn't say ...

  1. #1
    Registered User
    Join Date
    Nov 2009
    Posts
    151

    Transferring vector data to an array

    I'm reading an obj file to get its vertex and index data, but the file I was reading didn't say how many vertices or indices, so I decided to use a vector to read it and then transfer the data to an array. The problem is that I can't do this.
    Code:
    UINT indices[vector.size()];
    How can I get around that?

  2. #2
    C++ Witch laserlight's Avatar
    Join Date
    Oct 2003
    Location
    Singapore
    Posts
    21,441
    Why do you need the array when you already have a vector?
    iMalc likes this.
    C + C++ Compiler: MinGW port of GCC
    Version Control System: Bazaar

    Look up a C++ Reference and learn How To Ask Questions The Smart Way

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Replies: 1
    Last Post: 02-10-2012, 04:42 AM
  2. Replies: 1
    Last Post: 05-05-2009, 04:53 PM
  3. Transferring web C# projects to a different computer
    By Grayson_Peddie in forum C# Programming
    Replies: 1
    Last Post: 12-17-2003, 08:04 PM
  4. transferring GDI attributes.
    By Sebastiani in forum Windows Programming
    Replies: 4
    Last Post: 11-19-2002, 01:30 PM
  5. Transferring control to other execs
    By DarkDragon in forum C Programming
    Replies: 2
    Last Post: 12-28-2001, 02:01 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21