pHash 1.0.1 → 1.0.2

Sign up to get free protection for your applications and to get access to all the features.
data/lib/phash/audio.rb CHANGED
@@ -49,9 +49,8 @@ module Phash
49
49
  #
50
50
  attach_function :ph_audio_distance_ber, [:pointer, :int, :pointer, :int, :float, :int, :pointer], :pointer, :blocking => true
51
51
 
52
+ class AudioHash < HashData; end
52
53
  class << self
53
- class AudioHash < HashData; end
54
-
55
54
  # Read audio file specified by path and optional length using <tt>ph_readaudio</tt> and get its hash using <tt>ph_audiohash</tt>
56
55
  def audio_hash(path, length = 0)
57
56
  sample_rate = 8000
data/lib/phash/text.rb CHANGED
@@ -35,9 +35,8 @@ module Phash
35
35
  #
36
36
  attach_function :ph_compare_text_hashes, [:pointer, :int, :pointer, :int, :pointer], :pointer, :blocking => true
37
37
 
38
+ class TextHash < HashData; end
38
39
  class << self
39
- class TextHash < HashData; end
40
-
41
40
  # Get text file hash using <tt>ph_texthash</tt>
42
41
  def text_hash(path)
43
42
  hash_data_length_p = FFI::MemoryPointer.new :int
data/lib/phash/video.rb CHANGED
@@ -13,9 +13,8 @@ module Phash
13
13
  #
14
14
  attach_function :ph_dct_videohash_dist, [:pointer, :int, :pointer, :int, :int], :double, :blocking => true
15
15
 
16
+ class VideoHash < HashData; end
16
17
  class << self
17
- class VideoHash < HashData; end
18
-
19
18
  # Get video hash using <tt>ph_dct_videohash</tt>
20
19
  def video_hash(path)
21
20
  hash_data_length_p = FFI::MemoryPointer.new :int
data/pHash.gemspec CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = 'pHash'
5
- s.version = '1.0.1'
5
+ s.version = '1.0.2'
6
6
  s.summary = %q{Use pHash with ruby}
7
7
  s.homepage = "http://github.com/toy/#{s.name}"
8
8
  s.authors = ['Ivan Kuchin']
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pHash
3
3
  version: !ruby/object:Gem::Version
4
- hash: 21
4
+ hash: 19
5
5
  prerelease:
6
6
  segments:
7
7
  - 1
8
8
  - 0
9
- - 1
10
- version: 1.0.1
9
+ - 2
10
+ version: 1.0.2
11
11
  platform: ruby
12
12
  authors:
13
13
  - Ivan Kuchin