WO2014201940A1 - 拍照方法、装置和存储介质 - Google Patents

拍照方法、装置和存储介质 Download PDF

Info

Publication number
WO2014201940A1
WO2014201940A1 PCT/CN2014/078380 CN2014078380W WO2014201940A1 WO 2014201940 A1 WO2014201940 A1 WO 2014201940A1 CN 2014078380 W CN2014078380 W CN 2014078380W WO 2014201940 A1 WO2014201940 A1 WO 2014201940A1
Authority
WO
WIPO (PCT)
Prior art keywords
image data
encrypted
shooting
decryption
user
Prior art date
Application number
PCT/CN2014/078380
Other languages
English (en)
French (fr)
Inventor
林如蓝
邹烨
李丹华
杨朗
Original Assignee
腾讯科技(深圳)有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 腾讯科技(深圳)有限公司 filed Critical 腾讯科技(深圳)有限公司
Publication of WO2014201940A1 publication Critical patent/WO2014201940A1/zh

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N1/00Scanning, transmission or reproduction of documents or the like, e.g. facsimile transmission; Details thereof
    • H04N1/44Secrecy systems
    • H04N1/448Rendering the image unintelligible, e.g. scrambling
    • H04N1/4486Rendering the image unintelligible, e.g. scrambling using digital data encryption
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/60Control of cameras or camera modules
    • H04N23/667Camera operation mode switching, e.g. between still and video, sport and normal or high- and low-resolution modes

