\pdfoutput=1
\def\framed#1{\vrule\vbox{\hrule
      \hbox{#1}%
      \hrule}\vrule}
\def\himg{\framed{\pdfximage{test.png}\pdfrefximage\pdflastximage}}
\def\vimg{\framed{\vbox{\pdfximage{test.png}\pdfrefximage\pdflastximage}}}
\def\vr{\vrule width 1mm height 0.5mm depth 0.5mm}
\tt
TLT hlist: \himg\par
TRT hlist: {\textdir TRT\vr\himg}\par
TLT vlist: \vimg\par
TRT vlist: {\textdir TRT\vr\vimg}\par

\vfill\eject

BLB hlist: \himg\par
BRB hlist: {\textdir BRB\vr\himg}\par
BLB vlist: \vimg\par
BRB vlist: {\textdir BRB\vr\vimg}\par
\bye
