how-to-add-texture-to-sdf.md
by Tongkai Zhang, tongkaizhang@brandeis.edu
This is a quick guide for adding textures(.png) to your model in gazebo.
Texture Configuration
After building your own model in the sdf format, you should have a structured model cargodirectory same as the one below.
It's important that you have the directory exactly the same, since importing the texture into gazebo is based on finding parameters and texture images within that directory.
scripts: cargo.material, formatted file, defining the name, visual property for the material.
textures: the image texture file
model.config: meta data for the model
Basic Steps:
Get the texture image ready and put them under /textures
Define texture in cargo.material, note how texture image is included as well as how the name is set.
material Cargo/Diffuse is the unique name for this material.