Definitions

  • Photographing method, device and storage medium The patent application is filed on June 21, 2013, and the application number is 201310250632. 9. The applicant is Tencent Technology (Shenzhen) Co., Ltd., and the invention is entitled “Photographing Method and Device”. Priority of the application, the entire contents of which are incorporated herein by reference. Technical field
  • the present invention relates to the field of electronic device applications, and in particular, to a photographing method, device, and storage medium. Background technique
  • the existing image encryption process is usually as follows: After the user finishes shooting, the user exits the shooting application and enters the encryption protection application, and the image is encrypted and saved in the encryption protection application.
  • the embodiment of the invention provides a photographing method, device and storage medium, which can solve the problem that the image encryption and storage process is too cumbersome.
  • an embodiment of the present invention provides a photographing method, including:
  • the embodiment of the present invention further provides a photographing apparatus, including:
  • a receiving unit configured to receive a user-triggered encrypted shooting instruction after the shooting application is started; and a switching unit, configured to switch the normal shooting mode to the encrypted shooting mode according to the encrypted shooting instruction received by the receiving unit;
  • An acquiring unit configured to acquire image data captured by a camera in an encrypted shooting mode
  • an encryption and decryption unit configured to perform encryption processing on the image data acquired by the acquiring unit
  • a storage unit configured to save the image data after the encryption and decryption unit is encrypted.
  • an embodiment of the present invention further provides a storage medium including computer executable instructions for performing a photographing method when executed by a computer processor, the method comprising:
  • the encrypted image data is saved.
  • the photographing method, device and storage medium provided by the embodiments of the present invention can switch the normal shooting mode to the encrypted shooting mode according to the received encrypted shooting instruction during the shooting process, and acquire the image data captured by the camera in the encrypted shooting mode, and then The acquired image data is encrypted, and finally the encrypted image data is saved, so that subsequent users can view according to the user password.
  • the user needs to exit the shooting application to encrypt the image data, and can provide an encrypted shooting mode in the shooting application, and automatically encrypt and save the image captured by the camera in the encrypted shooting mode, which can save due to the shooting application and Encryption protects the steps generated by repeated switching between applications, thereby simplifying user operations during image encryption and preservation.
  • FIG. 1 is a flowchart of a photographing method in an embodiment of the present invention.
  • FIG. 2 is a flowchart of another photographing method in an embodiment of the present invention.
  • FIG. 3 is a schematic diagram of a photographing interface in an embodiment of the present invention.
  • FIG. 4 is a schematic diagram of a system file directory in an embodiment of the present invention.
  • FIG. 5 is a schematic diagram of another shooting interface according to an embodiment of the present invention.
  • FIG. 6 is a schematic diagram of still another shooting interface according to an embodiment of the present invention.
  • FIG. 7 is a schematic structural diagram of a photographing apparatus according to an embodiment of the present invention.
  • FIG. 8 is a schematic structural diagram of another camera device according to an embodiment of the present invention.
  • FIG. 9 is a schematic structural diagram of still another camera device according to an embodiment of the present invention.
  • the embodiment provides a photographing method, and the method can be applied to an electronic device equipped with a camera such as a mobile phone or a tablet computer. As shown in FIG. 1, the method includes:
  • the electronic device After starting the shooting application, the electronic device receives an encrypted shooting instruction triggered by the user.
  • the electronic device After the user launches the photographing application, the electronic device receives an encrypted photographing instruction for instructing switching to the encrypted photographing mode.
  • the electronic device switches the normal shooting mode to the encrypted shooting mode according to the encrypted shooting instruction. After receiving the encrypted shooting instruction, the electronic device switches the current normal shooting mode to the encrypted shooting mode. In the encrypted shooting mode, the electronic device can automatically encrypt and save the image captured by the camera. 103. The electronic device acquires image data captured by the camera in the encrypted shooting mode.
  • the image data described in this embodiment may be a still image data such as a photo, or may be a dynamic image data such as a video.
  • the camera shoots the subject.
  • the photos taken by the camera are saved in the system file directory, and the system file directory saves the photos taken by the camera in the order in which they were taken.
  • the electronic device extracts the picture taken by the camera from the system file directory.
  • the electronic device performs encryption processing on the image data.
  • the electronic device encrypts the photo extracted from the system file directory.
  • the electronic device may encrypt the photo content itself, and may also encrypt the attribute information of the photo to implement encryption of the photo content. This is not a limitation.
  • the electronic device saves the image data after the encryption process.
  • the electronic device saves the encrypted photo from the system file directory in the encrypted file directory, so that subsequent users can view according to the user password.
  • the encryption protection application is opened and the user password is input. Encrypted photos can be viewed.
  • the electronic device can save the photos in the order in which they were taken, or save the photos according to the attribute information of the photos.
  • the electronic device may use the file directory of the existing encryption protection application as the encrypted file directory, or may separately open a sub-area in the storage area to save the encrypted file directory, which is not limited in this embodiment.
  • photos taken by the user through the camera are saved in a system file directory, such as a default album folder.
  • a system file directory such as a default album folder.
  • the user needs to exit the shooting application, then open the encryption protection application and enter the user password, and migrate the photo to be encrypted from the system file directory to the encrypted file directory in the encryption protection application.
  • Switching between the capture application and the cryptographically protected application increases the user's operational steps while consuming the processing resources of the system.
  • the user needs to perform the same operation steps repeatedly, which is quite cumbersome to use.
  • the process of photo shooting and photo encryption saving is separated in time series, so the user easily forgets to encrypt the captured picture, and there is a risk of leakage. For example, after exiting the shooting application, the user does not enter the encryption protection application in time to encrypt the picture, and forgets the photo after a period of time. Chip encryption, if someone else steals the user's electronic device, you can directly open the system file directory to view the user's privacy photo.
  • a third-party encryption protection application in the prior art, which can drive the camera of the electronic device, allows the user to start the camera to shoot in the third-party application, and the captured photos are directly saved in the encrypted file directory.
  • the image encryption method can avoid the operation steps of switching the application and inputting the user password in the above encryption method, the shooting function and the shooting interface are different from the shooting application of the system, and the user's usage habit cannot be guaranteed. .
  • the photographing method further includes:
  • the photographing method provided in this embodiment can switch the normal shooting mode to the encrypted shooting mode according to the received encrypted shooting instruction during the shooting process, acquire the image data captured by the camera in the encrypted shooting mode, and then encrypt the acquired image data. After processing, the encrypted image data is finally saved, so that subsequent users can view according to the user password.
  • the user needs to exit the shooting application to encrypt the image data, and can provide an encrypted shooting mode in the shooting application, and automatically encrypt and save the image captured by the camera in the encrypted shooting mode, thereby saving the shooting application and Encryption protects the steps created by repeated switching between applications, thereby simplifying user operations during image encryption.
  • the photographing method provided by the embodiment is based on the improvement of the system shooting application most commonly used by the user. Compared with the third-party application, the image can be automatically encrypted under the familiar shooting interface and shooting function. Fit the user's usage habits.
  • the embodiment of the present invention further provides a photographing method. As shown in FIG. 2, the method includes:
  • the electronic device monitors the mode switching function key.
  • the electronic device can display the mode switching function key as shown in FIG. 3 in the floating window in the shooting interface, and monitor the mode switching function key.
  • the mode switching function key It is used to switch between the normal shooting mode and the encrypted shooting mode, where ON means to turn on the encrypted shooting mode, OFF means to turn off the encrypted shooting mode, that is, to turn on the normal shooting mode.
  • the electronic device receives a triggering command from the user to the mode switching function key.
  • the electronic device When the user switches the function key to the normal shooting mode, the electronic device performs step 202.
  • the electronic device performs step 203. .
  • the display mode switching function key allows the user to conveniently and quickly select a file directory to be saved in the photo during the shooting process.
  • the mode switching function key can be displayed in the floating window form to reduce the menu depth of the function keys, save the operation and time of the user switching mode, and be more suitable for shooting scenes such as snap shots.
  • the electronic device can also prompt the user to select the currently selected shooting mode through a dialog box. For example, in FIG. 3, when the user switches to the encrypted shooting mode, the electronic device displays the dialog box "photographed and The video will be saved in privacy.”
  • the electronic device can default to the current mode as the encrypted shooting mode, and the mode switching function key when the shooting application is turned on is as shown in FIG.
  • the user can manually trigger the mode switching function key.
  • the electronic device saves the image data captured by the camera according to the normal photographing mode.
  • the electronic device After the camera takes a photo, the electronic device saves the photo in the system file directory as shown in FIG. 4, wherein the left side of the system file directory is the photo data content, and the right side of the system file directory is the storage serial number of the photo, according to the queue "advanced first The rule of "out”, the most recently taken photo is saved in the first entry of the system file directory, that is, the entry of the serial number N in FIG.
  • the electronic device monitors the system file directory.
  • the photos taken by the camera are still saved in the system file directory.
  • the electronic device monitors the system file directory in real time and monitors whether new photos are added to the system file directory.
  • the electronic device extracts a new photo from a system file directory.
  • the electronic device When a new photo is added to the system file directory, the electronic device extracts the photo from the system file directory. Since the photos saved in the system file directory are photos that can be directly viewed, the electronic device The photo that needs to be encrypted needs to be extracted from the system file directory, and the photo does not exist in the system file directory after the photo is extracted.
  • the electronic device may further monitor the database file directory in the third-party camera application software, and when the user shoots through the third-party camera application software, the electronic device extracts the new file from the database file directory.
  • the photo, and then step 205; or the electronic device can also monitor the local system media database file directory, for example, to listen to the local album, when the new image is monitored, for example, the user downloads a wallpaper, the electronic device from the system The newly added wallpaper is extracted from the media database file directory, and then step 205 is performed.
  • the electronic device performs encryption processing on the extracted image data.
  • the data encryption method that can be used in this embodiment is more than two, and only two of the encryption methods are performed here. Description:
  • the photos acquired by the electronic device carry a file header containing photo attribute information, and the file header contains attribute information of at least 1 bit.
  • the electronic device extracts the file header from the photo, and then replaces the set position and the set number of bits in the file header with the user password, where the user password is a password preset by the user, that is, when the user logs in to the encryption protection application. User password.
  • the electronic device extracts a file header containing 100 bits from the photo, and then replaces the first 20 bits in the header with the user password, and the first 20 password bits after the replacement are : 12345612 345612 345612.
  • any type of data can be converted into a binary data storage sequence containing at least 1 bit.
  • the electronic device extracts the binary data storage sequence of the photo, and then determines the ordering of the bits in the binary data storage sequence based on the user password, and finally rearranges all the bits in the binary data storage sequence according to the sorting rule.
  • the first bit to the fifth bit are followed by &, b, c, (1 and 6.
  • the electronic device user password 54321 will be The position of the 5 bits of data is adjusted to e, d, c, b, and a, that is, the adjusted bit of the 1st bit Set to the first digit of the user's password "5", the second digit is adjusted to the second digit of the user's password "4", and so on.
  • the number of bits in this embodiment is merely an illustrative example and is not intended to limit the actual application. In practical applications, the number of bits in a binary data storage sequence for a photo is typically in the order of a million. In addition, the bit data a, b, c, d, and e are only used to facilitate the description of the encryption mode, and the bit data in the actual application is a binary number of 0 or 1.
  • the encryption method 1) There is a risk of small probability of cracking, and the criminals can read the data content by forcibly cracking the file header.
  • the encryption method 2) rearranges the data content itself. Without the user password (ie, the sorting rule), the illegal element cannot read the data content even if the file header is cracked. Therefore, as a preferred embodiment of the present embodiment, the electronic device encrypts the photo using the encryption method 2).
  • the electronic device saves the encrypted image data to an encrypted file directory.
  • the encrypted file directory is also used to save photos according to the time sequence of shooting or other attribute information, but unlike the system file directory, the encrypted file directory is used to save the encrypted photos, and the user only passes the user. You can view photos in the encrypted file directory after you log in to the encrypted protection application.
  • the electronic device encrypts the photos extracted from the system file directory, the database file directory in the third-party camera application software, or the system media database file directory, and then saves the encrypted photos in the encrypted file directory.
  • the electronic device can also obtain a thumbnail of the photo from the storage format of the photo, and then display the thumbnail of the photo and the serial number of the photo in the encrypted file directory in the shooting interface. For example, in FIG. 5, the electronic device displays the currently encrypted photo thumbnail saved on the right side of the mode switching function key, and displays the serial number 3 in the lower right corner of the thumbnail, the serial number indicates that the current photo is the third one saved in the encrypted file directory. photo.
  • the electronic device can also display a shortcut key of the encryption protection application in the shooting interface, for example, the "privacy space" shortcut key in the upper right corner of the shooting interface in FIG. 6.
  • the electronic device switches the current interface to the user.
  • the login interface displays the encrypted album in the privacy space after the user enters the user password.
  • the electronic device may further receive a decryption instruction triggered by the user, where the decryption instruction is used to indicate that the photo corresponding to the currently displayed thumbnail is decrypted.
  • the electronic device After receiving the decryption instruction, the electronic device extracts the photo corresponding to the thumbnail from the encrypted file directory, and decrypts the photo, and then saves the decrypted photo to the system file directory, and after the photo is saved, encrypts the file directory. The photo is no longer saved.
  • the electronic device When the electronic device displays the thumbnail of the current photo, the photo has been saved in the encrypted file directory.
  • Trigger the decryption instruction Trigger the decryption instruction.
  • the electronic device restores the encrypted photo to a normal save according to the decryption instruction.
  • the decryption instruction may be a long press instruction or a double-click instruction.
  • the electronic device extracts the photo corresponding to the thumbnail from the encrypted file directory, and then according to Step 205 decrypts the encrypted photo in the opposite manner, and finally saves the decrypted photo to the system file directory.
  • the electronic device can also display the thumbnail of the current photo in the shooting interface, and when the user wants to save the photo saved in the system file directory, the encryption instruction is triggered, the electronic device Steps 204 to 206 are sequentially executed, and the current photo that has been saved in the system file directory is extracted and encrypted, and then saved to the encrypted file directory.
  • the photographing method provided in this embodiment enables the user to easily select a shooting mode through a mode switching function key in the shooting interface.
  • the image captured by the camera can be automatically encrypted and saved without manual operation by the user.
  • the method can also display a thumbnail of the current image, so that the user can select the saved mode for the encrypted saved (or normal saved) photo twice without switching the shooting mode, thereby further simplifying the user operation.
  • the user starts the shooting application to take a photo
  • the default shooting mode of the electronic device is the encrypted shooting mode.
  • the user has taken two encrypted photos and then switched to the normal shooting mode with one button to continue shooting.
  • the user takes a photo in the encrypted shooting mode, then views the thumbnail of the photo, and finds that the photo is not stored encrypted. The user double-clicks on the thumbnail to migrate the photo from the encrypted saved album to the normally saved album.
  • the user takes a photo in the normal shooting mode. Then look at the thumbnail of the photo and find that the photo needs to be saved in encrypted form. The user double-clicks the thumbnail to migrate the photo from the normally saved album to the encrypted saved album.
  • the image captured by the camera is used as an encrypted storage object, and the object to be actually stored and encrypted may be, but not limited to, a short message, a chat record, and a video call record.
  • the electronic device will package the generated chat log into a folder, then encrypt it, and finally save it in the encrypted file directory.
  • the embodiment further provides a photographing apparatus for implementing the method shown in FIG. 1 or FIG.
  • the device may be located in an electronic device such as a mobile phone or a tablet computer.
  • the device 71 includes: a receiving unit 711, a switching unit 712, an obtaining unit 71 3, an encryption and decryption unit 714, a storage unit 715, and a display unit. 716 and a listening unit 717, wherein
  • the receiving unit 711 is configured to receive an encrypted shooting instruction triggered by the user after the shooting application is started.
  • the switching unit 712 is configured to switch the normal shooting mode to the encryption according to the encrypted shooting instruction received by the receiving unit 711.
  • Shooting mode is configured to switch the normal shooting mode to the encryption according to the encrypted shooting instruction received by the receiving unit 711.
  • the obtaining unit 71 3 is configured to acquire image data captured by the camera in the encrypted shooting mode; the encryption and decryption unit 714 is configured to perform encryption processing on the image data acquired by the acquiring unit 71 3;
  • the storage unit 715 is configured to save the image data encrypted by the encryption and decryption unit 714.
  • the obtaining unit 71 3 includes:
  • the monitoring sub-unit 81 1 is configured to monitor the system file directory
  • the extracting sub-unit 812 is configured to extract the new image data from the system file directory when the monitoring sub-unit 811 monitors the system file directory to add new image data.
  • the encryption and decryption unit 714 includes:
  • the first encryption/decryption subunit 911 is configured to extract a file header of the image data, and replace a set position and a set number of bits in the file header with a user password.
  • the encryption and decryption unit 714 includes:
  • a second encryption and decryption sub-unit 912 configured to extract a binary data storage sequence of the image data, determine a ranking rule of the bit according to the user password, and store the binary data according to the sorting rule. All bits in the sequence are rearranged.
  • the storage unit 715 is configured to save the image data encrypted by the encryption and decryption unit 714 into an encrypted file directory.
  • the acquiring unit 71 is further configured to acquire a thumbnail of the image data from a storage format of the image data;
  • the display unit 716 is configured to display, in the shooting interface, a thumbnail of the image data acquired by the acquiring unit 71 3 and a serial number of the image data in the directory of the confidential file.
  • the receiving unit 711 is further configured to receive a decryption instruction, where the decryption instruction is used to indicate that the image data corresponding to the currently displayed thumbnail is decrypted;
  • the extracting sub-unit 812 is further configured to extract image data corresponding to the thumbnail image from the encrypted file directory according to the decryption instruction received by the receiving unit 711;
  • the encryption and decryption unit 714 is further configured to decrypt the image data extracted by the extraction subunit 812;
  • the storage unit 715 is further configured to save the image data decrypted by the encryption and decryption unit 714 into a system file directory.
  • the display unit 716 is further configured to display a mode switching function key in the shooting interface;
  • the monitoring unit 717 is configured to monitor the mode switching function key;
  • the receiving unit 711 is further configured to receive a trigger instruction of the mode switching function key by the user. Further, the receiving unit 711 is further configured to receive a user-initiated de-encrypted shooting instruction; the switching unit 712 is further configured to switch the encrypted shooting mode to the normal shooting mode according to the de-encrypting shooting instruction;
  • the storage unit 715 is further configured to save the image data captured by the camera according to the normal photographing mode.
  • the photographing apparatus provided in this embodiment can switch the normal shooting mode to the encrypted shooting mode according to the received encrypted shooting instruction during the shooting, acquire the image data captured by the camera in the encrypted shooting mode, and then encrypt the acquired image data. After processing, the encrypted image data is finally saved, so that subsequent users can view according to the user password.
  • the encrypted shooting mode can be provided in the shooting application.
  • the image captured by the camera is automatically encrypted, thereby saving the operation steps generated by repeated switching between the shooting application and the encryption protection application, thereby simplifying the user operation in the image encryption and saving process.
  • the electronic device can automatically encrypt the image after the image is taken by the camera, the user does not need to pay attention to the encryption process, so that the problem of the encryption omission caused by the user forgetting can be avoided.
  • the camera device provided by the embodiment is based on the improvement of the system shooting application most commonly used by the user. Compared with the third-party application, the image can be automatically encrypted under the familiar shooting interface and shooting function. Fit the user's usage habits.
  • the photographing apparatus provided in this embodiment can also display a thumbnail of the current image, so that the user can select the save mode of the encrypted (or normal saved) photo twice without switching the shooting mode, thereby further simplifying the user. operating.
  • the embodiment of the present invention further provides a storage medium including computer executable instructions, which are used to execute a photographing method when executed by a computer processor, the photographing method comprising:
  • the encrypted image data is saved.
  • the photographing method further includes:
  • the encrypted shooting mode is switched to the normal shooting mode according to the unencrypted shooting instruction; the image data captured by the camera is saved according to the normal shooting mode.
  • the present invention can be implemented by software and necessary general hardware, and of course can also be implemented by hardware, but in many cases, the former is a better implementation.
  • the technical solution of the present invention may be embodied in the form of a software product in essence or in the form of a software product, which may be stored in a computer readable storage medium, such as a floppy disk of a computer. , ROM
  • ROM Read-Only Memory
  • RAM Random Access Memory
  • FLASH Flash memory
  • hard disk or optical disk etc.
  • a computer device which may be a personal computer, server, or network device, etc. to perform the methods described in various embodiments of the present invention.
  • the units and modules included in the photographing apparatus are only divided according to functional logic, but are not limited to the above-mentioned division, as long as the corresponding functions can be realized;
  • the specific names of the units are also for convenience of distinction from each other and are not intended to limit the scope of the present invention.

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Studio Devices (AREA)
  • Television Signal Processing For Recording (AREA)
  • Storage Device Security (AREA)

