A power generating apparatus of a renewable energy type for generating electric power from renewable energy, the apparatus comprising: a main shaft configured to rotate using the renewable energy; a hydraulic pump configured to pressurize and discharge working fluid by torque of the main shaft; a hydraulic motor configured to apply torque using pressure of the working fluid discharged by the hydraulic pump; and a generator configured to generate power using the torque applied by the hydraulic motor; a fluid working machine of a radial piston type constituted by one of the hydraulic pump or the hydraulic motor, the fluid working machine comprising: a rotation shaft; at least one cylinder part extending along a radial direction of the rotation shaft; a piston arranged in the at least one cylinder part and forming a working chamber with the at least one cylinder part; and a converting mechanism for performing conversion between reciprocating motion of the piston and rotational motion of the rotation shaft, wherein the converting mechanism comprises: a lobed cam fixed to the rotation shaft and having a cam face; and a roller interposed between the cam face and the piston, and the lobed cam is formed by a plurality of segments arranged along a circumferential direction of the rotation shaft (20, characterised by each of the plurality of the segments having a flat mounting surface facing the rotation shaft. a main shaft configured to rotate using the renewable energy; a hydraulic pump configured to pressurize and discharge working fluid by torque of the main shaft; a hydraulic motor configured to apply torque using pressure of the working fluid discharged by the hydraulic pump; and a generator configured to generate power using the torque applied by the hydraulic motor; a fluid working machine of a radial piston type constituted by one of the hydraulic pump or the hydraulic motor, the fluid working machine comprising: a rotation shaft; at least one cylinder part extending along a radial direction of the rotation shaft; a piston arranged in the at least one cylinder part and forming a working chamber with the at least one cylinder part; and a converting mechanism for performing conversion between reciprocating motion of the piston and rotational motion of the rotation shaft, wherein a rotation shaft; at least one cylinder part extending along a radial direction of the rotation shaft; a piston arranged in the at least one cylinder part and forming a working chamber with the at least one cylinder part; and a converting mechanism for performing conversion between reciprocating motion of the piston and rotational motion of the rotation shaft, wherein the converting mechanism comprises: a lobed cam fixed to the rotation shaft and having a cam face; and a roller interposed between the cam face and the piston, and a lobed cam fixed to the rotation shaft and having a cam face; and a roller interposed between the cam face and the piston, and the lobed cam is formed by a plurality of segments arranged along a circumferential direction of the rotation shaft (20, characterised by each of the plurality of the segments having a flat mounting surface facing the rotation shaft.