SoundSampleData.h
1 #pragma once
2 // Copyright (c) 2001-2024 Aspose Pty Ltd. All Rights Reserved.
3 
4 #include <system/object.h>
5 #include <cstdint>
6 
7 #include "Aspose.PDF.Cpp/aspose_pdf_api_defs.h"
8 
9 namespace Aspose
10 {
11 namespace Pdf
12 {
13 namespace Annotations
14 {
15 class SoundData;
17 } // namespace Annotations
18 } // namespace Pdf
19 } // namespace Aspose
20 namespace System
21 {
22 class String;
23 } // namespace System
24 
25 namespace Aspose {
26 
27 namespace Pdf {
28 
29 namespace Annotations {
30 
34 class ASPOSE_PDF_SHARED_CLASS SoundSampleData : public System::Object
35 {
36  typedef SoundSampleData ThisType;
37  typedef System::Object BaseType;
38 
39  typedef ::System::BaseTypesInfo<BaseType> ThisTypeBaseTypesInfo;
40  ASPOSE_PDF_SHARED_RTTI_INFO_DECL();
41 
43 
44 public:
45 
49  static const ASPOSE_PDF_SHARED_API int64_t DefaultSamplingRate;
53  static const ASPOSE_PDF_SHARED_API int32_t DefaultOfSoundChannels;
57  static const ASPOSE_PDF_SHARED_API int32_t DefaultOfBitsPerChannel;
61  static const ASPOSE_PDF_SHARED_API SoundSampleDataEncodingFormat DefaultEncodingFormat;
62 
66  ASPOSE_PDF_SHARED_API int64_t get_SamplingRate() const;
70  ASPOSE_PDF_SHARED_API void set_SamplingRate(int64_t value);
74  ASPOSE_PDF_SHARED_API int32_t get_NumberOfSoundChannels() const;
78  ASPOSE_PDF_SHARED_API void set_NumberOfSoundChannels(int32_t value);
82  ASPOSE_PDF_SHARED_API int32_t get_BitsPerChannel() const;
86  ASPOSE_PDF_SHARED_API void set_BitsPerChannel(int32_t value);
90  ASPOSE_PDF_SHARED_API SoundSampleDataEncodingFormat get_EncodingFormat() const;
94  ASPOSE_PDF_SHARED_API void set_EncodingFormat(SoundSampleDataEncodingFormat value);
95 
100  ASPOSE_PDF_SHARED_API SoundSampleData(int64_t samplingRate);
106  ASPOSE_PDF_SHARED_API SoundSampleData(int64_t samplingRate, int32_t numberOfSoundChannels);
113  ASPOSE_PDF_SHARED_API SoundSampleData(int64_t samplingRate, int32_t numberOfSoundChannels, int32_t bitsPerChannel);
121  ASPOSE_PDF_SHARED_API SoundSampleData(int64_t samplingRate, int32_t numberOfSoundChannels, int32_t bitsPerChannel, SoundSampleDataEncodingFormat soundSampleDataEncodingFormat);
122 
123 protected:
124 
129  System::String GetEncodingFormat();
135  static int64_t ReadSamplingRate(System::String soundFile);
136 
137 private:
138 
142  int64_t _samplingRate;
146  int32_t _numberOfSoundChannels;
150  int32_t _bitsPerChannel;
154  SoundSampleDataEncodingFormat _encodingFormat;
155 
156 };
157 
158 } // namespace Annotations
159 } // namespace Pdf
160 } // namespace Aspose
161 
162 
String class used across the library. Is a substitute for C# System.String when translating code...
Definition: string.h:121
SoundSampleDataEncodingFormat
The encoding format for the sound sample data.
Definition: SoundSampleDataEncodingFormat.h:18
Represents additional entries specific to a sound object (Section 9.2 PDF1-7)
Definition: SoundSampleData.h:34
Base class that enables using methods available for System.Object class in C#. All non-trivial classe...
Definition: object.h:64
static const ASPOSE_PDF_SHARED_API int32_t DefaultOfBitsPerChannel
Default value for BitsPerchannel parameter.
Definition: SoundSampleData.h:57
Definition: Artifact.h:67
Represents a sound data defining the sound to be played when the annotation is activated.
Definition: SoundData.h:47
Definition: AFRelationship.h:4
static const ASPOSE_PDF_SHARED_API int32_t DefaultOfSoundChannels
Default value for Channels parameter.
Definition: SoundSampleData.h:53
static const ASPOSE_PDF_SHARED_API int64_t DefaultSamplingRate
Default value for SamplingRate.
Definition: SoundSampleData.h:49
static const ASPOSE_PDF_SHARED_API SoundSampleDataEncodingFormat DefaultEncodingFormat
Default value for encoding format.
Definition: SoundSampleData.h:61
Whole PDF file will be submitted.