Abstract

本发明公开了一种拍照方法、装置和存储介质,涉及电子设备应用领域,能够解决图像加密保存过程操作过于繁琐的问题。本发明的方法包括:在启动拍摄应用后,接收用户触发的加密拍摄指令;根据所述加密拍摄指令将普通拍摄模式切换为加密拍摄模式;在加密拍摄模式下,获取摄像头拍摄的图像数据;对所述图像数据进行加密处理;对加密处理后的图像数据进行保存。本发明主要用于对摄像头拍摄的照片及视频进行加密保存。

Description

拍照方法、 装置和存储介质 本专利申请要求于 2013年 06月 21 日提交的、 申请号为 201310250632. 9、 申请人为腾讯科技(深圳)有限公司、 发明名称为 "拍照方法及装置" 的中国 专利申请的优先权, 该申请的全文以 I用的方式并入本申请中。 技术领域
本发明涉及电子设备应用领域, 尤其涉及一种拍照方法、 装置和存储介质。 背景技术
目前, 诸如手机、 平板电脑等电子设备都广泛配备有用于拍摄照片或视频 的摄像头, 用户可以通过摄像头将生活中的点滴瞬间记录下来, 并保存在电子 设备中便于日后查看。 当用户拍摄的照片或视频(后续统称为图像) 隐私级别 较高时, 用户需要对这些图像进行加密保存, 以防止他人窃用自己的电子设备 查看隐私图像。
现有的图像加密过程通常为: 用户在完成拍摄后, 退出拍摄应用并进入加 密保护应用, 在加密保护应用中对图像进行加密保存。
在上述图像加密保存的过程中 , 发明人发现现有技术中至少存在如下问题: 用户需要在拍摄应用和加密保护应用之间进行手动切换, 并且在进入加密保护 应用时需要输入加密密码, 用户操作过于复杂。 特别是当加密保存多个图像时, 用户需要反复执行相同的操作步骤, 使用起来相当繁瑣。 发明内容
本发明实施例提供一种拍照方法、 装置和存储介质, 能够解决图像加密保 存过程操作过于繁瑣的问题。
一方面, 本发明实施例提供了一种拍照方法, 包括:
在启动拍摄应用后, 接收用户触发的加密拍摄指令;
根据所述加密拍摄指令将普通拍摄模式切换为加密拍摄模式;
在加密拍摄模式下, 获取摄像头拍摄的图像数据;
对所述图像数据进行加密处理; 对加密处理后的图像数据进行保存。
另一方面, 本发明实施例还提供了一种拍照装置, 包括:
接收单元, 用于在启动拍摄应用后, 接收用户触发的加密拍摄指令; 切换单元, 用于根据所述接收单元接收的所述加密拍摄指令将普通拍摄模 式切换为加密拍摄模式;
获取单元, 用于在加密拍摄模式下获取摄像头拍摄的图像数据;
加解密单元, 用于对所述获取单元获取的所述图像数据进行加密处理; 存储单元, 用于对所述加解密单元加密处理后的图像数据进行保存。
再一方面, 本发明实施例还提供了一种包含计算机可执行指令的存储介质, 所述计算机可执行指令在由计算机处理器执行时用于执行一种拍照方法, 该方 法包括:
在启动拍摄应用后, 接收用户触发的加密拍摄指令;
根据所述加密拍摄指令将普通拍摄模式切换为加密拍摄模式;
在加密拍摄模式下, 获取摄像头拍摄的图像数据;
对所述图像数据进行加密处理;
对加密处理后的图像数据进行保存。
本发明实施例提供的拍照方法、 装置和存储介质, 能够在拍摄过程中根据 接收到的加密拍摄指令将普通拍摄模式切换为加密拍摄模式, 在加密拍摄模式 下获取摄像头拍摄的图像数据, 然后对获取的图像数据进行加密处理, 最后将 加密处理后的图像数据进行保存, 以便后续用户根据用户密码进行查看。 与现 有技术中需要用户退出拍摄应用对图像数据进行加密相比, 能够在拍摄应用中 提供加密拍摄模式, 在加密拍摄模式下自动对摄像头拍摄的图像进行加密保存, 可以节省由于在拍摄应用与加密保护应用之间反复切换产生的操作步骤 , 从而 简化图像加密保存过程中的用户操作。 附图说明
为了更清楚地说明本发明实施例中的技术方案, 下面将对实施例或现有技 术描述中所需使用的附图作简单地介绍, 当然, 以下描述中的附图仅仅是本发 明的一些实施例, 对于本领域普通技术人员来讲, 在不付出创造性劳动的前提 下, 还可以对这些附图进行修改和替换。
图 1为本发明实施例中拍照方法的流程图;
图 2为本发明实施例中另一个拍照方法的流程图;
图 3为本发明实施例中拍摄界面的示意图;
图 4为本发明实施例中系统文件目录的示意图;
图 5为本发明实施例中另一个拍摄界面的示意图;
图 6为本发明实施例中再一个拍摄界面的示意图;
图 7为本发明实施例中拍照装置的结构示意图;
图 8为本发明实施例中另一个拍照装置的结构示意图;
图 9为本发明实施例中再一个拍照装置的结构示意图。
具体实施方式
下面将结合附图对本实施例中的技术方案进行清楚、 完整地描述, 显然, 所描述的实施例仅仅是本发明的一部分实施例, 而不是全部的实施例, 是为了 阐述本发明的原理, 而不是要将本发明限制于这些具体的实施例。 基于本发明 中的实施例 , 本领域普通技术人员在没有作出创造性劳动前提下所获得的所有 其他实施例, 都属于本发明保护的范围。
为简化加密拍照的操作步骤, 本实施例提供了一种拍照方法, 所述方法可 以应用于诸如手机、 平板电脑等配备摄像头的电子设备中。 如图 1 所示, 所述 方法包括:
101、 在启动拍摄应用后, 电子设备接收用户触发的加密拍摄指令。
在用户启动拍摄应用后, 电子设备接收加密拍摄指令, 该加密拍摄指令用 于指示切换到加密拍照模式。
102、 电子设备根据加密拍摄指令将普通拍摄模式切换为加密拍摄模式。 当接收到加密拍摄指令后 , 电子设备将当前的普通拍摄模式切换为加密拍 摄模式。 在加密拍摄模式下, 电子设备可以自动对摄像头拍摄的图像进行加密 保存。 103、 在加密拍摄模式下电子设备获取摄像头拍摄的图像数据。
本实施例中所述的图像数据可以为静态图像数据例如照片, 也可以为动态 图像数据例如视频, 本实施例后续以照片为例进行说明。
当用户触发拍摄功能键时, 摄像头对拍摄对象进行拍摄。 通常, 摄像头拍 摄的照片会保存在系统文件目录中, 该系统文件目录按照拍摄的时间顺序对摄 像头拍摄的照片进行保存。 在加密拍摄模式下, 当摄像头对拍摄对象进行拍摄 后, 电子设备从系统文件目录中提取摄像头拍摄的照片。
104、 电子设备对图像数据进行加密处理。
电子设备对从系统文件目录中提取的照片进行加密, 本实施例中电子设备 可以对照片内容本身进行加密, 也可以对照片的属性信息进行加密, 从而实现 对照片内容进行加密, 本实施例对此不做限制。
105、 电子设备对加密处理后的图像数据进行保存。
电子设备将从系统文件目录中提取并进行加密的照片保存在加密文件目录 中, 以便后续用户根据用户密码进行查看, 当用户需要查看保存的加密照片时, 开启加密保护应用并输入用户密码, 就可以对加密照片进行查看了。 在加密文 件目录中, 电子设备可以按照拍摄的时间顺序对照片进行保存, 也可以按照照 片的属性信息对照片进行分类保存。 本实施例中, 电子设备可以将现有加密保 护应用的文件目录作为加密文件目录, 也可以在存储区域中独立开辟一个子区 域用来保存加密文件目录, 本实施例对此不做限制。
现有技术中, 用户通过摄像头拍摄的照片保存在系统文件目录中, 例如默 认的相册文件夹中。 当对照片进行加密时, 用户需要退出拍摄应用, 然后开启 加密保护应用并输入用户密码, 在加密保护应用中将待加密照片从系统文件目 录迁移到加密文件目录中。 在拍摄应用和加密保护应用之间的切换会增加用户 的操作步骤, 同时对系统的处理资源造成消耗。 特别是加密保存多张照片时, 用户需要反复执行相同的操作步骤, 使用起来相当繁瑣。 此外, 由于需要在不 同的应用之间进行切换, 照片拍摄和照片加密保存的过程在时序上被分隔开来, 因此用户容易遗忘对拍摄的图片进行加密, 存在泄密风险。 例如, 用户在退出 拍摄应用后未及时进入加密保护应用对图片进行加密, 一段时间后就忘记了照 片加密, 后续如果他人窃取了用户的电子设备, 则可以直接打开系统文件目录 查看用户的隐私照片。
目前, 现有技术中还存在一种第三方加密保护应用, 该第三方应用能够对 电子设备的摄像头进行驱动, 允许用户在第三方应用中启动摄像头进行拍摄, 拍摄的照片直接保存在加密文件目录中。 这种图像加密的方式虽然可以规避上 述加密方式中切换应用及输入用户密码产生的操作步骤, 但是其拍摄功能与拍 摄界面与系统的拍摄应用相比均差别较大, 用户的使用习惯无法得到保证。
进一步的, 该拍照方法还包括:
( 1 )接收用户触发的解除加密拍摄指令。
( 2 )根据所述解除加密拍摄指令将加密拍摄模式切换为普通拍摄模式。 ( 3 )按照所述普通拍照模式对摄像头拍摄的图像数据进行保存。
本实施例提供的拍照方法, 能够在拍摄过程中根据接收到的加密拍摄指令 将普通拍摄模式切换为加密拍摄模式, 在加密拍摄模式下获取摄像头拍摄的图 像数据, 然后对获取的图像数据进行加密处理, 最后将加密处理后的图像数据 进行保存, 以便后续用户根据用户密码进行查看。 与现有技术中需要用户退出 拍摄应用对图像数据进行加密相比, 能够在拍摄应用中提供加密拍摄模式, 在 加密拍摄模式下自动对摄像头拍摄的图像进行加密保存, 由此节省在拍摄应用 与加密保护应用之间反复切换产生的操作步骤, 进而简化图像加密保存过程中 的用户操作。 同时, 由于电子设备可以在摄像头拍摄图像后自动对图像进行加 密, 无需用户对加密过程进行关注, 因此可以避免用户因遗忘而导致的加密遗 漏的问题。 最后, 本实施例提供的拍照方法, 是基于用户最常使用的系统拍摄 应用进行的改进, 与第三方应用相比, 可以在用户熟悉的拍摄界面及拍摄功能 下完成图像的自动加密, 更为贴合用户的使用习惯。
作为对图 1 所示方法的详细说明及进一步扩展, 本发明实施例还提供了一 种拍照方法, 如图 2所示, 所述方法包括:
201、 电子设备对模式切换功能键进行监听。
在启动拍摄应用后, 电子设备可以在拍摄界面中以浮窗的形式显示如图 3 中所示的模式切换功能键, 并对模式切换功能键进行监听。 该模式切换功能键 用于在普通拍摄模式和加密拍摄模式之间进行切换, 其中 ON表示开启加密拍摄 模式, OFF表示关闭加密拍摄模式, 亦即开启普通拍摄模式。 电子设备接收用户 对模式切换功能键的触发指令, 当用户将该功能键切换到普通拍摄模式时, 电 子设备执行步骤 202 , 当用户将该功能键切换到加密拍摄模式时, 电子设备执行 步骤 203。
通常, 用户在开启拍摄应用后, 会连续拍摄多张照片, 其中部分照片需要 加密保存, 而部分照片按照普通方式保存即可。 显示模式切换功能键可以使用 户在拍摄的过程中方便快捷的对照片保存的文件目录进行选择。 此外通过浮窗 形式显示模式切换功能键可以减少功能键的菜单深度, 节省用户切换模式的操 作及时间, 更加适应抓拍抢拍等拍摄场景。
进一步的, 当用户切换拍摄模式时, 电子设备还可以通过对话框提示用户 当前选择的拍摄模式, 例如在图 3 中, 当用户切换到加密拍摄模式时, 电子设 备显示对话框 "拍摄的照片和视频将存入隐私空间 "。
优选的, 为避免用户因遗忘切换加密拍摄模式而导致加密遗漏, 在开启拍 摄应用时, 电子设备可以默认当前模式为加密拍摄模式, 开启拍摄应用时的模 式切换功能键如图 3 中所示。 如需切换到普通拍摄模式, 则由用户手动触发模 式切换功能键即可。
202、 电子设备按照普通拍照模式对摄像头拍摄的图像数据进行保存。
摄像头拍摄照片后, 电子设备将照片保存在如图 4所示的系统文件目录中, 其中, 系统文件目录左侧为照片数据内容, 系统文件目录右侧为照片的存储序 号, 按照队列 "先进先出" 的规则, 最近拍摄的照片保存在系统文件目录的第 一条表项中, 即图 4中序号 N所在的表项。
203、 电子设备对系统文件目录进行监听。
在加密拍摄模式下, 摄像头拍摄的照片仍保存在系统文件目录中。 电子设 备对系统文件目录进行实时监听, 监听系统文件目录中是否增加新的照片。
204、 电子设备从系统文件目录中提取新增照片。
当监听到系统文件目录中增加新的照片时, 电子设备从系统文件目录中提 取该照片。 由于系统文件目录中保存的照片为可直接查看的照片, 因此电子设 备需要将需要加密的照片从系统文件目录中提取出来, 照片提取后系统文件目 录不存在该照片。
可选的, 在步骤 201 中, 电子设备还可以对第三方拍照应用软件中的数据 库文件目录进行监听, 当用户通过第三方拍照应用软件进行拍摄时, 电子设备 从数据库文件目录中提取新增的照片, 然后执行步骤 205 ; 或者电子设备还可以 对本地的系统媒体数据库文件目录进行监听, 例如对本地相册进行监听, 当监 听到新增图片时, 例如用户下载了一幅壁纸, 电子设备从系统媒体数据库文件 目录中提取新增的壁纸, 然后执行步骤 205。
205、 电子设备对提取的图像数据进行加密处理。
在将从系统文件目录中提取的照片保存到加密文件目录中前, 电子设备对 该照片进行加密, 本实施例可以釆用的数据加密方式有^艮多, 这里只对其中两 种加密方式进行说明:
1 )替换照片文件头
通常电子设备获取的照片都携带有包含照片属性信息的文件头, 该文件头 中包含至少 1 比特位的属性信息。 电子设备从照片中提取文件头, 然后将该文 件头中设定位置及设定数量的比特位替换为用户密码, 所述用户密码为用户预 先设置的密码, 亦即用户登录加密保护应用时输入的用户密码。
以用户密码为 12 3456为例, 电子设备从照片中提取出包含 100比特位的文 件头, 然后将该文件头中的前 20个比特位替换为用户密码, 替换后的前 20个 密码位为: 12345612 345612 345612。
2 )对照片数据进行重排列
通常任何类型的数据都可以转化为包含至少 1 个比特位的二进制数据存储 序列。 电子设备提取照片的二进制数据存储序列, 然后根据用户密码确定二进 制数据存储序列中比特位的排序规则, 最后根据该排序规则对二进制数据存储 序列中所有的比特位进行重排列。
以用户密码为 54321为例, 在电子设备提取的二进制数据存储序列中, 第 1 个比特位至第 5个比特位依次为 &、 b、 c、 (1和6。 电子设备 居用户密码 54321 将 5个比特位数据的位置调整为 e、 d、 c、 b和 a , 即第 1个比特位调整后的位 置为用户密码的第 1位 " 5" , 第 2个比特位调整后的位置为用户密码的第 2位 "4" , 以此类推。
本实施例中的比特位个数仅为事例性说明, 不作为对实际应用的限定。 实 际应用中, 一幅照片的二进制数据存储序列中的比特位数量通常在百万级别。 此外, 比特位数据 a、 b、 c、 d和 e仅为便于对加密方式进行描述而用, 实际应 用中比特位数据为二进制数字 0或 1。
通常加密方式 1 )存在小概率破解的风险, 不法分子可以通过强制破解文件 头的方式读取数据内容。 而加密方式 2 )是对数据内容本身进行重新排列, 不法 分子在不知道用户密码(即排序规则) 的情况下, 即使对文件头进行破解也无 法读取数据内容。 因此, 作为本实施例的一个优选方案, 电子设备釆用加密方 式 2 )对照片进行加密。
206、 电子设备将加密处理后的图像数据保存到加密文件目录中。
与系统文件目录类似, 加密文件目录也用于按照拍摄的时间顺序或者其他 属性信息对照片进行保存, 但与系统文件目录不同的是, 加密文件目录用于保 存加密后的照片, 用户只有通过用户密码登录加密保护应用后才能查看加密文 件目录中的照片。
本实施例中, 电子设备将从系统文件目录、 第三方拍照应用软件中的数据 库文件目录或者系统媒体数据库文件目录中提取的照片进行加密后, 将加密的 照片保存在加密文件目录中。
作为对图 2 所示方法的进一步扩展, 电子设备还可以从照片的存储格式中 获取照片的缩略图, 然后在拍摄界面中显示该照片缩略图以及该照片在加密文 件目录中的序号。 例如在图 5 中, 电子设备在模式切换功能键右侧显示当前加 密保存的照片缩略图, 并且在缩略图右下角显示序号 3 , 该序号表示, 当前照片 为加密文件目录中保存的第三张照片。
进一步的, 电子设备还可以在拍摄界面中显示加密保护应用的快捷键, 例 如图 6 中拍摄界面右上角的 "隐私空间" 快捷键, 用户触发该快捷键后, 电子 设备将当前界面切换到用户登录界面, 待用户输入用户密码后, 显示隐私空间 中的加密相册。 进一步的, 为便于用户在加密拍摄模式下对拍摄的照片进行普通保存, 电 子设备还可以接收用户触发的解密指令, 该解密指令用于指示对当前显示缩略 图对应的照片进行解密。 在接收到解密指令后, 电子设备从加密文件目录中提 取该缩略图对应的照片, 并对该照片进行解密, 然后将解密后的照片保存到系 统文件目录中, 照片保存后, 加密文件目录中不再保存有该照片。
电子设备在显示当前照片的缩略图时, 该照片已经保存在加密文件目录中, 当用户后悔对当前照片进行加密保存, 或者希望在不切换拍摄模式的情况下对 当前照片进行普通保存时, 可以触发解密指令。 电子设备根据解密指令将已加 密保存的照片恢复为普通保存。 所述解密指令可以为长按指令或者双击指令, 当用户在缩略图上长按超过预设时长阈值或者进行双击操作时, 电子设备从加 密文件目录中提取该缩略图对应的照片, 然后按照与步骤 205相反的方式对加 密的照片进行解密, 最后将解密后的照片保存到系统文件目录中。
与此类似的, 在普通拍摄模式下, 电子设备也可以将当前照片的缩略图显 示在拍摄界面中, 当用户希望将已保存在系统文件目录中的照片加密保存时, 触发加密指令, 电子设备顺序执行步骤 204至步骤 206 , 将已保存在系统文件目 录中的当前照片提取出来进行加密, 然后保存到加密文件目录中。
本实施例提供的拍照方法, 能够使用户在拍摄界面中通过一个模式切换功 能键轻松选择拍摄模式, 在加密拍摄模式下, 无需用户手动操作即可对摄像头 拍摄的图像自动进行加密保存。 此外, 本方法还可以显示当前图像的缩略图, 以便用户在不切换拍摄模式的情况下, 对已加密保存(或普通保存) 的照片二 次选择保存方式, 进一步简化用户操作。
在本实施例的一个应用场景中, 用户启动拍摄应用进行拍照, 电子设备默 认拍摄模式为加密拍摄模式。 用户先后拍摄了 2 张加密保存的照片, 然后一键 切换到普通拍摄模式, 继续进行拍摄。
在本实施例的另一个应用场景中, 用户在加密拍摄模式下拍摄了一张照片 , 然后查看该照片的缩略图, 发现该照片无需加密保存。 用户双击该缩略图, 将 该照片从加密保存的相册中迁移至普通保存的相册中。
在本实施例的再一个应用场景中, 用户在普通拍摄模式下拍摄了一张照片, 然后查看该照片的缩略图, 发现该照片需要加密保存。 用户双击该缩略图, 将 该照片从普通保存的相册中迁移至加密保存的相册中。
本实施例以摄像头拍摄的图像作为加密保存对象进行了说明 , 实际应用加 密保存的对象还可以但不仅限于是短信、 聊天记录以及视频通话记录等。 以聊 天记录为例, 在 "私聊" 模式下, 电子设备将产生的聊天记录打包成文件夹, 然后进行加密, 最后保存在加密文件目录中。
参考图 1或图 2所示的方法, 本实施例还提供了一种拍照装置, 用以实现 图 1或图 2所示的方法。 所述装置可以位于手机、 平板电脑等电子设备中, 如 图 7所示, 所述装置 71包括: 接收单元 711、 切换单元 712、 获取单元 71 3、 加 解密单元 714、 存储单元 715、 显示单元 716以及监听单元 717 , 其中,
所述接收单元 711 ,用于在启动拍摄应用后,接收用户触发的加密拍摄指令; 所述切换单元 712 ,用于根据所述接收单元 711接收的所述加密拍摄指令将 普通拍摄模式切换为加密拍摄模式;
所述获取单元 71 3 , 用于在加密拍摄模式下获取摄像头拍摄的图像数据; 所述加解密单元 714 ,用于对所述获取单元 71 3获取的所述图像数据进行加 密处理;
所述存储单元 715 ,用于对所述加解密单元 714加密处理后的图像数据进行 保存。
进一步的, 如图 8所示, 所述获取单元 71 3包括:
监听子单元 81 1 , 用于对系统文件目录进行监听;
提取子单元 812 ,用于当所述监听子单元 811监听到所述系统文件目录中增 加新的图像数据时, 从所述系统文件目录中提取所述新的图像数据。
进一步的, 如图 9所示, 所述加解密单元 714包括:
第一加解密子单元 911 , 用于提取所述图像数据的文件头, 将所述文件头中 设定位置及设定数量的比特位替换为用户密码。
进一步的, 如图 9所示, 所述加解密单元 714包括:
第二加解密子单元 912 , 用于提取所述图像数据的二进制数据存储序列, 根 据用户密码确定比特位的排序规则, 根据所述排序规则对所述二进制数据存储 序列中所有的比特位进行重排列。
进一步的, 所述存储单元 715用于将所述加解密单元 714加密处理后的图 像数据保存到加密文件目录中。
进一步的, 所述获取单元 71 3还用于从所述图像数据的存储格式中获取所 述图像数据的缩略图;
进一步的, 所述显示单元 716 , 用于在拍摄界面中显示所述获取单元 71 3获 取的所述图像数据的缩略图以及所述图像数据在所 P密文件目录中的序号。
进一步的, 所述接收单元 711 还用于接收解密指令, 所述解密指令用于指 示对当前显示缩略图对应的图像数据进行解密;
所述提取子单元 812还用于根据所述接收单元 711接收的解密指令从所述 加密文件目录中提取所述缩略图对应的图像数据;
所述加解密单元 714还用于对所述提取子单元 812提取的所述图像数据进 行解密;
所述存储单元 715还用于将所述加解密单元 714解密后的图像数据保存到 系统文件目录中。
进一步的, 所述显示单元 716还用于在拍摄界面中显示模式切换功能键; 所述监听单元 717 , 用于对所述模式切换功能键进行监听;
所述接收单元 711还用于接收用户对所述模式切换功能键的触发指令。 进一步的, 所述接收单元 711还用于接收用户触发的解除加密拍摄指令; 所述切换单元 712还用于根据所述解除加密拍摄指令将加密拍摄模式切换 为普通拍摄模式;
所述存储单元 715还用于按照所述普通拍照模式对摄像头拍摄的图像数据 进行保存。
本实施例提供的拍照装置, 能够在拍摄过程中根据接收到的加密拍摄指令 将普通拍摄模式切换为加密拍摄模式, 在加密拍摄模式下获取摄像头拍摄的图 像数据, 然后对获取的图像数据进行加密处理, 最后将加密处理后的图像数据 进行保存, 以便后续用户根据用户密码进行查看。 与现有技术中需要用户退出 拍摄应用对图像数据进行加密相比, 能够在拍摄应用中提供加密拍摄模式, 在 加密拍摄模式下自动对摄像头拍摄的图像进行加密保存, 由此节省在拍摄应用 与加密保护应用之间反复切换产生的操作步骤, 进而简化图像加密保存过程中 的用户操作。 同时, 由于电子设备可以在摄像头拍摄图像后自动对图像进行加 密, 无需用户对加密过程进行关注, 因此可以避免用户因遗忘而导致的加密遗 漏的问题。 最后, 本实施例提供的拍照装置, 是基于用户最常使用的系统拍摄 应用进行的改进, 与第三方应用相比, 可以在用户熟悉的拍摄界面及拍摄功能 下完成图像的自动加密, 更为贴合用户的使用习惯。
此外, 本实施例提供的拍照装置, 还可以显示当前图像的缩略图, 以便用 户在不切换拍摄模式的情况下, 对已加密保存(或普通保存) 的照片二次选择 保存方式, 进一步简化用户操作。
本发明实施例还提供了一种包含计算机可执行指令的存储介质, 所述计算 机可执行指令在由计算机处理器执行时用于执行一种拍照方法, 所述拍照方法 包括:
在启动拍摄应用后, 接收用户触发的加密拍摄指令;
根据所述加密拍摄指令将普通拍摄模式切换为加密拍摄模式;
在加密拍摄模式下, 获取摄像头拍摄的图像数据;
对所述图像数据进行加密处理;
对加密处理后的图像数据进行保存。
进一步的, 所述拍照方法还包括:
接收用户触发的解除加密拍摄指令;
根据所述解除加密拍摄指令将加密拍摄模式切换为普通拍摄模式; 按照所述普通拍照模式对摄像头拍摄的图像数据进行保存。
通过以上关于实施方式的描述, 所属领域的技术人员可以清楚地了解到本 发明可借助软件及必需的通用硬件来实现, 当然也可以通过硬件实现, 但很多 情况下前者是更佳的实施方式。 基于这样的理解, 本发明的技术方案本质上或 者说对现有技术故出贡献的部分可以以软件产品的形式体现出来, 该计算机软 件产品可以存储在计算机可读存储介质中, 如计算机的软盘、 只读存储器
( Read-Only Memory, ROM )、随机存取存储器( Random Access Memory, RAM )、 闪存(FLASH )、 硬盘或光盘等, 包括若干指令用以使得一台计算机设备(可以 是个人计算机, 服务器, 或者网络设备等)执行本发明各个实施例所述的方法。
值得注意的是, 上述拍照装置的实施例中, 所包括的各个单元和模块只是 按照功能逻辑进行划分的, 但并不局限于上述的划分, 只要能够实现相应的功 能即可; 另外, 各功能单元的具体名称也只是为了便于相互区分, 并不用于限 制本发明的保护范围。
以上所述, 仅为本发明的具体实施方式, 但本发明的保护范围并不局限于 此, 任何熟悉本技术领域的技术人员在本发明披露的技术范围内, 可轻易想到 的变化或替换, 都应涵盖在本发明的保护范围之内。 因此, 本发明的保护范围 应所述以权利要求的保护范围为准。

