Open Presentation can not get PPImage X and Y

Presentation pres = new Presentation(path);
int i = 1;
foreach (var item in pres.Images)
{
Console.WriteLine($“X:{item.X}”);
Console.WriteLine($“X:{item.Y}”);
Console.WriteLine($“X:{item.Width}”);
Console.WriteLine($“X:{item.Height}”);
Console.WriteLine("-------------------");
}

--------------------this is result---------------------------------------
X:0
X:0
X:1280
X:1024

X:0
X:0
X:1462
X:198

X:0
X:0
X:2000
X:350

Q1:i want open exist Presentation for path, i can load it. but i can’t get PPImage X and Y.

Q2:btw,i also can’t get PPImage FileName. if i want mark a certain picture,Any good suggestions for me?

thanks.

@valuemar,
The X and Y coordinates regarding the slide can be obtained from a respective shape that contains the image.
API Reference: IShape interface

What did you mean by “mark”?

thank you for your reply.

“mark” mean is :
i design a temlate for customer.when they used my template,they told me this picture is fixed,that picture is not fixed ,by image name.
like this:
“FixP1.png” means this is fixed picture ,i will save this picture for next time use.
“P2.png” means this is dynamic, may be from web api.

@valuemar,
Please consider the following way to mark images and any other presentation shapes using Aspose.Slides API:

// an IShape object with the image
shape.AlternativeText = "fixed";

More details: Alternative Text for Shape

The following features may be useful to you for your purposes as well: Custom Presentation Properties