[PD] [datastruct] calculations inside drawing instructions