Claims

权 利 要 求 书
1、 一种拍照方法, 其特征在于, 包括:
在启动拍摄应用后, 接收用户触发的加密拍摄指令;
根据所述加密拍摄指令将普通拍摄模式切换为加密拍摄模式;
在加密拍摄模式下, 获取摄像头拍摄的图像数据;
对所述图像数据进行加密处理;
对加密处理后的图像数据进行保存。
2、 根据权利要求 1所述的方法, 其特征在于, 所述获取摄像头拍摄的图像 数据的步骤, 包括:
对系统文件目录进行监听;
当监听到所述系统文件目录中增加新的图像数据时, 从所述系统文件目录 中提取所述新的图像数据。
3、 根据权利要求 2所述的方法, 其特征在于, 所述对所述图像数据进行加 密处理的步骤, 包括:
提取所述图像数据的文件头;
将所述文件头中设定位置及设定数量的比特位替换为用户密码。
4、 根据权利要求 2所述的方法, 其特征在于, 所述对所述图像数据进行加 密处理的步骤, 包括:
提取所述图像数据的二进制数据存储序列;
根据用户密码确定比特位的排序规则;
根据所述排序规则对所述二进制数据存储序列中所有的比特位进行重排 列。
5、 根据权利要求 3或 4所述的方法, 其特征在于, 所述对加密处理后的图 像数据进行保存的步骤, 包括:
将所述加密处理后的图像数据保存到加密文件目录中。
6、 根据权利要求 5所述的方法, 其特征在于, 所述方法进一步包括: 从所述图像数据的存储格式中获取所述图像数据的缩略图;
在拍摄界面中显示所述图像数据的缩略图以及所述图像数据在所述加密文 件目录中的序号。
7、 根据权利要求 6所述的方法, 其特征在于, 所述方法进一步包括: 接收解密指令, 所述解密指令用于指示对当前显示缩略图对应的图像数据 进行解密;
从所述加密文件目录中提取所述缩略图对应的图像数据;
对所述图像数据进行解密, 并且将解密后的图像数据保存到系统文件目录 中。
8、 根据权利要求 7所述的方法, 其特征在于, 所述接收用户触发的加密拍 摄指令的步骤, 包括:
在拍摄界面中显示模式切换功能键;
对所述模式切换功能键进行监听;
接收用户对所述模式切换功能键的触发指令。
9、 根据权利要求 1所述的方法, 其特征在于, 还包括:
接收用户触发的解除加密拍摄指令;
根据所述解除加密拍摄指令将加密拍摄模式切换为普通拍摄模式; 按照所述普通拍照模式对摄像头拍摄的图像数据进行保存。
10、 一种拍照装置, 其特征在于, 包括:
接收单元, 用于在启动拍摄应用后, 接收用户触发的加密拍摄指令; 切换单元, 用于根据所述接收单元接收的所述加密拍摄指令将普通拍摄模 式切换为加密拍摄模式;
获取单元, 用于在加密拍摄模式下获取摄像头拍摄的图像数据;
加解密单元, 用于对所述获取单元获取的所述图像数据进行加密处理; 存储单元, 用于对所述加解密单元加密处理后的图像数据进行保存。
11、 根据权利要求 10所述的装置, 其特征在于, 所述获取单元包括: 监听子单元, 用于对系统文件目录进行监听;
提取子单元, 用于当所述监听子单元监听到所述系统文件目录中增加新的 图像数据时, 从所述系统文件目录中提取所述新的图像数据。
12、 根据权利要求 11所述的装置, 其特征在于, 所述加解密单元包括: 第一加解密子单元, 用于提取所述图像数据的文件头, 将所述文件头中设 定位置及设定数量的比特位替换为用户密码。
1 3、 根据权利要求 11所述的装置, 其特征在于, 所述加解密单元包括: 第二加解密子单元, 用于提取所述图像数据的二进制数据存储序列, 根据 用户密码确定比特位的排序规则, 根据所述排序规则对所述二进制数据存储序 列中所有的比特位进行重排列。
14、 根据权利要求 12或 1 3所述的装置, 其特征在于, 所述存储单元用于 将所述加解密单元加密处理后的图像数据保存到加密文件目录中。
15、 根据权利要求 14所述的装置, 其特征在于, 所述获取单元还用于从所 述图像数据的存储格式中获取所述图像数据的缩略图;
所述装置还包括显示单元, 用于在拍摄界面中显示所述获取单元获取的所 述图像数据的缩略图以及所述图像数据在所述加密文件目录中的序号。
16、 根据权利要求 15所述的装置, 其特征在于, 所述接收单元还用于接收 解密指令, 所述解密指令用于指示对当前显示缩略图对应的图像数据进行解密; 所述提取子单元还用于根据所述接收单元接收的解密指令从所述加密文件 目录中提取所述缩略图对应的图像数据;
所述加解密单元还用于对所述提取子单元提取的所述图像数据进行解密; 所述存储单元还用于将所述加解密单元解密后的图像数据保存到系统文件 目录中。
17、根据权利要求 16所述的装置, 其特征在于, 所述装置还包括监听单元; 所述显示单元还用于在拍摄界面中显示模式切换功能键;
所述监听单元, 用于对所述模式切换功能键进行监听;
所述接收单元还用于接收用户对所述模式切换功能键的触发指令。
18、 根据权利要求 10所述的装置, 其特征在于, 所述接收单元还用于接收 用户触发的解除加密拍摄指令;
所述切换单元还用于根据所述解除加密拍摄指令将加密拍摄模式切换为普 通拍摄模式;
所述存储单元还用于按照所述普通拍照模式对摄像头拍摄的图像数据进行 保存。
19、 一种包含计算机可执行指令的存储介质, 所述计算机可执行指令在由 算机处理器执行时用于执行一种拍照方法, 其特征在于, 所述方法包括: 在启动拍摄应用后, 接收用户触发的加密拍摄指令;
根据所述加密拍摄指令将普通拍摄模式切换为加密拍摄模式;
在加密拍摄模式下, 获取摄像头拍摄的图像数据;
对所述图像数据进行加密处理;
对加密处理后的图像数据进行保存。
20、 根据权利要求 19所述的存储介质, 其特征在于, 所述方法还包括: 接收用户触发的解除加密拍摄指令;
根据所述解除加密拍摄指令将加密拍摄模式切换为普通拍摄模式; 按照所述普通拍照模式对摄像头拍摄的图像数据进行保存。
PCT/CN2014/078380 2013-06-21 2014-05-26 拍照方法、装置和存储介质 WO2014201940A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201310250632.9 2013-06-21
CN201310250632.9A CN104135605B (zh) 2013-06-21 2013-06-21 拍照方法及装置

