If you would to draw a cube in an angle of a wall, first draw the object in its own proper shape and raise it onto a vertical plane until it resembles the angle in which the said object is to be represented.
Taken from The Notebooks of Leonardo da Vinci edited by Jean Paul Richter, 1880.