Highlighted

Output plugin - How to format validation?

Explorer ,
Jul 08, 2020

Copy link to clipboard

Copied

I am writing a custom AEX output plugin (using the C API) and there is the requirement the width has to be a multiple of 8 and the height a multiple of 4. I'd like to either (or both) ...

  • Auto correct width and height to a proper value after plugin start and once the user edits width and height
  • Inform the user the current frame size is not supported

 

I guess this has to be done in AEIO_OutputInfoChanged. But how?

 

In the AVI format this shown:

Vouk_0-1594204567295.png

Any idea how I can show this?

 

Thanks in advance,

Daniel

 

 

TOPICS
How to, Import and export, SDK

Views

398

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

Output plugin - How to format validation?

Explorer ,
Jul 08, 2020

Copy link to clipboard

Copied

I am writing a custom AEX output plugin (using the C API) and there is the requirement the width has to be a multiple of 8 and the height a multiple of 4. I'd like to either (or both) ...

  • Auto correct width and height to a proper value after plugin start and once the user edits width and height
  • Inform the user the current frame size is not supported

 

I guess this has to be done in AEIO_OutputInfoChanged. But how?

 

In the AVI format this shown:

Vouk_0-1594204567295.png

Any idea how I can show this?

 

Thanks in advance,

Daniel

 

 

TOPICS
How to, Import and export, SDK

Views

399

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Jul 08, 2020 0
Explorer ,
Jul 22, 2020

Copy link to clipboard

Copied

Does anybody know about this? It'd really help me out.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jul 22, 2020 0
Adobe Employee ,
Jul 28, 2020

Copy link to clipboard

Copied

Hi Vouk,

 

The "Settings mismatch" warning that shows up in the Output Module Settings dialog for AVI only works for some of our internal export plug-ins that are not AEGP plug-ins.

 

AEIO_OutputInfoChanged would be the right place to warn the user and you can use AEGP_GetOutSpecDimensions from there to get the current frame size from the dialog settings to inform the user the current frame size is not supported. I can follow up tomorrow but off the top of my head I don't believe you can auto correct and override the output dimensions that are shown in the dialog, which will ultimately be the dimensions of the frames that are sent to your plug-in for rendering.

 

Thanks,

Jamie

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jul 28, 2020 0
Explorer ,
Jul 29, 2020

Copy link to clipboard

Copied

Thank you for your reply, Jamie.

 

If I understand you correctly I'd have show a message box informing the user about the incompatible frame sizes and the user would have to correct it manually, right?

 

Unfortunately when using this code ...

static A_Err
My_OutputInfoChanged(AEIO_BasicData* basic_dataP, AEIO_OutSpecH outH)
{
	A_Err err = A_Err_NONE;

	AEGP_SuiteHandler suites(basic_dataP->pica_basicP);

	// Get frame dimensions
	A_long widthL = 0, heightL = 0;
	ERR(suites.IOOutSuite4()->AEGP_GetOutSpecDimensions(outH, &widthL, &heightL));
	
	if (widthL % 8 || heightL % 4)
		suites.UtilitySuite3()->AEGP_ReportInfo(basic_dataP->aegp_plug_id, "Invalid frame size!");

	return err;
};

 

 ... gets called a couple of times I get an exception in dvaui.dll.

 

  1. Is it actually safe in AEIO_OutputInfoChanged to show a modal message box?
  2. Did you find the time to check if it is possible to auto correct the frame dimensions?

 

Thanks,

Daniel

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jul 29, 2020 0
jgjerde1 LATEST
Adobe Employee ,
Jul 30, 2020

Copy link to clipboard

Copied

Hi Daniel,

 

1. Yes it should be safe to call, but since My_OutputInfoChanged can get called for other reasons perhaps you can keep track of the current width and height and only call AEGP_ReportInfo once and then only when the width or height actually changes.

2. Yes I have looked at this. You can change the dimensions of your output but you can't change the dimensions from what the user specifies in the OM settings dialog.

 

If you are still crashing feel free to send me a call stack in a DM.

 

Thanks,

Jamie

 

Thanks,

Jamie

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jul 30, 2020 0