Publications (1)

Publication Number Publication Date
WO2014201940A1 true WO2014201940A1 (zh) 2014-12-24

Family

ID=51808120

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2014/078380 WO2014201940A1 (zh) 2013-06-21 2014-05-26 拍照方法、装置和存储介质

Country Status (3)

Country Link
CN (1) CN104135605B (zh)
TW (1) TWI545948B (zh)
WO (1) WO2014201940A1 (zh)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104767938A (zh) * 2015-03-27 2015-07-08 广东欧珀移动通信有限公司 一种拍摄图片的方法及装置
CN105046167A (zh) * 2015-08-31 2015-11-11 宇龙计算机通信科技(深圳)有限公司 加密照片的生成方法、装置和电子设备
CN114267096A (zh) * 2021-12-03 2022-04-01 联通智网科技股份有限公司 行车记录数据处理方法、装置及存储介质

Families Citing this family (25)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104253933A (zh) * 2013-06-26 2014-12-31 华为技术有限公司 拍摄的方法及设备
CN104680078B (zh) * 2015-01-20 2021-09-03 中兴通讯股份有限公司 一种拍摄照片的方法、查看图片的方法、系统和终端
CN104751074B (zh) * 2015-03-31 2018-01-19 努比亚技术有限公司 图像显示处理方法及装置
CN104732158A (zh) * 2015-04-09 2015-06-24 上海斐讯数据通信技术有限公司 一种加密拍照方法、系统及装置
CN112765625A (zh) * 2015-06-04 2021-05-07 宏达国际电子股份有限公司 屏幕内容加密方法及使用此方法的电子装置
CN104866783A (zh) * 2015-06-15 2015-08-26 联想(北京)有限公司 一种文件存储方法及装置
CN105227827A (zh) * 2015-07-09 2016-01-06 北京君正集成电路股份有限公司 一种智能眼镜的拍照方法及智能眼镜
US10212168B2 (en) 2015-08-24 2019-02-19 Beijing Lenovo Software Ltd. Electronic device and control method thereof
CN105138252B (zh) * 2015-08-24 2020-08-25 联想(北京)有限公司 一种控制方法及电子设备
CN109688145B (zh) * 2015-12-23 2021-07-16 北京奇虎科技有限公司 隐私信息的保护方法及装置
WO2017128216A1 (zh) * 2016-01-28 2017-08-03 常平 一种图片加密技术使用数据采集方法及移动终端
CN105701655A (zh) * 2016-03-02 2016-06-22 上海皇和信息科技有限公司 基于usb加密摄像头的扫码支付系统及方法
CN106326762A (zh) * 2016-10-17 2017-01-11 广东七洲科技股份有限公司 一种移动终端即拍即加密的数据保护方法
CN106791542B (zh) * 2017-01-20 2019-11-29 维沃移动通信有限公司 一种全景图像拍摄方法及移动终端
CN106874918A (zh) * 2017-02-23 2017-06-20 上海与德信息技术有限公司 一种照片保存方法及装置
CN107105156B (zh) * 2017-03-22 2019-12-17 北京珠穆朗玛移动通信有限公司 一种图片管理方法及移动终端
CN107181910A (zh) * 2017-04-07 2017-09-19 北京安云世纪科技有限公司 一种移动终端的拍摄方法、装置及移动终端
CN107172344A (zh) * 2017-04-07 2017-09-15 北京安云世纪科技有限公司 一种移动终端的拍摄文件存储方法、装置及移动终端
CN107181911A (zh) * 2017-04-07 2017-09-19 北京安云世纪科技有限公司 一种拍摄方法、装置及移动终端
WO2019023955A1 (zh) * 2017-08-02 2019-02-07 深圳传音通讯有限公司 一种智能终端的图像存储与查看方法及图像存储与查看系统
CN107613207A (zh) * 2017-09-29 2018-01-19 努比亚技术有限公司 一种拍照控制方法、设备及计算机可读存储介质
CN108111757A (zh) * 2017-12-21 2018-06-01 广东欧珀移动通信有限公司 拍照方法、装置、存储介质及终端
CN110381356B (zh) * 2019-07-19 2022-06-07 北京字节跳动网络技术有限公司 音视频生成方法、装置、电子设备及可读介质
CN113343260A (zh) * 2021-06-18 2021-09-03 Oppo广东移动通信有限公司 数据加密方法、装置、电子设备及存储介质
CN115348405A (zh) * 2022-08-24 2022-11-15 维沃移动通信有限公司 视频录制方法、装置、电子设备及存储介质

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2003333519A (ja) * 2002-05-15 2003-11-21 Fuji Photo Film Co Ltd 撮像装置及び画像データ受渡方法
CN101415099A (zh) * 2007-10-18 2009-04-22 鸿富锦精密工业(深圳)有限公司 影像撷取装置加密系统及方法
CN101640779A (zh) * 2008-07-31 2010-02-03 鸿富锦精密工业(深圳)有限公司 影像摄取装置加密系统和方法
CN103164441A (zh) * 2011-12-14 2013-06-19 富泰华工业(深圳)有限公司 基于脸部特征值对图片分类的电子装置及方法
US20130156185A1 (en) * 2011-12-14 2013-06-20 Electronics And Telecommunications Research Institute Surveillance video transmission apparatus and method and surveillance video receiving apparatus and method

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101345866A (zh) * 2008-08-15 2009-01-14 四川长虹电器股份有限公司 静态音视频文件加密、解密方法
CN102495983B (zh) * 2011-12-08 2014-08-27 孙紫阳 一种智能移动终端数据实时加密和解密的方法
CN102891749A (zh) * 2012-09-25 2013-01-23 东莞宇龙通信科技有限公司 数据加密的方法及其通信终端

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2003333519A (ja) * 2002-05-15 2003-11-21 Fuji Photo Film Co Ltd 撮像装置及び画像データ受渡方法
CN101415099A (zh) * 2007-10-18 2009-04-22 鸿富锦精密工业(深圳)有限公司 影像撷取装置加密系统及方法
CN101640779A (zh) * 2008-07-31 2010-02-03 鸿富锦精密工业(深圳)有限公司 影像摄取装置加密系统和方法
CN103164441A (zh) * 2011-12-14 2013-06-19 富泰华工业(深圳)有限公司 基于脸部特征值对图片分类的电子装置及方法
US20130156185A1 (en) * 2011-12-14 2013-06-20 Electronics And Telecommunications Research Institute Surveillance video transmission apparatus and method and surveillance video receiving apparatus and method

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104767938A (zh) * 2015-03-27 2015-07-08 广东欧珀移动通信有限公司 一种拍摄图片的方法及装置
CN105046167A (zh) * 2015-08-31 2015-11-11 宇龙计算机通信科技(深圳)有限公司 加密照片的生成方法、装置和电子设备
CN105046167B (zh) * 2015-08-31 2018-09-07 宇龙计算机通信科技(深圳)有限公司 加密照片的生成方法、装置和电子设备
CN114267096A (zh) * 2021-12-03 2022-04-01 联通智网科技股份有限公司 行车记录数据处理方法、装置及存储介质

