libnx  v4.2.0
nacp.h
Go to the documentation of this file.
1 /**
2  * @file nacp.h
3  * @brief Control.nacp structure / related code for nacp.
4  * @copyright libnx Authors
5  */
6 
7 #pragma once
8 
9 /// Language entry. These strings are UTF-8.
10 typedef struct {
11  char name[0x200];
12  char author[0x100];
14 
15 /// ApplicationNeighborDetectionGroupConfiguration
16 typedef struct {
17  u64 group_id; ///< GroupId
18  u8 key[0x10];
20 
21 /// NeighborDetectionClientConfiguration
22 typedef struct {
24  NacpApplicationNeighborDetectionGroupConfiguration receivable_group_configurations[0x10]; ///< ReceivableGroupConfigurations
26 
27 /// ApplicationJitConfiguration
28 typedef struct {
29  u64 flags; ///< Flags
30  u64 memory_size; ///< MemorySize
32 
33 /// ns ApplicationControlProperty
34 typedef struct {
35  NacpLanguageEntry lang[16]; ///< \ref NacpLanguageEntry
36  u8 isbn[0x25]; ///< Isbn
37  u8 startup_user_account; ///< StartupUserAccount
38  u8 user_account_switch_lock; ///< UserAccountSwitchLock
39  u8 add_on_content_registration_type; ///< AddOnContentRegistrationType
40  u32 attribute_flag; ///< AttributeFlag
41  u32 supported_language_flag; ///< SupportedLanguageFlag
42  u32 parental_control_flag; ///< ParentalControlFlag
43  u8 screenshot; ///< Screenshot
44  u8 video_capture; ///< VideoCapture
45  u8 data_loss_confirmation; ///< DataLossConfirmation
46  u8 play_log_policy; ///< PlayLogPolicy
47  u64 presence_group_id; ///< PresenceGroupId
48  s8 rating_age[0x20]; ///< RatingAge
49  char display_version[0x10]; ///< DisplayVersion
50  u64 add_on_content_base_id; ///< AddOnContentBaseId
51  u64 save_data_owner_id; ///< SaveDataOwnerId
52  u64 user_account_save_data_size; ///< UserAccountSaveDataSize
53  u64 user_account_save_data_journal_size; ///< UserAccountSaveDataJournalSize
54  u64 device_save_data_size; ///< DeviceSaveDataSize
55  u64 device_save_data_journal_size; ///< DeviceSaveDataJournalSize
56  u64 bcat_delivery_cache_storage_size; ///< BcatDeliveryCacheStorageSize
57  u64 application_error_code_category; ///< ApplicationErrorCodeCategory
58  u64 local_communication_id[0x8]; ///< LocalCommunicationId
59  u8 logo_type; ///< LogoType
60  u8 logo_handling; ///< LogoHandling
61  u8 runtime_add_on_content_install; ///< RuntimeAddOnContentInstall
62  u8 runtime_parameter_delivery; ///< RuntimeParameterDelivery
63  u8 reserved_x30f4[0x2]; ///< Reserved
64  u8 crash_report; ///< CrashReport
65  u8 hdcp; ///< Hdcp
66  u64 pseudo_device_id_seed; ///< SeedForPseudoDeviceId
67  char bcat_passphrase[0x41]; ///< BcatPassphrase
68  u8 startup_user_account_option; ///< StartupUserAccountOption
69  u8 reserved_for_user_account_save_data_operation[0x6]; ///< ReservedForUserAccountSaveDataOperation
70  u64 user_account_save_data_size_max; ///< UserAccountSaveDataSizeMax
71  u64 user_account_save_data_journal_size_max; ///< UserAccountSaveDataJournalSizeMax
72  u64 device_save_data_size_max; ///< DeviceSaveDataSizeMax
73  u64 device_save_data_journal_size_max; ///< DeviceSaveDataJournalSizeMax
74  u64 temporary_storage_size; ///< TemporaryStorageSize
75  u64 cache_storage_size; ///< CacheStorageSize
76  u64 cache_storage_journal_size; ///< CacheStorageJournalSize
77  u64 cache_storage_data_and_journal_size_max; ///< CacheStorageDataAndJournalSizeMax
78  u16 cache_storage_index_max; ///< CacheStorageIndexMax
79  u8 reserved_x318a[0x6]; ///< Reserved
80  u64 play_log_queryable_application_id[0x10]; ///< PlayLogQueryableApplicationId
81  u8 play_log_query_capability; ///< PlayLogQueryCapability
82  u8 repair_flag; ///< RepairFlag
83  u8 program_index; ///< ProgramIndex
84  u8 required_network_service_license_on_launch; ///< RequiredNetworkServiceLicenseOnLaunchFlag
85  u32 reserved_x3214; ///< Reserved
88  u8 reserved_x33c0[0xc40]; ///< Reserved
89 } NacpStruct;
90 
91 /// Get the NacpLanguageEntry from the input nacp corresponding to the current system language (this may fallback to other languages when needed). Output langentry is NULL if none found / content of entry is empty.
92 /// If you're using ns you may want to use \ref nsGetApplicationDesiredLanguage instead.
94 
NacpStruct::screenshot
u8 screenshot
Screenshot.
Definition: nacp.h:43
NacpStruct::startup_user_account
u8 startup_user_account
StartupUserAccount.
Definition: nacp.h:37
NacpNeighborDetectionClientConfiguration
NeighborDetectionClientConfiguration.
Definition: nacp.h:22
NacpStruct::pseudo_device_id_seed
u64 pseudo_device_id_seed
SeedForPseudoDeviceId.
Definition: nacp.h:66
u8
uint8_t u8
8-bit unsigned integer.
Definition: types.h:19
NacpStruct::device_save_data_size_max
u64 device_save_data_size_max
DeviceSaveDataSizeMax.
Definition: nacp.h:72
NacpStruct::data_loss_confirmation
u8 data_loss_confirmation
DataLossConfirmation.
Definition: nacp.h:45
NacpStruct::hdcp
u8 hdcp
Hdcp.
Definition: nacp.h:65
NacpStruct::user_account_switch_lock
u8 user_account_switch_lock
UserAccountSwitchLock.
Definition: nacp.h:38
NacpStruct::add_on_content_base_id
u64 add_on_content_base_id
AddOnContentBaseId.
Definition: nacp.h:50
NacpApplicationJitConfiguration::flags
u64 flags
Flags.
Definition: nacp.h:29
NacpStruct::bcat_delivery_cache_storage_size
u64 bcat_delivery_cache_storage_size
BcatDeliveryCacheStorageSize.
Definition: nacp.h:56
NacpStruct
ns ApplicationControlProperty
Definition: nacp.h:34
NacpStruct::neighbor_detection_client_configuration
NacpNeighborDetectionClientConfiguration neighbor_detection_client_configuration
NeighborDetectionClientConfiguration.
Definition: nacp.h:86
NacpStruct::program_index
u8 program_index
ProgramIndex.
Definition: nacp.h:83
NacpStruct::add_on_content_registration_type
u8 add_on_content_registration_type
AddOnContentRegistrationType.
Definition: nacp.h:39
NacpStruct::cache_storage_data_and_journal_size_max
u64 cache_storage_data_and_journal_size_max
CacheStorageDataAndJournalSizeMax.
Definition: nacp.h:77
NacpApplicationJitConfiguration::memory_size
u64 memory_size
MemorySize.
Definition: nacp.h:30
NacpStruct::device_save_data_journal_size_max
u64 device_save_data_journal_size_max
DeviceSaveDataJournalSizeMax.
Definition: nacp.h:73
NacpStruct::play_log_policy
u8 play_log_policy
PlayLogPolicy.
Definition: nacp.h:46
NacpStruct::runtime_add_on_content_install
u8 runtime_add_on_content_install
RuntimeAddOnContentInstall.
Definition: nacp.h:61
NacpStruct::supported_language_flag
u32 supported_language_flag
SupportedLanguageFlag.
Definition: nacp.h:41
NacpLanguageEntry
Language entry. These strings are UTF-8.
Definition: nacp.h:10
NacpStruct::startup_user_account_option
u8 startup_user_account_option
StartupUserAccountOption.
Definition: nacp.h:68
NacpNeighborDetectionClientConfiguration::send_group_configuration
NacpApplicationNeighborDetectionGroupConfiguration send_group_configuration
SendGroupConfiguration.
Definition: nacp.h:23
NacpStruct::temporary_storage_size
u64 temporary_storage_size
TemporaryStorageSize.
Definition: nacp.h:74
NacpStruct::attribute_flag
u32 attribute_flag
AttributeFlag.
Definition: nacp.h:40
NacpStruct::logo_type
u8 logo_type
LogoType.
Definition: nacp.h:59
NacpStruct::user_account_save_data_journal_size_max
u64 user_account_save_data_journal_size_max
UserAccountSaveDataJournalSizeMax.
Definition: nacp.h:71
u32
uint32_t u32
32-bit unsigned integer.
Definition: types.h:21
NacpStruct::cache_storage_index_max
u16 cache_storage_index_max
CacheStorageIndexMax.
Definition: nacp.h:78
NacpStruct::save_data_owner_id
u64 save_data_owner_id
SaveDataOwnerId.
Definition: nacp.h:51
NacpStruct::application_error_code_category
u64 application_error_code_category
ApplicationErrorCodeCategory.
Definition: nacp.h:57
s8
int8_t s8
8-bit signed integer.
Definition: types.h:25
u64
uint64_t u64
64-bit unsigned integer.
Definition: types.h:22
NacpStruct::video_capture
u8 video_capture
VideoCapture.
Definition: nacp.h:44
NacpStruct::required_network_service_license_on_launch
u8 required_network_service_license_on_launch
RequiredNetworkServiceLicenseOnLaunchFlag.
Definition: nacp.h:84
NacpStruct::jit_configuration
NacpApplicationJitConfiguration jit_configuration
JitConfiguration.
Definition: nacp.h:87
Result
u32 Result
Function error code result type.
Definition: types.h:44
NacpStruct::user_account_save_data_size_max
u64 user_account_save_data_size_max
UserAccountSaveDataSizeMax.
Definition: nacp.h:70
NacpStruct::cache_storage_size
u64 cache_storage_size
CacheStorageSize.
Definition: nacp.h:75
nacpGetLanguageEntry
Result nacpGetLanguageEntry(NacpStruct *nacp, NacpLanguageEntry **langentry)
Get the NacpLanguageEntry from the input nacp corresponding to the current system language (this may ...
NacpStruct::logo_handling
u8 logo_handling
LogoHandling.
Definition: nacp.h:60
NacpStruct::repair_flag
u8 repair_flag
RepairFlag.
Definition: nacp.h:82
NacpStruct::runtime_parameter_delivery
u8 runtime_parameter_delivery
RuntimeParameterDelivery.
Definition: nacp.h:62
NacpStruct::device_save_data_journal_size
u64 device_save_data_journal_size
DeviceSaveDataJournalSize.
Definition: nacp.h:55
NacpStruct::user_account_save_data_journal_size
u64 user_account_save_data_journal_size
UserAccountSaveDataJournalSize.
Definition: nacp.h:53
NacpStruct::user_account_save_data_size
u64 user_account_save_data_size
UserAccountSaveDataSize.
Definition: nacp.h:52
NacpStruct::device_save_data_size
u64 device_save_data_size
DeviceSaveDataSize.
Definition: nacp.h:54
NacpStruct::crash_report
u8 crash_report
CrashReport.
Definition: nacp.h:64
NacpApplicationJitConfiguration
ApplicationJitConfiguration.
Definition: nacp.h:28
NacpStruct::cache_storage_journal_size
u64 cache_storage_journal_size
CacheStorageJournalSize.
Definition: nacp.h:76
NacpApplicationNeighborDetectionGroupConfiguration::group_id
u64 group_id
GroupId.
Definition: nacp.h:17
NacpApplicationNeighborDetectionGroupConfiguration
ApplicationNeighborDetectionGroupConfiguration.
Definition: nacp.h:16
NacpStruct::parental_control_flag
u32 parental_control_flag
ParentalControlFlag.
Definition: nacp.h:42
u16
uint16_t u16
16-bit unsigned integer.
Definition: types.h:20
NacpStruct::play_log_query_capability
u8 play_log_query_capability
PlayLogQueryCapability.
Definition: nacp.h:81
NacpStruct::reserved_x3214
u32 reserved_x3214
Reserved.
Definition: nacp.h:85
NacpStruct::presence_group_id
u64 presence_group_id
PresenceGroupId.
Definition: nacp.h:47