Subject: CGAL users discussion list
List archive
Re: [cgal-discuss] Exporting PLY file with Color Information using Polyhedron_3 in CGAL
Chronological Thread
- From: Simon Giraudot <>
- To:
- Subject: Re: [cgal-discuss] Exporting PLY file with Color Information using Polyhedron_3 in CGAL
- Date: Wed, 10 Feb 2021 09:21:47 +0100
- Authentication-results: mail2-smtp-roc.national.inria.fr; spf=None ; spf=None ; spf=None
- Ironport-phdr: 9a23:m4zcwh1CPG+t/BOqsmDT+DRfVm0co7zxezQtwd8ZsesUK/jxwZ3uMQTl6Ol3ixeRBMOHsqMC1rSd4/CocFdDyK7JiGoFfp1IWk1NouQttCtkPvS4D1bmJuXhdS0wEZcKflZk+3amLRodQ56mNBXdrXKo8DEdBAj0OxZrKeTpAI7SiNm82/yv95HJbAhEmT6wbalyIRi3ognctcobipZ+J6gszRfEvmFGcPlMy2NyIlKTkRf85sOu85Nm7i9dpfEv+dNeXKvjZ6g3QqBWAzogM2Au+c3krgLDQheV5nsdSWoZjBxFCBXY4R7gX5fxtiz6tvdh2CSfIMb7Q6w4VSik4qx2ThLjlSUJOCMj8GzPl8J+kqxbrhKiqRJxzYHbb4OaO+ZxcK7GYdMXRnBMUtpNWyFPAI6xaZYEAeobPeZfqonwv0YArRq7BQmrAuPk1z5Ghn7s3aIgzuQuDAbG3BA9FN8Jq3TUrdD1NKAUUeyvw6nIzC/DYOlL2Tjg74jIbgssof6SUrJ3dMre11UvFxnFj1Wes4PqIy+V1uMXs2mb9eZvSeWvi2s+pgx3vzOgydsihJPTiYIJ1lDL6z95wIAtKNC4VUJ2f8CpHZlOuy2EKoZ4TcIvT39qtSok17AKpJC1cSkFxZop2xLRZfiKfomG7B/gSOufITN1iXNkdb+hhxi/91WrxOP7VsmxyllKryxFn8HQuXACzRPT7tKLSvxn/keuwTqP2B7c6uZBIU8qiarbMZ4gwrAqmZUPrUTDGTX2mUXsgKCKcUUk//Ck6+L9bbr9vZCcM5F7hhviPaQpn8yyB/kzPAsWX2WD9umx1afv8VDlTLhKlPE7nKbUvIrHKcgGqKO1GwxY34U55xqiETur0c4UkHgbIF5fZR6KjpblN0nSLPziEfuzmUignC13y/3AI7bsHJHNLmXYkLf9Y7l98VNSyAsyzN9B/59YFrcMK+/pVEDrrtzXFBo5PhS0w+n5DNV90ZsTVGyVDq+cN6Pfs0WE5uc1LOmNYI8ZoTH9K+U55/L0in85h18dcbOv3ZQJdHC0BvVmI0OHbnrwmtoMHmYHshAjQOD2iFCOSzBeanmoU64h+z02BpqqDYLZSYCshLyB0j27HppTZm1eEVCMEHLod4KCW/sWZyKSI9VhnSYZVbe8TI8hyQqjtADkxLpgK+rb5DEYtYjj1dh7/eLciQ0y9TtuD8WdyW2CU2Z0nmYQSz8swK9/uVB9ykuE0aVgn/NYGsZc5/dQXggnNJ7c1PB1C83pWgLaZdqJU1anQtC+AT4rVN4xwtkOY1x8G9q4lBzD0TCqD6cQl7yMGZM77LrR32P0J8Zh03bKza4hj0Q6QsdXNW2pmKp/9w/LCo7Rl0WWjaareroG3CLQ9GqOz3CCvEFCXwJqVqXFQ3AfalHQrdvn+kPOV76uCbI5PQtd0cOONrFGZsHzgVlaXvvvJMzSY3itlGeoGRaI2rSMYZL2dGUSxirdDFEInB0S/XadKQc+Gzyho3nFATxvE1LveULs/vNkpHO1VE9nhz2NOkZu3r7w9h8OjuGHUNsS2KgFsWEvsWZaBlG4iunXDt2G7yVgZqxBbdQhqANc1GfesUpyP4apMqxlmnYRfgNysl/0xht+AZlHi9lsp3QvmlkhYZmE2U9MImvLlav7PafafzGroUKfLpXO01Sb6+64v6cC7PNi9we4+gSuSQwn+nRjlt5Izz2b+JWMCgcOA8qoAxQHsiNirrSfWREToobd1HliK66x6GaQ1N8uAeY50AeudtxDN7mVUgT1Fp9CXpT8GKkRg1GsKyk8EqVK7qduZpGpevyD1bKxLehply6hl3UB64d4gBqB
Hello again,
You can read this section of the manual: https://doc.cgal.org/latest/Surface_mesh/index.html#title7
Basically, you have to create 3 simplex properties with `mesh.add_property_map<vertex_descriptor, unsigned char>("v:red")` and so on, and these will be written by `CGAL::write_ply` (it should also work if you prefer to color faces instead of vertices, just use a face property in that case).
I hope this helps.
Best,
--
Simon Giraudot, PhD
R&D Engineer
GeometryFactory - http://geometryfactory.com/
Le 10/02/2021 à 09:02, Anisa-Aisha ( via cgal-discuss Mailing List) a écrit :
Hello,
I was able to fix the issue, I was making a type error in the header. But
could you please tell me more about the surface mesh method, about how to
embed properties on mesh simplices? I'd like to optimize my code as much as
possible.
--
Sent from: http://cgal-discuss.949826.n4.nabble.com/
- [cgal-discuss] Exporting PLY file with Color Information using Polyhedron_3 in CGAL, Anisa-Aisha, 02/09/2021
- Re: [cgal-discuss] Exporting PLY file with Color Information using Polyhedron_3 in CGAL, Simon Giraudot, 02/10/2021
- Re: [cgal-discuss] Exporting PLY file with Color Information using Polyhedron_3 in CGAL, Anisa-Aisha, 02/10/2021
- Re: [cgal-discuss] Exporting PLY file with Color Information using Polyhedron_3 in CGAL, Simon Giraudot, 02/10/2021
- [cgal-discuss] need help with vcpkg build on Windows- CMake not initialized with correct source and build path, Audette, Michel A., 02/19/2021
- Re: [cgal-discuss] Exporting PLY file with Color Information using Polyhedron_3 in CGAL, Anisa-Aisha, 02/10/2021
- Re: [cgal-discuss] Exporting PLY file with Color Information using Polyhedron_3 in CGAL, Simon Giraudot, 02/10/2021
Archive powered by MHonArc 2.6.19+.