Zomer,
First figure out how to do what you want using MAX. For the two items you mentioned, I believe you want to change the scale (for pixel decimation) and Reference Levels (for gain). They are both on the Basic page of the properties for your camera.
Once you know which properties you want to change, you can change them in your program using a property node.
Bruce
Bruce Ammons
Ammons Engineering