Method and apparatus for encoding/decoding video signal
A method of decoding a video signal according to the present invention may include: determining whether or not change in brightness is present between a current video including a current block and a reference video of the current video; when it is determined that change in brightness is present between the current video and the reference video, determining weight prediction parameter candidates of the current block; determining a weight prediction parameter of the current block on the basis of index information specifying any of the weight prediction parameter candidates; and performing prediction for the current block on the basis of the weight prediction parameter.
1 . A method of decoding a video, the method comprising:
deriving a first prediction block of a current block;
deriving a second prediction block of the current block; and
deriving a prediction block of the current block by applying a weight prediction parameter to the first prediction block and the second prediction block,
wherein the weight prediction parameter is derived based on a sample value of the first prediction block and a sample value of the second prediction block, and
wherein the weight prediction parameter is applied to the first prediction block and the second prediction block when information obtained from a bitstream specifies that the weight prediction parameter is used and a cost of applying the weight prediction parameter is not greater than a cost of not applying the weight prediction parameter.
2 . A method of encoding a video, the method comprising:
deriving a first prediction block of a current block;
deriving a second prediction block of the current block; and
deriving a prediction block of the current block by applying a weight prediction parameter to the first prediction block and the second prediction block,
wherein the weight prediction parameter is derived based on a sample value of the first prediction block and a sample value of the second prediction block, and
wherein the weight prediction parameter is applied to the first prediction block and the second prediction block when information encoded into a bitstream specifies that the weight prediction parameter is used and a cost of applying the weight prediction parameter is not greater than a cost of not applying the weight prediction parameter.
3 . A method of transmitting a bitstream generated by an encoding method, the encoding method comprising:
deriving a first prediction block of a current block;
deriving a second prediction block of the current block; and
deriving a prediction block of the current block by applying a weight prediction parameter to the first prediction block and the second prediction block,
wherein the weight prediction parameter is derived based on the first prediction block and the second prediction block, and
wherein the weight prediction parameter is applied to a sample value of the first prediction block and a sample value of the second prediction block when information encoded into a bitstream specifies that the weight prediction parameter is used and a cost of applying the weight prediction parameter is not greater than a cost of not applying the weight prediction parameter.