ce picture, PrevRefFrameNum is set equal to the value of frame_num for the last of the "non-existing" reference frames inferred by the decoding process for gaps in frame num specified in clause 8.2.5.2. Otherwise, PrevRefFrameNum is set equal to the value of frame_num for the previous access unit in decoding order that contained a reference picture. The value of frame num is constrained as follows: If the current picture is an IDR picture, frame_num shall be equal to 0. Otherwise (the current picture is not an IDR picture), referring to the primary coded picture in the previous access unit in decoding order that contains a reference picture as the preceding reference picture, the value of frame_num for the current picture shall not be equal to PrevRefFrameNum unless all of the following three conditions are true: a) The current picture and the preceding reference picture belong to consecutive access units in decoding order. b) The current picture and the preceding reference picture are reference fields having opposite parity. c) One or more of the following conditions is true: The preceding reference picture is an IDR picture, The preceding reference picture includes a memory_management_control_operationsyntax element equal to 5, NOTE 3 - When the preceding reference picture includes a nemory_management_control_operation syntax element equal to 5, PrevRefFrameNum is equal to 0. There is a primary coded picture that precedes the preceding reference picture and the primary coded picture that precedes the preceding reference picture does not have frame_num equal PrevRefFrameNum, There is a primary coded picture that precedes the preceding reference picture and the primary coded picture that precedes the preceding reference picture is not a reference picture. When the value of frame num is not equal to PrevRefFrameNum, it is a requirement of bitstream conformance that the following constraints shall be obeyed: a) There shall not be any previous field or frame in decoding order that is currently marked as "used for sh