TimoBolkart / TF_FLAME

Tensorflow framework for the FLAME 3D head model. The code demonstrates how to sample 3D heads from the model, fit the model to 2D or 3D keypoints, and how to generate textured head meshes from Images.
http://flame.is.tue.mpg.de/
444 stars 78 forks source link

Render checkboard-like texture on flame models #74

Open GainiK opened 1 year ago

GainiK commented 1 year ago

Hi! Thank you for the excellent work! I wanted to create and render checkboard-like textures on Flame models. Can you please advise on the best approaches for that? I saw that there is a way to render texture from BFM and AlbedoMM, but what is the best way to render checkboard-like texture?

TimoBolkart commented 1 year ago

Hi, the rendering is the same, regardless if you have a texture from the parametric texture models (BFM, AlbedoMM, or the FLAME texture space). The easiest way is to just take the textured FLAME mesh that the sample_texture script outputs and just replace the texture image with a checkerboard image. This would give you something like this: checkerboard

If you want the checkerboard to be not distorted on the mesh, you would need to adapt the texture according to FLAME's UV map.