<gh_stars>0
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%  To create image run: (for Windows use imgconvert)
%%
%%  convert -verbose -delay 50 -loop 0 -density 300 -resize 640x480 src/<NAME>.pdf images/<NAME>.gif
%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\documentclass[beamer,tikz,preview]{standalone}
%\documentclass{beamer}

%\setbeamertemplate{navigation symbols}{}
\usepackage{tikz}
\usepackage{color}

\tikzset{pics/.cd,
cube/.style args={#1/#2/#3/#4}{code={
\coordinate (O) at (0,0,0);
\coordinate (A) at (0,#2,0);
\coordinate (B) at (0,#2,#3);
\coordinate (C) at (0,0,#3);
\coordinate (D) at (#1,0,0);
\coordinate (E) at (#1,#2,0);
\coordinate (F) at (#1,#2,#3);
\coordinate (G) at (#1,0,#3);
\draw[black,fill=black!80] (O) -- (C) -- (G) -- (D) -- cycle;
\draw[black,fill=black!30] (O) -- (A) -- (E) -- (D) -- cycle;
\draw[black,fill=black!10] (O) -- (A) -- (B) -- (C) -- cycle;
\draw[black,fill=black!20,opacity=0.8] (D) -- (E) -- (F) -- (G) -- cycle;
\draw[black,fill=black!20,opacity=0.6] (C) -- (B) -- (F) -- (G) -- cycle;
\draw[black,fill=black!20,opacity=0.8] (A) -- (B) -- (F) -- (E) -- cycle;
\node at (0.5*#1,0.5*#2,0.5*#3) {#4};
}}}
\tikzset{pics/.cd,
ccube/.style args={#1/#2/#3/#4}{code={
\coordinate (O) at (0,0,0);
\coordinate (A) at (0,#2,0);
\coordinate (B) at (0,#2,#3);
\coordinate (C) at (0,0,#3);
\coordinate (D) at (#1,0,0);
\coordinate (E) at (#1,#2,0);
\coordinate (F) at (#1,#2,#3);
\coordinate (G) at (#1,0,#3);
\draw[black,fill=#4!80] (O) -- (C) -- (G) -- (D) -- cycle;
\draw[black,fill=#4!30] (O) -- (A) -- (E) -- (D) -- cycle;
\draw[black,fill=#4!10] (O) -- (A) -- (B) -- (C) -- cycle;
\draw[black,fill=#4!20,opacity=0.8] (D) -- (E) -- (F) -- (G) -- cycle;
\draw[black,fill=#4!20,opacity=0.6] (C) -- (B) -- (F) -- (G) -- cycle;
\draw[black,fill=#4!20,opacity=0.8] (A) -- (B) -- (F) -- (E) -- cycle;
%\node at (0.5*#1,0.5*#2,0.5*#3) {#4};
}}}
\tikzset{pics/.cd,
linecube/.style args={#1/#2/#3}{code={
\coordinate (O) at (0,0,0);
\coordinate (A) at (0,#2,0);
\coordinate (B) at (0,#2,#3);
\coordinate (C) at (0,0,#3);
\coordinate (D) at (#1,0,0);
\coordinate (E) at (#1,#2,0);
\coordinate (F) at (#1,#2,#3);
\coordinate (G) at (#1,0,#3);
\draw[black,dotted] (O) -- (C) -- (G) -- (D) -- cycle;
\draw[black,dotted] (O) -- (A) -- (E) -- (D) -- cycle;
\draw[black,dotted] (O) -- (A) -- (B) -- (C) -- cycle;
\draw[black,dotted] (D) -- (E) -- (F) -- (G) -- cycle;
\draw[black,dotted] (C) -- (B) -- (F) -- (G) -- cycle;
\draw[black,dotted] (A) -- (B) -- (F) -- (E) -- cycle;
%\node at (0.5*#1,0.5*#2,0.5*#3) {#4};
}}}

\tikzset{pics/.cd,
lwing/.style args={#1/#2/#3/#4}{code={
\coordinate (O) at ( 0, 0, 0);
\coordinate (A) at ( 0, 0,#3);
\coordinate (B) at ( 0,#2,#3);
\coordinate (C) at ( 0,#2, 0);
\draw[black,fill=red!20] (O) -- (A) -- (B) -- (C) -- cycle;
\node at (0,0.5*#2,0.5*#3) {#4};
}}}
\tikzset{pics/.cd,
mwing/.style args={#1/#2/#3/#4}{code={
\coordinate (O) at ( 0, 0, 0);
\coordinate (A) at (#1, 0, 0);
\coordinate (B) at (#1,#2, 0);
\coordinate (C) at ( 0,#2, 0);
\draw[black,fill=green!20] (O) -- (A) -- (B) -- (C) -- cycle;
\node at (0.5*#1,0.5*#2,0) {#4};
}}}
\tikzset{pics/.cd,
rwing/.style args={#1/#2/#3/#4}{code={
\coordinate (O) at ( 0, 0, 0);
\coordinate (A) at (#1, 0, 0);
\coordinate (B) at (#1, 0,#3);
\coordinate (C) at ( 0, 0,#3);
\draw[black,fill=blue!20] (O) -- (A) -- (B) -- (C) -- cycle;
\node at (0.5*#1,0,0.5*#3) {#4};
}}}

\begin{document}
\begin{frame}
\begin{tikzpicture}
    
    

        %
%
    \pic at (0,-2,0) {linecube={1/1/1}};
        \pic at (1,-2,0) {linecube={1/1/1}};
            \pic at (2,-2,0) {linecube={1/1/1}};
    \pic at (0,-1,0) {ccube={1/1/1/blue}};
        \pic at (1,-1,0) {linecube={1/1/1}};
            \pic at (2,-1,0) {linecube={1/1/1}};
    \pic at (0,0,0) {linecube={1/1/1}};
        \pic at (1,0,0) {ccube={1/1/1/blue}};
            \pic at (2,0,0) {linecube={1/1/1}};

    \pic at (0,0,1) {linecube={1/1/1}};
            \pic at (1,0,1) {linecube={1/1/1}};
                \pic at (2,0,1) {ccube={1/1/1/red}};
        \pic at (0,-1,1) {linecube={1/1/1}};
            \pic at (1,-1,1) {linecube={1/1/1}};
                \pic at (2,-1,1) {linecube={1/1/1}};
        \pic at (0,-2,1) {ccube={1/1/1/red}};
            \pic at (1,-2,1) {linecube={1/1/1}};
                \pic at (2,-2,1) {linecube={1/1/1}};
    \end{tikzpicture}
\end{frame}

\end{document}