update page now
Laravel Live Japan

Imagick::setImageIndex

(PECL imagick 2, PECL imagick 3)

Imagick::setImageIndexイテレータの位置を設定する

警告

この関数は Imagick 3.4.4 以降では 非推奨 になりました。この関数に依存したコードを書くのはやめましょう。

説明

public Imagick::setImageIndex(int $index): bool

画像リスト内でのイテレータの位置、index パラメータで指定した場所に設定します。

このメソッドは非推奨です。 Imagick::setIteratorIndex() を参照ください。

パラメータ

index

イテレータを設定する位置。

戻り値

成功した場合に true を返します。

エラー / 例外

エラー時に ImagickException をスローします。

add a note

User Contributed Notes 2 notes

up
2
Rob Hidalgo
13 years ago
When reading a PDF from an ImageBlob, and you want to set the page to be used, this is the function to use.
up
-1
maulik_Vr at yahoo dot co dot in
12 years ago
when you read pdf by getImageBlog and want to get the image or blob of a specific page, use this function as below.

$ims = new Imagick();
        
$ims->readImageBlob($pdfFileContent);
        
$ims->setImageIndex(5); /this will return 6th page of the pdf file
$image->setImageFormat('png');
            /etc 
$blob = $image->getImageBlob();
To Top

Follow Lee on X/Twitter - Father, Husband, Serial builder creating AI, crypto, games & web tools. We are friends :) AI Will Come To Life!

Check out: eBank.nz (Art Generator) | Netwrck.com (AI Tools) | Text-Generator.io (AI API) | BitBank.nz (Crypto AI) | ReadingTime (Kids Reading) | RewordGame | BigMultiplayerChess | WebFiddle | How.nz | Helix AI Assistant