Files
vitasdk-odin/Camera/Camera.odin
T

407 lines
11 KiB
Odin
Raw Normal View History

2024-05-11 23:24:13 +02:00
package camera
import "core:c"
import sce "../common"
foreign import camera "SceCamera_stub"
foreign camera {
/**
* Open a camera device.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[in] pInfo - Pointer to an already set ::SceCameraInfo struct.
*
* @return SCE_OK, <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraOpen :: proc(devnum: c.int, pInfo: ^SceCameraInfo) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Close a camera device.
*
* @param[in] devnum - One of ::SceCameraDevice.
*
* @return SCE_OK, <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraClose :: proc(devnum: c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Start camera streaming.
*
* @param[in] devnum - One of ::SceCameraDevice.
*
* @return SCE_OK, <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraStart :: proc(devnum: c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Stop camera streaming.
*
* @param[in] devnum - One of ::SceCameraDevice.
*
* @return SCE_OK, <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraStop :: proc(devnum: c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Read image data from current streaming.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[in] pRead - Pointer to an already set ::SceCameraRead.
*
* @return SCE_OK, <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraRead :: proc(devnum: c.int, pRead: ^SceCameraRead) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Check if camera device is active.
*
* @param[in] devnum - One of ::SceCameraDevice.
*
* @return 1 if camera is active, 0 if inactive , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraIsActive :: proc(devnum: c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Get camera saturation value.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[out] pLevel - Pointer to a variable where to save the result. (See ::SceCameraSaturation)
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraGetSaturation :: proc(devnum: c.int, pLevel: ^c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Set camera saturation value.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[in] level - One of ::SceCameraSaturation.
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraSetSaturation :: proc(devnum: c.int, level: c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Get camera brightness value.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[out] pLevel - Pointer to a variable where to save the result.
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraGetBrightness :: proc(devnum: c.int, pLevel: ^c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Set camera brightness value.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[in] level - Brightness value.
*
* @return SCE_OK , <0 on error.
*
* @note Brightness value must be between 0 and 255.
*/
2024-05-13 16:04:23 +02:00
sceCameraSetBrightness :: proc(devnum: c.int, level: c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Get camera contrast value.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[out] pLevel - Pointer to a variable where to save the result.
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraGetContrast :: proc(devnum: c.int, pLevel: ^c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Set camera contrast value.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[in] level - Contrast value.
*
* @return SCE_OK , <0 on error.
*
* @note Contrast value must be between 0 and 255.
*/
2024-05-13 16:04:23 +02:00
sceCameraSetContrast :: proc(devnum: c.int, level: c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Get camera sharpness value.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[out] pLevel - Pointer to a variable where to save the result. (See ::SceCameraSharpness)
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraGetSharpness :: proc(devnum: c.int, pLevel: ^c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Set camera sharpness value.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[in] level - One of ::SceCameraSharpness.
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraSetSharpness :: proc(devnum: c.int, level: c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Get camera reverse mode.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[out] pMode - Pointer to a variable where to save the result. (See ::SceCameraReverse)
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraGetReverse :: proc(devnum: c.int, pMode: ^c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Set camera reverse mode.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[in] mode - One of ::SceCameraReverse.
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraSetReverse :: proc(devnum: c.int, mode: c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Get active camera effects.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[out] pMode - Pointer to a variable where to save the result.
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraGetEffect :: proc(devnum: c.int, pMode: ^c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Active a camera effect.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[in] mode - One of ::SceCameraEffect.
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraSetEffect :: proc(devnum: c.int, mode: c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Get camera exposure compensation value.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[out] pLevel - Pointer to a variable where to save the result (See ::SceCameraExposureCompensation).
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraGetEV :: proc(devnum: c.int, pLevel: ^c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Set camera exposure compensation value.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[in] level - One of ::SceCameraExposureCompensation.
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraSetEV :: proc(devnum: c.int, level: c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Get camera zoom value.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[out] pLevel - Pointer to a variable where to save the result.
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraGetZoom :: proc(devnum: c.int, pLevel: ^c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Set camera zoom value.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[in] level - Camera zoom value.
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraSetZoom :: proc(devnum: c.int, level: c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Get camera anti-flickering mode.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[out] pMode - Pointer to a variable where to save the result. (See ::SceCameraAntiFlicker)
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraGetAntiFlicker :: proc(devnum: c.int, pMode: ^c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Set camera exposure anti-flickering mode.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[in] mode - One of ::SceCameraAntiFlicker.
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraSetAntiFlicker :: proc(devnum: c.int, mode: c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Get camera ISO speed mode.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[out] pMode - Pointer to a variable where to save the result. (See ::SceCameraISO)
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraGetISO :: proc(devnum: c.int, pMode: ^c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Set camera ISO speed mode.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[in] mode - One of ::SceCameraISO.
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraSetISO :: proc(devnum: c.int, mode: c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Get camera gain mode.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[out] pMode - Pointer to a variable where to save the result. (See ::SceCameraGain)
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraGetGain :: proc(devnum: c.int, pMode: ^c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Set camera gain mode.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[in] mode - One of ::SceCameraGain.
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraSetGain :: proc(devnum: c.int, mode: c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Get camera white balance mode.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[out] pMode - Pointer to a variable where to save the result. (See ::SceCameraWhiteBalance)
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraGetWhiteBalance :: proc(devnum: c.int, pMode: ^c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Set camera white balance mode.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[in] mode - One of ::SceCameraWhiteBalance.
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraSetWhiteBalance :: proc(devnum: c.int, mode: c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Get camera backlight compensation mode.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[out] pMode - Pointer to a variable where to save the result. (See ::SceCameraBacklight)
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraGetBacklight :: proc(devnum: c.int, pMode: ^c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Set camera backlight mode.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[in] mode - One of ::SceCameraBacklight.
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraSetBacklight :: proc(devnum: c.int, mode: c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Get nightmode mode.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[out] pMode - Pointer to a variable where to save the result. (See ::SceCameraNightmode)
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraGetNightmode :: proc(devnum: c.int, pMode: ^c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Set camera nightmoge mode.
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[in] mode - One of ::SceCameraNightmode.
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraSetNightmode :: proc(devnum: c.int, mode: c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Get exposure ceiling mode. (?)
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[out] pMode - Pointer to a variable where to save the result.
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraGetExposureCeiling :: proc(devnum: c.int, pMode: ^c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Set exposure ceiling mode. (?)
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[in] mode - Exposure ceiling mode value. (?)
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraSetExposureCeiling :: proc(devnum: c.int, mode: c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Get auto control hold mode. (?)
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[out] pMode - Pointer to a variable where to save the result.
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraGetAutoControlHold :: proc(devnum: c.int, pMode: ^c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Set auto control hold mode. (?)
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[in] mode - Auto control hold mode value. (?)
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraSetAutoControlHold :: proc(devnum: c.int, mode: c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
/**
* Get camera device location. (?)
*
* @param[in] devnum - One of ::SceCameraDevice.
* @param[out] pLocation - Pointer to a variable where to save the result.
*
* @return SCE_OK , <0 on error.
*/
2024-05-13 16:04:23 +02:00
sceCameraGetDeviceLocation :: proc(devnum: c.int, pLocation: ^sce.FVector3) -> c.int ---
2024-05-11 23:24:13 +02:00
2024-05-13 16:04:23 +02:00
sceCameraGetImageQuality :: proc(devnum: c.int, pLevel: ^c.int) -> c.int ---
sceCameraSetImageQuality :: proc(devnum: c.int, level: c.int) -> c.int ---
sceCameraGetNoiseReduction :: proc(devnum: c.int, pLevel: ^c.int) -> c.int ---
sceCameraSetNoiseReduction :: proc(devnum: c.int, level: c.int) -> c.int ---
sceCameraGetSharpnessOff :: proc(devnum: c.int, pLevel: ^c.int) -> c.int ---
sceCameraSetSharpnessOff :: proc(devnum: c.int, level: c.int) -> c.int ---
2024-05-11 23:24:13 +02:00
}