Partager via


CalculateVideoMemoryRequirements method of the Msvm_Synth3dVideoPool class

Calculates the amount of video memory required for a RemoteFX virtual machine.

Syntax

uint32 CalculateVideoMemoryRequirements(
  [in]  uint32 monitorResolution,
  [in]  uint32 numberOfMonitors,
  [out] uint64 requiredVideoMemory
);

Parameters

monitorResolution [in]

The maximum monitor resolution for the virtual machine. This must be one of the following values.

Value Meaning
0
The maximum resolution is 1024 768.
1
The maximum resolution is 1280 1024.
2
The maximum resolution is 1600 1200.
3
The maximum resolution is 1920 1200.

numberOfMonitors [in]

The maximum number of monitors for the virtual machine. The minimum number of monitors is one and the maximum is dependent upon the maximum screen resolution. The following table defines the maximum number of monitors allowed for different resolutions.

Resolution Maximum monitors
1024 768
4
1280 1024
4
1600 1200
3
1920 1200
2

requiredVideoMemory [out]

Receives the required amount of video memory, in bytes.

Return value

Returns a status code, which can be one of the following values.

Return code/value Description
Completed with No Error
0
Successful.
Method Parameters Checked - Job Started
4096
Job started.
Failed
32768
Failed.
Access Denied
32769
Access denied.
Not Supported
32770
Not supported.
Status is unknown
32771
Status is unknown.
Timeout
32772
Timeout.
Invalid parameter
32773
A parameter is not valid.
System is in used
32774
System is in use.
Invalid state for this operation
32775
The state is not valid for this operation.
Incorrect data type
32776
Incorrect data type.
System is not available
32777
System is not available.
Out of memory
32778
Out of memory.

Remarks

This method is typically called on the host system to determine if the host has enough available video memory to host a RemoteFX virtual machine. To do this, you compare the amount of video memory calculated by this method with the Msvm_PhysicalGPUInfo.AvailableVideoMemory property to determine if the host machine has enough available video memory. You can use this information to determine if a virtual machine can be moved to the host system.

Requirements

Minimum supported client
None supported
Minimum supported server
Windows Server 2008 R2 with SP1
End of client support
None supported
End of server support
Windows Server 2012
Namespace
Root\Virtualization
MOF
WindowsVirtualization.mof

See also

Msvm_PhysicalGPUInfo

Msvm_Synth3dVideoPool