Also Published As

Publication number Publication date
TW201501532A (zh) 2015-01-01
CN104135605A (zh) 2014-11-05
CN104135605B (zh) 2015-08-05
TWI545948B (zh) 2016-08-11

Similar Documents

Publication Publication Date Title
WO2014201940A1 (zh) 拍照方法、装置和存储介质
CN107659416B (zh) 一种会议记录分享的方法、装置、会议终端和存储介质
JP4931924B2 (ja) メディアデータ処理装置及びメディアデータ処理方法
WO2016206293A1 (zh) 运营商网络的接入方法和装置
CN112449102B (zh) 隐私图像加密方法及装置
JP6420916B2 (ja) システムパーティションファイルを監視する方法及び装置
CN104680078B (zh) 一种拍摄照片的方法、查看图片的方法、系统和终端
US20160073049A1 (en) Method and apparatus for backing up video
JP6450765B2 (ja) データをバックアップするための方法および装置並びに電子装置
WO2017080084A1 (zh) 字体添加方法及装置
WO2014094389A1 (zh) 密码安全系统和密码安全方法
CN101415099A (zh) 影像撷取装置加密系统及方法
WO2015096597A1 (zh) 一种多设备浏览文档的方法及装置
CN105095787A (zh) 一种信息处理方法及装置
CN103077357A (zh) 隐私文件储存方法
CN111565282A (zh) 一种拍摄控制处理方法、装置、设备及存储介质
WO2019011083A1 (zh) 私密信息的处理方法、装置和移动终端
CN104951710A (zh) 实现快速访问的方法及装置
WO2016141797A1 (zh) 信息处理方法及装置、计算机可读介质
CN107704337B (zh) 恢复出厂设置的方法、移动终端及具有存储功能的装置
WO2017201999A1 (zh) 文件加密方法、装置、终端及存储介质
CN106897634B (zh) 一种阅后即焚图片的显示方法及终端设备
US20090268056A1 (en) Digital camera with portrait image protecting function and portrait image protecting method thereof
CN104822083B (zh) 控制文件共享的方法、文件共享方法及装置
WO2014094388A1 (zh) 密码隐蔽方法和装置、密码取回方法和装置

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 14814086

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS (EPO FORM 1205A DATED 09.05.2016)

122 Ep: pct application non-entry in european phase

Ref document number: 14814086

Country of ref document: EP

Kind code of ref document: A1