Could friends here provide me some suggestions about creating my own c++ camera class in unreal?

Hi everyone,

I am quite new to unreal c++ gameplay programming, and currently I need to create my own C++ camera class in unreal. Since currently in unreal the camera has only basic functions, and what I need to do is to add more member variables and function members into my own-created camera class.
I see there are cameraactor class and cameracomponent class that I could inherit, however most of the variables and functions are private and now I have a problem about how to create my new camera and finally I could use my camera and see the scene from my new camera point of view.

Is anyone has any great suggestions about how to do this ?
Any suggestion is good so please help :slight_smile:

Thank you!

Fire up your code project in UE and go to the File menu and select “New C++ Class…” then find the camera component and inherit from that. A normal camera actor will still be able to implement your new camera component.

After that making things go public is a bit tricky, but I believe you can override private members and make them public. I’m only marginal at C++ myself but I’d have a go at it and find out.